| | |
| | | </up-list-item> |
| | | <view class="c-p-20"> |
| | | <view class="chuany-flex chuany-justify-between chuany-flex-wrap"> |
| | | <text class="chuany-font34"> |
| | | <text class="chuany-font32"> |
| | | {{dakaList.orderName}} |
| | | </text> |
| | | <text class=""> |
| | |
| | | </text> |
| | | </view> |
| | | </view> |
| | | <view class="c-p-20"> |
| | | <view class="c-p-l-20 c-p-r-20"> |
| | | <view class=""> |
| | | <text class=""> |
| | | 打卡记录: |
| | |
| | | <!-- <template #right-icon> |
| | | {{dakaList.workTime}} 小时 |
| | | </template> --> |
| | | <template #right-icon> |
| | | <template #right-icon v-if="dakaList.workerType!=1 && (dakaList.isShenPi!==2||dakaList.isModify)"> |
| | | <up-input v-model="dakaList.workTime" type="digit" |
| | | @change='(val) => {dakaList.todaySalary=$util.roundToTwo(val*dakaList.workPrice)}' |
| | | border="none" placeholder="请填写时长"></up-input> |
| | | </template> |
| | | <!-- <template #value v-else> |
| | | <template #value v-else> |
| | | {{dakaList.workTime}} 小时 |
| | | </template> --> |
| | | </template> |
| | | </up-cell> |
| | | <up-cell title="方式" :border='false'> |
| | | <template #right-icon> |
| | |
| | | </template> --> |
| | | </up-cell> |
| | | <up-cell title="数量" :border='false' v-if="dakaList.workerType==1"> |
| | | <template #right-icon> |
| | | <template #right-icon v-if="dakaList.isShenPiName!=='已结算'||isModify"> |
| | | <up-input v-model="dakaList.workCount" type="digit" |
| | | @blur='(val) => {dakaList.todaySalary=$util.roundToTwo(dakaList.workCount*dakaList.workPrice)}' |
| | | @change='(val) => {dakaList.todaySalary=$util.roundToTwo(val*dakaList.workPrice)}' |
| | | border="none" placeholder="请填写数量"></up-input> |
| | | </template> |
| | | <!-- <template #value v-else> |
| | | <template #value v-else> |
| | | {{dakaList.workCount}} |
| | | </template> --> |
| | | </template> |
| | | </up-cell> |
| | | <up-cell title="工资" :border='false'> |
| | | <!-- <template #right-icon> |
| | | {{dakaList.todaySalary}} 元 |
| | | </template> --> |
| | | <template #right-icon> |
| | | <up-input v-model="dakaList.todaySalary" type="digit" |
| | | border="none" placeholder="请填写工资"></up-input> |
| | | <template #right-icon v-if="dakaList.isShenPiName!=='已结算'||isModify"> |
| | | <up-input v-model="dakaList.todaySalary" type="digit" border="none" |
| | | placeholder="请填写工资"></up-input> |
| | | </template> |
| | | <!-- <template #value v-else> |
| | | <template #value v-else> |
| | | {{dakaList.todaySalary}} 元 |
| | | </template> --> |
| | | </template> |
| | | </up-cell> |
| | | <!-- <view class="stepwit"> |
| | | <tem-steps></tem-steps> |
| | | </view> --> |
| | | </up-list> |
| | | <view class="tabbtns"> |
| | | <up-button color='#fece01' class="text-69" :text="dakaList.isShenPiName!=='已结算'?'确认':'修改'" :loading='isLoading' loadingText="确认中" |
| | | :loadingText="dakaList.isShenPiName!=='已结算'?'确认中':'修改中'" @click="saveDakaDetailCompany"></up-button> |
| | | <view class="tabbtns" v-if="dakaList.isShenPiName!=='已结算'||isModify"> |
| | | <up-button color='#fece01' :text="dakaList.isShenPiName!=='已结算'?'核准工资':'修改'" |
| | | :loading='isLoading' :loadingText="dakaList.isShenPiName!=='已结算'?'核准中':'修改中'" |
| | | @click="saveDakaDetailCompany"></up-button> |
| | | </view> |
| | | </view> |
| | | </view> |
| | |
| | | orderBiddingDetailId: '', |
| | | dakaList: {}, |
| | | workCount: '', |
| | | confirmObj: { |
| | | orderBiddingDetailId: '', //招工打卡Id |
| | | workTime: '', //工作时长 |
| | | workCount: '', //计件数量 |
| | | todaySalary: '' //当日工资 |
| | | }, |
| | | workerInfo: '', |
| | | isLoading: false |
| | | } |
| | |
| | | onLoad(options) { |
| | | this.orderBiddingDetailId = options.id |
| | | this.getDakaDetail(this.orderBiddingDetailId) |
| | | }, |
| | | computed: { |
| | | isModify() { |
| | | return this.$util.minutesBetweenDates(this.dakaList.shenPitime, new Date()) <= 5 ? true : false |
| | | } |
| | | }, |
| | | methods: { |
| | | getWorkerInfo(id) { |
| | |
| | | if (this.dakaList.orderBiddingDetailCheck.length % 2 !== 0) { |
| | | this.dakaList.orderBiddingDetailCheck.push({}) |
| | | } |
| | | console.log(res, '打卡'); |
| | | console.log(res, this.dakaList.workTime, '打卡'); |
| | | }) |
| | | }, |
| | | saveDakaDetailCompany() { |
| | |
| | | title: '确认成功!', |
| | | icon: 'success' |
| | | }) |
| | | this.getDakaDetail(this.orderBiddingDetailId) |
| | | } else { |
| | | this.$util.showToast({ |
| | | title: res.msg ? res.msg : '失败!' |
| | | title: res.error ? res.error : '失败!' |
| | | }) |
| | | } |
| | | this.isLoading = false |