Commit 967b05b9 authored by zhengke's avatar zhengke
parents bd3acd8a 7d71e0f1
...@@ -284,3 +284,15 @@ export function saveRenewOrder(data) { ...@@ -284,3 +284,15 @@ export function saveRenewOrder(data) {
data data
}) })
} }
/**
* 销售 我的留学就业订单
*
*/
export function getMyStudyOrderPage(data) {
return request({
url: '/order/GetMyStudyOrderPageList',
method: 'post',
data
})
}
...@@ -54,7 +54,9 @@ ...@@ -54,7 +54,9 @@
OrderSource: 0, OrderSource: 0,
SaleRemark: "", SaleRemark: "",
Class_Price: 0, Class_Price: 0,
OrderId:0, OrderId: 0,
OrderType: 0, //订单类型(1-班级课程订单,2-留学就业订单)
SourceId: 0, //来源编号
}, },
UPrice: false, UPrice: false,
StepPriceList: [], StepPriceList: [],
...@@ -98,6 +100,8 @@ ...@@ -98,6 +100,8 @@
this.OrderMsg.SaleRemark = res.Data.OrderInfo.SaleRemark; this.OrderMsg.SaleRemark = res.Data.OrderInfo.SaleRemark;
this.OrderMsg.Class_Price = res.Data.OrderInfo.Class_Price; this.OrderMsg.Class_Price = res.Data.OrderInfo.Class_Price;
this.OrderMsg.OrderId = res.Data.OrderInfo.OrderId; this.OrderMsg.OrderId = res.Data.OrderInfo.OrderId;
this.OrderMsg.OrderType = res.Data.OrderInfo.OrderType;
this.OrderMsg.SourceId = res.Data.OrderInfo.SourceId;
this.UnitPrice = this.OrderMsg.Unit_Price; this.UnitPrice = this.OrderMsg.Unit_Price;
this.StepPriceList = res.Data.StepPriceList; this.StepPriceList = res.Data.StepPriceList;
this.IsShowEditOrder = true; this.IsShowEditOrder = true;
...@@ -161,7 +165,7 @@ ...@@ -161,7 +165,7 @@
return this.OrderMsg.Class_Price; return this.OrderMsg.Class_Price;
} }
}, },
getSortFun(order, sortBy){ getSortFun(order, sortBy) {
var ordAlpah = (order == 'asc') ? '>' : '<'; var ordAlpah = (order == 'asc') ? '>' : '<';
var sortFun = new Function('a', 'b', 'return a.' + sortBy + ordAlpah + 'b.' + sortBy + '?1:-1'); var sortFun = new Function('a', 'b', 'return a.' + sortBy + ordAlpah + 'b.' + sortBy + '?1:-1');
return sortFun; return sortFun;
......
...@@ -51,7 +51,14 @@ ...@@ -51,7 +51,14 @@
<span class="two-r">{{Detail.GuestNum}}</span> <span class="two-r">{{Detail.GuestNum}}</span>
</div> </div>
<div class="col-6 row"> <div class="col-6 row">
<span class="two-left">班级信息:</span> <span class="two-left">
<template v-if="Detail.OrderType==1">
班级信息
</template>
<template v-if="Detail.OrderType==2">
产品信息
</template>
</span>
<span class="two-r">{{Detail.ClassName}}</span> <span class="two-r">{{Detail.ClassName}}</span>
</div> </div>
<div class="col-6 row"> <div class="col-6 row">
...@@ -473,8 +480,8 @@ ...@@ -473,8 +480,8 @@
TCID: 0, TCID: 0,
OrderID: 0, OrderID: 0,
Type: 1, Type: 1,
IsSellOrderForm:1, IsSellOrderForm: 1,
IsFormRecPayQuery:1 IsFormRecPayQuery: 1
}, },
dataList: [], dataList: [],
dataListP: [], dataListP: [],
...@@ -520,7 +527,7 @@ ...@@ -520,7 +527,7 @@
OrderId: this.saveObj.OrderId OrderId: this.saveObj.OrderId
}).then(res => { }).then(res => {
this.Detail = res.Data; this.Detail = res.Data;
this.getfinanciaALLPageList(1,this.Detail.ClassId,this.Detail.OrderId) //财务单据 this.getfinanciaALLPageList(1, this.Detail.ClassId, this.Detail.OrderId) //财务单据
}).catch(() => { }).catch(() => {
}) })
...@@ -583,7 +590,7 @@ ...@@ -583,7 +590,7 @@
}) })
}, },
getfinanciaALLPageList(Type,TCID,OrderID) { getfinanciaALLPageList(Type, TCID, OrderID) {
this.floading = true this.floading = true
this.financiaMsg.TCID = TCID this.financiaMsg.TCID = TCID
this.financiaMsg.OrderID = OrderID this.financiaMsg.OrderID = OrderID
...@@ -593,7 +600,7 @@ ...@@ -593,7 +600,7 @@
let data = res.data.data.pageData.list; let data = res.data.data.pageData.list;
if (Type === 1) { if (Type === 1) {
this.dataList = data; this.dataList = data;
this.getfinanciaALLPageList(2,TCID,OrderID) this.getfinanciaALLPageList(2, TCID, OrderID)
} else { } else {
this.dataListP = data; this.dataListP = data;
this.floading = false this.floading = false
...@@ -616,7 +623,7 @@ ...@@ -616,7 +623,7 @@
}, },
//返回2位小数 //返回2位小数
getTwoWei(num) { getTwoWei(num) {
if (num>=0) { if (num >= 0) {
return num.toFixed(2); return num.toFixed(2);
} }
} }
......
...@@ -26,8 +26,15 @@ ...@@ -26,8 +26,15 @@
</div> </div>
<div>{{item.EnterName}}</div> <div>{{item.EnterName}}</div>
<div style="margin-top: 10px">{{item.CreateTime}}</div> <div style="margin-top: 10px">{{item.CreateTime}}</div>
<template v-if="isShowClass"> <template v-if="AuthorityObj.isShowName">
<div style="margin-top: 30px;margin-bottom: 10px">班级</div> <div style="margin-top: 30px;margin-bottom: 10px">
<template v-if="item.OrderType==1">
班级
</template>
<template v-if="item.OrderType==2">
留学就业
</template>
</div>
<div style="font-weight: bold;color:#2961FE;cursor:pointer;" @click="getClassInfo(item)"> <div style="font-weight: bold;color:#2961FE;cursor:pointer;" @click="getClassInfo(item)">
{{item.ClassName}}</div> {{item.ClassName}}</div>
</template> </template>
...@@ -70,43 +77,43 @@ ...@@ -70,43 +77,43 @@
<q-item-label>学生名单</q-item-label> <q-item-label>学生名单</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup v-if="isShowClass"> <q-item clickable v-close-popup v-if="AuthorityObj.isShowTransOrder">
<q-item-section @click="transferOrder(item,1)"> <q-item-section @click="transferOrder(item,1)">
<q-item-label>转交订单</q-item-label> <q-item-label>转交订单</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup v-if="!isShowClass"> <q-item clickable v-close-popup v-if="AuthorityObj.isShowEditSale">
<q-item-section @click="transferOrder(item,2)"> <q-item-section @click="transferOrder(item,2)">
<q-item-label>修改销售</q-item-label> <q-item-label>修改销售</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup v-if="isShowClass"> <q-item clickable v-close-popup v-if="AuthorityObj.isShowSaleRemark">
<q-item-section @click="editOrderRemark(item,1)"> <q-item-section @click="editOrderRemark(item,1)">
<q-item-label>销售备注</q-item-label> <q-item-label>销售备注</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup v-if="!isShowClass"> <q-item clickable v-close-popup v-if="AuthorityObj.isShowEducationRemark">
<q-item-section @click="editOrderRemark(item,2)"> <q-item-section @click="editOrderRemark(item,2)">
<q-item-label>教务备注</q-item-label> <q-item-label>教务备注</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup v-if="!isShowClass"> <q-item clickable v-close-popup v-if="AuthorityObj.isShowPrincipalRemark">
<q-item-section @click="editOrderRemark(item,3)"> <q-item-section @click="editOrderRemark(item,3)">
<q-item-label>校长备注</q-item-label> <q-item-label>校长备注</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup v-if="!isShowClass"> <q-item clickable v-close-popup v-if="AuthorityObj.isShowManagerRemark">
<q-item-section @click="editOrderRemark(item,4)"> <q-item-section @click="editOrderRemark(item,4)">
<q-item-label>总经理备注</q-item-label> <q-item-label>总经理备注</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup v-if="!isShowClass&&item.IsCommissionGive==1"> <q-item clickable v-close-popup v-if="AuthorityObj.isShowCommissionEdit&&item.IsCommissionGive==1">
<q-item-section @click="upDateMoney(item,1)"> <q-item-section @click="upDateMoney(item,1)">
<q-item-label>修改提成</q-item-label> <q-item-label>修改提成</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup v-if="!isShowClass"> <q-item clickable v-close-popup v-if="AuthorityObj.isShowRewardEdit">
<q-item-section @click="upDateMoney(item,2)"> <q-item-section @click="upDateMoney(item,2)">
<q-item-label>额外奖励</q-item-label> <q-item-label>额外奖励</q-item-label>
</q-item-section> </q-item-section>
...@@ -117,12 +124,12 @@ ...@@ -117,12 +124,12 @@
<q-item-label>取消订单</q-item-label> <q-item-label>取消订单</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup v-close-popup v-if="isShowClass"> <q-item clickable v-close-popup v-close-popup v-if="AuthorityObj.isShowBackClass">
<q-item-section> <q-item-section>
<q-item-label @click="showBackClassForm(item)">退课</q-item-label> <q-item-label @click="showBackClassForm(item)">退课</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup v-close-popup v-if="isShowClass"> <q-item clickable v-close-popup v-close-popup v-if="AuthorityObj.isShowRenewClass">
<q-item-section> <q-item-section>
<q-item-label @click="showContinueClass(item)">续课</q-item-label> <q-item-label @click="showContinueClass(item)">续课</q-item-label>
</q-item-section> </q-item-section>
...@@ -451,8 +458,8 @@ ...@@ -451,8 +458,8 @@
<div class="col"> <div class="col">
<div class="row" style="justify-content: space-between"> <div class="row" style="justify-content: space-between">
<span>收款单据:</span> <span>收款单据:</span>
<q-btn flat size="xs" icon="edit" v-if="isShowClass" style="font-weight:400;color: #02C499" label="修改" <q-btn flat size="xs" icon="edit" v-if="AuthorityObj.isShowFinanceBtn"
@click="chanceType(item,1)" /> style="font-weight:400;color: #02C499" label="修改" @click="chanceType(item,1)" />
</div> </div>
<div class="row wrap"> <div class="row wrap">
<div class="finance row" v-for="(x,j) in item.FinanceList" :index="j" <div class="finance row" v-for="(x,j) in item.FinanceList" :index="j"
...@@ -464,8 +471,8 @@ ...@@ -464,8 +471,8 @@
</div> </div>
<div class="row" style="justify-content: space-between"> <div class="row" style="justify-content: space-between">
<span>付款单据:</span> <span>付款单据:</span>
<q-btn flat size="xs" icon="edit" v-if="isShowClass" style="font-weight:400;color: #02C499" label="修改" <q-btn flat size="xs" icon="edit" v-if="AuthorityObj.isShowFinanceBtn"
@click="chanceType(item,2)" /> style="font-weight:400;color: #02C499" label="修改" @click="chanceType(item,2)" />
</div> </div>
<div class="row wrap"> <div class="row wrap">
<div class="finance row" v-for="(x,j) in item.RefundFinanceList" :index="j" <div class="finance row" v-for="(x,j) in item.RefundFinanceList" :index="j"
...@@ -509,7 +516,8 @@ ...@@ -509,7 +516,8 @@
<continueclass-form v-if="isShowContinueClass" :save-obj="orderObj" @close="closeContinueClassForm" <continueclass-form v-if="isShowContinueClass" :save-obj="orderObj" @close="closeContinueClassForm"
@success="refreshClassOrder"></continueclass-form> @success="refreshClassOrder"></continueclass-form>
<!-- 查看报价单 --> <!-- 查看报价单 -->
<viewquotation-form v-if="isShowviewQuo" :rId="rId" :isShowCancle="1" @close="closeQuota" @success="refreshView"> <viewquotation-form v-if="isShowviewQuo" :rId="offerId" :isShowCancle="1" @close="closeQuota"
@success="refreshView">
</viewquotation-form> </viewquotation-form>
</div> </div>
...@@ -556,11 +564,13 @@ ...@@ -556,11 +564,13 @@
type: Array, type: Array,
default: null default: null
}, },
//是否显示班级
isShowClass: { isShowClass: {
type: Boolean type: Boolean
}, },
Comtype: { //权限数据
type: Number authObj: {
type: Object,
} }
}, },
data() { data() {
...@@ -581,31 +591,87 @@ ...@@ -581,31 +591,87 @@
moneyObj: {}, moneyObj: {},
CommonType: -1, //用于判断是修改提成还是额外奖励 CommonType: -1, //用于判断是修改提成还是额外奖励
EmployeeList: [], //员工列表 EmployeeList: [], //员工列表
isShowviewQuo:false, isShowviewQuo: false, //是否显示报价单
rId:0 offerId: 0, //报价单编号
//权限显示对象
AuthorityObj: {
isShowName: true, //是否显示班级、留学就业产品名称【默认显示】
isShowGuestBtn: 0, //是否显示学员名单新增按钮【0-不显示,1-显示】
isShowFinanceBtn: false, //是否显示财务单据录入按钮【true显示,false不显示】
isShowTransOrder: false, //是否显示转交订单【true显示,false不显示】
isShowEditSale: false, //是否显示修改销售按钮【true显示,false不显示】
isShowSaleRemark: false, //是否显示修改销售备注按钮
isShowEducationRemark: false, //是否显示修改教务备注按钮
isShowPrincipalRemark: false, //是否显示修改校长备注按钮
isShowManagerRemark: false, //是都显示总经理备注
isShowCommissionEdit: false, //是否显示修改提成按钮
isShowRewardEdit: false, //是否显示修改额外提成按钮
isShowBackClass: false, //是否显示退课按钮
isShowRenewClass: false, //是否显示续课按钮
},
} }
}, },
created() { created() {
this.Employee() this.initAuth();
this.Employee();
}, },
mounted() {}, mounted() {},
methods: { methods: {
closeQuota(){ //初始化权限信息
this.isShowviewQuo=false; initAuth() {
if (this.authObj) {
if (this.authObj.isShowName != null && !this.authObj.isShowName) {
this.AuthorityObj.isShowName = this.authObj.isShowName;
}
if (this.authObj.isShowGuestBtn != null && this.authObj.isShowGuestBtn > 0) {
this.AuthorityObj.isShowGuestBtn = this.authObj.isShowGuestBtn;
}
if (this.authObj.isShowFinanceBtn != null && this.authObj.isShowFinanceBtn) {
this.AuthorityObj.isShowFinanceBtn = this.authObj.isShowFinanceBtn;
}
if (this.authObj.isShowTransOrder != null && this.authObj.isShowTransOrder) {
this.AuthorityObj.isShowTransOrder = this.authObj.isShowTransOrder;
}
if (this.authObj.isShowEditSale != null && this.authObj.isShowEditSale) {
this.AuthorityObj.isShowEditSale = this.authObj.isShowEditSale;
}
if (this.authObj.isShowSaleRemark != null && this.authObj.isShowSaleRemark) {
this.AuthorityObj.isShowSaleRemark = this.authObj.isShowSaleRemark;
}
if (this.authObj.isShowEducationRemark != null && this.authObj.isShowEducationRemark) {
this.AuthorityObj.isShowEducationRemark = this.authObj.isShowEducationRemark;
}
if (this.authObj.isShowPrincipalRemark != null && this.authObj.isShowPrincipalRemark) {
this.AuthorityObj.isShowPrincipalRemark = this.authObj.isShowPrincipalRemark;
}
if (this.authObj.isShowManagerRemark != null && this.authObj.isShowManagerRemark) {
this.AuthorityObj.isShowManagerRemark = this.authObj.isShowManagerRemark;
}
if (this.authObj.isShowCommissionEdit != null && this.authObj.isShowCommissionEdit) {
this.AuthorityObj.isShowCommissionEdit = this.authObj.isShowCommissionEdit;
}
if (this.authObj.isShowRewardEdit != null && this.authObj.isShowRewardEdit) {
this.AuthorityObj.isShowRewardEdit = this.authObj.isShowRewardEdit;
}
if (this.authObj.isShowBackClass != null && this.authObj.isShowBackClass) {
this.AuthorityObj.isShowBackClass = this.authObj.isShowBackClass;
}
if (this.authObj.isShowRenewClass != null && this.authObj.isShowRenewClass) {
this.AuthorityObj.isShowRenewClass = this.authObj.isShowRenewClass;
}
}
}, },
refreshView(){ closeQuota() {
this.isShowviewQuo = false;
},
//刷新页面
refreshView() {
}, },
//跳转 //跳转到报价单
goQuotation(Id) { goQuotation(Id) {
this.rId=Id; this.offerId = Id;
this.isShowviewQuo=true; this.isShowviewQuo = true;
// this.$router.push({
// path: "/sale/quotation",
// query: {
// Id: Id
// }
// });
}, },
getTkshow(data) { getTkshow(data) {
let Tkshow = false; let Tkshow = false;
...@@ -710,7 +776,7 @@ ...@@ -710,7 +776,7 @@
this.$router.push({ this.$router.push({
path: tempStr, path: tempStr,
query: { query: {
isShow: this.Comtype isShow: this.AuthorityObj.isShowGuestBtn
} }
}); });
}, },
...@@ -783,18 +849,18 @@ ...@@ -783,18 +849,18 @@
chanceType(obj, type) { chanceType(obj, type) {
let TCIDARR = [] let TCIDARR = []
TCIDARR.push(obj.ClassId); TCIDARR.push(obj.ClassId);
var orderObj={} var orderObj = {}
if(obj.OfferId>0){ if (obj.OfferId > 0) {
orderObj = { orderObj = {
OrderID: obj.OrderId, OrderID: obj.OrderId,
OrderSource: 17, OrderSource: 17,
Obj: {}, Obj: {},
SourceID: 0, SourceID: 0,
TCIDList: TCIDARR, TCIDList: TCIDARR,
OtherType:29, OtherType: 29,
ReFinanceId:obj.OfferId ReFinanceId: obj.OfferId
} }
}else{ } else {
orderObj = { orderObj = {
OrderID: obj.OrderId, OrderID: obj.OrderId,
OrderSource: 17, OrderSource: 17,
......
<template>
<q-dialog v-model="persistent" maximized full-height seamless position="right">
<q-card style="margin-top:61px;width:500px" class="no-border-radius classinfo_Dialog">
<div class="drawerTop">
<div style="display:flex;align-items:center;margin-left:10px;">
<span class="drawer_Span">学员报名</span>
</div>
</div>
<div style="padding:20px 15px;">
<q-input filled stack-label maxlength="4" :dense="false" v-model="enrollMsg.GuestNum" type="number"
@input="countPrice" class="col-12" label="人数" :rules="[val => !!val || '请填写人数']" />
<q-input filled stack-label :dense="false" maxlength="8" v-model="enrollMsg.Unit_Price"
:disable="UPrice==true?false:true" @blur="countPrice" class="col-12" label="成交单价"
:rules="[val => !!val || '请填成交单价']" />
<q-select standout="bg-primary text-white" option-value="Id" option-label="Name" v-model="enrollMsg.OrderSource"
:options="SourceEnumList" emit-value map-options label="客人来源" />
<q-input filled stack-label type="textarea" maxlength="500" :dense="false" v-model="enrollMsg.SaleRemark"
style="margin-top: 20px" class="col-12" label="备注" />
<div style="margin:30px 10px 0 0;">
<q-btn class="q-mr-md" label="取消" @click="persistent=false" />
<q-btn color="accent" class="q-mr-md" label="保存" @click="saveSatMsg()" />
</div>
</div>
</q-card>
<div class="dialog-out-close" @click="persistent=false"
style="height:40px !important;border-top-left-radius: 4px !important;border-bottom-left-radius: 4px !important;">
<q-icon name="iconfont icon-jujue1" size="26px" />
</div>
</q-dialog>
</template>
<script>
import {
getOrderSourceEnumList, //获取订单来源 枚举
setClassOrder, //新增 修改订单
} from '../../api/sale/sale';
export default {
name: "studyOrder-form",
props: {
saveObj: {
type: Object,
default: null,
},
},
data() {
return {
persistent: true,
//学员报名
enrollMsg: {
ClassId: 0,
GuestNum: 1,
Unit_Price: 0, //成交单价
PreferPrice: 0, //应收总额
OrderSource: 0, //客人来源 枚举
SaleRemark: '', //备注
OrderType: 2, //订单类型(1-班级课程订单,2-留学就业订单)
SourceId: 0, //来源变化
},
UPrice: 0, //单价
SourceEnumList: [], //来源
}
},
created() {
this.getOrderSEList();
},
mounted() {
this.enrollMsg.Unit_Price = this.saveObj.SellPrice;
this.enrollMsg.SourceId = this.saveObj.Id;
this.countPrice();
},
methods: {
//获取客人来源列表
getOrderSEList() {
getOrderSourceEnumList({}).then(res => {
if (res.Code == 1) {
var tempArray = res.Data;
this.SourceEnumList = tempArray;
this.enrollMsg.OrderSource = tempArray[0].Id;
}
})
},
//计算价格
countPrice() {
var guestNum = 0;
var unit_price = 0;
if (this.enrollMsg.GuestNum && this.enrollMsg.GuestNum > 0) {
guestNum = Number(this.enrollMsg.GuestNum);
}
if (this.enrollMsg.Unit_Price && this.enrollMsg.Unit_Price > 0) {
unit_price = Number(this.enrollMsg.Unit_Price);
}
this.enrollMsg.PreferPrice = Number(guestNum * unit_price).toFixed(2);
},
//保存订单
saveSatMsg() {
setClassOrder(this.enrollMsg).then(res => {
if (res.Code == 1) {
this.$q.notify({
icon: 'iconfont icon-chenggong',
color: 'accent',
timeout: 2000,
message: '报名成功!',
position: 'top'
})
this.$emit("save");
}
}).catch(() => {})
},
}
}
</script>
<template> <template>
<div class="page-body myOrder"> <div class="page-body myOrder">
<div class="row col" style="height: 40px"> <div class="row col" style="height: 40px">
<div class="row col" style="justify-content: space-between;align-items: center;margin-bottom: 10px" > <div class="row col" style="justify-content: space-between;align-items: center;margin-bottom: 10px">
<div> <div>
<template v-if="data&& data.ClassInfo"> <template v-if="data&& data.ClassInfo">
...@@ -14,7 +14,8 @@ ...@@ -14,7 +14,8 @@
<img :src="data.ClassInfo.TeacherIcon" /> <img :src="data.ClassInfo.TeacherIcon" />
</q-avatar> </q-avatar>
<q-avatar style="margin:0 5px;" size="sm" color="teal-10" text-color="white" v-else> <q-avatar style="margin:0 5px;" size="sm" color="teal-10" text-color="white" v-else>
<template v-if="data.ClassInfo&&data.ClassInfo.TeacherName">{{data.ClassInfo.TeacherName.substring(0,1)}}</template> <template
v-if="data.ClassInfo&&data.ClassInfo.TeacherName">{{data.ClassInfo.TeacherName.substring(0,1)}}</template>
</q-avatar> </q-avatar>
<span v-if="data&& data.ClassInfo" style="color:#2961FE;font-weight: bold"> <span v-if="data&& data.ClassInfo" style="color:#2961FE;font-weight: bold">
{{data.ClassInfo.TeacherName}} {{data.ClassInfo.TeacherName}}
...@@ -23,7 +24,8 @@ ...@@ -23,7 +24,8 @@
</div> </div>
</div> </div>
<div class="page-content"> <div class="page-content">
<orderlist :dataList="dataList" :isShowClass="false" ref="orderL" :Comtype="2" :cancelList="CancelList" @success="refreshClassOrder"></orderlist> <orderlist :dataList="dataList" ref="orderL" :authObj="authObj" :cancelList="CancelList"
@success="refreshClassOrder"></orderlist>
</div> </div>
</div> </div>
</template> </template>
...@@ -47,13 +49,22 @@ ...@@ -47,13 +49,22 @@
dataList: [], dataList: [],
//取消订单 //取消订单
CancelList: [], CancelList: [],
//权限判断
authObj: {
isShowName: false, //不显示班级名称
isShowEditSale: true, //显示修改销售按钮
isShowEducationRemark: true, //显示修改教务备注
isShowPrincipalRemark: true, //显示校长备注
isShowManagerRemark: true, //显示总经理备注
isShowCommissionEdit: true, //显示修改提成按钮
isShowRewardEdit: true, //显示修改额外提成按钮
}
} }
}, },
created() { created() {
if (this.$route.query.ClassId) { if (this.$route.query.ClassId) {
this.ClassId = this.$route.query.ClassId this.ClassId = this.$route.query.ClassId
this.msg.ClassId = this.ClassId; this.msg.ClassId = this.ClassId;
} }
this.getList(); this.getList();
}, },
...@@ -68,27 +79,27 @@ ...@@ -68,27 +79,27 @@
this.data = res.Data; this.data = res.Data;
if (this.data && this.data.OrderList && this.data.OrderList.NorList) { if (this.data && this.data.OrderList && this.data.OrderList.NorList) {
this.dataList = this.data.OrderList.NorList; this.dataList = this.data.OrderList.NorList;
let OrderIds=[] let OrderIds = []
this.dataList.forEach(x=>{ this.dataList.forEach(x => {
OrderIds.push(x.OrderId) OrderIds.push(x.OrderId)
}) })
if(OrderIds.length>0){ if (OrderIds.length > 0) {
OrderIds = OrderIds.join(',') OrderIds = OrderIds.join(',')
if(this.dataList.length>0){ if (this.dataList.length > 0) {
this.$refs.orderL.getOrderFinanceList(OrderIds,1) this.$refs.orderL.getOrderFinanceList(OrderIds, 1)
} }
} }
} }
if (this.data && this.data.OrderList && this.data.OrderList.CancelList) { if (this.data && this.data.OrderList && this.data.OrderList.CancelList) {
this.CancelList = this.data.OrderList.CancelList; this.CancelList = this.data.OrderList.CancelList;
let OrderIds=[] let OrderIds = []
this.CancelList.forEach(x=>{ this.CancelList.forEach(x => {
OrderIds.push(x.OrderId) OrderIds.push(x.OrderId)
}) })
if(OrderIds.length>0){ if (OrderIds.length > 0) {
OrderIds = OrderIds.join(',') OrderIds = OrderIds.join(',')
if(this.CancelList.length>0){ if (this.CancelList.length > 0) {
this.$refs.orderL.getOrderFinanceList(OrderIds,2) this.$refs.orderL.getOrderFinanceList(OrderIds, 2)
} }
} }
} }
......
...@@ -18,18 +18,6 @@ ...@@ -18,18 +18,6 @@
<q-select @input="resetSearch" standout="bg-primary text-white" option-value="CourseId" <q-select @input="resetSearch" standout="bg-primary text-white" option-value="CourseId"
option-label="CourseName" v-model="msg.CouseId" :options="ClassList" emit-value map-options label="学习课程" /> option-label="CourseName" v-model="msg.CouseId" :options="ClassList" emit-value map-options label="学习课程" />
</div> </div>
<!-- <div class="col-3">
<div class="col-3 Sysuser_Date">
<q-field filled>
 <template v-slot:control>
<el-date-picker v-model="dateList" @change="resetSearch" value-format="yyyy-MM-dd" type="daterange" style="border:none;"
  range-separator="至"  start-placeholder="开学日期"  end-placeholder="结束日期" clearable
@clear="resetSearch">
</el-date-picker>       
</template>
</q-field>
</div>
</div> -->
<div class="col-3"> <div class="col-3">
<div class="col-3 Sysuser_Date"> <div class="col-3 Sysuser_Date">
<q-field filled> <q-field filled>
...@@ -76,9 +64,12 @@ ...@@ -76,9 +64,12 @@
<div class="di-title">{{item.ClassName}}</div> <div class="di-title">{{item.ClassName}}</div>
<div class="di-c" style="margin-top: 25px;align-items:baseline"> <div class="di-c" style="margin-top: 25px;align-items:baseline">
<img src="../../assets/images/administration/kezname.png" alt="" <img src="../../assets/images/administration/kezname.png" alt=""
style="width: 14px;height: 14px;margin-right:5px;position:relative;top:2px;">{{item.CourseName}}</div> style="width: 14px;height: 14px;margin-right:5px;position:relative;top:2px;">{{item.CourseName}}
<div class="di-c" style="align-items:baseline"><img src="../../assets/images/administration/period.png" alt="" </div>
style="width: 14px;height: 14px;margin-right:5px;position:relative;top:2px;">{{item.ClassHours?item.ClassHours:'0'}}课时</div> <div class="di-c" style="align-items:baseline"><img src="../../assets/images/administration/period.png"
alt=""
style="width: 14px;height: 14px;margin-right:5px;position:relative;top:2px;">{{item.ClassHours?item.ClassHours:'0'}}课时
</div>
</div> </div>
<div class="d2"> <div class="d2">
<div class="row" style="align-items: center ;margin:0;padding:0;"> <div class="row" style="align-items: center ;margin:0;padding:0;">
...@@ -199,14 +190,19 @@ ...@@ -199,14 +190,19 @@
style="color:var(--q-color-negative);font-weight: bold">{{item.SurplusNum}}人</span></div> style="color:var(--q-color-negative);font-weight: bold">{{item.SurplusNum}}人</span></div>
</div> </div>
<div class="d7"> <div class="d7">
<div><q-btn style="margin-top:40px;" color="primary" size="sm" label="立即下单" v-if="item.IsCanApply==1" @click="placeAnorder(item)" /></div> <div>
<q-btn style="margin-top:40px;" color="primary" size="sm" label="立即下单" v-if="item.IsCanApply==1"
@click="placeAnorder(item)" />
</div>
<div v-if="item.IsCanApply==0"> <div v-if="item.IsCanApply==0">
<img src="../../assets/images/administration/bmym.png" alt="" <img src="../../assets/images/administration/bmym.png" alt=""
style="width: 64px;height: 62px;margin:20px 15px 0 0" v-if="item.SurplusNum==0"> style="width: 64px;height: 62px;margin:20px 15px 0 0" v-if="item.SurplusNum==0">
<img src="../../assets/images/administration/guoqi.png" alt="" style="width: 64px;height: 62px" <img src="../../assets/images/administration/guoqi.png" alt="" style="width: 64px;height: 62px"
v-if="getEXPDate(item.EndOrderTime)==true"> v-if="getEXPDate(item.EndOrderTime)==true">
</div> </div>
<div><q-btn style="margin-top:10px;" size="sm" color="primary" label="订单中心" @click="goclassorder(item)" /></div> <div>
<q-btn style="margin-top:10px;" size="sm" color="primary" label="订单中心" @click="goclassorder(item)" />
</div>
</div> </div>
</div> </div>
<div class="d6 row"> <div class="d6 row">
...@@ -296,6 +292,7 @@ ...@@ -296,6 +292,7 @@
JoinStartTime: '', //报名截止日期开始 JoinStartTime: '', //报名截止日期开始
JoinEndTime: "", //报名截止日期结束 JoinEndTime: "", //报名截止日期结束
}, },
//学员报名
enrollMsg: { enrollMsg: {
ClassId: 0, ClassId: 0,
GuestNum: 1, GuestNum: 1,
...@@ -303,6 +300,8 @@ ...@@ -303,6 +300,8 @@
PreferPrice: 0, //应收总额 PreferPrice: 0, //应收总额
OrderSource: 0, //客人来源 枚举 OrderSource: 0, //客人来源 枚举
SaleRemark: '', //备注 SaleRemark: '', //备注
OrderType:1,//订单类型(1-班级课程订单,2-留学就业订单)
SourceId:0,//来源编号
}, },
//关联校区列表 //关联校区列表
schoolList: [], schoolList: [],
...@@ -328,7 +327,7 @@ ...@@ -328,7 +327,7 @@
var month = nowDay.getMonth() + 1; //月 var month = nowDay.getMonth() + 1; //月
var day = nowDay.getDate(); //日 var day = nowDay.getDate(); //日
var currentDay = year + '-' + month + '-' + day; var currentDay = year + '-' + month + '-' + day;
//this.dateList[0] = currentDay;
this.msg.StartTime = currentDay this.msg.StartTime = currentDay
this.getList(); this.getList();
}, },
...@@ -410,14 +409,6 @@ ...@@ -410,14 +409,6 @@
}, },
//获取菜单分页列表 //获取菜单分页列表
getList() { getList() {
// if (this.dateList && this.dateList.length > 0) {
// this.msg.StartTime = this.dateList[0];
// this.msg.EndTime = this.dateList[1];
// } else {
// this.msg.StartTime = '';
// this.msg.EndTime = '';
// }
this.loading = true; this.loading = true;
getClassPruductList(this.msg).then(res => { getClassPruductList(this.msg).then(res => {
this.loading = false this.loading = false
......
...@@ -97,7 +97,7 @@ ...@@ -97,7 +97,7 @@
</div> </div>
</div> </div>
<div class="page-content"> <div class="page-content">
<orderlist :dataList="data.List" :isShowClass="true" :Comtype="1" @success="refreshClassOrder" ref="orderL"> <orderlist :dataList="data.List" :authObj="authObj" @success="refreshClassOrder" ref="orderL">
</orderlist> </orderlist>
<div class="row" style="justify-content: flex-end;padding: 5px 20px"> <div class="row" style="justify-content: flex-end;padding: 5px 20px">
<q-pagination v-model="msg.pageIndex" :max="pageCount" @input="changePage" class="full-width justify-end" <q-pagination v-model="msg.pageIndex" :max="pageCount" @input="changePage" class="full-width justify-end"
...@@ -161,6 +161,15 @@ ...@@ -161,6 +161,15 @@
classObjOption: null, classObjOption: null,
isShowClassInfo: false, //是否显示课程信息 isShowClassInfo: false, //是否显示课程信息
showone: false, showone: false,
//权限判断
authObj: {
isShowGuestBtn: 1, //显示新增学员名单按钮
isShowFinanceBtn: true, //显示财务单据按钮
isShowTransOrder: true, //显示转交订单按钮
isShowSaleRemark: true, //显示修改销售备注
isShowBackClass: true, //显示退课按钮
isShowRenewClass: true, //显示续课按钮
}
} }
}, },
created() { created() {
......
<template> <template>
<div class="page-body"> <div class="page-body">
<div class="page-content"> <div class="page-content">
<q-table :pagination="msg" :loading="loading" no-data-label="暂无相关数据" flat class="sticky-tow-column-table" <q-table :pagination="msg" :loading="loading" no-data-label="暂无相关数据" flat class="sticky-tow-column-table"
separator="none" :data="data" :columns="columns" row-key="name"> separator="none" :data="data" :columns="columns" row-key="name">
...@@ -13,7 +12,7 @@ ...@@ -13,7 +12,7 @@
</template> </template>
<template v-slot:body-cell-Sex="props"> <template v-slot:body-cell-Sex="props">
<q-td :props="props"> <q-td :props="props">
<span >{{props.row.Sex==1?'男':'女'}}</span> <span>{{props.row.Sex==1?'男':'女'}}</span>
</q-td> </q-td>
</template> </template>
<template v-slot:bottom> <template v-slot:bottom>
...@@ -24,15 +23,13 @@ ...@@ -24,15 +23,13 @@
<q-td :props="props"> <q-td :props="props">
<q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="编辑" <q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="编辑"
@click="EditRole(props.row)" /> @click="EditRole(props.row)" />
<q-btn flat size="xs" icon="iconfont icon-shanchu" color="negative" style="font-weight:400" <q-btn flat size="xs" icon="iconfont icon-shanchu" color="negative" style="font-weight:400" class="q-mr-xs"
class="q-mr-xs" label="删除" @click="deleteUser(props.row)" /> label="删除" @click="deleteUser(props.row)" />
</q-td> </q-td>
</template> </template>
</q-table> </q-table>
</div> </div>
<q-dialog v-model="persistent" content-class="bg-grey-1" persistent transition-show="scale" <q-dialog v-model="persistent" content-class="bg-grey-1" persistent transition-show="scale" transition-hide="scale">
transition-hide="scale">
<q-card style="width: 800px;max-width:900px;"> <q-card style="width: 800px;max-width:900px;">
<q-card-section> <q-card-section>
<div class="text-h6">{{addMsg.Id==0?'新增学员':'修改学员'}}</div> <div class="text-h6">{{addMsg.Id==0?'新增学员':'修改学员'}}</div>
...@@ -40,30 +37,37 @@ ...@@ -40,30 +37,37 @@
<div class="text-caption q-mb-lg q-px-md text-grey-6">基础信息</div> <div class="text-caption q-mb-lg q-px-md text-grey-6">基础信息</div>
<q-card-section class="q-pt-none"> <q-card-section class="q-pt-none">
<div class="row wrap"> <div class="row wrap">
<q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" v-model="addMsg.GuestName" label="姓名" :rules="[val => !!val || '姓名']"/> <q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white"
<q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" v-model="addMsg.Profession" label="职业" :rules="[val => !!val || '职业']"/> v-model="addMsg.GuestName" label="姓名" :rules="[val => !!val || '姓名']" />
<q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white"
v-model="addMsg.Profession" label="职业" :rules="[val => !!val || '职业']" />
<div class="col-6 q-pb-lg q-pr-lg"> <div class="col-6 q-pb-lg q-pr-lg">
<q-radio v-model="addMsg.Sex" val="1" label="男" /> <q-radio v-model="addMsg.Sex" val="1" label="男" />
<q-radio v-model="addMsg.Sex" val="2" label="女" /> <q-radio v-model="addMsg.Sex" val="2" label="女" />
</div> </div>
<q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" v-model="addMsg.Age" label="年龄" :rules="[val => !!val || '年龄']"/> <q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white"
<q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" v-model="addMsg.Mobile" label="电话" :rules="[val => !!val || '电话']" type="number"/> v-model="addMsg.Age" label="年龄" :rules="[val => !!val || '年龄']" />
<q-select class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" option-value="Name" option-label="Name" <q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white"
v-model="addMsg.Basics" :options="GBList" emit-value map-options label="语音基础" use-input new-value-mode="add-unique" hint="自己输入语音基础的话,输入之后按回车!"/> v-model="addMsg.Mobile" label="电话" :rules="[val => !!val || '电话']" type="number" />
<q-select class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" option-value="Id" option-label="Name" <q-select class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" option-value="Name"
v-model="addMsg.Education" :options="GEList" emit-value map-options label="最高学历" /> option-label="Name" v-model="addMsg.Basics" :options="GBList" emit-value map-options label="语音基础"
<q-select class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" option-value="Id" option-label="Name" use-input new-value-mode="add-unique" hint="自己输入语音基础的话,输入之后按回车!" />
v-model="addMsg.LearningGoals" :options="GLList" emit-value map-options label="学习目的" /> <q-select class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" option-value="Id"
<q-select class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" option-value="Id" option-label="Name" option-label="Name" v-model="addMsg.Education" :options="GEList" emit-value map-options label="最高学历" />
v-model="addMsg.GuestSource" :options="OFList" emit-value map-options label="客人来源" /> <q-select class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" option-value="Id"
option-label="Name" v-model="addMsg.LearningGoals" :options="GLList" emit-value map-options
label="学习目的" />
<q-select class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" option-value="Id"
option-label="Name" v-model="addMsg.GuestSource" :options="OFList" emit-value map-options label="客人来源" />
</div> </div>
</q-card-section> </q-card-section>
<div class="text-caption q-mb-lg q-px-md text-grey-6">附加信息</div> <div class="text-caption q-mb-lg q-px-md text-grey-6">附加信息</div>
<q-card-section> <q-card-section>
<div class="row wrap"> <div class="row wrap">
<q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" v-model="addMsg.Contact" label="重要联系人" /> <q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white"
<q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white" v-model="addMsg.ContactMobile" label="重要联系电话" /> v-model="addMsg.Contact" label="重要联系人" />
<q-input clearable filled class="col-6 q-pb-lg q-pr-lg" standout="bg-primary text-white"
v-model="addMsg.ContactMobile" label="重要联系电话" />
</div> </div>
</q-card-section> </q-card-section>
<q-separator /> <q-separator />
...@@ -80,12 +84,12 @@ ...@@ -80,12 +84,12 @@
<script> <script>
import { import {
getOrderGuestPageList, getOrderGuestPageList,
getGuestBasicsEnumList,//日语基础枚举 getGuestBasicsEnumList, //日语基础枚举
getGuestEducationEnumList,//学历枚举 getGuestEducationEnumList, //学历枚举
getGuestLearningGoalsEnumList,//获取学习目的 枚举 getGuestLearningGoalsEnumList, //获取学习目的 枚举
getOrderSourceEnumList,//来自 getOrderSourceEnumList, //来自
setOrderGuestInfo,//保存 setOrderGuestInfo, //保存
delOrderGuestInfo,//删除 delOrderGuestInfo, //删除
} from '../../api/sale/sale' } from '../../api/sale/sale'
export default { export default {
data() { data() {
...@@ -164,90 +168,85 @@ ...@@ -164,90 +168,85 @@
msg: { msg: {
pageIndex: 1, pageIndex: 1,
pageSize: 12, pageSize: 12,
rowsPerPage:12, rowsPerPage: 12,
OrderId: 0, OrderId: 0,
ClassId: 0, ClassId: 0,
GuestName: '', GuestName: '',
GuestState:0, GuestState: 0,
}, },
pageCount: 0, pageCount: 0,
persistent:false, persistent: false,
saveLoading:false, saveLoading: false,
addMsg:{ addMsg: {
Id:0, Id: 0,
OrderId:0, OrderId: 0,
GuestName:'', GuestName: '',
Profession:'', Profession: '',
Sex:'1', Sex: '1',
Age:0, Age: 0,
Mobile:'', Mobile: '',
Basics:'', Basics: '',
Education:'',//学历 Education: '', //学历
GuestSource:'',//来源 GuestSource: '', //来源
LearningGoals:"",// 学习目的 LearningGoals: "", // 学习目的
Contact:'',//紧急联系人 Contact: '', //紧急联系人
ContactMobile:'',//紧急联系电话 ContactMobile: '', //紧急联系电话
}, },
GBList:[], GBList: [],
GEList:[], GEList: [],
GLList:[], GLList: [],
OFList:[], OFList: [],
isShowBtn: true //默认显示新增名单
isShowBtn:true //默认显示新增名单
} }
}, },
mounted() { mounted() {
if(this.$route.query){ if (this.$route.query) {
this.msg.OrderId =this.$route.query.OrderId; this.msg.OrderId = this.$route.query.OrderId;
this.addMsg.OrderId =this.$route.query.OrderId; this.addMsg.OrderId = this.$route.query.OrderId;
this.msg.ClassId =this.$route.query.ClassId this.msg.ClassId = this.$route.query.ClassId
if(this.$route.query.isShow==1){ if (this.$route.query.isShow == 1) {
this.isShowBtn = true; this.isShowBtn = true;
}else{ } else {
this.isShowBtn=false this.isShowBtn = false
} }
} }
this.getRolelist(); this.getRolelist();
this.getGuestBasics()//日语基础枚举 this.getGuestBasics() //日语基础枚举
this.getGuestEducation()//学历枚举 this.getGuestEducation() //学历枚举
this.getGuestLearning()//获取学习目的 枚举 this.getGuestLearning() //获取学习目的 枚举
this.getOrderForm() this.getOrderForm()
}, },
methods: { methods: {
getGuestBasics(){ getGuestBasics() {
getGuestBasicsEnumList({}).then(res => { getGuestBasicsEnumList({}).then(res => {
if(res.Code==1){ if (res.Code == 1) {
this.GBList = res.Data this.GBList = res.Data
} }
}).catch(() => { }).catch(() => {})
})
}, },
getGuestEducation(){ getGuestEducation() {
getGuestEducationEnumList({}).then(res => { getGuestEducationEnumList({}).then(res => {
if(res.Code==1){ if (res.Code == 1) {
this.GEList = res.Data; this.GEList = res.Data;
} }
}).catch(() => { }).catch(() => {})
})
}, },
getGuestLearning(){ getGuestLearning() {
getGuestLearningGoalsEnumList({}).then(res => { getGuestLearningGoalsEnumList({}).then(res => {
if(res.Code==1){ if (res.Code == 1) {
this.GLList = res.Data; this.GLList = res.Data;
this.addMsg.LearningGoals = this.GLList[0].Id this.addMsg.LearningGoals = this.GLList[0].Id
} }
}).catch(() => { }).catch(() => {})
})
}, },
getOrderForm(){ getOrderForm() {
getOrderSourceEnumList({}).then(res => { getOrderSourceEnumList({}).then(res => {
if(res.Code==1){ if (res.Code == 1) {
this.OFList = res.Data this.OFList = res.Data
this.addMsg.GuestSource = this.OFList[0].Id this.addMsg.GuestSource = this.OFList[0].Id
} }
}).catch(() => { }).catch(() => {})
})
}, },
//重新查询 //重新查询
resetSearch() { resetSearch() {
...@@ -269,14 +268,14 @@ ...@@ -269,14 +268,14 @@
this.loading = false this.loading = false
}) })
}, },
goreturn(){ goreturn() {
this.$router.go(-1) this.$router.go(-1)
}, },
closeSaveForm(){ closeSaveForm() {
this.persistent=false this.persistent = false
}, },
save_t(){ save_t() {
if(this.addMsg.Basics==''){ if (this.addMsg.Basics == '') {
this.$q.notify({ this.$q.notify({
type: 'negative', type: 'negative',
position: "top", position: "top",
...@@ -284,7 +283,7 @@ ...@@ -284,7 +283,7 @@
}) })
return; return;
} }
if(this.addMsg.Education==''){ if (this.addMsg.Education == '') {
this.$q.notify({ this.$q.notify({
type: 'negative', type: 'negative',
position: "top", position: "top",
...@@ -292,9 +291,9 @@ ...@@ -292,9 +291,9 @@
}) })
return; return;
} }
this.saveLoading=true this.saveLoading = true
setOrderGuestInfo(this.addMsg).then(res => { setOrderGuestInfo(this.addMsg).then(res => {
if(res.Code==1){ if (res.Code == 1) {
this.$q.notify({ this.$q.notify({
icon: 'iconfont icon-chenggong', icon: 'iconfont icon-chenggong',
color: 'accent', color: 'accent',
...@@ -302,52 +301,52 @@ ...@@ -302,52 +301,52 @@
message: '保存成功!', message: '保存成功!',
position: 'top' position: 'top'
}) })
this.saveLoading=false; this.saveLoading = false;
this.persistent=false; this.persistent = false;
this.resetSearch() this.resetSearch()
this.initialize() this.initialize()
} }
}).catch(() => { }).catch(() => {
this.saveLoading=false this.saveLoading = false
}) })
}, },
initialize(){//初始化数据 initialize() { //初始化数据
this.addMsg= { this.addMsg = {
Id:0, Id: 0,
OrderId:this.$route.query.OrderId, OrderId: this.$route.query.OrderId,
GuestName:'', GuestName: '',
Profession:'', Profession: '',
Sex:'1', Sex: '1',
Age:0, Age: 0,
Mobile:'', Mobile: '',
Basics:'', Basics: '',
Education:'',//学历 Education: '', //学历
GuestSource:this.OFList[0].Id,//来源 GuestSource: this.OFList[0].Id, //来源
LearningGoals:this.GLList[0].Id,// 学习目的 LearningGoals: this.GLList[0].Id, // 学习目的
Contact:'',//紧急联系人 Contact: '', //紧急联系人
ContactMobile:'',//紧急联系电话 ContactMobile: '', //紧急联系电话
} }
}, },
addxue(){ addxue() {
this.persistent = true; this.persistent = true;
this.initialize() this.initialize()
}, },
EditRole(item){ EditRole(item) {
this.addMsg.Id= item.Id this.addMsg.Id = item.Id
this.addMsg.GuestName= item.GuestName this.addMsg.GuestName = item.GuestName
this.addMsg.Profession= item.Profession this.addMsg.Profession = item.Profession
this.addMsg.Sex= item.Sex.toString() this.addMsg.Sex = item.Sex.toString()
this.addMsg.Age= item.Age this.addMsg.Age = item.Age
this.addMsg.Mobile= item.Mobile this.addMsg.Mobile = item.Mobile
this.addMsg.Basics= item.Basics this.addMsg.Basics = item.Basics
this.addMsg.Education= item.Education this.addMsg.Education = item.Education
this.addMsg.GuestSource = item.GuestSource this.addMsg.GuestSource = item.GuestSource
this.addMsg.LearningGoals = item.LearningGoals this.addMsg.LearningGoals = item.LearningGoals
this.addMsg.Contact = item.Contact this.addMsg.Contact = item.Contact
this.addMsg.ContactMobile = item.ContactMobile; this.addMsg.ContactMobile = item.ContactMobile;
this.persistent= true this.persistent = true
}, },
deleteUser(item){ deleteUser(item) {
let that = this let that = this
this.$q.dialog({ this.$q.dialog({
title: '提示信息', title: '提示信息',
...@@ -357,7 +356,9 @@ ...@@ -357,7 +356,9 @@
ok: "确定", ok: "确定",
cancel: "取消", cancel: "取消",
}).onOk(() => { }).onOk(() => {
delOrderGuestInfo({GuestId:item.Id}).then(res => { delOrderGuestInfo({
GuestId: item.Id
}).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
that.$q.notify({ that.$q.notify({
icon: 'iconfont icon-chenggong', icon: 'iconfont icon-chenggong',
......
<template>
<div class="page-body myOrder">
<div style="width: 100%;display: flex;justify-content: space-between">
<span style="font-size: 20px;font-weight: 400; ">留学就业订单</span>
<span>
<q-toggle v-model="msg.Q_NotCollect" label="只看款未收齐订单" class="q-mb-md" false-value="0" true-value="1"
@input="resetSearch" /></span>
</div>
<div class="page-search row items-center">
<div class="col row wrap q-mr-lg q-col-gutter-md">
<div class="col-3">
<q-input @change="resetSearch" clearable standout="bg-primary text-white" v-model="msg.OrderId" label="订单号"
@clear="resetSearch" maxlength="10" />
</div>
<div class="col-3">
<q-input @change="resetSearch" clearable standout="bg-primary text-white" v-model="msg.GuestName" label="客户名称"
@clear="resetSearch" maxlength="20" />
</div>
<div class="col-3">
<q-select @input="resetSearch" standout="bg-primary text-white" option-value="Id" option-label="Name"
v-model="msg.OrderState" :options="OrderStateList" emit-value map-options label="订单状态" />
</div>
<div class="col-3">
<q-field filled>
 <template v-slot:control>
<el-date-picker v-model="dateList" @change="resetSearch()" value-format="yyyy-MM-dd" type="daterange" style="border:none;"
 range-separator="至"  start-placeholder="报名开始时间"  end-placeholder="报名结束时间">
 </el-date-picker>       
</template>
</q-field>
</div>
</div>
</div>
<div class="col row wrap q-gutter-x-md" v-if="data.Statistics">
<div class="col stics">
<span class="stics-name">应收款</span>
<span>{{data.Statistics.PreferPrice?data.Statistics.PreferPrice:0}}</span>
</div>
<div class="col stics">
<span class="stics-name">实收款</span>
<span>{{data.Statistics.Income}}</span>
</div>
<div class="col stics">
<span class="stics-name">待收款</span>
<span style="color: #F72E52">{{data.Statistics.DueInMoney}}</span>
</div>
<div class="col stics">
<span class="stics-name">收客人数</span>
<span style="color:#2961FE;">{{data.Statistics.GuestNum}}人</span>
</div>
<div class="col stics">
<span class="stics-name">取消人数</span>
<span>{{data.Statistics.CancelNum}}人</span>
</div>
<div class="col stics">
<span class="stics-name">提成金额</span>
<span>{{data.Statistics.CommissionMoney}}</span>
</div>
<div class="col stics">
<span class="stics-name">额外奖励</span>
<span>{{data.Statistics.ExtraRewardMoney}}</span>
</div>
</div>
<div class="row col" style="justify-content: flex-end">
<div class="row tis">
<div class="tis-k" style="background: #2961FE"></div>
<span>已打单</span>
</div>
<div class="row tis">
<div class="tis-k" style="background: #02C499"></div>
<span>平台出纳已审核</span>
</div>
<div class="row tis">
<div class="tis-k" style="background: #F28C1D"></div>
<span>银行出纳已审核</span>
</div>
<div class="row tis">
<div class="tis-k" style="background: #3FC4FF"></div>
<span>已通过</span>
</div>
</div>
<div class="page-content">
<orderlist :dataList="data.List" :isShowClass="false" :authObj="authObj" @success="refreshClassOrder" ref="orderL">
</orderlist>
<div class="row" style="justify-content: flex-end;padding: 5px 20px">
<q-pagination v-model="msg.pageIndex" :max="pageCount" @input="changePage" class="full-width justify-end"
color="primary" :input="true">
</q-pagination>
</div>
</div>
<classinfo-form v-if="isShowClassInfo" :seting-obj="classObjOption" @close="closeClass"
@success="refreshClassOrder">
</classinfo-form>
</div>
</template>
<script>
import {
getMyStudyOrderPage, //获取订单列表
getOrderStateEnumList //订单状态
} from '../../api/sale/sale';
import {
queryCourseDropdownList,
} from '../../api/course/index'
import myOrderForm from '../../components/sale/myOrder-form'
import classinfoForm from '../../components/course/classinfo-form';
import orderlist from '../../components/sale/orderlist'
export default {
meta: {
title: "我的订单"
},
components: {
myOrderForm,
classinfoForm,
orderlist
},
data() {
return {
dialog: false,
data: {},
loading: false,
dateList: [], //报名时间
dateList2: [], //开班时间
msg: {
pageIndex: 1,
pageSize: 8,
OrderId: '', //订单号
GuestName: '', //客人名称
ClassName: '', //班级名称
CouseId: 0, //课程id
StartTime: '', //报名开始时间
EndTime: '', //报名结束时间
OPStartTime: '', //开班开始时间
OPEndTime: '', //开班结束时间
Q_NotCollect: '0', //查询未收齐 1是 0否
OrderState: 0, //订单状态 枚举
Q_OrderState: 1, //查询 1正常订单 2取消订单 (默认传1 如果 选择了订单状态 则传 0)
Q_OrderBy: 2, //写死 =2
PlatformTax: 0, //平台税金
},
//订单状态
OrderStateList: [],
pageCount: 0,
CourseList: [], //关联课程下拉数据
classObjOption: null,
isShowClassInfo: false, //是否显示课程信息
showone: false,
//权限判断
authObj: {
isShowGuestBtn: 1, //显示新增学员名单按钮
isShowFinanceBtn: true, //显示财务单据按钮
isShowTransOrder: true, //显示转交订单按钮
isShowSaleRemark: true, //显示修改销售备注
}
}
},
created() {
if (this.$route.query.OrderId) {
this.msg.OrderId = this.$route.query.OrderId;
}
this.getOrderState();
this.getCourseList();
},
mounted() {
this.getList();
},
methods: {
//订单状态
getOrderState() {
getOrderStateEnumList({}).then(res => {
if (res.Code == 1) {
var tempArray = res.Data;
if (!tempArray) {
tempArray = [];
}
tempArray.unshift({
Id: 0,
Name: "不限"
})
this.OrderStateList = tempArray;
}
})
},
//获取课程
getCourseList() {
queryCourseDropdownList({}).then(res => {
if (res.Code == 1) {
var tempArray = res.Data;
if (!tempArray) {
tempArray = [];
}
tempArray.unshift({
CourseId: 0,
CourseName: "不限"
})
this.CourseList = tempArray;
}
})
},
//翻页
changePage(val) {
if (this.showone == true) {
this.msg.pageIndex = val;
this.getList()
} else {
this.showone = true
}
},
resetSearch() {
this.msg.pageIndex = 1;
this.getList()
},
//获取菜单分页列表
getList() {
if (this.dateList && this.dateList.length > 0) {
this.msg.StartTime = this.dateList[0];
this.msg.EndTime = this.dateList[1];
} else {
this.msg.StartTime = '';
this.msg.EndTime = '';
}
if (this.dateList2 && this.dateList2.length > 0) {
this.msg.OPStartTime = this.dateList2[0];
this.msg.OPEndTime = this.dateList2[1];
} else {
this.msg.OPStartTime = '';
this.msg.OPEndTime = '';
}
let msg = JSON.parse(JSON.stringify(this.msg));
if (msg.OrderId == '' || msg.OrderId == null) {
msg.OrderId = 0
}
this.loading = true;
getMyStudyOrderPage(msg).then(res => {
this.data = res.Data.PageData;
let OrderIds = []
this.data.List.forEach(x => {
OrderIds.push(x.OrderId)
})
this.loading = false
OrderIds = OrderIds.join(',')
if (this.data.List.length > 0) {
this.$refs.orderL.getOrderFinanceList(OrderIds, 1)
}
this.pageCount = res.Data.PageCount;
}).catch(() => {
this.loading = false
})
},
//刷新页面
refreshClassOrder() {
this.getList();
},
getClassInfo(obj) { //打开班级详情组件
this.classObjOption = obj;
this.isShowClassInfo = true;
},
//关闭班级信息弹窗
closeClass() {
this.isShowClassInfo = false;
},
}
}
</script>
<style>
li {
list-style-type: none;
}
.myOrder ul {
padding: 0px
}
.myOrder .price-popup {
border-radius: 4px;
}
.myOrder .el-range-editor .el-range-input {
background: transparent;
}
.myOrder .el-range-editor.el-input__inner {
background-color: transparent;
}
.myOrder .q-mb-md {
margin-bottom: 0;
}
.myOrder .stics {
padding: 10px 20px;
background: #DDDEE0;
border-radius: 4px;
font-size: 14px;
color: #000000;
font-weight: bold
}
.myOrder .stics .stics-name {
color: #2D2D2D;
font-weight: 600;
margin-right: 10px
}
.myOrder .tis {
margin: 10px 0;
align-items: center
}
.myOrder .tis .tis-k {
width: 10px;
height: 10px;
margin-right: 8px
}
.myOrder .tis span {
font-size: 14px;
color: #2D2D2D;
font-weight: 600;
margin-right: 20px
}
</style>
...@@ -112,7 +112,7 @@ ...@@ -112,7 +112,7 @@
<template v-slot:body-cell-Id="props"> <template v-slot:body-cell-Id="props">
<q-td :props="props"> <q-td :props="props">
<q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="立即下单" <q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="立即下单"
@click="getviewInfo(props.row)" /> @click="showOrderForm(props.row)" />
</q-td> </q-td>
</template> </template>
<template v-slot:bottom> <template v-slot:bottom>
...@@ -123,6 +123,9 @@ ...@@ -123,6 +123,9 @@
<q-dialog v-model="showForm" persistent> <q-dialog v-model="showForm" persistent>
<quotationstudy-form :obj="null" @save="showForm=false"></quotationstudy-form> <quotationstudy-form :obj="null" @save="showForm=false"></quotationstudy-form>
</q-dialog> </q-dialog>
<studyorder-form v-if="isShowOrderForm" :saveObj="studyObj" @save="refreshPage()"></studyorder-form>
</div> </div>
</div> </div>
</template> </template>
...@@ -132,6 +135,7 @@ ...@@ -132,6 +135,7 @@
queryStudyAbroadPage queryStudyAbroadPage
} from '../../api/studyabroad/index' } from '../../api/studyabroad/index'
import quotationstudyForm from '../../components/sale/quotationstudy-form' import quotationstudyForm from '../../components/sale/quotationstudy-form'
import studyorderForm from '../../components/sale/studyorder-form'
import { import {
mapState mapState
} from "vuex"; } from "vuex";
...@@ -141,7 +145,8 @@ ...@@ -141,7 +145,8 @@
title: "留学产品审核" title: "留学产品审核"
}, },
components: { components: {
quotationstudyForm quotationstudyForm,
studyorderForm
}, },
data() { data() {
return { return {
...@@ -168,7 +173,6 @@ ...@@ -168,7 +173,6 @@
field: 'Type', field: 'Type',
align: 'left' align: 'left'
}, },
{ {
name: 'SuggestPrice', name: 'SuggestPrice',
label: '建议卖价', label: '建议卖价',
...@@ -250,9 +254,10 @@ ...@@ -250,9 +254,10 @@
], //可见列 ], //可见列
PageCount: 0, PageCount: 0,
showForm: false, //是否显示报价单弹窗 showForm: false, //是否显示报价单弹窗
isShowOrderForm: false, //是否显示订单弹窗
studyObj: {}, //留学就业对象
} }
}, },
mounted() { mounted() {
this.getList(); this.getList();
}, },
...@@ -260,6 +265,12 @@ ...@@ -260,6 +265,12 @@
}, },
methods: { methods: {
//显示下单弹窗
showOrderForm(item) {
console.log("item",item)
this.isShowOrderForm = true;
this.studyObj = item;
},
//显示报价单弹窗 //显示报价单弹窗
createQuotation() { createQuotation() {
this.showForm = true; this.showForm = true;
...@@ -297,7 +308,11 @@ ...@@ -297,7 +308,11 @@
this.studyObj = obj; this.studyObj = obj;
this.isShowStudyAudit = true; this.isShowStudyAudit = true;
}, },
//刷新页面
refreshPage() { refreshPage() {
this.showForm = false;
this.isShowOrderForm = false;
this.studyObj = {};
this.getList(); this.getList();
}, },
//审核详情 //审核详情
......
...@@ -456,6 +456,11 @@ const routes = [{ ...@@ -456,6 +456,11 @@ const routes = [{
component: () => component: () =>
import("pages/sale/myOrder.vue") import("pages/sale/myOrder.vue")
}, },
{
path: "/sale/studyOrder", //销售 我的留学就业订单
component: () =>
import("pages/sale/studyOrder.vue")
},
{ {
path: "/sale/contractManage", //销售 合同管理 path: "/sale/contractManage", //销售 合同管理
component: () => component: () =>
......
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