Merge pull request '提交' (#10) from dev-zcx into master

Reviewed-on: #10
pull/11/head
zcx 2 years ago
commit 9800001876
  1. 7
      src/api/system/employee.js
  2. 35
      src/views/system/employee/index.vue
  3. 126
      src/views/zs/officeSign/components/OfiiceSignDialogForm.vue
  4. 6
      src/views/zs/sign/components/SignFormDialog.vue

@ -38,5 +38,12 @@ export default {
url: '/system/employee/getEmployees',
method: 'get'
});
},
getOffice(userId) {
return request({
url: '/system/employee/office/' + userId,
method: 'get'
});
}
};

@ -165,24 +165,31 @@
</el-form-item>
</el-col>
</el-row>
<!-- <el-row>
<el-row>
<el-col :span="12">
<el-form-item label="所属报名点">
<el-select v-model="form.officeId" placeholder="请选择">
<el-option v-for="dict in officeOptions" :key="dict.officeId" :label="dict.officeName" :value="dict.officeId" />
</el-select>
</el-form-item>
</el-col>
<!-- <el-col :span="12">
<el-form-item label="小程序权限">
<el-radio-group v-model="form.hasStudent">
<el-radio :label="true">开通</el-radio>
<el-radio :label="false">关闭</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12">
</el-col> -->
<!-- <el-col :span="12">
<el-form-item label="管理系统权限">
<el-radio-group v-model="form.hasSys">
<el-radio :label="true">开通</el-radio>
<el-radio :label="false">关闭</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
</el-row> -->
</el-col> -->
</el-row>
<el-row>
<el-col :span="24">
@ -203,6 +210,7 @@
<script>
import empAPi from '@/api/system/employee';
import { listOffice } from "@/api/zs/office";
import { deptTreeSelect } from '@/api/system/dept';
import { getRoleOptions } from '@/api/system/role';
import { resetUserPwd } from '@/api/system/user';
@ -296,7 +304,8 @@ export default {
]
},
userOptions: [],
areaOptions: []
areaOptions: [],
officeOptions: []
};
},
watch: {
@ -331,6 +340,7 @@ export default {
// })
}
});
this.getOffices();
},
methods: {
/** 查询用户列表 */
@ -407,7 +417,8 @@ export default {
checkin: true,
areaList: [],
weight: undefined,
count: true
count: true,
officeId: undefined
};
this.resetForm('form');
},
@ -468,7 +479,15 @@ export default {
}
}
});
}
},
//
getOffices() {
listOffice().then(resp => {
if (resp.code == 200) {
this.officeOptions = resp.rows
}
})
},
}
};
</script>

