| | |
| | | </template> |
| | | </up-cell> |
| | | <up-cell title="数量" :border='false' v-if="dakaList.workerType==1" > |
| | | <template #right-icon> |
| | | <up-input v-model="workCount" border="none" placeholder="请填写数量"></up-input> |
| | | <template #right-icon v-if="dakaList.isShenPiName!=='已结算'"> |
| | | <up-input v-model="dakaList.workCount" |
| | | @blur='(val) => {dakaList.todaySalary=$util.roundToTwo(dakaList.workCount*dakaList.workPrice)}' |
| | | border="none" placeholder="请填写数量"></up-input> |
| | | </template> |
| | | <template #value v-else> |
| | | {{dakaList.workCount}} |
| | | </template> |
| | | </up-cell> |
| | | <up-cell title="工资" :border='false'> |
| | |
| | | <tem-steps></tem-steps> |
| | | </view> --> |
| | | <view class="tabbtns"> |
| | | <up-button color='#fece01' class="text-69" text="工资申报" @click="saveDakaDetail"></up-button> |
| | | <up-button color='#fece01' class="text-69" text="工资申报" v-if="dakaList.isShenPiName!=='已结算'" @click="saveDakaDetail"></up-button> |
| | | </view> |
| | | </view> |
| | | </view> |
| | |
| | | orderBiddingDetailId: id |
| | | }).then(res => { |
| | | this.dakaList = res.data |
| | | this.dakaList.workCount = res.data.workCount |
| | | if (this.dakaList.orderBiddingDetailCheck.length == 0) { |
| | | this.dakaList.orderBiddingDetailCheck.length = 2 |
| | | } |
| | |
| | | }) |
| | | }, |
| | | saveDakaDetail() { |
| | | if (dakaList.workerType == 1 && this.workCount) { |
| | | if (this.dakaList.workerType == 1 && !this.dakaList.workCount) { |
| | | this.$util.showToast({ |
| | | title: '请填写数量!', |
| | | icon: 'error' |
| | |
| | | return |
| | | } |
| | | let obj = { |
| | | orderBiddingDetailId: dakaList.orderBiddingDetailId, //招工打卡Id |
| | | workTime: dakaList.workTime, //工作时长 |
| | | todaySalary: dakaList.todaySalary //当日工资 |
| | | orderBiddingDetailId: this.dakaList.orderBiddingDetailId, //招工打卡Id |
| | | workTime: this.dakaList.workTime, //工作时长 |
| | | todaySalary: this.dakaList.todaySalary //当日工资 |
| | | } |
| | | if (this.workCount) { |
| | | obj.workCount = this.workCount |
| | | if (this.dakaList.workCount) { |
| | | obj.workCount = this.dakaList.workCount |
| | | } |
| | | this.$api.saveDakaDetail(obj).then(res => { |
| | | if(res.code==1){ |
| | | this.$util.showToast({ |
| | | title: '申报成功!', |
| | | icon: 'success' |
| | | }) |
| | | } |
| | | console.log(res, '----'); |
| | | }) |
| | | }, |