| | |
| | | |
| | | |
| | | <view v-show="topContent.length!==0"> |
| | | <view class="mainContent" :style="{maxHeight:'1000rpx',overflow: 'scroll'}"> |
| | | <view class="mainContent" :style="{maxHeight:'1360rpx',overflow: 'scroll'}"> |
| | | |
| | | <view> |
| | | <u-gap height="10" bgColor="#eff0f1"></u-gap> |
| | |
| | | </view> |
| | | |
| | | <view class="marginRight20"> |
| | | <u-icon name="scan" @click="topScanClick" color="red" size="56"></u-icon> |
| | | <u-icon name="scan" @click="topScanClick" color="red" size="28"></u-icon> |
| | | </view> |
| | | |
| | | </view> |
| | |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <u-radio size='40' style='position: absolute;top: 45%;right: 0;' |
| | | <u-radio size='20' style='position: absolute;top: 45%;right: 0;' |
| | | :key="item.docu_code" :name="item.docu_code" |
| | | @change="groupChange(item.docu_code)" activeColor="red"></u-radio> |
| | | |
| | |
| | | </view> |
| | | |
| | | </view> |
| | | <u-gap height="20" bgColor="#eff0f1"></u-gap> |
| | | <u-gap height="10" bgColor="#eff0f1"></u-gap> |
| | | |
| | | <view class="head" style="padding-bottom: 10rpx;"> |
| | | <view class="head_block" style="margin-bottom: 10rpx;margin-top:20rpx;"> |
| | |
| | | </view> |
| | | </view> |
| | | <view class='inputClass contentFont' style="margin: 0 20rpx; width: 95%;"> |
| | | <u--textarea placeholder="请输入" confirm-type="send" border="surround" height='100' |
| | | <u--textarea placeholder="请输入" confirm-type="send" border="surround" height='80' |
| | | v-model="descMessage"> |
| | | </u--textarea> |
| | | </view> |
| | |
| | | <view style="display: flex;"> |
| | | <view v-for="(pic,index) in fileList" :key="pic.name"> |
| | | <view style="margin: 20rpx 0rpx 20rpx 20rpx;position: relative;"> |
| | | <u-icon name="close" color="#fff" size="26" |
| | | <u-icon name="close" color="#fff" size="13" |
| | | style="position: absolute;z-index: 10;right: 0;background-color: black;border-radius:50%;" |
| | | @click="deletePic(pic)"></u-icon> |
| | | |
| | |
| | | </view> |
| | | |
| | | |
| | | <u-gap height="20" bgColor="#eff0f1"></u-gap> |
| | | <u-gap height="10" bgColor="#eff0f1"></u-gap> |
| | | |
| | | <view class="head" style="padding-bottom: 10rpx;"> |
| | | <view class="head_block" style="margin-bottom: 10rpx;margin-top:20rpx;"> |
| | |
| | | </view> |
| | | </view> |
| | | |
| | | <view class="marginRight20" style="width: 200rpx;display: flex;"> |
| | | <u-button type="primary" :plain="isStop!=='Y'" text="是" @click="isStopClick('Y')"> |
| | | <view class="marginRight20" style="width: 200rpx;display: flex;align-items: center;"> |
| | | <u-button type="primary" :plain="isStop!=='Y'" style="height: 60rpx;" text="是" |
| | | @click="isStopClick('Y')"> |
| | | </u-button> |
| | | <u-button type="warning" :plain="isStop!=='N'" text="否" @click="isStopClick('N')"> |
| | | <u-button type="warning" :plain="isStop!=='N'" style="height: 60rpx;margin: 0 5rpx;" |
| | | text="否" @click="isStopClick('N')"> |
| | | </u-button> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | |
| | | <u-gap height="20" bgColor="#eff0f1"></u-gap> |
| | | <u-gap height="10" bgColor="#eff0f1"></u-gap> |
| | | |
| | | <view v-show="isStop==='N'" class="head" style="padding-bottom: 10rpx;padding-bottom: 20rpx;"> |
| | | <view class="head_block" style="margin-bottom: 10rpx;margin-top:20rpx;"> |
| | |
| | | </view> |
| | | </view> |
| | | <view class='inputClass contentFont' style="margin: 0 20rpx; width: 95%;"> |
| | | <u--textarea placeholder="请输入" confirm-type="send" border="surround" height='100' |
| | | <u--textarea placeholder="请输入" confirm-type="send" border="surround" height='80' |
| | | v-model="descMessage2"> |
| | | </u--textarea> |
| | | </view> |
| | | |
| | | </view> |
| | | |
| | | <u-gap height="20" bgColor="#eff0f1"></u-gap> |
| | | <u-gap height="10" bgColor="#eff0f1"></u-gap> |
| | | <!-- margin-bottom: 110rpx; --> |
| | | <view v-show="isStop==='N'" class="head" style="padding-bottom: 10rpx;"> |
| | | <view class="head_block" style="margin-bottom: 10rpx;margin-top:20rpx;"> |
| | |
| | | </view> |
| | | </view> |
| | | <view class='inputClass contentFont' style="margin: 0 20rpx; width: 95%;"> |
| | | <u--textarea placeholder="请输入" confirm-type="send" border="surround" height='100' |
| | | <u--textarea placeholder="请输入" confirm-type="send" border="surround" height='80' |
| | | v-model="descMessage3"> |
| | | </u--textarea> |
| | | </view> |
| | |
| | | <view style="display: flex;"> |
| | | <view v-for="(pic,index) in fileList2" :key="pic.name"> |
| | | <view style="margin: 20rpx 0rpx 20rpx 20rpx;position: relative;"> |
| | | <u-icon name="close" color="#fff" size="26" |
| | | <u-icon name="close" color="#fff" size="13" |
| | | style="position: absolute;z-index: 10;right: 0;background-color: black;border-radius:50%;" |
| | | @click="deletePic(pic)"></u-icon> |
| | | |
| | |
| | | for (let i = 0; i < files.length; i++) { |
| | | let obj = new Object(); |
| | | obj.name = 'files1;' + i + new Date().getTime(); |
| | | // obj.files1 = i + new Date().getTime(); |
| | | obj.uri = files[i].path; |
| | | that.fileList.push(obj); |
| | | if (obj.src == null || obj.src == '' || obj.src == undefined) { |
| | |
| | | for (let i = 0; i < files.length; i++) { |
| | | let obj = new Object(); |
| | | obj.name = 'files2;' + i + new Date().getTime(); |
| | | // obj.files2 = i + new Date().getTime(); |
| | | obj.uri = files[i].path; |
| | | that.fileList2.push(obj); |
| | | if (obj.src == null || obj.src == '' || obj.src == undefined) { |
| | |
| | | // 确认提交按钮 |
| | | async submit() { |
| | | const header = { |
| | | // 'Content-Type': 'multipart/form-data', |
| | | 'Content-Type': 'application/x-www-form-urlencoded', |
| | | 'rediskey': uni.getStorageSync('rediskey'), |
| | | 'admin': uni.getStorageSync('usercode'), |
| | | 'username': encodeURIComponent(uni.getStorageSync('username')), |
| | | 'navTabId': uni.getStorageSync('usercode'), |
| | | 'userid': uni.getStorageSync('userid'), |
| | | 'guid': uni.getStorageSync('guid'), |
| | | 'usertype': 'APP' |
| | | 'Content-Type': 'multipart/form-data', |
| | | 'Token': uni.getStorageSync('Token') |
| | | } |
| | | |
| | | const result = this.topContent.find(item => item.docu_code === this.radioValue) |
| | | const formData = { |
| | | username: uni.getStorageSync('username'), |
| | | // username: uni.getStorageSync('username'), |
| | | docu_code: result.docu_code, |
| | | eqpcode: result.eqpcode, |
| | | wkshpcode: result.wksp_code, |
| | | faultdescr: this.descMessage, |
| | | is_stoprepair: this.isStop, |
| | | // files1: this.fileList, |
| | | filse1: this.fileList.map(i => i.uri).join(','), |
| | | filse2: this.fileList2.map(i => i.uri).join(','), |
| | | repaircontent: this.descMessage2, |
| | | replaceparts: this.descMessage3 |
| | | } |
| | | // console.log(formData) |
| | | // console.log([...this.fileList, ...this.fileList2].length) |
| | | console.log(formData, 123) |
| | | console.log([...this.fileList, ...this.fileList2]) |
| | | this.isDisabledSubmitButton = true |
| | | uni.uploadFile({ |
| | | url: this.$baseUrl + '/AppDeviceManage/RepairScanDeviceSave', |
| | | url: this.$baseUrl + '/DeviceManager/RepairScanDeviceSave', |
| | | files: [...this.fileList, ...this.fileList2].length === 0 ? [{ |
| | | "uri": "/" |
| | | }] : [...this.fileList, ...this.fileList2], |
| | | name: 'files', |
| | | header: header, |
| | | formData: formData, |
| | | success: (res) => { |
| | | console.log(res) |
| | | console.log(res, 'res') |
| | | let result = JSON.parse(res.data) |
| | | if (res.statusCode == 200 && result.code == '200') { |
| | | uni.$u.toast('提交成功!') |
| | |
| | | this.isDisabledSubmitButton = false |
| | | }, |
| | | fail(res) { |
| | | console.log(res, 'res2') |
| | | uni.$u.toast('提交失败!') |
| | | this.isDisabledSubmitButton = false |
| | | }, |