|
|
@@ -114,7 +114,7 @@
|
|
|
</div>
|
|
|
<div class="accounts-list">
|
|
|
采购人
|
|
|
- <el-select ref="cgStaffRef" style="width:80%" v-model="form.cgStaffName" placeholder="请选择,Ctrl + / 选中" @change="changeCgStaff">
|
|
|
+ <el-select ref="cgStaffRef" style="width:80%" v-model="form.cgStaffName" placeholder="请选择" @change="changeCgStaff">
|
|
|
<el-option v-for="item in staffList" :key="item.id" :label="item.name" :value="item"> </el-option>
|
|
|
</el-select>
|
|
|
</div>
|
|
|
@@ -131,32 +131,32 @@
|
|
|
<div class="accounts-list">
|
|
|
运费支付
|
|
|
<div class="accounts-center">
|
|
|
- <el-button :type="form.yfPayWay == 1?'primary':''" @keyup.enter.native="form.yfPayWay == 1" @click="changeYfPayWay(1)" size="small">寄付( Ctrl + , )</el-button>
|
|
|
- <el-button :type="form.yfPayWay == 2?'primary':''" @keyup.enter.native="form.yfPayWay == 2" @click="changeYfPayWay(2)" size="small">到付( Ctrl + . )</el-button>
|
|
|
+ <el-button :type="form.yfPayWay == 1?'primary':''" @keyup.enter.native="form.yfPayWay == 1" @click="changeYfPayWay(1)" size="small">寄付</el-button>
|
|
|
+ <el-button :type="form.yfPayWay == 2?'primary':''" @keyup.enter.native="form.yfPayWay == 2" @click="changeYfPayWay(2)" size="small">到付</el-button>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="accounts-list">
|
|
|
短途运费
|
|
|
<div class="accounts-center">
|
|
|
- <el-input @input="inputFn" placeholder="请填写运费,留空免运费" v-model="form.shortCharge"></el-input>
|
|
|
+ <el-input @input="inputFn" placeholder="请填写" v-model="form.shortCharge"></el-input>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="accounts-list">
|
|
|
长途运费
|
|
|
<div class="accounts-center">
|
|
|
- <el-input @input="inputFn" placeholder="请填写运费,留空免运费" v-model="form.longCharge"></el-input>
|
|
|
+ <el-input @input="inputFn" placeholder="请填写" v-model="form.longCharge"></el-input>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="accounts-list">
|
|
|
提货费
|
|
|
<div class="accounts-center">
|
|
|
- <el-input @input="inputFn" placeholder="请填写运费,留空免运费" v-model="form.pickCharge"></el-input>
|
|
|
+ <el-input @input="inputFn" placeholder="请填写" v-model="form.pickCharge"></el-input>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="accounts-list">
|
|
|
本地运费
|
|
|
<div class="accounts-center">
|
|
|
- <el-input @input="inputFn" placeholder="请填写运费,留空免运费" v-model="form.localCharge"></el-input>
|
|
|
+ <el-input @input="inputFn" placeholder="请填写" v-model="form.localCharge"></el-input>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="accounts-list">
|
|
|
@@ -167,21 +167,21 @@
|
|
|
应付金额
|
|
|
<el-input style="width: 80%" v-model="modifyPrice" @focus="modifyPrice=''"></el-input>
|
|
|
</div>
|
|
|
- <div class="accounts-list" v-if="modifyPrice > 0 && modifyPrice < finalPrice" style="font-size:25upx;margin-left:20upx;color:green;font-weight:bold;">
|
|
|
+ <div class="accounts-list" style="font-size:25upx;margin-left:20upx;color:green;font-weight:bold;">
|
|
|
减免金额
|
|
|
- <div class="accounts-center">¥{{(totalPrice - modifyPrice).toFixed(2) }}</div>
|
|
|
+ <div class="accounts-center">¥{{ parseFloat((totalPrice - modifyPrice).toFixed(2)) }}</div>
|
|
|
</div>
|
|
|
<div class="accounts-list">
|
|
|
物流费用
|
|
|
<div class="accounts-center">
|
|
|
- <el-button :type="form.isCost == 1?'primary':''" @keyup.enter.native="form.isCost == 1" @click="form.isCost = 1" size="small">算成本( Ctrl + , )</el-button>
|
|
|
- <el-button :type="form.isCost == 0?'primary':''" @keyup.enter.native="form.isCost == 0" @click="form.isCost = 0" size="small">不算成本( Ctrl + . )</el-button>
|
|
|
+ <el-button :type="form.isCost == 1?'primary':''" @keyup.enter.native="form.isCost == 1" @click="form.isCost = 1" size="small">算成本</el-button>
|
|
|
+ <el-button :type="form.isCost == 0?'primary':''" @keyup.enter.native="form.isCost == 0" @click="form.isCost = 0" size="small">不算成本</el-button>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="accounts-list">
|
|
|
备注
|
|
|
<div class="accounts-center">
|
|
|
- <el-input type="textarea" :rows="1" placeholder="这里写备注,F8 插入光标" v-model="form.remark" ref="remarkRef"> </el-input>
|
|
|
+ <el-input type="textarea" :rows="1" placeholder="这里写备注" v-model="form.remark" ref="remarkRef"> </el-input>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="accounts-list">
|
|
|
@@ -234,7 +234,6 @@ export default {
|
|
|
},
|
|
|
detailsInfo: {},
|
|
|
totalPrice:0,
|
|
|
- modifyPrice:0,
|
|
|
totalFreight:0,
|
|
|
perKgFreight:0,
|
|
|
location:0,
|
|
|
@@ -276,34 +275,6 @@ export default {
|
|
|
mixins: [productMins],
|
|
|
computed: {
|
|
|
...mapGetters(['shopInfo']),
|
|
|
- displayPackCost(){
|
|
|
- if(this.currentShop.pfLevel && this.currentShop.pfLevel == 1){
|
|
|
- return true
|
|
|
- }
|
|
|
- return false
|
|
|
- },
|
|
|
- displaySendCost(){
|
|
|
- if(this.form.sendType == 2){
|
|
|
- return true
|
|
|
- }
|
|
|
- if(this.currentShop.pfLevel && this.currentShop.pfLevel == 1){
|
|
|
- return true
|
|
|
- }
|
|
|
- return false
|
|
|
- },
|
|
|
- finalPrice(){
|
|
|
- let totalPrice = this.allPrice.toFixed(2)
|
|
|
- let finalPrice = Number(totalPrice)
|
|
|
- if(this.displaySendCost == true){
|
|
|
- finalPrice = Number(finalPrice) + Number(this.form.sendCost)
|
|
|
- }
|
|
|
- if(this.displayPackCost == true){
|
|
|
- finalPrice = Number(finalPrice) + Number(this.form.packCost)
|
|
|
- }
|
|
|
- let currentPrice = parseFloat(finalPrice)
|
|
|
- this.modifyPrice = currentPrice
|
|
|
- return currentPrice
|
|
|
- },
|
|
|
totalItemNum(){
|
|
|
let big = 0
|
|
|
let small = 0
|
|
|
@@ -392,31 +363,6 @@ export default {
|
|
|
if(e && e.key =='ArrowDown'){
|
|
|
that.goDown();
|
|
|
}
|
|
|
- if(e && e.key=='.' && e.ctrlKey){
|
|
|
- if(that.showCommitPop == true){
|
|
|
- that.form.needPrint = 2
|
|
|
- }
|
|
|
- }
|
|
|
- if( e && e.key==',' && e.ctrlKey){
|
|
|
- if(that.showCommitPop == true){
|
|
|
- that.form.needPrint = 1
|
|
|
- }
|
|
|
- }
|
|
|
- if( e && e.key=='/' && e.ctrlKey){
|
|
|
- if(that.showCommitPop == true){
|
|
|
- that.$refs.cgStaffRef.focus()
|
|
|
- }
|
|
|
- }
|
|
|
- if( e && e.key=='[' && e.ctrlKey){
|
|
|
- if(that.showCommitPop == true){
|
|
|
- that.form.hasPay = 2
|
|
|
- }
|
|
|
- }
|
|
|
- if( e && e.key==']' && e.ctrlKey){
|
|
|
- if(that.showCommitPop == true){
|
|
|
- that.form.hasPay = 1
|
|
|
- }
|
|
|
- }
|
|
|
if(e && e.key=='Delete'){
|
|
|
if(that.selectList[that.selectIndex]){
|
|
|
let current = that.selectList[that.selectIndex]
|
|
|
@@ -442,9 +388,6 @@ export default {
|
|
|
return;
|
|
|
}
|
|
|
that.$refs['itemSearchRef'].blur()
|
|
|
- that.setSendType(0)
|
|
|
- that.setTransType(4)
|
|
|
- that.form.hasPay = 2
|
|
|
that.showCommitPop = true
|
|
|
}
|
|
|
if(e && e.key=='F8'){
|
|
|
@@ -456,8 +399,6 @@ export default {
|
|
|
//门店信息
|
|
|
this.$service.common.shopInfo().then(res => {
|
|
|
that.currentShop = res.shopInfo
|
|
|
- let currentStaff = res.staff
|
|
|
- //获取开单人
|
|
|
that.$service.shopAdmin.getAllStaff().then(res => {
|
|
|
that.staffList = res.list
|
|
|
})
|
|
|
@@ -535,12 +476,6 @@ export default {
|
|
|
setTransType(type){
|
|
|
this.form.transType = type
|
|
|
},
|
|
|
- setSendType (type) {
|
|
|
- this.form.sendType = type
|
|
|
- if (type !== 2) {
|
|
|
- this.form.sendCost = ""
|
|
|
- }
|
|
|
- },
|
|
|
comeBack(){
|
|
|
this.form.ghsId = 0
|
|
|
this.form.ghsName = ''
|
|
|
@@ -599,25 +534,7 @@ export default {
|
|
|
}
|
|
|
let book = 0
|
|
|
let params = {...formData,modifyPrice: this.modifyPrice,newVersion:1,book:book};
|
|
|
-
|
|
|
- if(book == 1){
|
|
|
- if(this.form.hasPay != 2){
|
|
|
- this.$message({message: '预订单只能选择赊账',type: 'warning'})
|
|
|
- return false
|
|
|
- }
|
|
|
- if(Number(this.form.sendCost)>0){
|
|
|
- this.$message({message: '预订单不能填写运费',type: 'warning'})
|
|
|
- return false
|
|
|
- }
|
|
|
- }
|
|
|
let name = '确认提交'
|
|
|
- if(this.form.hasPay == 1){
|
|
|
- name = '确认线下付款?'
|
|
|
- }else if(this.form.hasPay == 2){
|
|
|
- name = '确认赊账?'
|
|
|
- }else{
|
|
|
- name = '确认提交'
|
|
|
- }
|
|
|
this.$confirm(name, '提示', { confirmButtonText: '确定', cancelButtonText: '取消', type: 'warning' }).then(() => {
|
|
|
that.$service.order.orderCreate(params).then(data => {
|
|
|
if(data.respondType && data.respondType == 'priceError'){
|