Commit 2450d0e2 authored by zhengke's avatar zhengke

修改

parent 256e3b0a
...@@ -12,7 +12,7 @@ export default { ...@@ -12,7 +12,7 @@ export default {
<style> <style>
@import url('~assets/css/font.css'); @import url('~assets/css/font.css');
@import url('//at.alicdn.com/t/font_2077629_v5y4jdrtlx.css'); @import url('//at.alicdn.com/t/font_2077629_006c4joct5c8d.css');
html, html,
body, body,
......
...@@ -244,4 +244,16 @@ export function setVisitorReserveStatus(data) { ...@@ -244,4 +244,16 @@ export function setVisitorReserveStatus(data) {
method: 'post', method: 'post',
data data
}) })
}
/**
* 删除约课数据
* @param {JSON参数} data
*/
export function RemoveVisitorReserve(data) {
return request({
url: '/VisitorReserve/RemoveVisitorReserve',
method: 'post',
data
})
} }
\ No newline at end of file
...@@ -150,7 +150,7 @@ ...@@ -150,7 +150,7 @@
} }
}, },
mounted() { mounted() {
this.queryClassInfo(); // this.queryClassInfo();
}, },
methods: { methods: {
queryClassInfo() { queryClassInfo() {
......
...@@ -24,7 +24,8 @@ ...@@ -24,7 +24,8 @@
<div style="margin-bottom:20px;"> <div style="margin-bottom:20px;">
<div class="Appoint_Line"></div>预约申请 <div class="Appoint_Line"></div>预约申请
</div> </div>
<q-input filled v-model="addMsg.ClassDate" class="col-6 q-pb-lg" :rules="[val => !!val || '请选择预约日期']" ref="ClassDate" mask="date" label="预约日期"> <q-input filled v-model="addMsg.ClassDate" class="col-6 q-pb-lg" :rules="[val => !!val || '请选择预约日期']"
ref="ClassDate" mask="date" label="预约日期">
<template v-slot:append> <template v-slot:append>
<q-icon name="event" class="cursor-pointer"> <q-icon name="event" class="cursor-pointer">
<q-popup-proxy ref="qDateProxy1" transition-show="scale" transition-hide="scale"> <q-popup-proxy ref="qDateProxy1" transition-show="scale" transition-hide="scale">
...@@ -37,17 +38,17 @@ ...@@ -37,17 +38,17 @@
<q-field filled class="q-pb-lg"> <q-field filled class="q-pb-lg">
  <template v-slot:control>   <template v-slot:control>
<el-time-select v-model="addMsg.ClassTime" ref="ClassTime" style="width:100%" :picker-options="{ <el-time-select v-model="addMsg.ClassTime" ref="ClassTime" style="width:100%" :picker-options="{
start: '09:00', start: '09:00',
step: '00:15', step: '00:15',
end: '21:00' end: '21:00'
}" placeholder="预约时间"> }" placeholder="预约时间">
</el-time-select> </el-time-select>
</template> </template>
</q-field> </q-field>
</div> </div>
<q-select filled stack-label option-value="Name" option-label="Name" <q-select filled stack-label option-value="Name" option-label="Name" v-model="addMsg.ClassContent"
v-model="addMsg.ClassContent" ref="ClassContent" :options="ContentList" :rules="[val => !!val || '请选择主讲内容']" label="主讲内容" :dense="false" ref="ClassContent" :options="ContentList" :rules="[val => !!val || '请选择主讲内容']" label="主讲内容" :dense="false"
class="col-6 q-pb-lg" emit-value map-options /> class="col-6 q-pb-lg" emit-value map-options />
<div style="display:flex;align-items:center;"> <div style="display:flex;align-items:center;">
<q-select filled stack-label option-value="TId" style="width:90%" option-label="TeacherName" <q-select filled stack-label option-value="TId" style="width:90%" option-label="TeacherName"
v-model="addMsg.TeacherId" ref="TeacherId" :options="TeacherList" label="选择教师" :dense="false" v-model="addMsg.TeacherId" ref="TeacherId" :options="TeacherList" label="选择教师" :dense="false"
...@@ -144,7 +145,7 @@ ...@@ -144,7 +145,7 @@
getTeacherDropDownList({}).then(res => { getTeacherDropDownList({}).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
this.TeacherList = res.Data; this.TeacherList = res.Data;
var obj = { var obj = {
TeacherName: '请选择', TeacherName: '请选择',
TId: 0 TId: 0
} }
...@@ -167,31 +168,39 @@ ...@@ -167,31 +168,39 @@
}, },
//保存 //保存
saveAppointForm() { saveAppointForm() {
if(this.saveObj){ if (this.saveObj) {
this.addMsg.Visitor_Id = this.saveObj.Id; this.addMsg.Visitor_Id = this.saveObj.Id;
} }
this.$refs.ClassDate.validate(); this.$refs.ClassDate.validate();
this.$refs.ClassContent.validate(); this.$refs.ClassContent.validate();
if (this.addMsg.ClassTime == '') {
if (!this.$refs.ClassDate.hasError && !this.$refs.ClassContent.hasError){ this.$q.notify({
type: 'negative',
position: "top",
timeout: 2000,
message: '请选择预约时间!',
})
return;
}
if (!this.$refs.ClassDate.hasError && !this.$refs.ClassContent.hasError) {
SetVisitorReserve(this.addMsg).then(res => { SetVisitorReserve(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',
timeout: 2000, timeout: 2000,
message: '数据保存成功!', message: '数据保存成功!',
position: 'top' position: 'top'
}) })
this.$emit('success'); this.$emit('success');
this.closeAppointForm(); this.closeAppointForm();
} }
}) })
} }
}, },
//子组件选中传值 //子组件选中传值
getchildInfo(obj){ getchildInfo(obj) {
this.addMsg.TeacherId = obj.TeacherId; this.addMsg.TeacherId = obj.TeacherId;
this.addMsg.ClassRoomId = obj.ClassRoomId; this.addMsg.ClassRoomId = obj.ClassRoomId;
this.addMsg.ReserveClassId = obj.ReserveClassId; this.addMsg.ReserveClassId = obj.ReserveClassId;
......
...@@ -101,7 +101,7 @@ ...@@ -101,7 +101,7 @@
this.msg.ReserveStatus = 3; this.msg.ReserveStatus = 3;
} }
if (this.ChoiceType == 2) { if (this.ChoiceType == 2) {
this.msg.remark = this.chooseLiudan.toString(); this.msg.Remark = this.chooseLiudan.toString();
} }
setVisitorReserveStatus(this.msg).then(res => { setVisitorReserveStatus(this.msg).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
......
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
<template v-slot:body-cell-OrderId="props"> <template v-slot:body-cell-OrderId="props">
<q-td :props="props"> <q-td :props="props">
<template v-if="props.row.OrderId && props.row.OrderId>0"> <template v-if="props.row.OrderId && props.row.OrderId>0">
{{props.row.OrderId}} <span style="color:blue;cursor:pointer" @click="goOrderStatistics(props.row.OrderId)">{{props.row.OrderId}}</span>
</template> </template>
</q-td> </q-td>
</template> </template>
...@@ -67,7 +67,7 @@ ...@@ -67,7 +67,7 @@
<span style="color:green;cursor:pointer;"> {{props.row.ReserveStatusStr}}</span> <span style="color:green;cursor:pointer;"> {{props.row.ReserveStatusStr}}</span>
</template> </template>
<template v-if="props.row.ReserveStatus==2"> <template v-if="props.row.ReserveStatus==2">
<span style="color:#8F4586;cursor:pointer;"> {{props.row.ReserveStatusStr}}</span> <span style="color:#ff00ff;cursor:pointer;"> {{props.row.ReserveStatusStr}}</span>
  <q-tooltip :offset="[10, 10]">   <q-tooltip :offset="[10, 10]">
   {{props.row.Remark}}    {{props.row.Remark}}
 </q-tooltip>  </q-tooltip>
...@@ -84,6 +84,8 @@ ...@@ -84,6 +84,8 @@
<q-td :props="props"> <q-td :props="props">
<q-btn flat size="xs" @click="getDetail(props.row)" icon="iconfont icon-View" color="accent" <q-btn flat size="xs" @click="getDetail(props.row)" icon="iconfont icon-View" color="accent"
style="font-weight:400" label="详情" /> style="font-weight:400" label="详情" />
<q-btn flat size="xs" icon="delete" color="negative" style="font-weight:400;" label="删除"
@click="deleteAppoint(props.row)" />
<q-btn-dropdown flat size="xs" color="dark" label="更多" style="margin-left:10px;" <q-btn-dropdown flat size="xs" color="dark" label="更多" style="margin-left:10px;"
v-if="props.row.ReserveStatus==0"> v-if="props.row.ReserveStatus==0">
<q-list> <q-list>
...@@ -122,7 +124,8 @@ ...@@ -122,7 +124,8 @@
<script> <script>
import { import {
queryVisitorReservePage queryVisitorReservePage,
RemoveVisitorReserve
} from '../../api/scheduling/schedu' } from '../../api/scheduling/schedu'
import { import {
getTeacherDropDownList, getTeacherDropDownList,
...@@ -308,7 +311,41 @@ ...@@ -308,7 +311,41 @@
getDetail(item) { getDetail(item) {
this.orderObj = item; this.orderObj = item;
this.isShowDetail = true; this.isShowDetail = true;
console.log(item, 'item'); },
//跳转到报名统计
goOrderStatistics(id){
this.OpenNewUrl("/sale/orderStatistics", {
OrderId: id
});
},
//删除约课管理
deleteAppoint(item){
let delMsg = {
Id: item.Id
};
this.$q.dialog({
title: '提示信息',
message: '是否确定删除约课信息?',
cancel: true,
persistent: true,
ok: "确定",
cancel: "取消",
}).onOk(() => {
RemoveVisitorReserve(delMsg).then(res => {
if (res.Code == 1) {
this.$q.notify({
icon: 'iconfont icon-chenggong',
color: 'accent',
timeout: 2000,
message: '删除成功!',
position: 'top'
})
this.getList();
}
})
}).onCancel(() => {
});
} }
} }
} }
......
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