diff --git a/src/pages/back/backCode.vue b/src/pages/back/backCode.vue index dd5254c..113e362 100644 --- a/src/pages/back/backCode.vue +++ b/src/pages/back/backCode.vue @@ -915,12 +915,12 @@ onLoad((options) => { } } .top-content { - max-height: 30px; + height: 30px; overflow: hidden; transition: max-height 0.5s ease-out; &.is-expanded { - max-height: 2000px !important; + height: auto !important; } } diff --git a/src/pages/back/backNum.vue b/src/pages/back/backNum.vue index e13c641..4cf49bf 100644 --- a/src/pages/back/backNum.vue +++ b/src/pages/back/backNum.vue @@ -573,12 +573,12 @@ onLoad((options)=>{ } } .top-content { - max-height: 30px; + height: 30px; overflow: hidden; transition: max-height 0.5s ease-out; &.is-expanded { - max-height: 800px; + height: auto; } } diff --git a/src/pages/picking/outbound/code-outbound.vue b/src/pages/picking/outbound/code-outbound.vue index 3a424dc..97e3786 100644 --- a/src/pages/picking/outbound/code-outbound.vue +++ b/src/pages/picking/outbound/code-outbound.vue @@ -222,7 +222,7 @@ const isWithinOneMonth = (dateStr) => { const diffTime = inputDate.getTime() - today.getTime() const diffDays = diffTime / (1000 * 60 * 60 * 24) - return diffDays <= 30 + return diffDays <= 90 } // 获取编码列表 diff --git a/src/pages/repair/repairManage/batch-repair.vue b/src/pages/repair/repairManage/batch-repair.vue index 257a26a..dcf94aa 100644 --- a/src/pages/repair/repairManage/batch-repair.vue +++ b/src/pages/repair/repairManage/batch-repair.vue @@ -20,20 +20,24 @@ >{{ selectedCodesDisplay }} + + 维修人员: + + + + + + + 提交 + + - - - 提交 - - - - - + @@ -101,6 +105,20 @@ + + + + +
+
+
+ +
+
+
@@ -212,7 +230,8 @@ const remark = ref('') //备注 const imgBeseUrl = ref('') //图片展示 const bmFileInfos = ref([]) //图片数组 //上传 -const uploadImg = () => { +const uploadImg = (item) => { + console.log('🚀 ~ uploadImg ~ item:', item) uni.chooseImage({ count: 1, //图片可选择数量 sizeType: ['original', 'compressed'], //original 原图,compressed 压缩图,默认二者都有 @@ -220,7 +239,7 @@ const uploadImg = () => { success: (res) => { console.log(res) let imgFiles = res.tempFilePaths //图片的本地文件路径列表 - imgBeseUrl.value = imgFiles[0] + item.imgBeseUrl = imgFiles[0] // console.log('请求地址', baseURL+"/file/upload") uni.uploadFile({ // url: baseURL+"/file/upload",//app @@ -236,11 +255,11 @@ const uploadImg = () => { name: res.data.name, url: res.data.url, } - bmFileInfos.value = [obj] - console.log('上传成功', bmFileInfos.value) + item.bmFileInfos = [obj] + console.log('上传成功', item) uni.showToast({ title: '上传成功', icon: 'none' }) } else { - bmFileInfos.value = [] + item.bmFileInfos = [] uni.showToast({ title: '上传失败', icon: 'none' }) } }, @@ -286,7 +305,7 @@ const partTreeChange = (val, index) => { } //内部维修 -const partItems = ref([{ partNum: '', partType: 0, partId: '', storageNum: '' }]) +const partItems = ref([{ partNum: '', partType: 0, partId: '', storageNum: '', remark: '', fileList: [] }]) const getPartItemData = async () => { console.log("bbbbbbbbbbbbbbbbb",queryParams.value.ids) @@ -319,7 +338,7 @@ const getPartItemData = async () => { const addPart = () => { - partItems.value.push({ partNum: '', partType: 0, partId: '', storageNum: '' }) + partItems.value.push({ partNum: '', partType: 0, partId: '', storageNum: '', remark: '', fileList: [] }) } const delPart = (index) => { if (partItems.value.length > 1) { @@ -413,8 +432,8 @@ const saveCodeApi = async () => { rowData.value.repairDeviceList[i].repairList = [ { repairer: repairPerson.value, - remark: remark.value, - fileList: bmFileInfos.value, + // remark: remark.value, + // fileList: bmFileInfos.value, }, ] // 初始化配件列表数组(如果不存在) @@ -428,6 +447,8 @@ const saveCodeApi = async () => { partId: partItems.value[j].partId, partNum: partItems.value[j].partNum, storageNum: partItems.value[j].storageNum, + remark: partItems.value[j].remark, + fileList: partItems.value[j].bmFileInfos, }) } @@ -437,6 +458,9 @@ const saveCodeApi = async () => { // console.log('🚀 ~ saveCodeApi ~ 提交:', rowData.value.repairDeviceList) const params = rowData.value.repairDeviceList.filter(item => queryParams.value.selectedCodes.includes(item.code)) console.log('🚀 ~ saveCodeApi ~ params:', params) + uni.showLoading({ + title: '提交中...', + }); saveRepairRow(params).then(async (response) => { if (response.code == 200) { uni.showToast({ title: '保存成功', icon: 'none' }) @@ -445,8 +469,10 @@ const saveCodeApi = async () => { }) } loading.value = false + uni.hideLoading() }).catch(() => { loading.value = false + uni.hideLoading() }) } @@ -549,11 +575,12 @@ const saveCodeApi = async () => { margin-bottom: 24rpx; position: relative; padding-left: 24rpx; + margin-left: 10px; &::before { content: ''; position: absolute; - left: 0; + left: -10px; top: 50%; transform: translateY(-50%); width: 6rpx; @@ -630,11 +657,11 @@ const saveCodeApi = async () => { // 操作按钮组 .search-form { - margin-bottom: 24rpx; + /* margin-bottom: 24rpx; background: #fff !important; border-radius: 20rpx !important; padding: 24rpx !important; - box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.06); + box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.06); */ .btnBox { height: 88rpx; diff --git a/src/pages/repair/repairManage/code-operate.vue b/src/pages/repair/repairManage/code-operate.vue index f915e85..72095d4 100644 --- a/src/pages/repair/repairManage/code-operate.vue +++ b/src/pages/repair/repairManage/code-operate.vue @@ -20,29 +20,33 @@ >{{ queryParams.repairDeviceList[rowIndex].code }} + + 维修人员: + + + + + + + 内部维修 + + + 返厂维修 + + + 待报废 + + + 提交 + +
- - - 内部维修 - - - 返厂维修 - - - 待报废 - - - 提交 - - - - - + @@ -111,6 +115,20 @@ + + + + +
+
+
+ +
+
+
@@ -166,6 +184,20 @@ + + + + +
+
+
+ +
+
+
@@ -218,6 +250,7 @@ +
@@ -324,7 +357,7 @@ const remark = ref('') //备注 const imgBeseUrl = ref('') //图片展示 const bmFileInfos = ref([]) //图片数组 //上传 -const uploadImg = () => { +const uploadImg = (item) => { uni.chooseImage({ count: 1, //图片可选择数量 sizeType: ['original', 'compressed'], //original 原图,compressed 压缩图,默认二者都有 @@ -332,7 +365,7 @@ const uploadImg = () => { success: (res) => { console.log(res) let imgFiles = res.tempFilePaths //图片的本地文件路径列表 - imgBeseUrl.value = imgFiles[0] + item.imgBeseUrl = imgFiles[0] // console.log('请求地址', baseURL+"/file/upload") uni.uploadFile({ // url: baseURL+"/file/upload",//app @@ -348,11 +381,11 @@ const uploadImg = () => { name: res.data.name, url: res.data.url, } - bmFileInfos.value = [obj] - console.log('上传成功', bmFileInfos.value) + item.bmFileInfos = [obj] + console.log('上传成功', item) uni.showToast({ title: '上传成功', icon: 'none' }) } else { - bmFileInfos.value = [] + item.bmFileInfos = [] uni.showToast({ title: '上传失败', icon: 'none' }) } }, @@ -397,7 +430,7 @@ const partTreeChange = (val, index) => { } //内部维修 -const partItems = ref([{ partNum: '', partType: 1, partId: '', storageNum: ''}]) +const partItems = ref([{ partNum: '', partType: 1, partId: '', storageNum: '', remark: '', fileList: [] }]) const getPartItemData = async () => { console.log("bbbbbbbbbbbbbbbbb",queryParams.value.ids) @@ -427,7 +460,7 @@ const getPartItemData = async () => { } } const addPart = () => { - partItems.value.push({ partNum: '', partType: 1, partId: '', storageNum: '' }) + partItems.value.push({ partNum: '', partType: 1, partId: '', storageNum: '', remark: '', fileList: [] }) } const delPart = (index) => { if (partItems.value.length > 1) { @@ -453,7 +486,7 @@ const getSupplierListData = async () => { } getSupplierListData() const partItemsMiddle = ref([ - { partName: '', supplierId: '', partNum: 0, partPrice: 0, partType: 1 }, + { partName: '', supplierId: '', partNum: 0, partPrice: 0, partType: 1, remark: '', fileList: [] }, ]) const addMidPart = () => { partItemsMiddle.value.push({ @@ -462,6 +495,8 @@ const addMidPart = () => { partNum: 0, partPrice: 0, partType: 1, + remark: '', + fileList: [], }) } const delMidPart = (index) => { @@ -624,10 +659,13 @@ const saveCodeApi = async () => { rowData.value.repairDeviceList[rowIndex.value].repairList = [ { repairer: repairPerson.value, - remark: remark.value, - fileList: bmFileInfos.value, + // remark: remark.value, + // fileList: bmFileInfos.value, }, ] + rowData.value.repairDeviceList[rowIndex.value].codeInRepairPartList = [] + rowData.value.repairDeviceList[rowIndex.value].codeOutRepairPartList = [] + rowData.value.repairDeviceList[rowIndex.value].codeScrapRepairPartList = [] if (repairType.value == 1) { for (let i = 0; i < partItems.value.length; i++) { rowData.value.repairDeviceList[rowIndex.value].codeInRepairPartList.push({ @@ -635,6 +673,8 @@ const saveCodeApi = async () => { partId: partItems.value[i].partId, partNum: partItems.value[i].partNum, storageNum: partItems.value[i].storageNum, + remark: partItems.value[i].remark, + fileList: partItems.value[i].bmFileInfos, // repairNum: formLeft.value.repairNum, }) } @@ -646,6 +686,8 @@ const saveCodeApi = async () => { partNum: partItemsMiddle.value[i].partNum, partName: partItemsMiddle.value[i].partName, supplierId: partItemsMiddle.value[i].supplierId, + remark: partItemsMiddle.value[i].remark, + fileList: partItemsMiddle.value[i].bmFileInfos, // repairNum: formMiddle.value.repairNum, }) } @@ -654,6 +696,7 @@ const saveCodeApi = async () => { } rowData.value.repairDeviceList[rowIndex.value].repairType = repairType.value console.log(rowData.value.repairDeviceList) + uni.showLoading({ title: '提交中...' }) saveRepairRow(rowData.value.repairDeviceList).then(async (response) => { if (response.code == 200) { uni.showToast({ title: '保存成功', icon: 'none' }) @@ -661,6 +704,10 @@ const saveCodeApi = async () => { delta: 2, // 返回到已存在的页面 }) } + }).catch((error) => { + console.log(error) + }).finally(() => { + uni.hideLoading() }) } @@ -763,11 +810,12 @@ const saveCodeApi = async () => { margin-bottom: 24rpx; position: relative; padding-left: 24rpx; + margin-left: 10px; &::before { content: ''; position: absolute; - left: 0; + left: -10px; top: 50%; transform: translateY(-50%); width: 6rpx; @@ -844,11 +892,11 @@ const saveCodeApi = async () => { // 操作按钮组 .search-form { - margin-bottom: 24rpx; - background: #fff !important; - border-radius: 20rpx !important; - padding: 24rpx !important; - box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.06); + // margin-bottom: 24rpx; + // background: #fff !important; + // border-radius: 20rpx !important; + // padding: 24rpx !important; + // box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.06); .btnBox { height: 88rpx; diff --git a/src/pages/repair/repairManage/details.vue b/src/pages/repair/repairManage/details.vue index 9900299..ca9328a 100644 --- a/src/pages/repair/repairManage/details.vue +++ b/src/pages/repair/repairManage/details.vue @@ -47,7 +47,7 @@ @tap="onRepairItem(item)" >
- 维修任务 + {{ item.typeName + ' ' + item.type }}
@@ -63,25 +63,25 @@ - 物资名称: + 退料数量: - {{ item.typeName }} + {{ item.typeRepairNum }} - + + {{ index + 1 }} 已修数量: @@ -103,14 +103,14 @@ {{ Number(item.typeRepairNum)-Number(item.typeRepairedNum)-Number(item.typeScrapNum) }} - + +
diff --git a/src/pages/repair/repairManage/num-operate.vue b/src/pages/repair/repairManage/num-operate.vue index e8f564e..f013860 100644 --- a/src/pages/repair/repairManage/num-operate.vue +++ b/src/pages/repair/repairManage/num-operate.vue @@ -1,13 +1,13 @@