Commit f808410d authored by 吴春's avatar 吴春

1

parent 7cd7066a
......@@ -28,7 +28,7 @@ export function getOrderSourceEnumList(data) {
*/
export function setClassOrder(data) {
return request({
url: '/order/SetClassOrder',
url: '/order/SetNewClassOrder',
method: 'post',
data
})
......@@ -40,7 +40,7 @@ export function setClassOrder(data) {
*/
export function SetClassOrderBatch(data) {
return request({
url: '/order/SetClassOrderBatch',
url: '/order/SetNewClassOrderBatch',
method: 'post',
data
})
......
......@@ -198,7 +198,13 @@
</div>
</template>
<template v-if="item.OrderType == 1">
<div v-if="item.CourseName">
<div v-if="item.ClassList&&item.ClassList.length>0">
课程名称:
<span v-for="(itemc, indexc) in item.ClassList">
{{indexc>1?',':""}}{{ itemc.CourseName }}
</span>
</div>
<div v-else="item.CourseName">
课程名称:{{ item.CourseName }}
</div>
<div v-if="item.CourseSubjectName">
......
......@@ -311,14 +311,40 @@ export default {
selectCourse(val) {
this.selectedCourseList = []
if (val.length > 0) {
this.saveObj = val[0];
this.saveObj.Unit_Price = this.saveObj.SellPrice;
// this.saveObj = val[0];
// this.saveObj.Unit_Price = this.saveObj.SellPrice;
this.selectedCourseList = val;
} else {
this.saveObj = {};
this.saveObj.Unit_Price = 0;
this.selectedCourseList = [];
}
}
this.saveObj = {};
this.saveObj.Unit_Price = 0;
this.saveObj.OrderCourseList =[];
if(this.selectedCourseList&&this.selectedCourseList.length>0){
this.selectedCourseList.forEach((item,index) => {
if(index==0){
this.saveObj = JSON.parse(JSON.stringify(item));
console.log("this.saveObj111",this.saveObj);
this.saveObj.Unit_Price = item.SellPrice;
this.saveObj.PreferPrice = item.SellPrice;
console.log("this.saveObj111.Unit_Price",this.saveObj.Unit_Price);
}
else{
this.saveObj.CourseName+=","+item.CourseName
this.saveObj.SellPrice+=Number(item.SellPrice)
this.saveObj.Unit_Price+=Number(item.SellPrice)
this.saveObj.TotalClassHours+=Number(item.TotalClassHours)
this.saveObj.DiscountMoney=0;//number(item.DiscountMoney)
this.saveObj.LessPrice=0;
this.saveObj.TextbookFee+=Number(item.TextbookFee)
this.saveObj.PreferPrice +=Number(item.SellPrice)
this.saveObj.CoursewareFee+=Number(item.CoursewareFee)
}
});
this.saveObj.OrderCourseList =[];
this.saveObj.OrderCourseList =this.selectedCourseList;
}
console.log("this.saveObj",this.saveObj);
console.log("this.selectedCourseList",this.selectedCourseList);
},
next() {
if (this.step == 1 && this.mode <= 0) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment