|
@@ -199,7 +199,8 @@
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="8" :lg="8">
|
|
|
<a-form-item label="工龄" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
|
|
- <a-input style="width: 70%" :maxLength="5" placeholder="请输入工龄" suffix="月" v-model="workMoth" />
|
|
|
+ <a-input :disabled="workMothis" :style="userId!=''&&userId!=null?'width: 40%':'width: 70%'" :maxLength="5" placeholder="请输入工龄" suffix="月" v-model="workMoth" />
|
|
|
+ <a-button style="margin-left: 5px;" icon="search" @click="onEdit()" v-if="userId!=null&&userId!=''">变更</a-button>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
|
|
@@ -326,6 +327,10 @@
|
|
|
|
|
|
</a-table>
|
|
|
</a-modal>
|
|
|
+
|
|
|
+ <a-modal v-model="visloading" title="工龄" @ok="EditWorkMoth()">
|
|
|
+ <a-input :maxLength="5" placeholder="请输入工龄" suffix="月" v-model="workMoths" />
|
|
|
+ </a-modal>
|
|
|
</a-modal>
|
|
|
|
|
|
|
|
@@ -344,7 +349,8 @@
|
|
|
import {
|
|
|
getAction,
|
|
|
httpAction,
|
|
|
- deleteAction
|
|
|
+ deleteAction,
|
|
|
+ putAction
|
|
|
} from '@/api/manage'
|
|
|
import {
|
|
|
addUser,
|
|
@@ -378,9 +384,11 @@
|
|
|
statet:true,
|
|
|
titles: "新增员工",
|
|
|
isatt:'0',
|
|
|
+ workMoths:0,
|
|
|
visibles: false,
|
|
|
isEdit:false,
|
|
|
worMoth:0,
|
|
|
+ workMothis:false,
|
|
|
personType: false,
|
|
|
cEndDate:null,
|
|
|
dataSources: [],
|
|
@@ -562,6 +570,7 @@
|
|
|
},
|
|
|
},
|
|
|
uploadLoading: false,
|
|
|
+ visloading:false,
|
|
|
confirmLoading: false,
|
|
|
headers: {},
|
|
|
form: this.$form.createForm(this),
|
|
@@ -577,7 +586,8 @@
|
|
|
sysFile: '/sysFile/sysFile/queryByUserId',
|
|
|
delSysFile: '/sysFile/sysFile/deleteById',
|
|
|
post: '/sys/position/listByDept',
|
|
|
- emails:'/sys/user/emails'
|
|
|
+ emails:'/sys/user/emails',
|
|
|
+ editWorkMoth:'/sys/user/editWorkMoth'
|
|
|
},
|
|
|
identity: "1",
|
|
|
fileList: [],
|
|
@@ -600,6 +610,9 @@
|
|
|
workMoth(newVal,oldVal){
|
|
|
this.workMoth=newVal.replace(/[^0-9]/ig,"");
|
|
|
},
|
|
|
+ workMoths(newVal,oldVal){
|
|
|
+ this.workMoths=newVal.replace(/[^0-9]/ig,"");
|
|
|
+ },
|
|
|
moth(newVal,oldVal){
|
|
|
this.moth=newVal.replace(/[^0-9]/ig,"");
|
|
|
},
|
|
@@ -619,9 +632,26 @@
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
-
|
|
|
+ EditWorkMoth(){
|
|
|
+ putAction(this.url.editWorkMoth, {
|
|
|
+ id: this.userId,
|
|
|
+ workMoth:this.workMoths
|
|
|
+ }).then(res => {
|
|
|
+ if (res.success) {
|
|
|
+ this.$message.success(res.message);
|
|
|
+ this.workMoth=this.workMoths - 0+this.moth - 0;
|
|
|
+ this.visloading=false;
|
|
|
+ } else {
|
|
|
+ this.$message.warning(res.message);
|
|
|
+ }
|
|
|
+
|
|
|
+ })
|
|
|
+ },
|
|
|
+ onEdit(){
|
|
|
+ this.workMoths=this.workMoth;
|
|
|
+ this.visloading=true;
|
|
|
+ },
|
|
|
zwOk() {
|
|
|
- console.log(this.selectedRowKeys)
|
|
|
if (this.selectionRows != null && this.selectionRows.length > 0) {
|
|
|
this.zwName = this.selectionRows[0].name;
|
|
|
this.zwCode = this.selectionRows[0].code;
|
|
@@ -653,8 +683,6 @@
|
|
|
this.selectedRowKeys.push(this.zwCode);
|
|
|
this.visibles = true;
|
|
|
this.queryzw();
|
|
|
- console.log(this.selectedRowKeys)
|
|
|
-
|
|
|
},
|
|
|
queryzw() {
|
|
|
getAction(this.url.post, {
|
|
@@ -818,7 +846,7 @@
|
|
|
if (res.success) {
|
|
|
this.roleList = res.result;
|
|
|
} else {
|
|
|
- console.log(res.message);
|
|
|
+
|
|
|
}
|
|
|
});
|
|
|
},
|
|
@@ -829,7 +857,7 @@
|
|
|
if (res.success) {
|
|
|
this.selectedRole = res.result;
|
|
|
} else {
|
|
|
- console.log(res.message);
|
|
|
+
|
|
|
}
|
|
|
});
|
|
|
},
|
|
@@ -858,6 +886,7 @@
|
|
|
this.selectedRowKeys = [];
|
|
|
this.selectionRows = [];
|
|
|
this.isEdit=false;
|
|
|
+ this.workMothis=false;
|
|
|
},
|
|
|
add() {
|
|
|
this.picUrl = "";
|
|
@@ -942,6 +971,7 @@
|
|
|
|
|
|
if (record.id != null && record.id != "") {
|
|
|
this.userId = record.id;
|
|
|
+ this.workMothis=true;
|
|
|
this.isEdit=true;
|
|
|
this.queryFiles(record.id)
|
|
|
}
|
|
@@ -990,7 +1020,7 @@
|
|
|
}
|
|
|
that.userDepartModel.departIdList = that.checkedDepartKeys
|
|
|
} else {
|
|
|
- console.log(res.message);
|
|
|
+
|
|
|
}
|
|
|
})
|
|
|
},
|
|
@@ -1057,7 +1087,6 @@
|
|
|
formData.workMoth=this.workMoth;
|
|
|
var a = this.fileLists;
|
|
|
var txt = [];
|
|
|
- console.log(this.fileLists)
|
|
|
if (this.fileLists != null && this.fileLists.length > 0) {
|
|
|
for (var i = 0; i < this.fileLists.length; i++) {
|
|
|
txt.push(this.fileLists[i].response.message)
|
|
@@ -1115,7 +1144,6 @@
|
|
|
})
|
|
|
|
|
|
} else {
|
|
|
- console.log("1")
|
|
|
}
|
|
|
})
|
|
|
},
|
|
@@ -1256,7 +1284,6 @@
|
|
|
callback()
|
|
|
} else {
|
|
|
var date= this.form.getFieldValue('entryDate');
|
|
|
- console.log(this.statet)
|
|
|
if(date!=null&&this.statet==true){
|
|
|
var da=new Date(date);
|
|
|
if(value==1){
|
|
@@ -1409,7 +1436,6 @@
|
|
|
},
|
|
|
|
|
|
normFile(e) {
|
|
|
- console.log('Upload event:', e);
|
|
|
if (Array.isArray(e)) {
|
|
|
return e
|
|
|
}
|
|
@@ -1432,7 +1458,6 @@
|
|
|
if (info.file.status === 'done') {
|
|
|
var response = info.file.response;
|
|
|
this.uploadLoading = false;
|
|
|
- console.log(response);
|
|
|
if (response.success) {
|
|
|
this.model.avatar = response.message;
|
|
|
this.picUrl = "Has no pic url yet";
|