|
@@ -100,10 +100,19 @@
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<!-- 单选 -->
|
|
<!-- 单选 -->
|
|
<el-form-item style="display: block" label="时长单位">
|
|
<el-form-item style="display: block" label="时长单位">
|
|
- <el-radio-group v-model="addForm.timeType" @change="chanRadio()">
|
|
|
|
|
|
+ <el-radio-group v-model="addForm.timeType" @change="chanRadio()" style="display:inline-block;width:240px">
|
|
<el-radio label="0">按天请假</el-radio>
|
|
<el-radio label="0">按天请假</el-radio>
|
|
<el-radio label="1" v-if="addForm.leaveType != 6">按小时请假</el-radio>
|
|
<el-radio label="1" v-if="addForm.leaveType != 6">按小时请假</el-radio>
|
|
</el-radio-group>
|
|
</el-radio-group>
|
|
|
|
+ <span style="margin-left:8px">审批人</span>
|
|
|
|
+ <el-select style="display:inline-block;width:250px;margin-left:6px" multiple v-model="addForm.projectAuditorJson" placeholder="请选择">
|
|
|
|
+ <el-option
|
|
|
|
+ v-for="item in approverList"
|
|
|
|
+ :key="item.id"
|
|
|
|
+ :label="item.name"
|
|
|
|
+ :value="item.id"
|
|
|
|
+ ></el-option>
|
|
|
|
+ </el-select>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<!-- 时间选择 -->
|
|
<!-- 时间选择 -->
|
|
<el-form-item :label="flg ? '选择日期' : '选择时间'" style="width: 100%;">
|
|
<el-form-item :label="flg ? '选择日期' : '选择时间'" style="width: 100%;">
|
|
@@ -561,7 +570,8 @@ export default {
|
|
ownerId: [{ required: true, message: "请选择请假人", trigger: "blur" }],
|
|
ownerId: [{ required: true, message: "请选择请假人", trigger: "blur" }],
|
|
tel: [{required: true, validator: checkTel, trigger: 'blur'}],
|
|
tel: [{required: true, validator: checkTel, trigger: 'blur'}],
|
|
timeDays: [{required: true, validator: checks, trigger: 'blur'}],
|
|
timeDays: [{required: true, validator: checks, trigger: 'blur'}],
|
|
- leaveType: [{ required: true, message: "请选择请假类型", trigger: "blur" }]
|
|
|
|
|
|
+ leaveType: [{ required: true, message: "请选择请假类型", trigger: "blur" }],
|
|
|
|
+ projectAuditorJson: [{ required: true, message: "请选择审批人", trigger: "blur" }]
|
|
},
|
|
},
|
|
user: JSON.parse(sessionStorage.getItem("user")),
|
|
user: JSON.parse(sessionStorage.getItem("user")),
|
|
shuz: ['事假填报', '病假填报', '年假填报', '产假填报'],
|
|
shuz: ['事假填报', '病假填报', '年假填报', '产假填报'],
|
|
@@ -576,7 +586,8 @@ export default {
|
|
// indate: this.getCurrentTime(),
|
|
// indate: this.getCurrentTime(),
|
|
timeHours: 8,
|
|
timeHours: 8,
|
|
tel: '',
|
|
tel: '',
|
|
- remark: ''
|
|
|
|
|
|
+ remark: '',
|
|
|
|
+ projectAuditorJson: ''
|
|
},
|
|
},
|
|
displayTable: false,
|
|
displayTable: false,
|
|
users: [], // 人员信息
|
|
users: [], // 人员信息
|
|
@@ -693,7 +704,9 @@ export default {
|
|
iAlData : [],
|
|
iAlData : [],
|
|
|
|
|
|
// ---------
|
|
// ---------
|
|
- txselnum: 0
|
|
|
|
|
|
+ txselnum: 0,
|
|
|
|
+
|
|
|
|
+ approverList: []
|
|
};
|
|
};
|
|
},
|
|
},
|
|
computed: {},
|
|
computed: {},
|
|
@@ -710,10 +723,32 @@ export default {
|
|
mounted() {
|
|
mounted() {
|
|
this.getUsers() // 获取人员信息
|
|
this.getUsers() // 获取人员信息
|
|
this.getDepartment();
|
|
this.getDepartment();
|
|
- this.getAl()
|
|
|
|
|
|
+ this.getAl();
|
|
|
|
+ this.getApproverList()
|
|
},
|
|
},
|
|
filters: {},
|
|
filters: {},
|
|
methods: {
|
|
methods: {
|
|
|
|
+ getApproverList(){
|
|
|
|
+ this.http.post('/project/getMyParticiPMList',{
|
|
|
|
+ },res => {
|
|
|
|
+ if(res.code == 'ok'){
|
|
|
|
+ this.approverList = res.data
|
|
|
|
+ console.log('list',res.data);
|
|
|
|
+ }else {
|
|
|
|
+ this.$message({
|
|
|
|
+ message: res.msg,
|
|
|
|
+ type: 'error'
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ },error => {
|
|
|
|
+ this.$message({
|
|
|
|
+ message: error,
|
|
|
|
+ type: 'error'
|
|
|
|
+ })
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+
|
|
changeAltime(e){
|
|
changeAltime(e){
|
|
if(e == 0 && this.AlchangeP.length == 0){
|
|
if(e == 0 && this.AlchangeP.length == 0){
|
|
this.$message('请选择要批量设置的项')
|
|
this.$message('请选择要批量设置的项')
|
|
@@ -1184,6 +1219,7 @@ export default {
|
|
this.$refs.addForm.validate(valid => {
|
|
this.$refs.addForm.validate(valid => {
|
|
this.addForm.endDate = this.buling(this.addForm.endDate)
|
|
this.addForm.endDate = this.buling(this.addForm.endDate)
|
|
this.addForm.startDate = this.buling(this.addForm.startDate)
|
|
this.addForm.startDate = this.buling(this.addForm.startDate)
|
|
|
|
+ this.addForm.projectAuditorJson = JSON.stringify(this.addForm.projectAuditorJson)
|
|
if (valid) {
|
|
if (valid) {
|
|
this.http.post('/leave-sheet/add', this.addForm,
|
|
this.http.post('/leave-sheet/add', this.addForm,
|
|
res => {
|
|
res => {
|
|
@@ -1192,13 +1228,26 @@ export default {
|
|
message: '填报成功',
|
|
message: '填报成功',
|
|
type: "success"
|
|
type: "success"
|
|
});
|
|
});
|
|
- this.addForm.timeType = '0'
|
|
|
|
- this.addForm.startDate = this.getCurrentTime()
|
|
|
|
- this.addForm.endDate = this.getCurrentTime()
|
|
|
|
- this.addForm.timeDays = 1
|
|
|
|
- this.addForm.leaveType = 0
|
|
|
|
- this.addForm.timeHours = 8
|
|
|
|
- this.addForm.remark = ''
|
|
|
|
|
|
+ // this.addForm.timeType = '0'
|
|
|
|
+ // this.addForm.startDate = this.getCurrentTime()
|
|
|
|
+ // this.addForm.endDate = this.getCurrentTime()
|
|
|
|
+ // this.addForm.timeDays = 1
|
|
|
|
+ // this.addForm.leaveType = 0
|
|
|
|
+ // this.addForm.timeHours = 8
|
|
|
|
+ // this.addForm.remark = ''
|
|
|
|
+ this.addForm = {
|
|
|
|
+ timeType: '0',
|
|
|
|
+ startDate: this.getCurrentTime(),
|
|
|
|
+ endDate: this.getCurrentTime(),
|
|
|
|
+ timeDays: 1,
|
|
|
|
+ leaveType: 0,
|
|
|
|
+ ownerId: '',
|
|
|
|
+ // indate: this.getCurrentTime(),
|
|
|
|
+ timeHours: 8,
|
|
|
|
+ tel: '',
|
|
|
|
+ remark: '',
|
|
|
|
+ projectAuditorJson: ''
|
|
|
|
+ }
|
|
this.flg = true
|
|
this.flg = true
|
|
} else {
|
|
} else {
|
|
this.$message({
|
|
this.$message({
|