Merge branch 'main-cq'

This commit is contained in:
FrancisHu 2024-05-14 09:22:01 +08:00
commit b9d9e240f2
5 changed files with 82 additions and 69 deletions

View File

@ -9,7 +9,7 @@
class="single-fetch" class="single-fetch"
v-for="(fetch, index) in fetchMaterialList" v-for="(fetch, index) in fetchMaterialList"
:key="index" :key="index"
@click="optionClick($event, fetch.id)" @click="optionClick($event, fetch.id, fetch.modelId)"
> >
<view class="fetch-upper"> <view class="fetch-upper">
<!-- {{ fetch.taskStatus }} --> <!-- {{ fetch.taskStatus }} -->
@ -124,10 +124,10 @@ import { basePath } from '../../public'
} }
}, },
methods: { methods: {
optionClick (e, id) { optionClick (e, id, modelId) {
console.log(id); console.log(id);
uni.navigateTo({ uni.navigateTo({
url: `/pages/seeBackMaterialDetail/seeBackMaterialDetail?id=${id}` url: `/pages/seeBackMaterialDetail/seeBackMaterialDetail?id=${id}&typeId=${modelId}`
}) })
}, },
seeDetail (item) { seeDetail (item) {

View File

@ -91,13 +91,15 @@
<uni-icons <uni-icons
style="color: #AAAAAA; font-weight: bold;" style="color: #AAAAAA; font-weight: bold;"
type="closeempty" type="closeempty"
size="32"
@click="closePopup" @click="closePopup"
> >
</uni-icons> </uni-icons>
</view> </view>
<h4 style="width: 85%; margin: 2vh auto; font-weight: normal; text-align: center;">是否通过审批</h4>
<view class="select-area"> <view class="select-area">
<uni-forms ref="examForm" :modelValue="examFormData" :rules="rules" label-position="top"> <view @click="modalConfirm">通过</view>
<view @click="modalReject">驳回</view>
<!-- <uni-forms ref="examForm" :modelValue="examFormData" :rules="rules" label-position="top">
<uni-forms-item name="ifPass" required label="是否通过" label-width="150"> <uni-forms-item name="ifPass" required label="是否通过" label-width="150">
<uni-data-select <uni-data-select
v-model="examFormData.ifPass" v-model="examFormData.ifPass"
@ -110,7 +112,7 @@
<uni-easyinput type="textarea" v-model="examFormData.noPassReason" placeholder="请输入内容"></uni-easyinput> <uni-easyinput type="textarea" v-model="examFormData.noPassReason" placeholder="请输入内容"></uni-easyinput>
</uni-forms-item> </uni-forms-item>
<button class="submit-btn" @click="formSubmit">确认</button> <button class="submit-btn" @click="formSubmit">确认</button>
</uni-forms> </uni-forms> -->
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@ -208,7 +210,8 @@
for (let i = 0; i < that.taskIdList.length; i++) { for (let i = 0; i < that.taskIdList.length; i++) {
that.subArr.push(that.taskIdList[i].taskId) that.subArr.push(that.taskIdList[i].taskId)
} }
uni.showModal({ that.openPopup()
/* uni.showModal({
title: '审核通过', title: '审核通过',
content: '确认审核通过吗?', content: '确认审核通过吗?',
confirmText: '通过', confirmText: '通过',
@ -222,7 +225,7 @@
that.subInStore(that.subObj) that.subInStore(that.subObj)
} }
} }
}) }) */
} }
}, },
subInStore (obj) { subInStore (obj) {
@ -235,9 +238,7 @@
icon: 'none', icon: 'none',
title: res.data.msg, title: res.data.msg,
success: () => { success: () => {
/* uni.redirectTo({ that.closePopup()
url: '/pages/repairTestInStore/repairTestInStore'
}) */
uni.redirectTo({ uni.redirectTo({
url: '/pages/crashExam/crashExam' url: '/pages/crashExam/crashExam'
}) })
@ -251,12 +252,29 @@
} }
}) })
}, },
openPopup () {
this.$refs.popup.open()
},
closePopup () { closePopup () {
this.$refs.popup.close() this.$refs.popup.close()
}, },
seeExam (name) { modalConfirm () {
console.log(name); let that = this
this.$refs.popup.open() that.subObj = {
checkResult: '通过',
taskIdList: that.taskIdList
}
console.log(that.subObj);
that.subInStore(that.subObj)
},
modalReject () {
let that = this
that.subObj = {
checkResult: '驳回',
taskIdList: that.taskIdList
}
console.log(that.subObj);
that.subInStore(that.subObj)
}, },
formSubmit () { formSubmit () {
let that = this let that = this
@ -454,7 +472,7 @@
} }
.popup{ .popup{
width: 80vw; width: 80vw;
height: 60vh; height: 20vh;
background-color: #fff; background-color: #fff;
border-radius: 15rpx; border-radius: 15rpx;
overflow: hidden; overflow: hidden;
@ -471,9 +489,16 @@
.select-area{ .select-area{
width: 85%; width: 85%;
margin: 40rpx auto; margin: 40rpx auto;
.submit-btn{ display: flex;
background-color: #409EFF; justify-content: space-around;
align-items: center;
view{
box-sizing: border-box;
font-size: 30rpx;
padding: 12rpx 24rpx;
background-color: #3788FF;
color: #fff; color: #fff;
border-radius: 20rpx;
} }
} }
} }

View File

