|
@@ -8,7 +8,8 @@
|
|
<view class="row">
|
|
<view class="row">
|
|
<view class="left">任务编号</view>
|
|
<view class="left">任务编号</view>
|
|
<view @click='inOutShow=true'>{{detailData.inOutTaskNo}}</view>
|
|
<view @click='inOutShow=true'>{{detailData.inOutTaskNo}}</view>
|
|
- <u-picker :range="inOutNoList" range-key="inOutTaskNo" @confirm='inOutChange' v-model="inOutShow" mode="selector">
|
|
|
|
|
|
+ <u-picker :range="inOutNoList" range-key="inOutTaskNo" @confirm='inOutChange' v-model="inOutShow"
|
|
|
|
+ mode="selector">
|
|
</u-picker>
|
|
</u-picker>
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom">
|
|
<view class="row row-bottom">
|
|
@@ -47,12 +48,13 @@
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom">
|
|
<view class="row row-bottom">
|
|
<view class="left">净重(吨)</view>
|
|
<view class="left">净重(吨)</view>
|
|
- <input type="number" v-model='netWeight' class="right-bottom" placeholder="不可编辑,自动计算"
|
|
|
|
|
|
+ <input type="number" v-model='netWeight' class="right-bottom" placeholder="不可编辑,自动计算"
|
|
:disabled="true"></input>
|
|
:disabled="true"></input>
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom">
|
|
<view class="row row-bottom">
|
|
<view class="left">扣款(元/吨)</view>
|
|
<view class="left">扣款(元/吨)</view>
|
|
- <input type="number" v-model='detailData.deductionAmount' class="right-bottom" placeholder="输入扣款"></input>
|
|
|
|
|
|
+ <input type="number" v-model='detailData.deductionAmount' class="right-bottom"
|
|
|
|
+ placeholder="输入扣款"></input>
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom" v-if="detailData.type=='潮粮'">
|
|
<view class="row row-bottom" v-if="detailData.type=='潮粮'">
|
|
<view class="left">扣重比</view>
|
|
<view class="left">扣重比</view>
|
|
@@ -61,18 +63,18 @@
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom" v-if="detailData.type=='潮粮'">
|
|
<view class="row row-bottom" v-if="detailData.type=='潮粮'">
|
|
<view class="left">干粮水分(%)</view>
|
|
<view class="left">干粮水分(%)</view>
|
|
- <input type="number" v-model='detailData.solidGrainWater' class="right-bottom" placeholder="输入干粮水分占比"
|
|
|
|
|
|
+ <input type="number" v-model='detailData.solidGrainWater' class="right-bottom" placeholder="输入干粮水分占比"
|
|
@input="pureWeightCount"></input>
|
|
@input="pureWeightCount"></input>
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom" v-if="detailData.type=='潮粮'">
|
|
<view class="row row-bottom" v-if="detailData.type=='潮粮'">
|
|
<view class="left">潮粮水分(%)</view>
|
|
<view class="left">潮粮水分(%)</view>
|
|
- <input type="number" v-model='detailData.tidalGrainWater' class="right-bottom" placeholder="输入潮粮水分占比"
|
|
|
|
|
|
+ <input type="number" v-model='detailData.tidalGrainWater' class="right-bottom" placeholder="输入潮粮水分占比"
|
|
@input="pureWeightCount"></input>
|
|
@input="pureWeightCount"></input>
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom" v-if="detailData.type=='潮粮'">
|
|
<view class="row row-bottom" v-if="detailData.type=='潮粮'">
|
|
<view class="left">纯重(吨)</view>
|
|
<view class="left">纯重(吨)</view>
|
|
- <input type="number" @input='calculate' v-model='detailData.pureWeight' class="right-bottom" placeholder="不可编辑,自动计算"
|
|
|
|
- :disabled="true"></input>
|
|
|
|
|
|
+ <input type="number" @input='calculate' v-model='detailData.pureWeight' class="right-bottom"
|
|
|
|
+ placeholder="不可编辑,自动计算" :disabled="true"></input>
|
|
</view>
|
|
</view>
|
|
<view class="row">
|
|
<view class="row">
|
|
<view class="left">品级</view>
|
|
<view class="left">品级</view>
|
|
@@ -95,7 +97,8 @@
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom">
|
|
<view class="row row-bottom">
|
|
<view class="left">入库类型</view>
|
|
<view class="left">入库类型</view>
|
|
- <input v-model='detailData.inOutType' class="right-bottom" :disabled="isSelectType" @click="selectType" placeholder="自动获取"></input>
|
|
|
|
|
|
+ <input v-model='detailData.inOutType' class="right-bottom" :disabled="isSelectType" @click="selectType"
|
|
|
|
+ placeholder="自动获取"></input>
|
|
<u-picker :range="warehousingTypeList" range-key="constValue" @confirm='warehousingTypePicker($event)'
|
|
<u-picker :range="warehousingTypeList" range-key="constValue" @confirm='warehousingTypePicker($event)'
|
|
v-model="show5" mode="selector">
|
|
v-model="show5" mode="selector">
|
|
</u-picker>
|
|
</u-picker>
|
|
@@ -103,27 +106,35 @@
|
|
<view class="row">
|
|
<view class="row">
|
|
<view class="left">入库方式</view>
|
|
<view class="left">入库方式</view>
|
|
<view @click='show8=true'>{{detailData.outType?detailData.outType:'汽运'}}</view>
|
|
<view @click='show8=true'>{{detailData.outType?detailData.outType:'汽运'}}</view>
|
|
- <u-picker v-model="show8" mode="selector" range-key="name" :range="multiSelector" @confirm='outtypeChange($event)'>
|
|
|
|
|
|
+ <u-picker v-model="show8" mode="selector" range-key="name" :range="multiSelector"
|
|
|
|
+ @confirm='outtypeChange($event)'>
|
|
</u-picker>
|
|
</u-picker>
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom">
|
|
<view class="row row-bottom">
|
|
<view class="left">车牌号</view>
|
|
<view class="left">车牌号</view>
|
|
- <input v-if="!isPC" v-model='detailData.carNo' class="right-bottom"
|
|
|
|
- placeholder="请输入车牌号"></input>
|
|
|
|
|
|
+ <input v-if="!isPC" v-model='detailData.carNo' class="right-bottom" placeholder="请输入车牌号"></input>
|
|
<view @click='slectCarNo' v-if="isPC">{{detailData.carNo}}</view>
|
|
<view @click='slectCarNo' v-if="isPC">{{detailData.carNo}}</view>
|
|
</view>
|
|
</view>
|
|
- <view v-if='detailData.outType=="集装箱船"' class="row row-bottom">
|
|
|
|
|
|
+ <view v-if='detailData.outType=="集装箱船"||!detailData.outType||detailData.outType=="汽运"'
|
|
|
|
+ class="row row-bottom">
|
|
<view class="left">箱号</view>
|
|
<view class="left">箱号</view>
|
|
- <!-- <view @click='show9=true'>{{usestart?usestart:'汽运'}}</view>
|
|
|
|
- <u-picker v-model="show9" mode="selector" range-key="name" :range="multiSelector1" @confirm='usestartChange($event)'>
|
|
|
|
- </u-picker> -->
|
|
|
|
- <input v-model='detailData.boxNo' @input="toUpperCase" class="right-bottom" placeholder="请输入箱号"></input>
|
|
|
|
- <input v-model='detailData.boxNoOther' @input="toUpperCase1" class="right-bottom" placeholder="请输入箱号"></input>
|
|
|
|
|
|
+ <input v-model='detailData.boxNo' class="right-bottom" placeholder="请输入箱号"></input>
|
|
|
|
+ <input v-model='detailData.boxNoOther' class="right-bottom"
|
|
|
|
+ placeholder="请输入箱号"></input>
|
|
|
|
+ </view>
|
|
|
|
+ <view v-if='!detailData.outType||detailData.outType=="汽运"' class="row row-bottom">
|
|
|
|
+ <view class="left">封号</view>
|
|
|
|
+ <input v-model='detailData.titleNo' class="right-bottom"
|
|
|
|
+ placeholder="请输入封号"></input>
|
|
|
|
+ <input v-model='detailData.titleNoOther' class="right-bottom"
|
|
|
|
+ placeholder="请输入封号"></input>
|
|
</view>
|
|
</view>
|
|
<view v-if='detailData.outType=="火运"' class="row row-bottom">
|
|
<view v-if='detailData.outType=="火运"' class="row row-bottom">
|
|
<view class="left">车厢号</view>
|
|
<view class="left">车厢号</view>
|
|
- <input v-model='detailData.boxNo' @input="toUpperCase" class="right-bottom" placeholder="请输入车厢号"></input>
|
|
|
|
- <input v-model='detailData.boxNoOther' @input="toUpperCase1" class="right-bottom" placeholder="请输入车厢号"></input>
|
|
|
|
|
|
+ <input v-model='detailData.boxNo' @input="toUpperCase" class="right-bottom"
|
|
|
|
+ placeholder="请输入车厢号"></input>
|
|
|
|
+ <input v-model='detailData.boxNoOther' @input="toUpperCase1" class="right-bottom"
|
|
|
|
+ placeholder="请输入车厢号"></input>
|
|
</view>
|
|
</view>
|
|
<view v-if='detailData.outType=="散船"' class="row row-bottom">
|
|
<view v-if='detailData.outType=="散船"' class="row row-bottom">
|
|
<view class="left">仓位号</view>
|
|
<view class="left">仓位号</view>
|
|
@@ -131,8 +142,8 @@
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom has-btn">
|
|
<view class="row row-bottom has-btn">
|
|
<view class="left">成本(元/吨)</view>
|
|
<view class="left">成本(元/吨)</view>
|
|
- <input type="number" v-model='detailData.cost' class="right-bottom"
|
|
|
|
- placeholder="自动获取" :disabled="isEditCB"></input>
|
|
|
|
|
|
+ <input type="number" v-model='detailData.cost' class="right-bottom" placeholder="自动获取"
|
|
|
|
+ :disabled="isEditCB"></input>
|
|
<!-- <input type="number" v-if="detailData.inOutType!='采购入库'" v-model='detailData.cost' class="right-bottom"
|
|
<!-- <input type="number" v-if="detailData.inOutType!='采购入库'" v-model='detailData.cost' class="right-bottom"
|
|
placeholder="自动获取" :disabled="isEditCB"></input> -->
|
|
placeholder="自动获取" :disabled="isEditCB"></input> -->
|
|
<u-button class="edit-btn" hover-class="none" @click="editCB">编辑</u-button>
|
|
<u-button class="edit-btn" hover-class="none" @click="editCB">编辑</u-button>
|
|
@@ -161,8 +172,8 @@
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom">
|
|
<view class="row row-bottom">
|
|
<view class="left">水分(%)</view>
|
|
<view class="left">水分(%)</view>
|
|
- <input type="number" @input='' v-model='detailData.warehouseInOutDetail.waterContent' class="right-bottom"
|
|
|
|
- placeholder="输入水分占比"></input>
|
|
|
|
|
|
+ <input type="number" @input='' v-model='detailData.warehouseInOutDetail.waterContent'
|
|
|
|
+ class="right-bottom" placeholder="输入水分占比"></input>
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom">
|
|
<view class="row row-bottom">
|
|
<view class="left">容重(克/升)</view>
|
|
<view class="left">容重(克/升)</view>
|
|
@@ -181,8 +192,8 @@
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom">
|
|
<view class="row row-bottom">
|
|
<view class="left">霉变粒(%)</view>
|
|
<view class="left">霉变粒(%)</view>
|
|
- <input type="number" @input='' v-model='detailData.warehouseInOutDetail.mildewGrain' class="right-bottom"
|
|
|
|
- placeholder="输入霉变粒占比"></input>
|
|
|
|
|
|
+ <input type="number" @input='' v-model='detailData.warehouseInOutDetail.mildewGrain'
|
|
|
|
+ class="right-bottom" placeholder="输入霉变粒占比"></input>
|
|
</view>
|
|
</view>
|
|
<view class="row row-bottom">
|
|
<view class="row row-bottom">
|
|
<view class="left">不完善粒(%)</view>
|
|
<view class="left">不完善粒(%)</view>
|
|
@@ -218,8 +229,8 @@
|
|
show5: false,
|
|
show5: false,
|
|
show6: false,
|
|
show6: false,
|
|
isPC: true,
|
|
isPC: true,
|
|
- isSelectType:true,
|
|
|
|
- inOutShow:false,
|
|
|
|
|
|
+ isSelectType: true,
|
|
|
|
+ inOutShow: false,
|
|
params: {
|
|
params: {
|
|
year: true,
|
|
year: true,
|
|
month: true,
|
|
month: true,
|
|
@@ -230,11 +241,22 @@
|
|
warehouseName: '',
|
|
warehouseName: '',
|
|
binNumber: '',
|
|
binNumber: '',
|
|
contractNoList: [],
|
|
contractNoList: [],
|
|
- multiSelector:[
|
|
|
|
- {name:'汽运',value:'0'},
|
|
|
|
- {name:'火运',value:'1'},
|
|
|
|
- {name:'集装箱船',value:'2'},
|
|
|
|
- {name:'散船',value:'3'},
|
|
|
|
|
|
+ multiSelector: [{
|
|
|
|
+ name: '汽运',
|
|
|
|
+ value: '0'
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ name: '火运',
|
|
|
|
+ value: '1'
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ name: '集装箱船',
|
|
|
|
+ value: '2'
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ name: '散船',
|
|
|
|
+ value: '3'
|
|
|
|
+ },
|
|
],
|
|
],
|
|
typeList: [{
|
|
typeList: [{
|
|
type: "干粮"
|
|
type: "干粮"
|
|
@@ -256,17 +278,21 @@
|
|
grade: "等外"
|
|
grade: "等外"
|
|
}
|
|
}
|
|
],
|
|
],
|
|
- inOutNoList:[],
|
|
|
|
- show8:false,
|
|
|
|
|
|
+ inOutNoList: [],
|
|
|
|
+ show8: false,
|
|
handlerList: [],
|
|
handlerList: [],
|
|
- warehousingTypeList: [{constValue:'移库入库'},{constValue:'退库'}],
|
|
|
|
|
|
+ warehousingTypeList: [{
|
|
|
|
+ constValue: '移库入库'
|
|
|
|
+ }, {
|
|
|
|
+ constValue: '退库'
|
|
|
|
+ }],
|
|
action: this.$uploadUrl,
|
|
action: this.$uploadUrl,
|
|
maxSize: 50 * 1024 * 1024, //限制文件大小 50M
|
|
maxSize: 50 * 1024 * 1024, //限制文件大小 50M
|
|
btnLoading: false, //防止重复点击
|
|
btnLoading: false, //防止重复点击
|
|
isAdd: true,
|
|
isAdd: true,
|
|
netWeight: "",
|
|
netWeight: "",
|
|
inOutDate1: "",
|
|
inOutDate1: "",
|
|
- contractNoList:[],
|
|
|
|
|
|
+ contractNoList: [],
|
|
detailData: {
|
|
detailData: {
|
|
contractNo: "请选择合同编号",
|
|
contractNo: "请选择合同编号",
|
|
carNo: '请输入车牌号',
|
|
carNo: '请输入车牌号',
|
|
@@ -281,7 +307,7 @@
|
|
tare: '',
|
|
tare: '',
|
|
deductionAmount: '',
|
|
deductionAmount: '',
|
|
netWeight: 0,
|
|
netWeight: 0,
|
|
- cost:0,
|
|
|
|
|
|
+ cost: 0,
|
|
warehouseInOutDetail: {}
|
|
warehouseInOutDetail: {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -298,9 +324,9 @@
|
|
...mapState(['hasLogin', 'userInfo']),
|
|
...mapState(['hasLogin', 'userInfo']),
|
|
},
|
|
},
|
|
onShow() {
|
|
onShow() {
|
|
- let _data = uni.getStorageSync('erpContractNo')==''?{}:uni.getStorageSync('erpContractNo')
|
|
|
|
- if(helper.erpWarehouse.personCharge)
|
|
|
|
- this.detailData.agent = helper.erpWarehouse.personCharge
|
|
|
|
|
|
+ let _data = uni.getStorageSync('erpContractNo') == '' ? {} : uni.getStorageSync('erpContractNo')
|
|
|
|
+ if (helper.erpWarehouse.personCharge)
|
|
|
|
+ this.detailData.agent = helper.erpWarehouse.personCharge
|
|
this.detailData.goodsName = _data.goodsName;
|
|
this.detailData.goodsName = _data.goodsName;
|
|
this.detailData.contractNo = _data.contractNo;
|
|
this.detailData.contractNo = _data.contractNo;
|
|
this.detailData.goodsNameKey = _data.goodsNameKey;
|
|
this.detailData.goodsNameKey = _data.goodsNameKey;
|
|
@@ -316,49 +342,49 @@
|
|
} else if (this.detailData.inOutType == '退库') {
|
|
} else if (this.detailData.inOutType == '退库') {
|
|
this.detailData.inOutTypeKey = 6
|
|
this.detailData.inOutTypeKey = 6
|
|
}
|
|
}
|
|
- if(_data.unitContractPrice) {
|
|
|
|
|
|
+ if (_data.unitContractPrice) {
|
|
this.detailData.cost = _data.unitContractPrice
|
|
this.detailData.cost = _data.unitContractPrice
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+
|
|
if (_data.inOutType == '采购入库') {
|
|
if (_data.inOutType == '采购入库') {
|
|
this.detailData.freight = 0
|
|
this.detailData.freight = 0
|
|
-
|
|
|
|
- }else if(_data.inOutType == '移库入库'){
|
|
|
|
|
|
+
|
|
|
|
+ } else if (_data.inOutType == '移库入库') {
|
|
this.isSelectType = false
|
|
this.isSelectType = false
|
|
- }
|
|
|
|
- else{
|
|
|
|
|
|
+ } else {
|
|
this.detailData.freight = uni.getStorageSync('CarFreight')
|
|
this.detailData.freight = uni.getStorageSync('CarFreight')
|
|
this.isSelectType = true
|
|
this.isSelectType = true
|
|
}
|
|
}
|
|
- if (!_data.tranCarInfoList){
|
|
|
|
-
|
|
|
|
|
|
+ if (!_data.tranCarInfoList) {
|
|
|
|
+
|
|
this.isPC = false
|
|
this.isPC = false
|
|
// this.detailData.carNo = ""
|
|
// this.detailData.carNo = ""
|
|
// this.detailData.cost = ""
|
|
// this.detailData.cost = ""
|
|
// _data.tranCarInfoList = []
|
|
// _data.tranCarInfoList = []
|
|
- } else{
|
|
|
|
|
|
+ } else {
|
|
this.isPC = true
|
|
this.isPC = true
|
|
uni.setStorageSync('erpContractNoCarList', _data.tranCarInfoList);
|
|
uni.setStorageSync('erpContractNoCarList', _data.tranCarInfoList);
|
|
- this.detailData.freight=uni.getStorageSync('erpcarNo').tranPrice
|
|
|
|
- if(uni.getStorageSync('ContractNoCar')){
|
|
|
|
|
|
+ this.detailData.freight = uni.getStorageSync('erpcarNo').tranPrice
|
|
|
|
+ if (uni.getStorageSync('ContractNoCar')) {
|
|
this.detailData.carNo = uni.getStorageSync('ContractNoCar')
|
|
this.detailData.carNo = uni.getStorageSync('ContractNoCar')
|
|
this.$api.doRequest('get', '/warehouseBaseInfo/selectCost', {
|
|
this.$api.doRequest('get', '/warehouseBaseInfo/selectCost', {
|
|
contractNo: this.detailData.contractNo,
|
|
contractNo: this.detailData.contractNo,
|
|
- carNo:this.detailData.carNo
|
|
|
|
|
|
+ carNo: this.detailData.carNo
|
|
}).then(res => {
|
|
}).then(res => {
|
|
if (res.data.code == 200) {
|
|
if (res.data.code == 200) {
|
|
this.detailData.cost = res.data.data
|
|
this.detailData.cost = res.data.data
|
|
}
|
|
}
|
|
})
|
|
})
|
|
- }else{
|
|
|
|
|
|
+ } else {
|
|
this.detailData.carNo = _data.tranCarInfoList[0].carNo
|
|
this.detailData.carNo = _data.tranCarInfoList[0].carNo
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- if(this.detailData.carNo){
|
|
|
|
- var tranCarInfoList=uni.getStorageSync('erpContractNo').tranCarInfoList?uni.getStorageSync('erpContractNo').tranCarInfoList:[]
|
|
|
|
- for(let i = 0 ; i < tranCarInfoList.length ;i++){
|
|
|
|
- if(tranCarInfoList[i].carNo == this.detailData.carNo)
|
|
|
|
- this.detailData.tranCarNo = tranCarInfoList[i].tranCarNo
|
|
|
|
|
|
+ if (this.detailData.carNo) {
|
|
|
|
+ var tranCarInfoList = uni.getStorageSync('erpContractNo').tranCarInfoList ? uni.getStorageSync(
|
|
|
|
+ 'erpContractNo').tranCarInfoList : []
|
|
|
|
+ for (let i = 0; i < tranCarInfoList.length; i++) {
|
|
|
|
+ if (tranCarInfoList[i].carNo == this.detailData.carNo)
|
|
|
|
+ this.detailData.tranCarNo = tranCarInfoList[i].tranCarNo
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (!this.detailData.contractNo) {
|
|
if (!this.detailData.contractNo) {
|
|
@@ -384,14 +410,16 @@
|
|
},
|
|
},
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- inOutNo(){
|
|
|
|
- this.$api.doRequest('get', '/inOutWarehouseTask/selectInOutWarehouseNo', {flag :2}).then(res => {
|
|
|
|
|
|
+ inOutNo() {
|
|
|
|
+ this.$api.doRequest('get', '/inOutWarehouseTask/selectInOutWarehouseNo', {
|
|
|
|
+ flag: 2
|
|
|
|
+ }).then(res => {
|
|
this.inOutNoList = res.data.data
|
|
this.inOutNoList = res.data.data
|
|
this.detailData.inOutTaskNo = this.inOutNoList[0].inOutTaskNo
|
|
this.detailData.inOutTaskNo = this.inOutNoList[0].inOutTaskNo
|
|
this.detailData.agent = this.inOutNoList[0].agent
|
|
this.detailData.agent = this.inOutNoList[0].agent
|
|
- if(this.inOutNoList[0].contractNo){
|
|
|
|
|
|
+ if (this.inOutNoList[0].contractNo) {
|
|
this.detailData.contractNo = this.inOutNoList[0].contractNo
|
|
this.detailData.contractNo = this.inOutNoList[0].contractNo
|
|
- }else{
|
|
|
|
|
|
+ } else {
|
|
this.detailData.contractNo = this.inOutNoList[0].moveTaskNo
|
|
this.detailData.contractNo = this.inOutNoList[0].moveTaskNo
|
|
}
|
|
}
|
|
this.detailData.goodsName = this.inOutNoList[0].goodsName
|
|
this.detailData.goodsName = this.inOutNoList[0].goodsName
|
|
@@ -401,62 +429,61 @@
|
|
this.$api.doRequest('get', 'warehouseBaseInfo/selectContractNoList', ).then(res => {
|
|
this.$api.doRequest('get', 'warehouseBaseInfo/selectContractNoList', ).then(res => {
|
|
this.contractNoList = res.data.data
|
|
this.contractNoList = res.data.data
|
|
for (var i = 0; i < this.contractNoList.length; i++) {
|
|
for (var i = 0; i < this.contractNoList.length; i++) {
|
|
- if(this.contractNoList[i].contractNo==this.detailData.contractNo){
|
|
|
|
|
|
+ if (this.contractNoList[i].contractNo == this.detailData.contractNo) {
|
|
if (this.detailData.inOutType == '采购入库') {
|
|
if (this.detailData.inOutType == '采购入库') {
|
|
- this.detailData.tips='卖方'+this.contractNoList[i].seller
|
|
|
|
|
|
+ this.detailData.tips = '卖方' + this.contractNoList[i].seller
|
|
} else if (this.detailData.inOutType == '移库入库') {
|
|
} else if (this.detailData.inOutType == '移库入库') {
|
|
- this.detailData.tips='出货库'+this.inOutNoList[0].warehouseName
|
|
|
|
- } else if (this.detailData.inOutType == '退库') {
|
|
|
|
- this.detailData.tips='出货库'+this.inOutNoList[0].warehouseName
|
|
|
|
|
|
+ this.detailData.tips = '出货库' + this.inOutNoList[0].warehouseName
|
|
|
|
+ } else if (this.detailData.inOutType == '退库') {
|
|
|
|
+ this.detailData.tips = '出货库' + this.inOutNoList[0].warehouseName
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- inOutChange(e){
|
|
|
|
|
|
+ inOutChange(e) {
|
|
this.detailData.inOutTaskNo = this.inOutNoList[e[0]].inOutTaskNo
|
|
this.detailData.inOutTaskNo = this.inOutNoList[e[0]].inOutTaskNo
|
|
this.detailData.agent = this.inOutNoList[e[0]].agent
|
|
this.detailData.agent = this.inOutNoList[e[0]].agent
|
|
- if(this.inOutNoList[e[0]].contractNo){
|
|
|
|
|
|
+ if (this.inOutNoList[e[0]].contractNo) {
|
|
this.detailData.contractNo = this.inOutNoList[e[0]].contractNo
|
|
this.detailData.contractNo = this.inOutNoList[e[0]].contractNo
|
|
- }else{
|
|
|
|
|
|
+ } else {
|
|
this.detailData.contractNo = this.inOutNoList[e[0]].moveTaskNo
|
|
this.detailData.contractNo = this.inOutNoList[e[0]].moveTaskNo
|
|
}
|
|
}
|
|
this.detailData.goodsName = this.inOutNoList[e[0]].goodsName
|
|
this.detailData.goodsName = this.inOutNoList[e[0]].goodsName
|
|
this.detailData.grade = this.inOutNoList[e[0]].grade
|
|
this.detailData.grade = this.inOutNoList[e[0]].grade
|
|
- this.detailData.inOutType = this.inOutNoList[e[0]].inOutType
|
|
|
|
- for (var i = 0; i < this.contractNoList.length; i++) {
|
|
|
|
- if(this.contractNoList[i].contractNo==this.detailData.contractNo){
|
|
|
|
- if (this.detailData.inOutType == '采购入库') {
|
|
|
|
- this.detailData.tips='卖方'+this.contractNoList[i].seller
|
|
|
|
- } else if (this.detailData.inOutType == '移库入库') {
|
|
|
|
- this.detailData.tips='出货库'+this.inOutNoList[e[0]].warehouseName
|
|
|
|
- } else if (this.detailData.inOutType == '退库') {
|
|
|
|
- if(this.contractNoList[i].contractNo){
|
|
|
|
- this.deptBudgetList.tips='买方'+this.contractNoList[i].buyer
|
|
|
|
- }
|
|
|
|
- else{
|
|
|
|
- this.deptBudgetList.tips='出货库'+this.inOutNoList[e[0]].warehouseName
|
|
|
|
- }
|
|
|
|
|
|
+ this.detailData.inOutType = this.inOutNoList[e[0]].inOutType
|
|
|
|
+ for (var i = 0; i < this.contractNoList.length; i++) {
|
|
|
|
+ if (this.contractNoList[i].contractNo == this.detailData.contractNo) {
|
|
|
|
+ if (this.detailData.inOutType == '采购入库') {
|
|
|
|
+ this.detailData.tips = '卖方' + this.contractNoList[i].seller
|
|
|
|
+ } else if (this.detailData.inOutType == '移库入库') {
|
|
|
|
+ this.detailData.tips = '出货库' + this.inOutNoList[e[0]].warehouseName
|
|
|
|
+ } else if (this.detailData.inOutType == '退库') {
|
|
|
|
+ if (this.contractNoList[i].contractNo) {
|
|
|
|
+ this.deptBudgetList.tips = '买方' + this.contractNoList[i].buyer
|
|
|
|
+ } else {
|
|
|
|
+ this.deptBudgetList.tips = '出货库' + this.inOutNoList[e[0]].warehouseName
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+ }
|
|
|
|
+
|
|
},
|
|
},
|
|
- toUpperCase(val){
|
|
|
|
|
|
+ toUpperCase(val) {
|
|
this.detailData.boxNo = val.detail.value.toUpperCase()
|
|
this.detailData.boxNo = val.detail.value.toUpperCase()
|
|
},
|
|
},
|
|
- toUpperCase1(val){
|
|
|
|
|
|
+ toUpperCase1(val) {
|
|
this.detailData.boxNoOther = val.detail.value.toUpperCase()
|
|
this.detailData.boxNoOther = val.detail.value.toUpperCase()
|
|
},
|
|
},
|
|
- usestartChange(e){
|
|
|
|
- this.usestart=this.multiSelector1[e].name
|
|
|
|
|
|
+ usestartChange(e) {
|
|
|
|
+ this.usestart = this.multiSelector1[e].name
|
|
},
|
|
},
|
|
- outtypeChange(e){
|
|
|
|
- this.detailData.outType=this.multiSelector[e].name
|
|
|
|
|
|
+ outtypeChange(e) {
|
|
|
|
+ this.detailData.outType = this.multiSelector[e].name
|
|
console.log(e)
|
|
console.log(e)
|
|
},
|
|
},
|
|
- selectType(){
|
|
|
|
- if(this.isSelectType) return
|
|
|
|
|
|
+ selectType() {
|
|
|
|
+ if (this.isSelectType) return
|
|
this.show5 = true
|
|
this.show5 = true
|
|
},
|
|
},
|
|
//计算纯重
|
|
//计算纯重
|
|
@@ -489,7 +516,7 @@
|
|
this.detailData.type = this.typeList[e].type
|
|
this.detailData.type = this.typeList[e].type
|
|
},
|
|
},
|
|
pjPicker(e) {
|
|
pjPicker(e) {
|
|
- this.detailData.gradeKey = e[0]+1
|
|
|
|
|
|
+ this.detailData.gradeKey = e[0] + 1
|
|
this.detailData.grade = this.pjList[e].grade
|
|
this.detailData.grade = this.pjList[e].grade
|
|
},
|
|
},
|
|
handlerPicker(e) {
|
|
handlerPicker(e) {
|
|
@@ -514,11 +541,13 @@
|
|
} else if (this.detailData.inOutType == '退库') {
|
|
} else if (this.detailData.inOutType == '退库') {
|
|
this.detailData.inOutTypeKey = 6
|
|
this.detailData.inOutTypeKey = 6
|
|
}
|
|
}
|
|
- let _data = uni.getStorageSync('erpContractNo')==''?{}:uni.getStorageSync('erpContractNo')
|
|
|
|
|
|
+ let _data = uni.getStorageSync('erpContractNo') == '' ? {} : uni.getStorageSync('erpContractNo')
|
|
if (this.detailData.inOutType == '采购入库') {
|
|
if (this.detailData.inOutType == '采购入库') {
|
|
this.detailData.freight = 0
|
|
this.detailData.freight = 0
|
|
- }else{this.detailData.freight = uni.getStorageSync('CarFreight')}
|
|
|
|
-
|
|
|
|
|
|
+ } else {
|
|
|
|
+ this.detailData.freight = uni.getStorageSync('CarFreight')
|
|
|
|
+ }
|
|
|
|
+
|
|
},
|
|
},
|
|
filterFileType(index, lists) {
|
|
filterFileType(index, lists) {
|
|
if (lists[index].fileType != 'jpg' && lists[index].fileType != 'png' && lists[index].fileType != 'gif') {
|
|
if (lists[index].fileType != 'jpg' && lists[index].fileType != 'png' && lists[index].fileType != 'gif') {
|
|
@@ -533,7 +562,8 @@
|
|
}
|
|
}
|
|
},
|
|
},
|
|
calculate() {
|
|
calculate() {
|
|
- this.netWeight = (this.detailData.grossWeight - this.detailData.tare - this.detailData.deductionWeight).toFixed(2)
|
|
|
|
|
|
+ this.netWeight = (this.detailData.grossWeight - this.detailData.tare - this.detailData.deductionWeight)
|
|
|
|
+ .toFixed(2)
|
|
},
|
|
},
|
|
getImgUrl(res) {
|
|
getImgUrl(res) {
|
|
this.detailData.addressUrl = res
|
|
this.detailData.addressUrl = res
|
|
@@ -748,20 +778,20 @@
|
|
this.$api.msg('请上传磅单')
|
|
this.$api.msg('请上传磅单')
|
|
return
|
|
return
|
|
}
|
|
}
|
|
- if (!this.detailData.cost && num == 2) {
|
|
|
|
- this.$api.msg('未获取到成本,请编辑后提交')
|
|
|
|
- return
|
|
|
|
- }
|
|
|
|
- if (String(this.detailData.cost).indexOf('.') != -1 && String(this.detailData
|
|
|
|
- .cost).length - (String(
|
|
|
|
- this.detailData.cost).indexOf('.') + 1) > 2) {
|
|
|
|
- this.$api.msg('成本输入错误')
|
|
|
|
- return
|
|
|
|
- }
|
|
|
|
- if (this.detailData.cost < 0 || this.detailData.cost > 20000) {
|
|
|
|
- this.$api.msg('成本输入错误')
|
|
|
|
- return
|
|
|
|
- }
|
|
|
|
|
|
+ if (!this.detailData.cost && num == 2) {
|
|
|
|
+ this.$api.msg('未获取到成本,请编辑后提交')
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ if (String(this.detailData.cost).indexOf('.') != -1 && String(this.detailData
|
|
|
|
+ .cost).length - (String(
|
|
|
|
+ this.detailData.cost).indexOf('.') + 1) > 2) {
|
|
|
|
+ this.$api.msg('成本输入错误')
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ if (this.detailData.cost < 0 || this.detailData.cost > 20000) {
|
|
|
|
+ this.$api.msg('成本输入错误')
|
|
|
|
+ return
|
|
|
|
+ }
|
|
if (!this.detailData.freight && num == 2) {
|
|
if (!this.detailData.freight && num == 2) {
|
|
this.$api.msg('运费不能为空')
|
|
this.$api.msg('运费不能为空')
|
|
return
|
|
return
|
|
@@ -788,13 +818,13 @@
|
|
return
|
|
return
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- if (String(this.detailData.warehouseInOutDetail.waterContent).indexOf('.') != -1 && String(this
|
|
|
|
- .detailData.warehouseInOutDetail.waterContent).length - (String(
|
|
|
|
- this.detailData.warehouseInOutDetail.waterContent).indexOf('.') + 1) > 1) {
|
|
|
|
- this.$api.msg('水分占比输入错误')
|
|
|
|
- return
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
|
|
+ if (String(this.detailData.warehouseInOutDetail.waterContent).indexOf('.') != -1 && String(this
|
|
|
|
+ .detailData.warehouseInOutDetail.waterContent).length - (String(
|
|
|
|
+ this.detailData.warehouseInOutDetail.waterContent).indexOf('.') + 1) > 1) {
|
|
|
|
+ this.$api.msg('水分占比输入错误')
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+
|
|
}
|
|
}
|
|
if (this.detailData.warehouseInOutDetail.bulkDensity) {
|
|
if (this.detailData.warehouseInOutDetail.bulkDensity) {
|
|
if (this.detailData.warehouseInOutDetail.bulkDensity < 500 || this.detailData.warehouseInOutDetail
|
|
if (this.detailData.warehouseInOutDetail.bulkDensity < 500 || this.detailData.warehouseInOutDetail
|
|
@@ -893,11 +923,11 @@
|
|
that.$api.doRequest('post', '/warehouseInOutInfo/InOutWarehouse',
|
|
that.$api.doRequest('post', '/warehouseInOutInfo/InOutWarehouse',
|
|
that.detailData).then(res => {
|
|
that.detailData).then(res => {
|
|
if (res.data.code == 200) {
|
|
if (res.data.code == 200) {
|
|
- that.$api.msg(title)
|
|
|
|
- setTimeout(() => {
|
|
|
|
- uni.navigateBack()
|
|
|
|
- }, 1000)
|
|
|
|
- }else{
|
|
|
|
|
|
+ that.$api.msg(title)
|
|
|
|
+ setTimeout(() => {
|
|
|
|
+ uni.navigateBack()
|
|
|
|
+ }, 1000)
|
|
|
|
+ } else {
|
|
that.$api.msg(res.data.message)
|
|
that.$api.msg(res.data.message)
|
|
}
|
|
}
|
|
})
|
|
})
|