|
|
@ -178,18 +178,25 @@ |
|
|
<uni-icons type="right" size="16" |
|
|
<uni-icons type="right" size="16" |
|
|
style="margin-left: 80rpx;line-height: 80rpx;"></uni-icons> |
|
|
style="margin-left: 80rpx;line-height: 80rpx;"></uni-icons> |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
</view> |
|
|
|
|
|
<view class="content-list" v-if="radioType == '4'"> |
|
|
|
|
|
<view class="list-name" style="width:150rpx;">选择车号</view> |
|
|
|
|
|
<view class="list-val"> |
|
|
|
|
|
<input type="text" placeholder="请选择" disabled |
|
|
|
|
|
style="border-bottom: 1px solid #fff;text-align: center;" |
|
|
|
|
|
@tap="goPopleList('fcName')"> |
|
|
|
|
|
<uni-icons type="right" size="16" |
|
|
|
|
|
style="margin-left: 80rpx;line-height: 80rpx;"></uni-icons> |
|
|
|
|
|
</view> |
|
|
|
|
|
</view> |
|
|
|
|
|
<view class="content-list" v-if="radioType !=''"> |
|
|
|
|
|
<view class="tui-flex-shrink">配送方式</view> |
|
|
|
|
|
<view class="tui-goods-price"> |
|
|
|
|
|
<uni-data-checkbox v-model="radio1" :localdata="sex" |
|
|
|
|
|
@change="checkBoxChange"></uni-data-checkbox> |
|
|
|
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
<view class="content-list" v-if="radioType == '4'"> |
|
|
<view class="content-list" v-if="radioType1 != '1' && radioType !=''"> |
|
|
<view class="list-name" style="width:150rpx;">选择车号</view> |
|
|
|
|
|
<view class="list-val"> |
|
|
|
|
|
<input type="text" placeholder="请选择" disabled |
|
|
|
|
|
style="border-bottom: 1px solid #fff;text-align: center;" |
|
|
|
|
|
@tap="goPopleList('fcName')"> |
|
|
|
|
|
<uni-icons type="right" size="16" |
|
|
|
|
|
style="margin-left: 80rpx;line-height: 80rpx;"></uni-icons> |
|
|
|
|
|
</view> |
|
|
|
|
|
</view> |
|
|
|
|
|
<view class="content-list" v-if="radioType != '2' && radioType !=''"> |
|
|
|
|
|
<view class="list-name" style="width:150rpx;">{{radioType == '1'? '快递员' :'拉包工'}}</view> |
|
|
<view class="list-name" style="width:150rpx;">{{radioType == '1'? '快递员' :'拉包工'}}</view> |
|
|
<view class="list-val"> |
|
|
<view class="list-val"> |
|
|
<input type="text" placeholder="请选择" disabled |
|
|
<input type="text" placeholder="请选择" disabled |
|
|
@ -255,6 +262,13 @@ |
|
|
priceCurrent:'', |
|
|
priceCurrent:'', |
|
|
priceOk:'', //已收金额 |
|
|
priceOk:'', //已收金额 |
|
|
value: '', |
|
|
value: '', |
|
|
|
|
|
sex: [{ |
|
|
|
|
|
text: '平台配送', |
|
|
|
|
|
value: 0 |
|
|
|
|
|
}, { |
|
|
|
|
|
text: '自送', |
|
|
|
|
|
value: 1 |
|
|
|
|
|
}], |
|
|
priceItems:[{ |
|
|
priceItems:[{ |
|
|
value: '0', |
|
|
value: '0', |
|
|
name: '零售价' |
|
|
name: '零售价' |
|
|
@ -281,10 +295,10 @@ |
|
|
value: '1', |
|
|
value: '1', |
|
|
name: '快递' |
|
|
name: '快递' |
|
|
}, |
|
|
}, |
|
|
{ |
|
|
// { |
|
|
value: '2', |
|
|
// value: '2', |
|
|
name: '自送' |
|
|
// name: '自送' |
|
|
}, |
|
|
// }, |
|
|
{ |
|
|
{ |
|
|
value: '3', |
|
|
value: '3', |
|
|
name: '拼包' |
|
|
name: '拼包' |
|
|
@ -312,16 +326,27 @@ |
|
|
totalAmount: 0, |
|
|
totalAmount: 0, |
|
|
customPrice:0,//选择自定义金额 |
|
|
customPrice:0,//选择自定义金额 |
|
|
remark:'', |
|
|
remark:'', |
|
|
pbAddress:'' |
|
|
pbAddress:'', |
|
|
|
|
|
carList1:[], |
|
|
|
|
|
radioType1:'' |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
onShow() { |
|
|
onShow() { |
|
|
let that = this; |
|
|
let that = this; |
|
|
this.khName = JSON.parse(JSON.stringify(this.khName)) || '' |
|
|
this.khName = JSON.parse(JSON.stringify(this.khName)) |
|
|
this.gysName = JSON.parse(JSON.stringify(this.gysName)) || '' |
|
|
this.gysName = JSON.parse(JSON.stringify(this.gysName)) |
|
|
this.wlName = JSON.parse(JSON.stringify(this.wlName)) || '' |
|
|
this.wlName = JSON.parse(JSON.stringify(this.wlName)) |
|
|
this.kdyName = JSON.parse(JSON.stringify(this.kdyName)) || '' |
|
|
this.kdyName = JSON.parse(JSON.stringify(this.kdyName)) |
|
|
this.lbgName = JSON.parse(JSON.stringify(this.lbgName)) || '' |
|
|
this.lbgName = JSON.parse(JSON.stringify(this.lbgName)) |
|
|
|
|
|
if(uni.getStorageSync('carList1')){ |
|
|
|
|
|
this.carList1 = uni.getStorageSync('carList1') |
|
|
|
|
|
this.remark = this.carList1[0].remark |
|
|
|
|
|
}else{ |
|
|
|
|
|
this.carList1 = this.carList1 |
|
|
|
|
|
} |
|
|
|
|
|
this.totalAmount = 0; |
|
|
|
|
|
this.shouldPay = 0 |
|
|
|
|
|
console.log('哈哈哈',this.carList1) |
|
|
if (this.carList.size == 0) { //当前页没有数据 |
|
|
if (this.carList.size == 0) { //当前页没有数据 |
|
|
for (let i = 0; i < this.carList1.length; i++) { |
|
|
for (let i = 0; i < this.carList1.length; i++) { |
|
|
let obj = { |
|
|
let obj = { |
|
|
@ -348,6 +373,7 @@ |
|
|
} |
|
|
} |
|
|
this.carList.set(this.carList1[i].id, obj) |
|
|
this.carList.set(this.carList1[i].id, obj) |
|
|
} |
|
|
} |
|
|
|
|
|
uni.removeStorageSync('carList1') |
|
|
this.carList1 = [] |
|
|
this.carList1 = [] |
|
|
} else { //当前页有数据 |
|
|
} else { //当前页有数据 |
|
|
for (let i = 0; i < this.carList1.length; i++) { |
|
|
for (let i = 0; i < this.carList1.length; i++) { |
|
|
@ -392,7 +418,6 @@ |
|
|
this.carList1 = [] |
|
|
this.carList1 = [] |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
that.shouldPay = 0 |
|
|
|
|
|
this.carList.forEach(function(value, key) { |
|
|
this.carList.forEach(function(value, key) { |
|
|
if(that.priceType == 0){ //零售 |
|
|
if(that.priceType == 0){ //零售 |
|
|
value.unitPrice = value.lsprice |
|
|
value.unitPrice = value.lsprice |
|
|
@ -423,13 +448,18 @@ |
|
|
return 10 |
|
|
return 10 |
|
|
}else if(val < 0){ |
|
|
}else if(val < 0){ |
|
|
return 0 |
|
|
return 0 |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
onLoad() { |
|
|
onLoad() { |
|
|
this.xsyList(); |
|
|
this.xsyList(); |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
|
|
|
//页面初始化信息处理 |
|
|
|
|
|
pageMessage(){ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
//销售员列表 |
|
|
//销售员列表 |
|
|
xsyList() { |
|
|
xsyList() { |
|
|
this.tui.request('/app/common/user/findAllUserByShopId', 'get', { |
|
|
this.tui.request('/app/common/user/findAllUserByShopId', 'get', { |
|
|
@ -454,7 +484,7 @@ |
|
|
}, |
|
|
}, |
|
|
//切换销售员 |
|
|
//切换销售员 |
|
|
categoryChange(e) { |
|
|
categoryChange(e) { |
|
|
for (i=0;i<this.categoryList.length;i++) { |
|
|
for (let i=0;i<this.categoryList.length;i++) { |
|
|
if(this.categoryList[i].value== e){ |
|
|
if(this.categoryList[i].value== e){ |
|
|
this.xsyId = e; |
|
|
this.xsyId = e; |
|
|
this.createByName = this.categoryList[i].text |
|
|
this.createByName = this.categoryList[i].text |
|
|
@ -494,7 +524,6 @@ |
|
|
}, |
|
|
}, |
|
|
//点击发货方式按钮 |
|
|
//点击发货方式按钮 |
|
|
radioChange(e) { |
|
|
radioChange(e) { |
|
|
this.khName = '' |
|
|
|
|
|
this.gysName = '' |
|
|
this.gysName = '' |
|
|
this.wlName = '' |
|
|
this.wlName = '' |
|
|
this.kdyName = '' |
|
|
this.kdyName = '' |
|
|
@ -523,6 +552,10 @@ |
|
|
url: '/pages/index/peopleList?popleType=' + popleType + '&companyType=' + companyType |
|
|
url: '/pages/index/peopleList?popleType=' + popleType + '&companyType=' + companyType |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
//是否平台取货 |
|
|
|
|
|
checkBoxChange(e){ |
|
|
|
|
|
this.radioType1 = e.detail.value |
|
|
|
|
|
}, |
|
|
//点击加号手动添加商品 |
|
|
//点击加号手动添加商品 |
|
|
goodsAdd() { |
|
|
goodsAdd() { |
|
|
uni.navigateTo({ |
|
|
uni.navigateTo({ |
|
|
@ -531,32 +564,34 @@ |
|
|
}, |
|
|
}, |
|
|
//点击底部开单按钮 |
|
|
//点击底部开单按钮 |
|
|
goSell() { |
|
|
goSell() { |
|
|
// console.log(this.khName) |
|
|
console.log(this.khName) |
|
|
// console.log(this.lbgName) |
|
|
console.log(this.lbgName) |
|
|
// console.log(this.wlName) |
|
|
console.log(this.wlName) |
|
|
let obj = { |
|
|
let obj = { |
|
|
orderByWorker: this.lbgName.workerId, |
|
|
|
|
|
transCompany: this.wlName.id, |
|
|
|
|
|
sale: { |
|
|
sale: { |
|
|
relPrice:this.relPrice, //实收金额 |
|
|
// relPrice:, |
|
|
alreadyEarn: this.priceOk, //已付金额 |
|
|
alreadyEarn: this.priceOk, //已付金额 |
|
|
realAmount: this.shouldPay, //总金额 |
|
|
realAmount: this.relPrice, //实收金额 |
|
|
noEarn: this.noPay, //欠款 |
|
|
noEarn: this.noPay, //欠款 |
|
|
totalAmount: this.totalAmount, //总数量 |
|
|
totalAmount: this.shouldPay, //总金额 |
|
|
area: this.khName.area, |
|
|
area: this.khName.area, |
|
|
city: this.khName.city, |
|
|
city: this.khName.city, |
|
|
province: this.khName.province, |
|
|
province: this.khName.province, |
|
|
payStatus: 1, |
|
|
payStatus: 1, |
|
|
receiveAddress: this.khName.address, |
|
|
receiveAddress: this.khName.address, |
|
|
transportType: this.radioType, //this.radioType |
|
|
userId:this.khName.userId, |
|
|
|
|
|
userName:this.khName.name, |
|
|
|
|
|
transportType: this.radioType1 == 1?2:this.radioType, //this.radioType |
|
|
discount: this.discountNum, |
|
|
discount: this.discountNum, |
|
|
createBy: this.xsyId, |
|
|
createBy: this.xsyId, |
|
|
createByName:this.createByName, |
|
|
createByName:this.createByName, |
|
|
remark: this.remark, |
|
|
remark: this.remark, |
|
|
otherExpense:this.otherExpense, //其他费用 |
|
|
otherExpense:this.otherExpense, //其他费用 |
|
|
pbAddress:this.pbAddress |
|
|
pbAddress:this.pbAddress, |
|
|
}, |
|
|
transCompany: this.wlName.id, |
|
|
|
|
|
companyName:this.wlName.companyName, |
|
|
|
|
|
orderByWorker: this.lbgName.workerId, |
|
|
|
|
|
}, |
|
|
saleDetailList: [] |
|
|
saleDetailList: [] |
|
|
} |
|
|
} |
|
|
let purchaseDetails = []; |
|
|
let purchaseDetails = []; |
|
|
|