@ -201,43 +201,6 @@
}) })
} }
/* if (!this.lowerIpt.passedNum && !this.lowerIpt.waitRepairNum && !this.lowerIpt.waitCrashNum) {
uni.showToast({
icon: 'none',
title: '请至少填写一个数据!'
})
return
}
that.totalNum = Number(that.lowerIpt.passedNum) + Number(that.lowerIpt.waitRepairNum) + Number(that
.lowerIpt.waitCrashNum)
console.log(that.totalNum);
if (that.totalNum > that.upperInfo.num) {
uni.showToast({
icon: 'none',
title: '接收总量不能大于退库数量!'
})
} else if (that.totalNum == 0) {
uni.showToast({
icon: 'none',
title: '请确保退料总量不为0'
})
} else {
console.log(this.handleSubmitData());
that.$api.backMaterialReceive.backMaterialSetNumBack({
taskId: this.upperInfo.taskId,
arr: this.handleSubmitData()
}).then(res => {
console.log("res===", res)
uni.showToast({
icon: 'none',
title: '接收成功'
})
setTimeout(() => {
uni.navigateBack()
},
300)
})
} */
}, },
handleSubmitData() { handleSubmitData() {
let list = [] let list = []

View File

@ -49,7 +49,7 @@
}, },
onLoad(params) { onLoad(params) {
let that = this let that = this
console.log(params.id); console.log(params.id, params.typeId);
// 退 // 退
that.$api.backMaterialReceive.seeBackMaterialDetail({ that.$api.backMaterialReceive.seeBackMaterialDetail({
parentId: params.id parentId: params.id

View File

@ -87,13 +87,15 @@
<uni-icons <uni-icons
style="color: #AAAAAA; font-weight: bold;" style="color: #AAAAAA; font-weight: bold;"
type="closeempty" type="closeempty"
size="32"
@click="closePopup" @click="closePopup"
> >
</uni-icons> </uni-icons>
</view> </view>
<h4 style="width: 85%; margin: 2vh auto; font-weight: normal; text-align: center;">是否通过审批</h4>
<view class="select-area"> <view class="select-area">
<uni-forms ref="examForm" :modelValue="examFormData" :rules="rules" label-position="top"> <view @click="modalConfirm">通过</view>
<view @click="modalReject">驳回</view>
<!-- <uni-forms ref="examForm" :modelValue="examFormData" :rules="rules" label-position="top">
<uni-forms-item name="ifPass" required label="是否通过" label-width="150"> <uni-forms-item name="ifPass" required label="是否通过" label-width="150">
<uni-data-select <uni-data-select
v-model="examFormData.ifPass" v-model="examFormData.ifPass"
@ -106,7 +108,7 @@
<uni-easyinput type="textarea" v-model="examFormData.noPassReason" placeholder="请输入内容"></uni-easyinput> <uni-easyinput type="textarea" v-model="examFormData.noPassReason" placeholder="请输入内容"></uni-easyinput>
</uni-forms-item> </uni-forms-item>
<button class="submit-btn" @click="formSubmit">确认</button> <button class="submit-btn" @click="formSubmit">确认</button>
</uni-forms> </uni-forms> -->
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@ -204,7 +206,8 @@
for (let i = 0; i < that.taskIdList.length; i++) { for (let i = 0; i < that.taskIdList.length; i++) {
that.subArr.push(that.taskIdList[i].taskId) that.subArr.push(that.taskIdList[i].taskId)
} }
uni.showModal({ that.openPopup()
/* uni.showModal({
title: '审核通过', title: '审核通过',
content: '确认审核通过吗?', content: '确认审核通过吗?',
confirmText: '通过', confirmText: '通过',
@ -218,7 +221,7 @@
that.subInStore(that.subObj) that.subInStore(that.subObj)
} }
} }
}) }) */
} }
}, },
subInStore (obj) { subInStore (obj) {
@ -231,9 +234,7 @@
icon: 'none', icon: 'none',
title: res.data.msg, title: res.data.msg,
success: () => { success: () => {
/* uni.redirectTo({ that.closePopup()
url: '/pages/repairTestInStore/repairTestInStore'
}) */
uni.redirectTo({ uni.redirectTo({
url: '/pages/testExam/testExam' url: '/pages/testExam/testExam'
}) })
@ -247,12 +248,29 @@
} }
}) })
}, },
openPopup () {
this.$refs.popup.open()
},
closePopup () { closePopup () {
this.$refs.popup.close() this.$refs.popup.close()
}, },
seeExam (name) { modalConfirm () {
console.log(name); let that = this
this.$refs.popup.open() that.subObj = {
checkResult: '通过',
taskIdList: that.subArr
}
console.log(that.subObj);
that.subInStore(that.subObj)
},
modalReject () {
let that = this
that.subObj = {
checkResult: '驳回',
taskIdList: that.taskIdList
}
console.log(that.subObj);
that.subInStore(that.subObj)
}, },
formSubmit () { formSubmit () {
let that = this let that = this
@ -450,7 +468,7 @@
} }
.popup{ .popup{
width: 80vw; width: 80vw;
height: 60vh; height: 20vh;
background-color: #fff; background-color: #fff;
border-radius: 15rpx; border-radius: 15rpx;
overflow: hidden; overflow: hidden;
@ -467,9 +485,16 @@
.select-area{ .select-area{
width: 85%; width: 85%;
margin: 40rpx auto; margin: 40rpx auto;
.submit-btn{ display: flex;
background-color: #409EFF; justify-content: space-around;
align-items: center;
view{
box-sizing: border-box;
font-size: 30rpx;
padding: 12rpx 24rpx;
background-color: #3788FF;
color: #fff; color: #fff;
border-radius: 20rpx;
} }
} }
} }