|
@@ -40,7 +40,15 @@
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="政治面貌" prop="politicalOutlook" :rules="[]">
|
|
|
- <el-input v-model="inputForm.politicalOutlook"></el-input>
|
|
|
+<!-- <el-input v-model="inputForm.politicalOutlook"></el-input>-->
|
|
|
+ <el-select v-model="inputForm.politicalOutlook" placeholder="请选择政治面貌" style="width:100%;">
|
|
|
+ <el-option
|
|
|
+ v-for="item in $dictUtils.getDictList('political_outlook')"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
@@ -55,8 +63,16 @@
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="婚姻状况" prop="maritalStatus" :rules="[]">
|
|
|
- <el-input v-model="inputForm.maritalStatus"></el-input>
|
|
|
+ <el-select v-model="inputForm.maritalStatus" placeholder="请选择婚姻状况" clearable style="width: 100%;">
|
|
|
+ <el-option
|
|
|
+ v-for="item in $dictUtils.getDictList('marital_status')"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
|
+
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="联系电话" prop="mobilePhone" :rules="[{required: true, message: '联系电话不能为空', trigger: 'change'}]">
|
|
@@ -78,6 +94,9 @@
|
|
|
<el-input v-model="inputForm.permanentAddress"></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
+ </el-row>
|
|
|
+ <el-divider content-position="left"><i class="el-icon-document"></i> 学历信息</el-divider>
|
|
|
+ <el-row :gutter="26">
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="毕业院校" prop="graduatedFrom" :rules="[]">
|
|
|
<el-input v-model="inputForm.graduatedFrom"></el-input>
|
|
@@ -116,34 +135,69 @@
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="学历" prop="education" :rules="[]">
|
|
|
- <el-input v-model="inputForm.education"></el-input>
|
|
|
+ <el-select v-model="inputForm.education" placeholder="请选择学历" clearable style="width: 100%;">
|
|
|
+ <el-option
|
|
|
+ v-for="item in $dictUtils.getDictList('education')"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="学历性质" prop="educationNature" :rules="[]">
|
|
|
- <el-input v-model="inputForm.educationNature"></el-input>
|
|
|
+ <el-select v-model="inputForm.educationNature" placeholder="请选择学历性质" clearable style="width: 100%;">
|
|
|
+ <el-option
|
|
|
+ v-for="item in $dictUtils.getDictList('education_nature')"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="是否毕业" prop="graduatedOrNot" :rules="[]">
|
|
|
- <el-input v-model="inputForm.graduatedOrNot"></el-input>
|
|
|
+ <el-radio-group v-model="inputForm.graduatedOrNot">
|
|
|
+ <el-radio v-for="item in $dictUtils.getDictList('graduated_or_not')" :label="item.value" :key="item.value">{{item.label}}</el-radio>
|
|
|
+ </el-radio-group>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="英语等级" prop="englishLevel" :rules="[]">
|
|
|
- <el-input v-model="inputForm.englishLevel"></el-input>
|
|
|
+ <el-select v-model="inputForm.englishLevel" placeholder="请选择英语等级" clearable style="width: 100%;">
|
|
|
+ <el-option
|
|
|
+ v-for="item in $dictUtils.getDictList('english_level')"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="计算机等级" prop="ncre" :rules="[]">
|
|
|
- <el-input v-model="inputForm.ncre"></el-input>
|
|
|
+ <el-select v-model="inputForm.ncre" placeholder="请选择英语等级" clearable style="width: 100%;">
|
|
|
+ <el-option
|
|
|
+ v-for="item in $dictUtils.getDictList('computer_level')"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
+ </el-row>
|
|
|
+ <el-row :gutter="26">
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="个人简介" prop="remarks" :rules="[]">
|
|
|
- <el-input type="textarea" v-model="inputForm.remarks"></el-input>
|
|
|
+ <el-input type="textarea" maxlength="200" show-word-limit v-model="inputForm.remarks"></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
+ </el-row>
|
|
|
+ <el-divider content-position="left"><i class="el-icon-document"></i> 部门信息</el-divider>
|
|
|
+ <el-row :gutter="26">
|
|
|
<el-form v-if="status === 'audit'" style="width: 100%" :model="inputForm" ref="inputForm" v-loading="loading" :class="method==='view'?'readonly':''"
|
|
|
label-width="110px" @submit.native.prevent>
|
|
|
<el-row :gutter="26">
|
|
@@ -161,7 +215,7 @@
|
|
|
:url="`/system-server/sys/office/treeData?type=2`"
|
|
|
:value="inputForm.department"
|
|
|
:accordion="true"
|
|
|
- size="large"
|
|
|
+ size="default"
|
|
|
@getValue="(value) => {inputForm.department=value}"/>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
@@ -193,13 +247,165 @@
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
</el-form>
|
|
|
-
|
|
|
+ <el-form v-else-if="inputForm.type !== '0'" style="width: 100%" :model="inputForm" ref="inputForm" v-loading="loading" :class="method==='view'?'readonly':''"
|
|
|
+ :disabled="true"
|
|
|
+ label-width="110px" @submit.native.prevent>
|
|
|
+ <el-row :gutter="26">
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="所属部门" prop="department" :rules="[
|
|
|
+ ]">
|
|
|
+ <SelectTree
|
|
|
+ ref="officeTree"
|
|
|
+ :props="{
|
|
|
+ value: 'id', // ID字段名
|
|
|
+ label: 'name', // 显示名称
|
|
|
+ children: 'children' // 子级字段名
|
|
|
+ }"
|
|
|
+ :url="`/system-server/sys/office/treeData?type=2`"
|
|
|
+ :value="inputForm.department"
|
|
|
+ :accordion="true"
|
|
|
+ size="default"
|
|
|
+ @getValue="(value) => {inputForm.department=value}"/>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="进所日期" prop="entryDate" :rules="[
|
|
|
+ ]">
|
|
|
+ <el-date-picker
|
|
|
+ style="width: 100%"
|
|
|
+ v-model="inputForm.entryDate"
|
|
|
+ value-format="YYYY-MM-DD"
|
|
|
+ placeholder="选择日期"
|
|
|
+ >
|
|
|
+ </el-date-picker>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="合同开始日期" prop="contractStartDate" :rules="[
|
|
|
+ ]">
|
|
|
+ <el-date-picker
|
|
|
+ style="width: 100%"
|
|
|
+ v-model="inputForm.contractStartDate"
|
|
|
+ value-format="YYYY-MM-DD"
|
|
|
+ placeholder="选择日期"
|
|
|
+ >
|
|
|
+ </el-date-picker>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ </el-form>
|
|
|
</el-row>
|
|
|
<el-divider content-position="left"><i class="el-icon-document"></i> 社保信息(选填)</el-divider>
|
|
|
- <el-row :gutter="26">
|
|
|
+ <el-row :gutter="26" v-if="status === 'audit' || status === 'taskFormDetail'">
|
|
|
<el-col :span="12">
|
|
|
<el-form-item label="社保编号" prop="socialSecurityNumber" :rules="[]">
|
|
|
- <el-input v-model="inputForm.socialSecurityNumber" maxlength="10"></el-input>
|
|
|
+ <el-input v-model="inputForm.socialSecurityNumber" maxlength="10" @input="validateInput"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="社保银行卡号" prop="socialSecurityBankNumber" :rules="[]">
|
|
|
+ <el-input v-model="inputForm.socialSecurityBankNumber" @change="checkBankNumber(inputForm.socialSecurityBankNumber)" maxlength="19"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="社保卡照片正面" prop="socialSecurityPictureFront" :rules="[]">
|
|
|
+ <el-upload :action="`${$http.BASE_URL}/public-modules-server/oss/file/webUpload/upload`"
|
|
|
+ :limit="limitNum"
|
|
|
+ :disabled="hideUploadEdit"
|
|
|
+ list-type="picture-card"
|
|
|
+ :auto-upload="true"
|
|
|
+ :on-success="handleUploadSuccess"
|
|
|
+ v-model:file-list="fileList"
|
|
|
+ >
|
|
|
+ <el-icon><Plus /></el-icon>
|
|
|
+
|
|
|
+ <template #file="{ file }">
|
|
|
+ <div>
|
|
|
+ <img class="el-upload-list__item-thumbnail" :src="file.url" alt="" />
|
|
|
+ <span class="el-upload-list__item-actions">
|
|
|
+ <span
|
|
|
+ class="el-upload-list__item-preview"
|
|
|
+ @click="handlePictureCardPreview(file)"
|
|
|
+ >
|
|
|
+ <el-icon><zoom-in /></el-icon>
|
|
|
+ </span>
|
|
|
+ <span
|
|
|
+ v-if="!disabled"
|
|
|
+ class="el-upload-list__item-delete"
|
|
|
+ @click="handleDownload(file)"
|
|
|
+ >
|
|
|
+ <el-icon><Download /></el-icon>
|
|
|
+ </span>
|
|
|
+ <span
|
|
|
+ v-if="!disabled"
|
|
|
+ style="display:none;"
|
|
|
+ class="el-upload-list__item-delete"
|
|
|
+ @click="handleRemove(file,fileList)"
|
|
|
+ >
|
|
|
+ <el-icon><Delete /></el-icon>
|
|
|
+ </span>
|
|
|
+ </span>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </el-upload>
|
|
|
+ <el-dialog v-model="dialogVisible">
|
|
|
+ <img w-full :src="inputForm.socialSecurityPictureFrontUrl" alt="Preview Image" :style="{ maxWidth: '100%', maxHeight: '100%' }"/>
|
|
|
+ </el-dialog>
|
|
|
+
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="社保卡照片反面" prop="socialSecurityPictureOpposite" :rules="[]">
|
|
|
+ <el-upload :action="`${$http.BASE_URL}/public-modules-server/oss/file/webUpload/upload`"
|
|
|
+ :limit="limitNum"
|
|
|
+ :disabled="hideUploadEdit2"
|
|
|
+ list-type="picture-card"
|
|
|
+ :auto-upload="true"
|
|
|
+ :on-success="handleUploadSuccess2"
|
|
|
+ v-model:file-list="fileList2"
|
|
|
+ >
|
|
|
+ <el-icon><Plus /></el-icon>
|
|
|
+
|
|
|
+ <template #file="{ file }">
|
|
|
+ <div>
|
|
|
+ <img class="el-upload-list__item-thumbnail" :src="file.url" alt="" />
|
|
|
+ <span class="el-upload-list__item-actions">
|
|
|
+ <span
|
|
|
+ class="el-upload-list__item-preview"
|
|
|
+ @click="handlePictureCardPreview2(file)"
|
|
|
+ >
|
|
|
+ <el-icon><zoom-in /></el-icon>
|
|
|
+ </span>
|
|
|
+ <span
|
|
|
+ v-if="!disabled"
|
|
|
+ class="el-upload-list__item-delete"
|
|
|
+ @click="handleDownload2(file)"
|
|
|
+ >
|
|
|
+ <el-icon><Download /></el-icon>
|
|
|
+ </span>
|
|
|
+ <span
|
|
|
+ v-if="!disabled"
|
|
|
+ style="display:none;"
|
|
|
+ class="el-upload-list__item-delete"
|
|
|
+ @click="handleRemove2(file,fileList2)"
|
|
|
+ >
|
|
|
+ <el-icon><Delete /></el-icon>
|
|
|
+ </span>
|
|
|
+ </span>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </el-upload>
|
|
|
+ <el-dialog v-model="dialogVisible2">
|
|
|
+ <img w-full :src="inputForm.socialSecurityPictureOppositeUrl" alt="Preview Image" :style="{ maxWidth: '100%', maxHeight: '100%' }"/>
|
|
|
+ </el-dialog>
|
|
|
+
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ <el-row :gutter="26" v-else>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="社保编号" prop="socialSecurityNumber" :rules="[]">
|
|
|
+ <el-input v-model="inputForm.socialSecurityNumber" maxlength="10" @input="validateInput"></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
@@ -448,17 +654,26 @@
|
|
|
}
|
|
|
},
|
|
|
handleDownload(file) {
|
|
|
- toHref(file)
|
|
|
+ let file2 = {
|
|
|
+ url: this.inputForm.socialSecurityPictureFront
|
|
|
+ }
|
|
|
+ toHref(file2)
|
|
|
},
|
|
|
handleDownload2(file) {
|
|
|
- toHref(file)
|
|
|
+ let file2 = {
|
|
|
+ url: this.inputForm.socialSecurityPictureOpposite
|
|
|
+ }
|
|
|
+ toHref(file2)
|
|
|
},
|
|
|
handlePictureCardPreview(file) {
|
|
|
this.dialogImageUrl = file.url;
|
|
|
+ this.inputForm.socialSecurityPictureFrontUrl = file.url
|
|
|
+ console.log('file.url1', file.url)
|
|
|
this.dialogVisible = true;
|
|
|
},
|
|
|
handlePictureCardPreview2(file) {
|
|
|
this.dialogImageUrl = file.url;
|
|
|
+ this.inputForm.socialSecurityPictureOppositeUrl = file.url
|
|
|
this.dialogVisible2 = true;
|
|
|
},
|
|
|
async httpRequest (file) {
|
|
@@ -600,6 +815,12 @@
|
|
|
this.$message.error('身份证号码不能为空')
|
|
|
throw new Error('身份证号码不能为空')
|
|
|
}
|
|
|
+ if (!this.validateXG.isPhoneOrMobile(this.inputForm.mobilePhone)) {
|
|
|
+ this.$message.error('”联系电话“填写不正确,请重新填写')
|
|
|
+ this.loading = false
|
|
|
+ this.inputForm.mobilePhone = ''
|
|
|
+ throw new Error('”联系电话“填写不正确,请重新填写')
|
|
|
+ }
|
|
|
|
|
|
if (this.commonJS.isNotEmpty(this.inputForm.socialSecurityNumber) && (this.commonJS.isEmpty(this.inputForm.socialSecurityBankNumber) || this.commonJS.isEmpty(this.inputForm.socialSecurityPictureFront))) {
|
|
|
this.loading = false
|
|
@@ -618,7 +839,7 @@
|
|
|
}
|
|
|
this.inputForm.type = '2'
|
|
|
enrollmentRegistrationService.save(this.inputForm).then((data) => {
|
|
|
- this.inputForm.title = `${this.$store.state.user.name} 发起了 [入职登记]`
|
|
|
+ this.inputForm.title = `${this.$store.state.user.name} 发起了 [${this.inputForm.name} - 入职登记]`
|
|
|
this.inputForm.id = data.businessId
|
|
|
callback(data.businessTable, data.businessId, this.inputForm)
|
|
|
this.$refs.inputForm.resetFields()
|
|
@@ -703,13 +924,18 @@
|
|
|
throw new Error('身份证号码已存在,请重新确认')
|
|
|
}
|
|
|
})
|
|
|
-
|
|
|
},
|
|
|
//联系电话唯一性判断
|
|
|
mobilePhoneOnly(mobilePhone) {
|
|
|
+ if (!this.validateXG.isPhoneOrMobile(mobilePhone)) {
|
|
|
+ this.$message.error('”联系电话“填写不正确,请重新填写')
|
|
|
+ this.loading = false
|
|
|
+ this.inputForm.mobilePhone = ''
|
|
|
+ throw new Error('”联系电话“填写不正确,请重新填写')
|
|
|
+ }
|
|
|
enrollmentRegistrationService.findMobilePhoneOnly(mobilePhone).then((data) => {
|
|
|
if (data !== 0) {
|
|
|
- this.$message.error('手机码已存在,请重新确认')
|
|
|
+ this.$message.error('联系电话已存在,请重新确认')
|
|
|
this.inputForm.mobilePhone = ''
|
|
|
throw new Error('联系电话已存在,请重新确认')
|
|
|
}
|
|
@@ -726,8 +952,10 @@
|
|
|
handleAvatarSuccess (res, file, fileList, index, val) {
|
|
|
console.log('foleList', fileList)
|
|
|
if (val === 'front') {
|
|
|
- this.inputForm.socialSecurityPictureFront = res.url
|
|
|
+ this.inputForm.socialSecurityPictureFront = '/' + res.url
|
|
|
this.inputForm.socialSecurityPictureFrontUrl = res.lsUrl
|
|
|
+ console.log('res.url', res.url)
|
|
|
+ console.log('res.lsUrl', res.lsUrl)
|
|
|
}
|
|
|
this.hideUploadEdit = true
|
|
|
this.$forceUpdate()
|
|
@@ -750,6 +978,10 @@
|
|
|
checkIsPic (file) {
|
|
|
return this.commonJS.isPic(file)
|
|
|
},
|
|
|
+ validateInput() {
|
|
|
+ // 使用正则表达式验证输入内容,禁止中文
|
|
|
+ this.inputForm.socialSecurityNumber = this.inputForm.socialSecurityNumber.replace(/[\u4e00-\u9fa5]/g, '');
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
</script>
|