20200727-入园申请
This commit is contained in:
parent
5cafc37152
commit
c23ccd6420
@ -49,7 +49,7 @@
|
|||||||
"@fullcalendar/vue": "^4.4.0",
|
"@fullcalendar/vue": "^4.4.0",
|
||||||
"@riophae/vue-treeselect": "0.4.0",
|
"@riophae/vue-treeselect": "0.4.0",
|
||||||
"axios": "0.18.1",
|
"axios": "0.18.1",
|
||||||
"clipboard": "2.0.4",
|
"clipboard": "^2.0.4",
|
||||||
"driver.js": "^0.9.8",
|
"driver.js": "^0.9.8",
|
||||||
"echarts": "4.2.1",
|
"echarts": "4.2.1",
|
||||||
"element-ui": "2.13.0",
|
"element-ui": "2.13.0",
|
||||||
|
@ -17,10 +17,19 @@ export function getExperience(id) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 查询入班体验申请详细
|
||||||
|
export function getExperience_query(query) {
|
||||||
|
return request({
|
||||||
|
url: '/benyi/experience/getInfo',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
// 新增入班体验申请
|
// 新增入班体验申请
|
||||||
export function addExperience(data) {
|
export function addExperience(data) {
|
||||||
return request({
|
return request({
|
||||||
url: '/benyi/experience',
|
url: '/benyi/experience/add',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: data
|
data: data
|
||||||
})
|
})
|
||||||
|
@ -1,11 +1,17 @@
|
|||||||
import router from './router'
|
import router from './router'
|
||||||
import store from './store'
|
import store from './store'
|
||||||
import { Message } from 'element-ui'
|
import {
|
||||||
|
Message
|
||||||
|
} from 'element-ui'
|
||||||
import NProgress from 'nprogress'
|
import NProgress from 'nprogress'
|
||||||
import 'nprogress/nprogress.css'
|
import 'nprogress/nprogress.css'
|
||||||
import { getToken } from '@/utils/auth'
|
import {
|
||||||
|
getToken
|
||||||
|
} from '@/utils/auth'
|
||||||
|
|
||||||
NProgress.configure({ showSpinner: false })
|
NProgress.configure({
|
||||||
|
showSpinner: false
|
||||||
|
})
|
||||||
|
|
||||||
//const whiteList = ['/login', '/auth-redirect', '/bind', '/register']
|
//const whiteList = ['/login', '/auth-redirect', '/bind', '/register']
|
||||||
const whiteList = ['/login']
|
const whiteList = ['/login']
|
||||||
@ -15,7 +21,9 @@ router.beforeEach((to, from, next) => {
|
|||||||
if (getToken()) {
|
if (getToken()) {
|
||||||
/* has token*/
|
/* has token*/
|
||||||
if (to.path === '/login') {
|
if (to.path === '/login') {
|
||||||
next({ path: '/' })
|
next({
|
||||||
|
path: '/'
|
||||||
|
})
|
||||||
NProgress.done()
|
NProgress.done()
|
||||||
} else {
|
} else {
|
||||||
if (store.getters.roles.length === 0) {
|
if (store.getters.roles.length === 0) {
|
||||||
@ -23,18 +31,25 @@ router.beforeEach((to, from, next) => {
|
|||||||
store.dispatch('GetInfo').then(res => {
|
store.dispatch('GetInfo').then(res => {
|
||||||
// 拉取user_info
|
// 拉取user_info
|
||||||
const roles = res.roles
|
const roles = res.roles
|
||||||
store.dispatch('GenerateRoutes', { roles }).then(accessRoutes => {
|
store.dispatch('GenerateRoutes', {
|
||||||
|
roles
|
||||||
|
}).then(accessRoutes => {
|
||||||
// 测试 默认静态页面
|
// 测试 默认静态页面
|
||||||
// store.dispatch('permission/generateRoutes', { roles }).then(accessRoutes => {
|
// store.dispatch('permission/generateRoutes', { roles }).then(accessRoutes => {
|
||||||
// 根据roles权限生成可访问的路由表
|
// 根据roles权限生成可访问的路由表
|
||||||
router.addRoutes(accessRoutes) // 动态添加可访问路由表
|
router.addRoutes(accessRoutes) // 动态添加可访问路由表
|
||||||
next({ ...to, replace: true }) // hack方法 确保addRoutes已完成
|
next({
|
||||||
|
...to,
|
||||||
|
replace: true
|
||||||
|
}) // hack方法 确保addRoutes已完成
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
.catch(err => {
|
.catch(err => {
|
||||||
store.dispatch('FedLogOut').then(() => {
|
store.dispatch('FedLogOut').then(() => {
|
||||||
Message.error(err)
|
Message.error(err)
|
||||||
next({ path: '/' })
|
next({
|
||||||
|
path: '/'
|
||||||
|
})
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
@ -49,8 +64,9 @@ router.beforeEach((to, from, next) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
//console.log(whiteList.indexOf(to.path));
|
||||||
// 没有token
|
// 没有token
|
||||||
if (whiteList.indexOf(to.path) !== -1) {
|
if (whiteList.indexOf(to.path) !== -1 ||to.path.indexOf("/experience/choose/") != -1||to.path.indexOf("/experience/apply/") != -1||to.path.indexOf("/experience/result/") != -1) {
|
||||||
// 在免登录白名单,直接进入
|
// 在免登录白名单,直接进入
|
||||||
next()
|
next()
|
||||||
} else {
|
} else {
|
||||||
|
@ -1,8 +1,15 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div class="apply-input">
|
||||||
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
<h2 class="title">入班半日体验申请表</h2>
|
||||||
|
<p class="info">为了更好地了解贵园,申请来贵园进行入班半日体验。</p>
|
||||||
|
<div class="apply-form">
|
||||||
|
<el-form ref="form" :model="form" :rules="rules" label-width="110px">
|
||||||
<el-form-item label="家长姓名" prop="jzxm">
|
<el-form-item label="家长姓名" prop="jzxm">
|
||||||
<el-input v-model="form.jzxm" placeholder="请输入家长姓名" />
|
<el-input v-model="form.jzxm" placeholder="请输入家长姓名" />
|
||||||
|
<el-input v-model="form.schoolid" v-if="false" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="联系方式" prop="lxfs">
|
||||||
|
<el-input v-model="form.lxfs" placeholder="请输入联系方式" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="幼儿姓名" prop="yexm">
|
<el-form-item label="幼儿姓名" prop="yexm">
|
||||||
<el-input v-model="form.yexm" placeholder="请输入幼儿姓名" />
|
<el-input v-model="form.yexm" placeholder="请输入幼儿姓名" />
|
||||||
@ -18,9 +25,6 @@
|
|||||||
placeholder="选择幼儿出生日期"
|
placeholder="选择幼儿出生日期"
|
||||||
></el-date-picker>
|
></el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="联系方式" prop="lxfs">
|
|
||||||
<el-input v-model="form.lxfs" placeholder="请输入联系方式" />
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="拟入园时间" prop="nrysj">
|
<el-form-item label="拟入园时间" prop="nrysj">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
clearable
|
clearable
|
||||||
@ -32,66 +36,36 @@
|
|||||||
placeholder="选择拟入园时间"
|
placeholder="选择拟入园时间"
|
||||||
></el-date-picker>
|
></el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="申请体验时间" prop="sqtysj">
|
<div>
|
||||||
|
<div>
|
||||||
|
<el-form-item label="预约体验时间" prop="sqtysj">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
clearable
|
clearable
|
||||||
size="small"
|
size="small"
|
||||||
style="width: 200px"
|
|
||||||
v-model="form.sqtysj"
|
v-model="form.sqtysj"
|
||||||
type="date"
|
|
||||||
value-format="yyyy-MM-dd"
|
|
||||||
placeholder="选择申请体验时间"
|
|
||||||
></el-date-picker>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="上午或下午" prop="swxw">
|
|
||||||
<el-input v-model="form.swxw" placeholder="请输入上午或下午" />
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="体验学校" prop="schoolid">
|
|
||||||
<el-input v-model="form.schoolid" placeholder="请输入体验学校" />
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="是否回复" prop="sfhf">
|
|
||||||
<el-input v-model="form.sfhf" placeholder="请输入是否回复" />
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="回复内容" prop="hfrn">
|
|
||||||
<el-input v-model="form.hfrn" type="textarea" placeholder="请输入内容" />
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="回复人" prop="hfuserid">
|
|
||||||
<el-input v-model="form.hfuserid" placeholder="请输入回复人" />
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="回复时间" prop="fhsj">
|
|
||||||
<el-date-picker
|
|
||||||
clearable
|
|
||||||
size="small"
|
|
||||||
style="width: 200px"
|
style="width: 200px"
|
||||||
v-model="form.fhsj"
|
|
||||||
type="date"
|
type="date"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
placeholder="选择回复时间"
|
placeholder="申请体验时间"
|
||||||
></el-date-picker>
|
></el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="园长指示" prop="yzzs">
|
<el-form-item prop="swxw">
|
||||||
<el-input v-model="form.yzzs" type="textarea" placeholder="请输入内容" />
|
<el-radio-group v-model="form.swxw">
|
||||||
</el-form-item>
|
<el-radio label="1">上午</el-radio>
|
||||||
<el-form-item label="体验结果
|
<el-radio label="2">下午</el-radio>
|
||||||
0不入园
|
</el-radio-group>
|
||||||
1入园" prop="tyjg">
|
|
||||||
<el-input v-model="form.tyjg" placeholder="请输入体验结果
|
|
||||||
0不入园
|
|
||||||
1入园" />
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="入园时间" prop="rysj">
|
|
||||||
<el-date-picker
|
|
||||||
clearable
|
|
||||||
size="small"
|
|
||||||
style="width: 200px"
|
|
||||||
v-model="form.rysj"
|
|
||||||
type="date"
|
|
||||||
value-format="yyyy-MM-dd"
|
|
||||||
placeholder="选择入园时间"
|
|
||||||
></el-date-picker>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<p class="come-txt">来园入班体验。请园长为我安排与我孩子年龄段相适应的班级。届时,我将与我的孩子准时入班进行半日体验。</p>
|
||||||
|
</div>
|
||||||
|
<p class="thanks-top">请园长批准我的申请为盼。</p>
|
||||||
|
<p class="thanks">谢谢!</p>
|
||||||
|
</div>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-button type="primary" @click="submitForm">确 定</el-button>
|
<div class="btns">
|
||||||
|
<el-button class="btn" type="primary" @click="submitForm">确 定</el-button>
|
||||||
|
<el-button class="btn" @click="cancel">返 回</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -99,18 +73,49 @@
|
|||||||
import { addExperience } from "@/api/benyi/experience";
|
import { addExperience } from "@/api/benyi/experience";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "Experience",
|
name: "Apply",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
// 遮罩层
|
activeNames: ["1"],
|
||||||
loading: true,
|
yysj: "",
|
||||||
|
sworxw: "",
|
||||||
// 表单参数
|
// 表单参数
|
||||||
form: {},
|
form: {},
|
||||||
// 表单校验
|
// 表单校验
|
||||||
rules: {},
|
rules: {
|
||||||
|
jzxm: [
|
||||||
|
{ required: true, message: "家长姓名不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
yexm: [
|
||||||
|
{ required: true, message: "幼儿姓名不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
csrq: [
|
||||||
|
{ required: true, message: "幼儿出生日期不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
lxfs: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/,
|
||||||
|
message: "请输入正确的手机号码",
|
||||||
|
trigger: "blur",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
nrysj: [
|
||||||
|
{ required: true, message: "拟入园时间不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
sqtysj: [
|
||||||
|
{ required: true, message: "申请体验时间不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
swxw: [
|
||||||
|
{ required: true, message: "下午或下午不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {},
|
created() {
|
||||||
|
const sid = this.$route.params && this.$route.params.id;
|
||||||
|
this.form.schoolid = sid;
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
// 表单重置
|
// 表单重置
|
||||||
reset() {
|
reset() {
|
||||||
@ -124,42 +129,74 @@ export default {
|
|||||||
sqtysj: undefined,
|
sqtysj: undefined,
|
||||||
swxw: undefined,
|
swxw: undefined,
|
||||||
schoolid: undefined,
|
schoolid: undefined,
|
||||||
sfhf: undefined,
|
|
||||||
hfrn: undefined,
|
|
||||||
hfuserid: undefined,
|
|
||||||
fhsj: undefined,
|
|
||||||
yzzs: undefined,
|
|
||||||
tyjg: undefined,
|
|
||||||
rysj: undefined,
|
|
||||||
createTime: undefined,
|
createTime: undefined,
|
||||||
};
|
};
|
||||||
this.resetForm("form");
|
this.resetForm("form");
|
||||||
},
|
},
|
||||||
|
// 返回按钮
|
||||||
|
cancel() {
|
||||||
|
this.$router.go(-1);
|
||||||
|
},
|
||||||
/** 提交按钮 */
|
/** 提交按钮 */
|
||||||
submitForm: function () {
|
submitForm: function () {
|
||||||
this.$refs["form"].validate((valid) => {
|
this.$refs["form"].validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
if (this.form.id != undefined) {
|
|
||||||
updateExperience(this.form).then((response) => {
|
|
||||||
if (response.code === 200) {
|
|
||||||
this.msgSuccess("修改成功");
|
|
||||||
this.open = false;
|
|
||||||
this.getList();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
addExperience(this.form).then((response) => {
|
addExperience(this.form).then((response) => {
|
||||||
if (response.code === 200) {
|
if (response.code === 200) {
|
||||||
this.msgSuccess("新增成功");
|
this.msgSuccess("您的申请提交成功,等待园长回复");
|
||||||
this.open = false;
|
this.reset();
|
||||||
this.getList();
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
.apply-input {
|
||||||
|
padding-top: 30px;
|
||||||
|
p {
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
.title {
|
||||||
|
text-align: center;
|
||||||
|
font-size: 18px;
|
||||||
|
}
|
||||||
|
.info {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.apply-form {
|
||||||
|
width: 500px;
|
||||||
|
margin: 30px auto 0;
|
||||||
|
}
|
||||||
|
.btns {
|
||||||
|
display: flex;
|
||||||
|
margin-top: 30px;
|
||||||
|
.btn {
|
||||||
|
flex: 1;
|
||||||
|
margin: 0 10px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.come-txt {
|
||||||
|
line-height: 22px;
|
||||||
|
text-indent: 2em;
|
||||||
|
}
|
||||||
|
.thanks-top {
|
||||||
|
padding: 8px 0 8px 0;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
.thanks {
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@media screen and (max-width: 768.89px) {
|
||||||
|
.apply-input {
|
||||||
|
padding: 30px 10px 0;
|
||||||
|
.apply-form {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div class="result-content">
|
||||||
<el-link type="primary" :href="'/experience/apply/{{schoolId}}'">入班半日体验申请</el-link>
|
<el-link class="btn" :href="href_apply">入班半日体验申请</el-link>
|
||||||
<el-link type="success" :href="'/experience/result/{{schoolId}}'">申请结果查询</el-link>
|
<el-link class="btn" :href="href_result">申请结果查询</el-link>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
@ -9,12 +9,44 @@ export default {
|
|||||||
name: "Choose",
|
name: "Choose",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
schoolId: "",
|
href_apply: "",
|
||||||
|
href_result: "",
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
const sid = this.$route.params && this.$route.params.id;
|
const sid = this.$route.params && this.$route.params.id;
|
||||||
this.schoolId = sid;
|
this.href_apply = "/experience/apply/" + sid;
|
||||||
|
this.href_result = "/experience/result/" + sid;
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.result-content {
|
||||||
|
height: 100%;
|
||||||
|
background: linear-gradient(-45deg, #6ab7ff, #edf7fb);
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
padding-top: 100px;
|
||||||
|
.btn {
|
||||||
|
width: 200px;
|
||||||
|
height: 40px;
|
||||||
|
line-height: 40px;
|
||||||
|
text-align: center;
|
||||||
|
margin: 0 10px;
|
||||||
|
font-size: 16px;
|
||||||
|
font-weight: 700;
|
||||||
|
text-decoration: none;
|
||||||
|
background: #1b469c;
|
||||||
|
color: #fff;
|
||||||
|
border-radius: 20px;
|
||||||
|
&::after {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
transition: all .5s;
|
||||||
|
&:hover {
|
||||||
|
background: #072052;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
@ -40,9 +40,9 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="el-icon-plus"
|
icon="el-icon-plus"
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="handleAdd"
|
@click="copy($event,inviteCode)"
|
||||||
v-hasPermi="['benyi:experience:add']"
|
v-hasPermi="['benyi:experience:add']"
|
||||||
>新增</el-button>
|
>一键复制</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="1.5">
|
<el-col :span="1.5">
|
||||||
<el-button
|
<el-button
|
||||||
@ -77,35 +77,13 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="联系方式" align="center" prop="lxfs" />
|
<el-table-column label="联系方式" align="center" prop="lxfs" />
|
||||||
<el-table-column label="拟入园时间" align="center" prop="nrysj" width="180">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
<span>{{ parseTime(scope.row.nrysj, '{y}-{m}-{d}') }}</span>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="申请体验时间" align="center" prop="sqtysj" width="180">
|
<el-table-column label="申请体验时间" align="center" prop="sqtysj" width="180">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span>{{ parseTime(scope.row.sqtysj, '{y}-{m}-{d}') }}</span>
|
<span>{{ parseTime(scope.row.sqtysj, '{y}-{m}-{d}') }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="上午或下午" align="center" prop="swxw" />
|
<el-table-column label="上午或下午" align="center" prop="swxw" :formatter="swxwFormat" />
|
||||||
<el-table-column label="体验学校" align="center" prop="schoolid" />
|
<el-table-column label="是否回复" align="center" prop="sfhf" :formatter="ynFormat" />
|
||||||
<el-table-column label="是否回复" align="center" prop="sfhf" />
|
|
||||||
<el-table-column label="回复内容" align="center" prop="hfrn" />
|
|
||||||
<el-table-column label="回复人" align="center" prop="hfuserid" />
|
|
||||||
<el-table-column label="回复时间" align="center" prop="fhsj" width="180">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
<span>{{ parseTime(scope.row.fhsj, '{y}-{m}-{d}') }}</span>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="园长指示" align="center" prop="yzzs" />
|
|
||||||
<el-table-column label="体验结果
|
|
||||||
0不入园
|
|
||||||
1入园" align="center" prop="tyjg" />
|
|
||||||
<el-table-column label="入园时间" align="center" prop="rysj" width="180">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
<span>{{ parseTime(scope.row.rysj, '{y}-{m}-{d}') }}</span>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button
|
<el-button
|
||||||
@ -135,15 +113,26 @@
|
|||||||
/>
|
/>
|
||||||
|
|
||||||
<!-- 添加或修改入班体验申请对话框 -->
|
<!-- 添加或修改入班体验申请对话框 -->
|
||||||
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
<el-dialog :title="title" :visible.sync="open" width="800px" append-to-body>
|
||||||
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
<el-row :gutter="15">
|
||||||
|
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
|
||||||
|
<el-col :span="12">
|
||||||
<el-form-item label="家长姓名" prop="jzxm">
|
<el-form-item label="家长姓名" prop="jzxm">
|
||||||
<el-input v-model="form.jzxm" placeholder="请输入家长姓名" />
|
<el-input v-model="form.jzxm" placeholder="请输入家长姓名" disabled="true" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="联系方式" prop="lxfs">
|
||||||
|
<el-input v-model="form.lxfs" placeholder="请输入联系方式" disabled="true" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
<el-form-item label="幼儿姓名" prop="yexm">
|
<el-form-item label="幼儿姓名" prop="yexm">
|
||||||
<el-input v-model="form.yexm" placeholder="请输入幼儿姓名" />
|
<el-input v-model="form.yexm" placeholder="请输入幼儿姓名" disabled="true" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="幼儿出生日期" prop="csrq">
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="出生日期" prop="csrq">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
clearable
|
clearable
|
||||||
size="small"
|
size="small"
|
||||||
@ -152,11 +141,11 @@
|
|||||||
type="date"
|
type="date"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
placeholder="选择幼儿出生日期"
|
placeholder="选择幼儿出生日期"
|
||||||
|
disabled="true"
|
||||||
></el-date-picker>
|
></el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="联系方式" prop="lxfs">
|
</el-col>
|
||||||
<el-input v-model="form.lxfs" placeholder="请输入联系方式" />
|
<el-col :span="12">
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="拟入园时间" prop="nrysj">
|
<el-form-item label="拟入园时间" prop="nrysj">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
clearable
|
clearable
|
||||||
@ -166,8 +155,11 @@
|
|||||||
type="date"
|
type="date"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
placeholder="选择拟入园时间"
|
placeholder="选择拟入园时间"
|
||||||
|
disabled="true"
|
||||||
></el-date-picker>
|
></el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
<el-form-item label="申请体验时间" prop="sqtysj">
|
<el-form-item label="申请体验时间" prop="sqtysj">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
clearable
|
clearable
|
||||||
@ -177,44 +169,57 @@
|
|||||||
type="date"
|
type="date"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
placeholder="选择申请体验时间"
|
placeholder="选择申请体验时间"
|
||||||
|
disabled="true"
|
||||||
></el-date-picker>
|
></el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
<el-form-item label="上午或下午" prop="swxw">
|
<el-form-item label="上午或下午" prop="swxw">
|
||||||
<el-input v-model="form.swxw" placeholder="请输入上午或下午" />
|
<el-select v-model="form.swxw" placeholder="请选择" disabled="true">
|
||||||
</el-form-item>
|
<el-option
|
||||||
<el-form-item label="体验学校" prop="schoolid">
|
v-for="dict in swxwOptions"
|
||||||
<el-input v-model="form.schoolid" placeholder="请输入体验学校" />
|
:key="dict.dictValue"
|
||||||
|
:label="dict.dictLabel"
|
||||||
|
:value="dict.dictValue"
|
||||||
|
></el-option>
|
||||||
|
</el-select>
|
||||||
|
<el-input v-model="form.schoolid" v-if="false" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
<el-form-item label="是否回复" prop="sfhf">
|
<el-form-item label="是否回复" prop="sfhf">
|
||||||
<el-input v-model="form.sfhf" placeholder="请输入是否回复" />
|
<el-radio-group v-model="form.sfhf">
|
||||||
|
<el-radio
|
||||||
|
v-for="dict in ynOptions"
|
||||||
|
:key="dict.dictValue"
|
||||||
|
:label="dict.dictValue"
|
||||||
|
>{{dict.dictLabel}}</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="24">
|
||||||
<el-form-item label="回复内容" prop="hfrn">
|
<el-form-item label="回复内容" prop="hfrn">
|
||||||
<el-input v-model="form.hfrn" type="textarea" placeholder="请输入内容" />
|
<el-input v-model="form.hfrn" type="textarea" placeholder="请输入内容" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="回复人" prop="hfuserid">
|
</el-col>
|
||||||
<el-input v-model="form.hfuserid" placeholder="请输入回复人" />
|
<el-col :span="24">
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="回复时间" prop="fhsj">
|
|
||||||
<el-date-picker
|
|
||||||
clearable
|
|
||||||
size="small"
|
|
||||||
style="width: 200px"
|
|
||||||
v-model="form.fhsj"
|
|
||||||
type="date"
|
|
||||||
value-format="yyyy-MM-dd"
|
|
||||||
placeholder="选择回复时间"
|
|
||||||
></el-date-picker>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="园长指示" prop="yzzs">
|
<el-form-item label="园长指示" prop="yzzs">
|
||||||
<el-input v-model="form.yzzs" type="textarea" placeholder="请输入内容" />
|
<el-input v-model="form.yzzs" type="textarea" placeholder="请输入内容" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="体验结果
|
</el-col>
|
||||||
0不入园
|
<el-col :span="12">
|
||||||
1入园" prop="tyjg">
|
<el-form-item label="体验结果" prop="tyjg">
|
||||||
<el-input v-model="form.tyjg" placeholder="请输入体验结果
|
<el-select v-model="form.tyjg" placeholder="请选择">
|
||||||
0不入园
|
<el-option
|
||||||
1入园" />
|
v-for="dict in tyjgOptions"
|
||||||
|
:key="dict.dictValue"
|
||||||
|
:label="dict.dictLabel"
|
||||||
|
:value="dict.dictValue"
|
||||||
|
></el-option>
|
||||||
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
<el-form-item label="入园时间" prop="rysj">
|
<el-form-item label="入园时间" prop="rysj">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
clearable
|
clearable
|
||||||
@ -226,7 +231,9 @@
|
|||||||
placeholder="选择入园时间"
|
placeholder="选择入园时间"
|
||||||
></el-date-picker>
|
></el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
</el-form>
|
</el-form>
|
||||||
|
</el-row>
|
||||||
<div slot="footer" class="dialog-footer">
|
<div slot="footer" class="dialog-footer">
|
||||||
<el-button type="primary" @click="submitForm">确 定</el-button>
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||||
<el-button @click="cancel">取 消</el-button>
|
<el-button @click="cancel">取 消</el-button>
|
||||||
@ -245,10 +252,15 @@ import {
|
|||||||
exportExperience,
|
exportExperience,
|
||||||
} from "@/api/benyi/experience";
|
} from "@/api/benyi/experience";
|
||||||
|
|
||||||
|
import { getUserProfile } from "@/api/system/user";
|
||||||
|
|
||||||
|
import Clipboard from "clipboard";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "Experience",
|
name: "Experience",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
inviteCode: "",
|
||||||
// 遮罩层
|
// 遮罩层
|
||||||
loading: true,
|
loading: true,
|
||||||
// 选中数组
|
// 选中数组
|
||||||
@ -261,6 +273,10 @@ export default {
|
|||||||
total: 0,
|
total: 0,
|
||||||
// 入班体验申请表格数据
|
// 入班体验申请表格数据
|
||||||
experienceList: [],
|
experienceList: [],
|
||||||
|
//字典翻译
|
||||||
|
swxwOptions: [],
|
||||||
|
ynOptions: [],
|
||||||
|
tyjgOptions: [],
|
||||||
// 弹出层标题
|
// 弹出层标题
|
||||||
title: "",
|
title: "",
|
||||||
// 是否显示弹出层
|
// 是否显示弹出层
|
||||||
@ -288,13 +304,78 @@ export default {
|
|||||||
// 表单参数
|
// 表单参数
|
||||||
form: {},
|
form: {},
|
||||||
// 表单校验
|
// 表单校验
|
||||||
rules: {},
|
rules: {
|
||||||
|
jzxm: [
|
||||||
|
{ required: true, message: "家长姓名不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
yexm: [
|
||||||
|
{ required: true, message: "幼儿姓名不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
csrq: [
|
||||||
|
{ required: true, message: "幼儿出生日期不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
lxfs: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/,
|
||||||
|
message: "请输入正确的手机号码",
|
||||||
|
trigger: "blur",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
nrysj: [
|
||||||
|
{ required: true, message: "拟入园时间不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
sqtysj: [
|
||||||
|
{ required: true, message: "申请体验时间不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
swxw: [
|
||||||
|
{ required: true, message: "下午或下午不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
hfrn: [
|
||||||
|
{ required: true, message: "回复内容不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
yzzs: [
|
||||||
|
{ required: true, message: "园长指示不能为空", trigger: "blur" },
|
||||||
|
],
|
||||||
|
},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getList();
|
this.getList();
|
||||||
|
this.getUser();
|
||||||
|
this.getDicts("sys_dm_swxw").then((response) => {
|
||||||
|
this.swxwOptions = response.data;
|
||||||
|
});
|
||||||
|
this.getDicts("sys_yes_no").then((response) => {
|
||||||
|
this.ynOptions = response.data;
|
||||||
|
});
|
||||||
|
this.getDicts("sys_dm_tyjg").then((response) => {
|
||||||
|
this.tyjgOptions = response.data;
|
||||||
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
getUser() {
|
||||||
|
getUserProfile().then((response) => {
|
||||||
|
var domain = window.location.host;
|
||||||
|
console.log(domain);
|
||||||
|
//this.user = response.data;
|
||||||
|
this.inviteCode =
|
||||||
|
response.data.dept.deptName +
|
||||||
|
"入班半日体验申请表 " +
|
||||||
|
"http://" +
|
||||||
|
domain +
|
||||||
|
"/experience/choose/" +
|
||||||
|
response.data.dept.deptId;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
// 字典翻译
|
||||||
|
ynFormat(row, column) {
|
||||||
|
return this.selectDictLabel(this.ynOptions, row.sfhf);
|
||||||
|
},
|
||||||
|
// 字典翻译
|
||||||
|
swxwFormat(row, column) {
|
||||||
|
return this.selectDictLabel(this.swxwOptions, row.swxw);
|
||||||
|
},
|
||||||
/** 查询入班体验申请列表 */
|
/** 查询入班体验申请列表 */
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
@ -354,6 +435,25 @@ export default {
|
|||||||
this.open = true;
|
this.open = true;
|
||||||
this.title = "添加入班体验申请";
|
this.title = "添加入班体验申请";
|
||||||
},
|
},
|
||||||
|
copy(e, text) {
|
||||||
|
const clipboard = new Clipboard(e.target, { text: () => text });
|
||||||
|
clipboard.on("success", (e) => {
|
||||||
|
this.msgSuccess("复制成功");
|
||||||
|
// 释放内存
|
||||||
|
clipboard.off("error");
|
||||||
|
clipboard.off("success");
|
||||||
|
clipboard.destroy();
|
||||||
|
});
|
||||||
|
clipboard.on("error", (e) => {
|
||||||
|
// 不支持复制
|
||||||
|
this.msgError("手机权限不支持复制功能");
|
||||||
|
// 释放内存
|
||||||
|
clipboard.off("error");
|
||||||
|
clipboard.off("success");
|
||||||
|
clipboard.destroy();
|
||||||
|
});
|
||||||
|
clipboard.onClick(e);
|
||||||
|
},
|
||||||
/** 修改按钮操作 */
|
/** 修改按钮操作 */
|
||||||
handleUpdate(row) {
|
handleUpdate(row) {
|
||||||
this.reset();
|
this.reset();
|
||||||
@ -362,6 +462,15 @@ export default {
|
|||||||
this.form = response.data;
|
this.form = response.data;
|
||||||
this.open = true;
|
this.open = true;
|
||||||
this.title = "修改入班体验申请";
|
this.title = "修改入班体验申请";
|
||||||
|
this.form.sfhf = "Y";
|
||||||
|
(this.form.hfrn =
|
||||||
|
"家长你好,非常欢迎你带孩子来园入班进行半日体验。我已经按照你所申请入班体验的时间,在本园XX班做了安排。请你在" +
|
||||||
|
response.data.sqtysj +
|
||||||
|
"(" +
|
||||||
|
this.swxwFormat(response.data) +
|
||||||
|
")" +
|
||||||
|
"开始进班体验。小一班班长章一梦老师将联系你安排具体事宜,并给你一份半日体验计划表。祝你体验愉快!"),
|
||||||
|
(this.form.yzzs = "请XX班按此预约时间做准备。");
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
/** 提交按钮 */
|
/** 提交按钮 */
|
||||||
@ -408,7 +517,7 @@ export default {
|
|||||||
this.msgSuccess("删除成功");
|
this.msgSuccess("删除成功");
|
||||||
})
|
})
|
||||||
.catch(function () {});
|
.catch(function () {});
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
@ -0,0 +1,187 @@
|
|||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-form :model="queryParams" ref="queryForm" :inline="true" label-width="68px">
|
||||||
|
<el-form-item label="幼儿姓名" prop="yexm">
|
||||||
|
<el-input v-model="queryParams.yexm" placeholder="请输入幼儿姓名" clearable size="small" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="联系方式" prop="lxfs">
|
||||||
|
<el-input v-model="queryParams.lxfs" placeholder="请输入联系方式" clearable size="small" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" size="mini" @click="handleQuery">查询</el-button>
|
||||||
|
<el-button type="primary" size="mini" @click="cancel">返回</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<div v-show="hide">
|
||||||
|
<h2>入班半日体验申请表</h2>
|
||||||
|
<el-row :gutter="15">
|
||||||
|
<el-form ref="form" :model="form" label-width="80px">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="家长姓名" prop="jzxm">
|
||||||
|
<el-input v-model="form.jzxm" placeholder="请输入家长姓名" :disabled="hide" />
|
||||||
|
<el-input v-model="form.schoolid" v-if="false" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="联系方式" prop="lxfs">
|
||||||
|
<el-input v-model="form.lxfs" placeholder="请输入联系方式" :disabled="hide" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="幼儿姓名" prop="yexm">
|
||||||
|
<el-input v-model="form.yexm" placeholder="请输入幼儿姓名" :disabled="hide" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="幼儿出生日期" prop="csrq">
|
||||||
|
<el-date-picker
|
||||||
|
clearable
|
||||||
|
size="small"
|
||||||
|
style="width: 200px"
|
||||||
|
v-model="form.csrq"
|
||||||
|
type="date"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
placeholder="选择幼儿出生日期"
|
||||||
|
:disabled="hide"
|
||||||
|
></el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="拟入园时间" prop="nrysj">
|
||||||
|
<el-date-picker
|
||||||
|
clearable
|
||||||
|
size="small"
|
||||||
|
style="width: 200px"
|
||||||
|
v-model="form.nrysj"
|
||||||
|
type="date"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
placeholder="选择拟入园时间"
|
||||||
|
:disabled="hide"
|
||||||
|
></el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-collapse v-model="activeNames">
|
||||||
|
<el-collapse-item title="园长你好" name="1">
|
||||||
|
<div>
|
||||||
|
为了更好地了解贵园,我申请来贵园进行入班半日体验。我预约
|
||||||
|
<el-form-item prop="sqtysj">
|
||||||
|
<el-date-picker
|
||||||
|
clearable
|
||||||
|
size="small"
|
||||||
|
v-model="form.sqtysj"
|
||||||
|
type="date"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
placeholder="选择申请体验时间"
|
||||||
|
:disabled="hide"
|
||||||
|
></el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item prop="swxw">
|
||||||
|
<el-radio-group v-model="form.swxw" :disabled="hide">
|
||||||
|
<el-radio label="1">上午</el-radio>
|
||||||
|
<el-radio label="2">下午</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</el-form-item>来园入班体验。请园长为我安排与我孩子年龄段相适应的班级。届时,我将与我的孩子准时入班进行半日体验。
|
||||||
|
</div>
|
||||||
|
<div>请园长批准我的申请为盼。谢谢!</div>
|
||||||
|
</el-collapse-item>
|
||||||
|
</el-collapse>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="24" v-show="ishf">
|
||||||
|
<el-collapse v-model="activeNames">
|
||||||
|
<el-collapse-item title="园长答复" name="2">{{hfrn}}</el-collapse-item>
|
||||||
|
</el-collapse>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="24" v-show="ishf">
|
||||||
|
<el-collapse v-model="activeNames">
|
||||||
|
<el-collapse-item title="园长指示" name="3">{{yzzs}}</el-collapse-item>
|
||||||
|
</el-collapse>
|
||||||
|
</el-col>
|
||||||
|
</el-form>
|
||||||
|
</el-row>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import { getExperience_query } from "@/api/benyi/experience";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: "result",
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
hide: false,
|
||||||
|
ishf: false,
|
||||||
|
hfrn: "",
|
||||||
|
yzzs: "",
|
||||||
|
activeNames: ["1", "2", "3"],
|
||||||
|
// 查询参数
|
||||||
|
queryParams: {
|
||||||
|
yexm: undefined,
|
||||||
|
lxfs: undefined,
|
||||||
|
schoolId: undefined,
|
||||||
|
},
|
||||||
|
// 表单参数
|
||||||
|
form: {},
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
const sid = this.$route.params && this.$route.params.id;
|
||||||
|
this.queryParams.schoolid = sid;
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
// 字典翻译
|
||||||
|
ynFormat(row, column) {
|
||||||
|
return this.selectDictLabel(this.ynOptions, row.sfhf);
|
||||||
|
},
|
||||||
|
// 字典翻译
|
||||||
|
swxwFormat(row, column) {
|
||||||
|
return this.selectDictLabel(this.swxwOptions, row.swxw);
|
||||||
|
},
|
||||||
|
/** 查询入班体验申请列表 */
|
||||||
|
getInfo() {
|
||||||
|
getExperience_query(this.queryParams).then((response) => {
|
||||||
|
//console.log(response);
|
||||||
|
if (response.code == "200") {
|
||||||
|
this.hide = true;
|
||||||
|
this.form = response.data;
|
||||||
|
if (response.data.sfhf == "Y") {
|
||||||
|
this.ishf = true;
|
||||||
|
this.hfrn = response.data.hfrn;
|
||||||
|
this.yzzs = response.data.yzzs;
|
||||||
|
} else {
|
||||||
|
this.ishf = false;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.hide = false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
/** 搜索按钮操作 */
|
||||||
|
handleQuery() {
|
||||||
|
//console.log(this.queryParams.yexm);
|
||||||
|
if (
|
||||||
|
this.queryParams.yexm == undefined ||
|
||||||
|
this.queryParams.yexm.trim() == ""
|
||||||
|
) {
|
||||||
|
this.msgError("请输入幼儿姓名");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (
|
||||||
|
this.queryParams.lxfs == undefined ||
|
||||||
|
this.queryParams.lxfs.trim() == ""
|
||||||
|
) {
|
||||||
|
this.msgError("请输入联系方式");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
this.getInfo();
|
||||||
|
},
|
||||||
|
// 返回按钮
|
||||||
|
cancel() {
|
||||||
|
this.$router.go(-1);
|
||||||
|
},
|
||||||
|
},
|
||||||
|
};
|
||||||
|
</script>
|
@ -22,8 +22,7 @@ import com.ruoyi.framework.security.handle.LogoutSuccessHandlerImpl;
|
|||||||
* @author ruoyi
|
* @author ruoyi
|
||||||
*/
|
*/
|
||||||
@EnableGlobalMethodSecurity(prePostEnabled = true, securedEnabled = true)
|
@EnableGlobalMethodSecurity(prePostEnabled = true, securedEnabled = true)
|
||||||
public class SecurityConfig extends WebSecurityConfigurerAdapter
|
public class SecurityConfig extends WebSecurityConfigurerAdapter {
|
||||||
{
|
|
||||||
/**
|
/**
|
||||||
* 自定义用户认证逻辑
|
* 自定义用户认证逻辑
|
||||||
*/
|
*/
|
||||||
@ -56,8 +55,7 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
|
|||||||
*/
|
*/
|
||||||
@Bean
|
@Bean
|
||||||
@Override
|
@Override
|
||||||
public AuthenticationManager authenticationManagerBean() throws Exception
|
public AuthenticationManager authenticationManagerBean() throws Exception {
|
||||||
{
|
|
||||||
return super.authenticationManagerBean();
|
return super.authenticationManagerBean();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -77,8 +75,7 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
|
|||||||
* authenticated | 用户登录后可访问
|
* authenticated | 用户登录后可访问
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
protected void configure(HttpSecurity httpSecurity) throws Exception
|
protected void configure(HttpSecurity httpSecurity) throws Exception {
|
||||||
{
|
|
||||||
httpSecurity
|
httpSecurity
|
||||||
// CRSF禁用,因为不使用session
|
// CRSF禁用,因为不使用session
|
||||||
.csrf().disable()
|
.csrf().disable()
|
||||||
@ -105,6 +102,8 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
|
|||||||
.antMatchers("/webjars/**").anonymous()
|
.antMatchers("/webjars/**").anonymous()
|
||||||
.antMatchers("/*/api-docs").anonymous()
|
.antMatchers("/*/api-docs").anonymous()
|
||||||
.antMatchers("/druid/**").anonymous()
|
.antMatchers("/druid/**").anonymous()
|
||||||
|
.antMatchers("/benyi/experience/add").anonymous()//半日入园体验申请
|
||||||
|
.antMatchers("/benyi/experience/getInfo**").anonymous()//半日入园体验明细
|
||||||
// 除上面外的所有请求全部需要鉴权认证
|
// 除上面外的所有请求全部需要鉴权认证
|
||||||
.anyRequest().authenticated()
|
.anyRequest().authenticated()
|
||||||
.and()
|
.and()
|
||||||
@ -119,8 +118,7 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
|
|||||||
* 强散列哈希加密实现
|
* 强散列哈希加密实现
|
||||||
*/
|
*/
|
||||||
@Bean
|
@Bean
|
||||||
public BCryptPasswordEncoder bCryptPasswordEncoder()
|
public BCryptPasswordEncoder bCryptPasswordEncoder() {
|
||||||
{
|
|
||||||
return new BCryptPasswordEncoder();
|
return new BCryptPasswordEncoder();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -128,8 +126,7 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
|
|||||||
* 身份认证接口
|
* 身份认证接口
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
protected void configure(AuthenticationManagerBuilder auth) throws Exception
|
protected void configure(AuthenticationManagerBuilder auth) throws Exception {
|
||||||
{
|
|
||||||
auth.userDetailsService(userDetailsService).passwordEncoder(bCryptPasswordEncoder());
|
auth.userDetailsService(userDetailsService).passwordEncoder(bCryptPasswordEncoder());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2,6 +2,8 @@ package com.ruoyi.project.benyi.controller;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.ruoyi.common.utils.SecurityUtils;
|
||||||
|
import com.ruoyi.project.common.SchoolCommon;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
@ -32,6 +34,8 @@ import com.ruoyi.framework.web.page.TableDataInfo;
|
|||||||
public class ByExperienceController extends BaseController {
|
public class ByExperienceController extends BaseController {
|
||||||
@Autowired
|
@Autowired
|
||||||
private IByExperienceService byExperienceService;
|
private IByExperienceService byExperienceService;
|
||||||
|
@Autowired
|
||||||
|
private SchoolCommon schoolCommon;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询入班体验申请列表
|
* 查询入班体验申请列表
|
||||||
@ -40,6 +44,7 @@ public class ByExperienceController extends BaseController {
|
|||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
public TableDataInfo list(ByExperience byExperience) {
|
public TableDataInfo list(ByExperience byExperience) {
|
||||||
startPage();
|
startPage();
|
||||||
|
byExperience.setSchoolid(SecurityUtils.getLoginUser().getUser().getDept().getDeptId());
|
||||||
List<ByExperience> list = byExperienceService.selectByExperienceList(byExperience);
|
List<ByExperience> list = byExperienceService.selectByExperienceList(byExperience);
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
@ -65,12 +70,31 @@ public class ByExperienceController extends BaseController {
|
|||||||
return AjaxResult.success(byExperienceService.selectByExperienceById(id));
|
return AjaxResult.success(byExperienceService.selectByExperienceById(id));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取入班体验申请详细信息
|
||||||
|
*/
|
||||||
|
@GetMapping("/getInfo")
|
||||||
|
public AjaxResult getInfo_query(ByExperience byExperience) {
|
||||||
|
if(schoolCommon.isStringEmpty(byExperience.getYexm())){
|
||||||
|
return AjaxResult.error("请输入幼儿姓名");
|
||||||
|
}
|
||||||
|
if(schoolCommon.isStringEmpty(byExperience.getLxfs())){
|
||||||
|
return AjaxResult.error("请输入家长联系方式");
|
||||||
|
}
|
||||||
|
|
||||||
|
List<ByExperience> list = byExperienceService.selectByExperienceList(byExperience);
|
||||||
|
if (list == null || list.size() == 0) {
|
||||||
|
return AjaxResult.error("未找到该幼儿的半日入园体验信息");
|
||||||
|
}
|
||||||
|
return AjaxResult.success(list.get(0));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增入班体验申请
|
* 新增入班体验申请
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('benyi:experience:add')")
|
// @PreAuthorize("@ss.hasPermi('benyi:experience:add')")
|
||||||
@Log(title = "入班体验申请", businessType = BusinessType.INSERT)
|
@Log(title = "入班体验申请", businessType = BusinessType.INSERT)
|
||||||
@PostMapping
|
@PostMapping("/add")
|
||||||
public AjaxResult add(@RequestBody ByExperience byExperience) {
|
public AjaxResult add(@RequestBody ByExperience byExperience) {
|
||||||
return toAjax(byExperienceService.insertByExperience(byExperience));
|
return toAjax(byExperienceService.insertByExperience(byExperience));
|
||||||
}
|
}
|
||||||
|
@ -5,23 +5,23 @@
|
|||||||
<mapper namespace="com.ruoyi.project.benyi.mapper.ByExperienceMapper">
|
<mapper namespace="com.ruoyi.project.benyi.mapper.ByExperienceMapper">
|
||||||
|
|
||||||
<resultMap type="ByExperience" id="ByExperienceResult">
|
<resultMap type="ByExperience" id="ByExperienceResult">
|
||||||
<result property="id" column="id" />
|
<result property="id" column="id"/>
|
||||||
<result property="jzxm" column="jzxm" />
|
<result property="jzxm" column="jzxm"/>
|
||||||
<result property="yexm" column="yexm" />
|
<result property="yexm" column="yexm"/>
|
||||||
<result property="csrq" column="csrq" />
|
<result property="csrq" column="csrq"/>
|
||||||
<result property="lxfs" column="lxfs" />
|
<result property="lxfs" column="lxfs"/>
|
||||||
<result property="nrysj" column="nrysj" />
|
<result property="nrysj" column="nrysj"/>
|
||||||
<result property="sqtysj" column="sqtysj" />
|
<result property="sqtysj" column="sqtysj"/>
|
||||||
<result property="swxw" column="swxw" />
|
<result property="swxw" column="swxw"/>
|
||||||
<result property="schoolid" column="schoolid" />
|
<result property="schoolid" column="schoolid"/>
|
||||||
<result property="sfhf" column="sfhf" />
|
<result property="sfhf" column="sfhf"/>
|
||||||
<result property="hfrn" column="hfrn" />
|
<result property="hfrn" column="hfrn"/>
|
||||||
<result property="hfuserid" column="hfuserid" />
|
<result property="hfuserid" column="hfuserid"/>
|
||||||
<result property="fhsj" column="fhsj" />
|
<result property="fhsj" column="fhsj"/>
|
||||||
<result property="yzzs" column="yzzs" />
|
<result property="yzzs" column="yzzs"/>
|
||||||
<result property="tyjg" column="tyjg" />
|
<result property="tyjg" column="tyjg"/>
|
||||||
<result property="rysj" column="rysj" />
|
<result property="rysj" column="rysj"/>
|
||||||
<result property="createTime" column="create_time" />
|
<result property="createTime" column="create_time"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectByExperienceVo">
|
<sql id="selectByExperienceVo">
|
||||||
@ -31,22 +31,23 @@
|
|||||||
<select id="selectByExperienceList" parameterType="ByExperience" resultMap="ByExperienceResult">
|
<select id="selectByExperienceList" parameterType="ByExperience" resultMap="ByExperienceResult">
|
||||||
<include refid="selectByExperienceVo"/>
|
<include refid="selectByExperienceVo"/>
|
||||||
<where>
|
<where>
|
||||||
<if test="jzxm != null and jzxm != ''"> and jzxm = #{jzxm}</if>
|
<if test="jzxm != null and jzxm != ''">and jzxm = #{jzxm}</if>
|
||||||
<if test="yexm != null and yexm != ''"> and yexm = #{yexm}</if>
|
<if test="yexm != null and yexm != ''">and yexm = #{yexm}</if>
|
||||||
<if test="csrq != null "> and csrq = #{csrq}</if>
|
<if test="csrq != null ">and csrq = #{csrq}</if>
|
||||||
<if test="lxfs != null and lxfs != ''"> and lxfs = #{lxfs}</if>
|
<if test="lxfs != null and lxfs != ''">and lxfs = #{lxfs}</if>
|
||||||
<if test="nrysj != null "> and nrysj = #{nrysj}</if>
|
<if test="nrysj != null ">and nrysj = #{nrysj}</if>
|
||||||
<if test="sqtysj != null "> and sqtysj = #{sqtysj}</if>
|
<if test="sqtysj != null ">and sqtysj = #{sqtysj}</if>
|
||||||
<if test="swxw != null and swxw != ''"> and swxw = #{swxw}</if>
|
<if test="swxw != null and swxw != ''">and swxw = #{swxw}</if>
|
||||||
<if test="schoolid != null "> and schoolid = #{schoolid}</if>
|
<if test="schoolid != null ">and schoolid = #{schoolid}</if>
|
||||||
<if test="sfhf != null and sfhf != ''"> and sfhf = #{sfhf}</if>
|
<if test="sfhf != null and sfhf != ''">and sfhf = #{sfhf}</if>
|
||||||
<if test="hfrn != null and hfrn != ''"> and hfrn = #{hfrn}</if>
|
<if test="hfrn != null and hfrn != ''">and hfrn = #{hfrn}</if>
|
||||||
<if test="hfuserid != null "> and hfuserid = #{hfuserid}</if>
|
<if test="hfuserid != null ">and hfuserid = #{hfuserid}</if>
|
||||||
<if test="fhsj != null "> and fhsj = #{fhsj}</if>
|
<if test="fhsj != null ">and fhsj = #{fhsj}</if>
|
||||||
<if test="yzzs != null and yzzs != ''"> and yzzs = #{yzzs}</if>
|
<if test="yzzs != null and yzzs != ''">and yzzs = #{yzzs}</if>
|
||||||
<if test="tyjg != null and tyjg != ''"> and tyjg = #{tyjg}</if>
|
<if test="tyjg != null and tyjg != ''">and tyjg = #{tyjg}</if>
|
||||||
<if test="rysj != null "> and rysj = #{rysj}</if>
|
<if test="rysj != null ">and rysj = #{rysj}</if>
|
||||||
</where>
|
</where>
|
||||||
|
order by create_time desc
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectByExperienceById" parameterType="Long" resultMap="ByExperienceResult">
|
<select id="selectByExperienceById" parameterType="Long" resultMap="ByExperienceResult">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user