| | |
| | | fontSize='36'></u-notice-bar> |
| | | <view class="top-information"> |
| | | <view class="cutomer-name" |
| | | v-if="orderType == '转入' || orderType == '转出'">煤场:{{ coalDetailsData.toFiledName || '' }}</view> |
| | | v-if="orderType == '转入' || orderType == '转出'">场地:{{ coalDetailsData.toFiledName || '' }}</view> |
| | | <view class="cutomer-name" |
| | | v-else>客户:{{ coalDetailsData.customerName || '' }}</view> |
| | | <view class="fild-name"> |
| | | <view class="">矿场:{{ coalDetailsData.deptName || '暂无' }}</view> |
| | | <view class="" |
| | | v-if="orderType == '转入' || orderType == '转出'">煤场:{{ coalDetailsData.filedName || '' }}</view> |
| | | v-if="orderType == '转入' || orderType == '转出'">场地:{{ coalDetailsData.filedName || '' }}</view> |
| | | <view class="" |
| | | v-else>仓库:{{ coalDetailsData.filedName || '暂无' }}</view> |
| | | </view> |
| | |
| | | <uni-th align="center">皮重</uni-th> |
| | | <uni-th align="center">毛重</uni-th> |
| | | <uni-th align="center">净重</uni-th> |
| | | <uni-th align="center">扣吨</uni-th> |
| | | <uni-th align="center">扣吨</uni-th> |
| | | <uni-th align="center">件数</uni-th> |
| | | </uni-tr> |
| | | <uni-tr v-for="(subItem, index) in tmTaskCoalList" :key="index"> |
| | | <uni-td align="center"> |
| | |
| | | <uni-td align="right"> |
| | | <view>{{ subItem.discount }}</view |
| | | ></uni-td> |
| | | |
| | | <uni-td align="right"> |
| | | <view>{{ subItem.productQuantity }}</view |
| | | ></uni-td> |
| | | </uni-tr> |
| | | </uni-table> |
| | | </view> |
| | |
| | | <!-- title --> |
| | | <view slot="title"> |
| | | <view class="first-line"><combined-title title="原发信息"></combined-title></view> |
| | | |
| | | </view> |
| | | <view class="" slot='cont'> |
| | | <u-form :model="originInfoForm" |
| | | <u-form :model="originInfoForm" |
| | | :rules="rules" |
| | | label-position="top" |
| | | label-width="160" |
| | | :label-style="{'marginLeft':'9px'}" |
| | | ref="originInfoRef"> |
| | | <u-form-item prop="coalContactSkin"> |
| | | <view v-if="coalDetailsData.isWeight"> |
| | | <u-form-item prop="coalContactSkin"> |
| | | <view class="second-line"> |
| | | <view class="label-text" |
| | | :class="{ focusClass: isfocus1 }"><text style="color: #f56c6c;">*</text>皮重</view> |
| | |
| | | </view> |
| | | <view class="unit">吨</view> |
| | | </view> |
| | | </u-form-item> |
| | | </u-form-item> |
| | | </view> |
| | | <!-- 输入数量 --> |
| | | <view v-else class="table-div"> |
| | | <uni-table |
| | | border |
| | | id="table-box" |
| | | emptyText="暂无更多数据"> |
| | | <uni-tr> |
| | | <uni-th align="center" >产品</uni-th> |
| | | <!-- <uni-th align="center">皮重</uni-th> |
| | | <uni-th align="center">毛重</uni-th> |
| | | <uni-th align="center">净重</uni-th> --> |
| | | <uni-th align="center">数量</uni-th> |
| | | </uni-tr> |
| | | <uni-tr v-for="(subItem, index) in coalDetailsData.tmTaskCoalList" :key="index"> |
| | | <uni-td align="center"> |
| | | <view class="name">{{ subItem.productName }}</view></uni-td> |
| | | <!-- <uni-td align='right'> |
| | | <view v-if="subItem.skin">{{ Number( subItem.skin).toFixed(2) || ''}}</view> |
| | | </uni-td> |
| | | <uni-td align='right'> |
| | | <view class="name" v-if="subItem.hair">{{ Number(subItem.hair) .toFixed(2) || '' }}</view> |
| | | </uni-td> |
| | | <uni-td align='right'> |
| | | <view class="name" v-if="subItem.clean">{{ Number( subItem.clean).toFixed(2) || '' }}</view> |
| | | </uni-td> --> |
| | | |
| | | <uni-td align="right"> |
| | | <view> |
| | | <u--input |
| | | placeholder="请输入产品数量" |
| | | type='number' |
| | | v-model="subItem.productQuantity" |
| | | ></u--input> |
| | | </view></uni-td> |
| | | |
| | | </uni-tr> |
| | | </uni-table> |
| | | </view> |
| | | |
| | | <u-form-item prop='contactPicture'> |
| | | <view class="label-text"> |
| | | <text style="color: #f56c6c;">*</text>原发磅单 |
| | |
| | | placement="row" |
| | | @change="radioChange" |
| | | > |
| | | <u-radio label="煤场" :name="'煤场'" :labelSize="30" :size="30"></u-radio> |
| | | <u-radio label="单位" :name="'单位'":labelSize="30" :size="30"></u-radio> |
| | | <u-radio label="场地" :name="'场地'" :labelSize="30" :size="30"></u-radio> |
| | | <u-radio v-for="(item,index) in wareList" :label="'仓库'+(index+1)" :name="index":labelSize="30" :size="30" ></u-radio> |
| | | </u-radio-group> |
| | | |
| | | <div class="guidebox"> |
| | | <u-swiper |
| | | v-if="guideLineshow" |
| | | :height="200" |
| | | :height="400" |
| | | @click="swiperClick" |
| | | :list="swiperList" |
| | | keyName="image" |
| | |
| | | return { |
| | | swiperList:[], |
| | | orderPlanId: null, |
| | | radioValue:'煤场', |
| | | radioValue:'场地', |
| | | tmTaskCoalList:[], |
| | | currentNum:0, |
| | | guideLineshow:false, |
| | |
| | | affiliationId:'', |
| | | type:2, |
| | | }, |
| | | wareList:[], |
| | | coalDetailsData: { |
| | | tmTaskCoalList:[] |
| | | }, // 提煤单详情 |
| | |
| | | return this.correctStatus !== 3 |
| | | }, |
| | | coalContactClean() { |
| | | if(this.coalDetailsData.isWeight){ |
| | | let xx = BigNumber(this.originInfoForm.coalContactHair ? this.originInfoForm.coalContactHair : 0) |
| | | let yy = BigNumber(this.originInfoForm.coalContactSkin ? this.originInfoForm.coalContactSkin : 0) |
| | | return xx.minus(yy).toNumber() > 0 ? xx.minus(yy).toNumber().toFixed(2) : 0 |
| | | }else{ |
| | | //数量 |
| | | if(!this.coalDetailsData.tmTaskCoalList.length){ |
| | | return false |
| | | }else{ |
| | | const reslut = this.coalDetailsData.tmTaskCoalList.find(item=>!item.productQuantity); |
| | | console.log(reslut); |
| | | if(reslut){ |
| | | return false |
| | | }else{ |
| | | return true |
| | | } |
| | | } |
| | | } |
| | | |
| | | }, |
| | | currentTime() { |
| | | let currentDate = new Date(); |
| | |
| | | this.orderType = this.coalDetailsData.orderType; |
| | | // |
| | | this.isSpecial = res.data.isSpecial |
| | | this.wareList=res.data.bunkerIds.split(",") |
| | | // // 判断是否完成外销订单 |
| | | // this.completeOutSale.orderType = this.coalDetailsData.orderType; |
| | | // this.completeOutSale.deptId = this.coalDetailsData.deptId; |
| | |
| | | this.ablePrintOut = this.coalDetailsData.hair && this.coalDetailsData.skin || this |
| | | .coalDetailsData.status === 6 |
| | | // 原发信息回显以及控制是否可修改 |
| | | this.haveInputOrigin = !this.coalDetailsData.skinTwo && this.coalDetailsData.orderType === |
| | | '外购' |
| | | const originFlag = this.coalDetailsData.tmTaskCoalList.find(item=>!item.productQuantity); |
| | | if(this.coalDetailsData.isWeight === 1){ |
| | | this.haveInputOrigin = (!this.coalDetailsData.skinTwo && this.coalDetailsData.orderType === |
| | | '外购') |
| | | }else{ |
| | | this.haveInputOrigin = !!originFlag |
| | | } |
| | | console.log(originFlag,this.coalDetailsData.tmTaskCoalList,'origin') |
| | | this.deletable = this.coalDetailsData.status > 3 |
| | | this.originInfoForm.coalContactSkin = this.coalDetailsData.skinTwo; |
| | | this.originInfoForm.coalContactHair = this.coalDetailsData.hairTwo; |
| | |
| | | taskCoalCode: this.coalDetailsData.code, |
| | | carNo: this.coalDetailsData.carNo, |
| | | } |
| | | if (this.originInfoForm.coalContactSkin && this.originInfoForm.coalContactHair && this |
| | | if(this.coalDetailsData.isWeight === 1){ |
| | | if (this.originInfoForm.coalContactSkin && this.originInfoForm.coalContactHair && this |
| | | .originInfoForm |
| | | .contactPicture) { |
| | | this.submitOriginInfoLoading = true |
| | |
| | | } else { |
| | | uni.$u.toast('请填写完整原发信息') |
| | | } |
| | | }else{ |
| | | //数量 |
| | | form.numDtoList = this.coalDetailsData.tmTaskCoalList.map(item=>{ |
| | | let obj = { |
| | | tmId:item.id, |
| | | num:Number(item.productQuantity) |
| | | } |
| | | return obj; |
| | | }); |
| | | //删除皮毛净 |
| | | delete form.clean; |
| | | delete form.hair; |
| | | delete form.skin; |
| | | if (this.coalContactClean && this |
| | | .originInfoForm |
| | | .contactPicture) { |
| | | this.submitOriginInfoLoading = true; |
| | | console.log(form,'form') |
| | | this.$reqPost('appSaveContact', form, 'json').then(res => { |
| | | if (res.code === 0) { |
| | | this.$u.toast('提交成功') |
| | | this.submitOriginInfoLoading = false |
| | | } else { |
| | | this.submitOriginInfoLoading = false |
| | | this.$u.toast(res.msg ? res.msg : '提交失败') |
| | | } |
| | | }).then(()=>{ |
| | | setTimeout(() => { |
| | | this.getTakeCoal() |
| | | }, 1000); |
| | | }) |
| | | } else { |
| | | uni.$u.toast('请填写完整原发信息') |
| | | } |
| | | } |
| | | |
| | | }, |
| | | streamView() { |
| | | uni.navigateTo({ |
| | |
| | | this.guideLineshow = true; |
| | | this.swiperList = []; |
| | | this.activeText = ''; |
| | | this.activeObj.affiliationId = this.coalDetailsData.filedId; //默认查煤场 |
| | | this.activeObj.affiliationId = this.coalDetailsData.filedId; |
| | | this.getguideFun(); |
| | | |
| | | }, |
| | |
| | | this.guideLineshow = false; |
| | | }, |
| | | radioChange(item){ |
| | | console.log(item); |
| | | if(item == '煤场'){ |
| | | console.log(111,item,this.coalDetailsData,this.wareList); |
| | | if(item == '场地'){ |
| | | this.activeObj.affiliationId = this.coalDetailsData.filedId; |
| | | this.activeObj.type = 2 |
| | | }else{ |
| | | this.activeObj.affiliationId = this.coalDetailsData.deptId; |
| | | this.activeObj.affiliationId = this.wareList.length>0?this.wareList[item]:this.coalDetailsData.deptId; |
| | | this.activeObj.type = 1 |
| | | } |
| | | this.getguideFun(); |