|
|
@ -118,7 +118,8 @@ |
|
|
|
<!-- 处理中 || 有未生效的课程 || (新增订单 && 有课程) --> |
|
|
|
<!-- 处理中 || 有未生效的课程 || (新增订单 && 有课程) --> |
|
|
|
<template v-if="!viewDisabled && (dispose || coursePermissions.find(e => e.status == 1) || (isAdd && coursePermissions.length))"> |
|
|
|
<template v-if="!viewDisabled && (dispose || coursePermissions.find(e => e.status == 1) || (isAdd && coursePermissions.length))"> |
|
|
|
<el-button v-if="coursePermissions.find(e => !e.ship)" v-auth="'/order:发货'" type="primary" round @click="batchDeliver(1, 0)">一键发货</el-button> |
|
|
|
<el-button v-if="coursePermissions.find(e => !e.ship)" v-auth="'/order:发货'" type="primary" round @click="batchDeliver(1, 0)">一键发货</el-button> |
|
|
|
<el-button v-else v-auth="'/order:发货'" type="primary" round @click="batchDeliver(0, 0)">取消全部发货</el-button> |
|
|
|
<el-button v-if="pageTypes" v-auth="'/order:发货'" type="primary" round @click="batchDeliver(0, 0)">取消全部发货</el-button> |
|
|
|
|
|
|
|
|
|
|
|
</template> |
|
|
|
</template> |
|
|
|
<el-button v-if="!viewDisabled&&!editDisabled&&!renewDisabled" type="primary" round @click="addCourseJurisdiction()">添加</el-button> |
|
|
|
<el-button v-if="!viewDisabled&&!editDisabled&&!renewDisabled" type="primary" round @click="addCourseJurisdiction()">添加</el-button> |
|
|
|
</div> |
|
|
|
</div> |
|
|
@ -237,7 +238,7 @@ |
|
|
|
3、处理中的订单显示发货,不显示禁用 |
|
|
|
3、处理中的订单显示发货,不显示禁用 |
|
|
|
--> |
|
|
|
--> |
|
|
|
<el-switch |
|
|
|
<el-switch |
|
|
|
v-if="scope.row.status === 1 || dispose || isAdd" |
|
|
|
v-if="scope.row.ship === 0 || dispose || isAdd " |
|
|
|
v-auth="'/order:发货'" |
|
|
|
v-auth="'/order:发货'" |
|
|
|
style="margin-right:10px;" |
|
|
|
style="margin-right:10px;" |
|
|
|
v-model="scope.row.ship" |
|
|
|
v-model="scope.row.ship" |
|
|
@ -819,6 +820,7 @@ export default { |
|
|
|
}, |
|
|
|
}, |
|
|
|
data() { |
|
|
|
data() { |
|
|
|
return { |
|
|
|
return { |
|
|
|
|
|
|
|
pageTypes: false, |
|
|
|
loading: false,// 页面加载 |
|
|
|
loading: false,// 页面加载 |
|
|
|
isAdd: false, // 是否添加 |
|
|
|
isAdd: false, // 是否添加 |
|
|
|
viewDisabled: false,// 查看禁用 |
|
|
|
viewDisabled: false,// 查看禁用 |
|
|
@ -985,7 +987,7 @@ export default { |
|
|
|
this.searchTimer = setTimeout(() => { |
|
|
|
this.searchTimer = setTimeout(() => { |
|
|
|
this.getDataJurisdiction(); |
|
|
|
this.getDataJurisdiction(); |
|
|
|
}, 500); |
|
|
|
}, 500); |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
async created() { |
|
|
|
async created() { |
|
|
|
this.getTeam() |
|
|
|
this.getTeam() |
|
|
@ -1207,7 +1209,8 @@ export default { |
|
|
|
if (this.coursePermissions.length) { |
|
|
|
if (this.coursePermissions.length) { |
|
|
|
let courseVerify = |
|
|
|
let courseVerify = |
|
|
|
this.coursePermissions.some(e => { |
|
|
|
this.coursePermissions.some(e => { |
|
|
|
if (!e.periodOfUse || e.finalPrice === '') { |
|
|
|
// if (!e.periodOfUse || e.finalPrice === '') { |
|
|
|
|
|
|
|
if (!e.periodOfUse || e.finalPrice === '' || !e.startTime) { |
|
|
|
return false; |
|
|
|
return false; |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
const curPurchase = +e.settlementPrice + (e.settlementPrice * (this.rate / 100)) |
|
|
|
const curPurchase = +e.settlementPrice + (e.settlementPrice * (this.rate / 100)) |
|
|
@ -1292,6 +1295,7 @@ export default { |
|
|
|
orderOther: tempArr//俩列表 |
|
|
|
orderOther: tempArr//俩列表 |
|
|
|
}; |
|
|
|
}; |
|
|
|
this.loading = true; |
|
|
|
this.loading = true; |
|
|
|
|
|
|
|
console.log(param) |
|
|
|
if (this.editDisabled) { |
|
|
|
if (this.editDisabled) { |
|
|
|
this.$post(this.api.orderUpdate, param).then(res => { |
|
|
|
this.$post(this.api.orderUpdate, param).then(res => { |
|
|
|
this.refreshCache() |
|
|
|
this.refreshCache() |
|
|
@ -1410,7 +1414,7 @@ export default { |
|
|
|
discountRate: "",// 折扣率 |
|
|
|
discountRate: "",// 折扣率 |
|
|
|
accountNum: "",// 账号数 |
|
|
|
accountNum: "",// 账号数 |
|
|
|
totalAmount: "",// 总价 |
|
|
|
totalAmount: "",// 总价 |
|
|
|
isEnable: 1, // 启用否:1启用,0禁用 |
|
|
|
isEnable: 0, // 启用否:1启用,0禁用 |
|
|
|
ship: 0,// 发货否(0未发货,1已发货,默认不发货) |
|
|
|
ship: 0,// 发货否(0未发货,1已发货,默认不发货) |
|
|
|
authority: 1, // 区分权限 0为数据平台权限,1为课程权限 |
|
|
|
authority: 1, // 区分权限 0为数据平台权限,1为课程权限 |
|
|
|
options: 1, |
|
|
|
options: 1, |
|
|
@ -1647,16 +1651,28 @@ export default { |
|
|
|
}, |
|
|
|
}, |
|
|
|
// 课程/数据平台-启用 |
|
|
|
// 课程/数据平台-启用 |
|
|
|
handleEnable(e, row) { |
|
|
|
handleEnable(e, row) { |
|
|
|
|
|
|
|
console.log('1111=>',e) |
|
|
|
|
|
|
|
console.log('row=>',row) |
|
|
|
|
|
|
|
if (row.isEnable === 0 ) { |
|
|
|
|
|
|
|
this.pageTypes = false |
|
|
|
|
|
|
|
}else { |
|
|
|
|
|
|
|
this.pageTypes = false |
|
|
|
|
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
// 一键发货 |
|
|
|
// 一键发货 |
|
|
|
batchDeliver(ship, data) { |
|
|
|
batchDeliver(ship, data) { |
|
|
|
|
|
|
|
this.pageTypes = !this.pageTypes |
|
|
|
const list = data == 1 ? |
|
|
|
const list = data == 1 ? |
|
|
|
this.dataPlatformPermissions : |
|
|
|
this.dataPlatformPermissions : |
|
|
|
data == 2 ? |
|
|
|
data == 2 ? |
|
|
|
this.valuePermissions : |
|
|
|
this.valuePermissions : |
|
|
|
this.coursePermissions |
|
|
|
this.coursePermissions |
|
|
|
list.map(e => e.ship = ship) |
|
|
|
list.map(e => { |
|
|
|
|
|
|
|
e.ship = ship |
|
|
|
|
|
|
|
if(e.ship === 1) { |
|
|
|
|
|
|
|
e.isEnable = 1 |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
if (this.editDisabled) { |
|
|
|
if (this.editDisabled) { |
|
|
|
// this.refreshCache() |
|
|
|
// this.refreshCache() |
|
|
|
// this.$post(this.api.bulkShipping, { |
|
|
|
// this.$post(this.api.bulkShipping, { |
|
|
@ -1666,9 +1682,11 @@ export default { |
|
|
|
}, |
|
|
|
}, |
|
|
|
// 课程/数据平台-发货 |
|
|
|
// 课程/数据平台-发货 |
|
|
|
handleDeliver(e, row) { |
|
|
|
handleDeliver(e, row) { |
|
|
|
if (this.editDisabled) { |
|
|
|
if(row.ship === 1) { |
|
|
|
// this.refreshCache() |
|
|
|
row.isEnable = 1 |
|
|
|
// this.$post(this.api.ship,row).then(res => {}); |
|
|
|
this.pageType = true |
|
|
|
|
|
|
|
}else { |
|
|
|
|
|
|
|
this.pageType = false |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
// 如果非数字,则返回0 |
|
|
|
// 如果非数字,则返回0 |
|
|
|