@ -1,11 +1,13 @@
<template>
<el-dialog title="报名点信息" :close-on-click-modal="false" append-to-body :visible.sync="visible" width="800px" @close="closeDialog" style>
<el-dialog title="报名点信息" :close-on-click-modal="false" append-to-body :visible.sync="visible" width="900px" @close="closeDialog" style>
<div>
<el-form ref="dialogForm" :model="dialogForm" :rules="dataRule" label-width="110px" @keyup.enter.native="dialogFormSubmit()" :disabled="type == 2 || dialogForm.checkState==1 || dialogForm.checkState==2">
<el-row>
<el-col :span="12">
<el-form-item label="报名点" prop="officeId">
<el-input v-model="dialogForm.officeId" placeholder="请输入报名点ID" />
<el-select v-model="dialogForm.officeId" filterable placeholder="请选择" value-key="schoolId" clearable size="mini" @change="officeChange">
<el-option v-for="(dict, index) in officeOptions" :key="index" :label="dict.officeName" :value="dict.officeId" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
@ -29,7 +31,7 @@
<el-row>
<el-col :span="12">
<el-form-item label="线索来源" prop="source">
<el-select v-model="dialogForm.source" placeholder="请选择" clearable size="small" :disabled="modalForm.clueId != undefined">
<el-select v-model="dialogForm.source" placeholder="请选择" clearable size="small">
<el-option v-for="(dict, index) in sourceOptions" :key="index" :label="dict.dictLabel" :value="dict.dictValue" />
</el-select>
</el-form-item>
@ -60,14 +62,14 @@
<el-row>
<el-col :span="12">
<el-form-item label="报名班型" prop="signClass">
<el-select v-model="dialogForm.signClass" filterable placeholder="请选择" clearable value-key="typeId" size="small" @change="priceChange">
<el-select v-model="dialogForm.signClass" filterable placeholder="请选择" clearable value-key="typeId" size="small">
<el-option v-for="(dict, index) in classTypeOptions" :key="index" :label="`${dict.licenseType}-${dict.typeName}`" :value="dict.typeId" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="报名价格" prop="signPrice">
<el-input v-model="dialogForm.signPrice" placeholder="请输入报名价格" />
<el-input v-model="dialogForm.signPrice" placeholder="请输入报名价格" type="number" />
</el-form-item>
</el-col>
@ -75,30 +77,30 @@
<el-row>
<el-col :span="12">
<el-form-item label="培训费" prop="trainFee">
<el-input v-model="dialogForm.trainFee" placeholder="请输入培训费" />
<el-input v-model="dialogForm.trainFee" placeholder="请输入培训费" type="number" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="考试费" prop="examFee">
<el-input v-model="dialogForm.examFee" placeholder="请输入考试费" />
<el-input v-model="dialogForm.examFee" placeholder="请输入考试费" type="number" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="学杂费" prop="learningFee">
<el-input v-model="dialogForm.learningFee" placeholder="请输入学杂费" />
<el-input v-model="dialogForm.learningFee" placeholder="请输入学杂费" type="number" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="体检费" prop="physicalExamFee">
<el-input v-model="dialogForm.physicalExamFee" placeholder="请输入体检费" />
<el-input v-model="dialogForm.physicalExamFee" placeholder="请输入体检费" type="number" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="额外支出项目" prop="extraPayType">
<el-form-item label="额外支出项目" prop="extraPayTypes">
<el-select v-model="dialogForm.extraPayTypes" filterable multiple placeholder="请选择" clearable size="small">
<el-option v-for="(dict, index) in extraPayTypeOptions" :key="index" :label="dict.dictLabel" :value="dict.dictValue" />
</el-select>
@ -106,7 +108,7 @@
</el-col>
<el-col :span="12">
<el-form-item label="额外支出金额" prop="extraPay">
<el-input v-model="dialogForm.extraPay" placeholder="请输入额外支出金额" />
<el-input v-model="dialogForm.extraPay" placeholder="请输入额外支出金额" type="number" />
</el-form-item>
</el-col>
</el-row>
@ -118,10 +120,11 @@
</el-col>
<el-col :span="12">
<el-form-item label="利润" prop="profit">
<el-input v-model="dialogForm.profit" placeholder="请输入利润" />
<el-input v-model="dialogForm.profit" placeholder="请输入利润" type="number" />
</el-form-item>
</el-col>
</el-row>
<el-divider></el-divider>
<el-row>
<el-col :span="12">
<el-form-item label="收款账户" prop="collectionAccount1">
@ -138,12 +141,12 @@
<el-row>
<el-col :span="12">
<el-form-item label="入账金额" prop="entryMoney1">
<el-input v-model="dialogForm.entryMoney1" placeholder="请输入入账金额" />
<el-input v-model="dialogForm.entryMoney1" placeholder="请输入入账金额" type="number" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="手续费" prop="commission1">
<el-input v-model="dialogForm.commission1" placeholder="请输入手续费" />
<el-input v-model="dialogForm.commission1" placeholder="请输入手续费" type="number" />
</el-form-item>
</el-col>
</el-row>
@ -163,15 +166,16 @@
<el-row>
<el-col :span="12">
<el-form-item label="入账金额2" prop="entryMoney2">
<el-input v-model="dialogForm.entryMoney2" placeholder="请输入入账金额" />
<el-input v-model="dialogForm.entryMoney2" placeholder="请输入入账金额" type="number" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="手续费2" prop="commission2">
<el-input v-model="dialogForm.commission2" placeholder="请输入手续费" />
<el-input v-model="dialogForm.commission2" placeholder="请输入手续费" type="number" />
</el-form-item>
</el-col>
</el-row>
<el-divider></el-divider>
<el-row>
<el-col :span="12">
<el-form-item label="送审日期" prop="submissionTime">
@ -180,15 +184,15 @@
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="学员状态" prop="commission2">
<el-input v-model="dialogForm.commission2" placeholder="请输入手续费" />
<el-form-item label="学员状态" prop="stuStatus">
<el-input v-model="dialogForm.stuStatus" placeholder="请输入手续费" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="24">
<el-form-item label="归属人员" prop="followUserList">
<el-select v-model="modalForm.followUserList" multiple placeholder="请选择" clearable size="small" :disabled="modalForm.clueId != undefined">
<el-select v-model="dialogForm.followUserList" multiple placeholder="请选择" clearable size="small">
<el-option v-for="(dict, index) in userOptions" :key="index" :label="dict.name" :value="dict.id" />
</el-select>
</el-form-item>
@ -215,6 +219,7 @@
</template>
<script>
import { listOffice } from "@/api/zs/office";
import { addSign, updateSign, checkSign } from "@/api/zs/officeSign";
import schoolAPi from '@/api/sch/school'
import empApi from '@/api/system/employee'
@ -230,8 +235,32 @@ export default {
canSubmit: true,
dialogForm: {},
dataRule: {
officeName: [{ required: true, message: '报名点名称不能为空', trigger: 'blur' }],
schoolList: [{ required: true, message: '推送驾校不能为空', trigger: 'blur' }]
officeId: [{ required: true, message: '报名点不能为空', trigger: 'blur,change' }],
name: [{ required: true, message: '姓名不能为空', trigger: 'blur' }],
idcard: [{ required: true, message: '身份证号不能为空', trigger: 'blur' }],
phone: [{ required: true, message: '手机号不能为空', trigger: 'blur' }],
source: [{ required: true, message: '线索来源不能为空', trigger: 'blur, change' }],
signType: [{ required: true, message: '报名类别不能为空', trigger: 'blur,change' }],
dealDate: [{ required: true, message: '报名日期不能为空', trigger: 'blur,change' }],
signSchool: [{ required: true, message: '报名驾校不能为空', trigger: 'blur,change' }],
signPlace: [{ required: true, message: '报名场地不能为空', trigger: 'blur,change' }],
signClass: [{ required: true, message: '报名班型不能为空', trigger: 'blur,change' }],
signPrice: [{ required: true, message: '报名价格不能为空', trigger: 'blur' }],
profit: [{ required: true, message: '利润不能为空', trigger: 'blur' }],
trainFee: [{ required: true, message: '培训费不能为空', trigger: 'blur' }],
examFee: [{ required: true, message: '考试费不能为空', trigger: 'blur' }],
learningFee: [{ required: true, message: '学杂费不能为空', trigger: 'blur' }],
physicalExamFee: [{ required: true, message: '体检费不能为空', trigger: 'blur' }],
extraPayTypes: [{ required: true, message: '额外支付项目不能为空', trigger: 'blur' }],
extraPay: [{ required: true, message: '额外支付金额不能为空', trigger: 'blur' }],
extraPayWay: [{ required: true, message: '支付方式不能为空', trigger: 'blur' }],
collectionAccount1: [{ required: true, message: '收款账号不能为空', trigger: 'blur' }],
entryTime1: [{ required: true, message: '入账时间不能为空', trigger: 'blur' }],
entryMoney1: [{ required: true, message: '入账金额不能为空', trigger: 'blur' }],
commission1: [{ required: true, message: '手续费不能为空', trigger: 'blur' }],
submissionTime: [{ required: true, message: '送审时间不能为空', trigger: 'blur, change' }],
stuStatus: [{ required: true, message: '学员状态不能为空', trigger: 'blur,change' }],
followUserList: [{ required: true, message: '归属人员不能为空', trigger: 'blur,change' }],
},
officeOptions: [],
schoolOptions: [],
@ -240,7 +269,9 @@ export default {
userOptions: [],
sourceOptions: [],
extraPayTypeOptions: [],
type: 1
officeOptions: [],
type: 1,
schoolIdList: []
};
},
methods: {
@ -267,6 +298,7 @@ export default {
initData() {
this.getSchools();
this.getEmployee();
this.getOffices();
//线
this.getDicts('dm_source').then((response) => {
this.sourceOptions = response.data
@ -280,7 +312,6 @@ export default {
this.dialogForm = {
officeSignId: null,
officeId: null,
clueId: null,
name: null,
idcard: null,
phone: null,
@ -312,9 +343,13 @@ export default {
submissionTime: null,
stuStatus: "0",
collectionAccount1: null,
entryTime: null,
entryMoney: null,
commission: null,
entryTime1: null,
entryMoney1: null,
commission1: null,
collectionAccount2: null,
entryTime2: null,
entryMoney2: null,
commission2: null,
extraPayType: null,
extraPay: null,
extraPayWay: null
@ -393,6 +428,7 @@ export default {
}
)
},
//
getEmployee() {
empApi.getEmployee().then((resp) => {
if (resp.code == 200) {
@ -400,6 +436,44 @@ export default {
}
})
},
//
getOffices() {
listOffice().then(resp => {
if (resp.code == 200) {
this.officeOptions = resp.rows
}
})
},
//
getUserOfficeInfo() {
let userId = localStorage.getItem('userId');
empApi.getOffice().then((resp) => {
if (resp.code == 200) {
this.userOptions = resp.data
}
})
},
officeChange() {
},
//change
schoolChange(e) {
this.$set(this.dialogForm, 'signPlace', undefined)
this.$set(this.dialogForm, 'signClass', undefined)
this.classTypeOptions = []
this.getPlaces(e)
},
//change
placeChange() {
this.$set(this.dialogForm, 'signClass', undefined)
this.classTypeOptions = []
if (this.dialogForm.signPlace) {
const place = this.placeOptions.find(
(item) => item.placeId === this.dialogForm.signPlace
)
this.getClassTypes(this.dialogForm.signSchool, this.dialogForm.signPlace)
}
},
}
};
</script>

@ -50,14 +50,14 @@
<el-col :span="12">
<el-form-item label="报名驾校" prop="signSchool">
<el-select v-model="modalForm.signSchool" filterable placeholder="请选择" value-key="schoolId" clearable size="small" @change="schoolChange">
<el-option v-for="(dict, index) in schoolOptions" :key="index" :label="dict.schoolName" :value="dict.schoolId" />
<el-option v-for="(dict, index) in schoolOptions.filter(item =>item.schoolId === form.signSchool)" :key="index" :label="dict.schoolName" :value="dict.schoolId" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="报名场地" prop="signPlace">
<el-select v-model="modalForm.signPlace" filterable placeholder="请选择" clearable value-key="placeId" size="small" @change="placeChange">
<el-option v-for="(dict, index) in placeOptions" :key="index" :label="dict.name" :value="dict.placeId" />
<el-option v-for="(dict, index) in placeOptions.filter(item =>item.schoolId === form.signSchool)" :key="index" :label="dict.name" :value="dict.placeId" />
</el-select>
</el-form-item>
</el-col>
@ -67,7 +67,7 @@
<el-col :span="12">
<el-form-item label="报名班型" prop="signClass">
<el-select v-model="modalForm.signClass" filterable placeholder="请选择" clearable value-key="typeId" size="small" @change="priceChange">
<el-option v-for="(dict, index) in classTypeOptions" :key="index" :label="`${dict.licenseType}-${dict.typeName}`" :value="dict.typeId" />
<el-option v-for="(dict, index) in classTypeOptions.filter(item =>((!item.placeId && item.schoolId === form.signSchool) || item.placeId === form.signPlace))" :key="index" :label="`${dict.licenseType}-${dict.typeName}`" :value="dict.typeId" />
</el-select>
</el-form-item>
</el-col>

Loading…
Cancel
Save