编辑功能恢复

pet_li_6.6
liujun 2024-03-01 09:53:05 +08:00
parent 49d05552e1
commit d0fab97b30
3 changed files with 214 additions and 37 deletions

View File

@ -183,7 +183,7 @@
</el-select>
</el-form-item>
</el-col>
<el-col v-if="form.POLITICAL_STATUS=='zhonggongdangyuan'" :span="12">
<el-col v-show="form.POLITICAL_STATUS === 'zhonggongdangyuan'" :span="12">
<el-form-item label="入党时间" prop="POLITICAL_TIME">
<el-date-picker
v-model="form.POLITICAL_TIME"
@ -386,8 +386,8 @@
<el-col :span="12"/>
<el-col :span="12"/>
</el-row>
</el-row></el-form>
</el-row>
</el-form>
</div>
<div class="ui-height"/>
<div class="ui-foot">

View File

@ -133,8 +133,8 @@
<el-input v-model="form.AGE" type="number" placeholder="这里输入年龄..." disabled/>
</el-form-item>
</el-col>
</el-row>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="户口所在地" prop="HKLOCAL" class="input-width">
@ -170,7 +170,6 @@
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="政治面貌" prop="POLITICAL_STATUS">
@ -184,7 +183,7 @@
</el-select>
</el-form-item>
</el-col>
<el-col v-show="form.POLITICAL_STATUS == 'zhonggongdangyuan'" :span="12">
<el-col v-show="form.POLITICAL_STATUS === 'zhonggongdangyuan'" :span="12">
<el-form-item label="入党时间" prop="POLITICAL_TIME">
<el-date-picker
v-model="form.POLITICAL_TIME"
@ -197,7 +196,6 @@
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="是否缴纳社保" prop="IS_SOCIAL">
@ -236,6 +234,100 @@
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="是否签订劳动合同" prop="IS_SIGN_LABOR">
<el-radio-group v-model="form.IS_SIGN_LABOR" @change="form.contractFileList = []">
<el-radio v-model="form.IS_SIGN_LABOR" label="1"></el-radio>
<el-radio v-model="form.IS_SIGN_LABOR" label="0"></el-radio>
</el-radio-group>
</el-form-item>
<el-form-item v-if="form.IS_SIGN_LABOR === '1'" label="合同图片" prop="contractFileList">
<el-upload
ref="contractFileList"
:file-list="form.contractFileList"
:limit="4"
:class="{hide:hideContractUpload}"
:auto-upload="false"
:before-remove="handlePhotoBeforeRemove"
:on-remove="handleContractFileRemove"
:on-change="handleContractFileChange"
multiple
action="#"
accept=".jpg,.jpeg,.png"
list-type="picture-card">
<i class="el-icon-plus" />
</el-upload>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="是否缴纳商业保险" prop="ISPAY" @change="form.insuranceFileList = []">
<el-radio-group v-model="form.ISPAY">
<el-radio v-model="form.ISPAY" label="1"></el-radio>
<el-radio v-model="form.ISPAY" label="0"></el-radio>
</el-radio-group>
</el-form-item>
<el-form-item v-if="form.ISPAY === '1'" label="商业保险单号" prop="ISPAY_NUMBER">
<el-input v-model="form.ISPAY_NUMBER" placeholder="这里输入商业保险单号..."/>
</el-form-item>
<el-form-item v-if="form.ISPAY === '1'" label="保险图片" prop="insuranceFileList">
<el-upload
ref="insuranceFileList"
:file-list="form.insuranceFileList"
:limit="4"
:class="{hide:hideInsuranceUpload}"
:auto-upload="false"
:on-remove="handleInsuranceFileRemove"
:on-change="handleInsuranceFileChange"
:before-remove="handlePhotoBeforeRemove"
multiple
action="#"
accept=".jpg,.jpeg,.png"
list-type="picture-card">
<i class="el-icon-plus" />
</el-upload>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="是否按期缴纳工伤保险" prop="IS_INJURIES_PAY" style="float:left">
<el-radio-group v-model="form.IS_INJURIES_PAY">
<el-radio v-model="form.IS_INJURIES_PAY" label="1"></el-radio>
<el-radio v-model="form.IS_INJURIES_PAY" label="0"></el-radio>
</el-radio-group>
</el-form-item>
<el-form-item v-if="form.IS_INJURIES_PAY ==='1'" label="工伤保险有效期" prop="IS_INJURIES_PAY_TIME" style="float:left">
<el-date-picker
v-model="form.IS_INJURIES_PAY_TIME"
type="date"
placeholder="选择日期"
value-format="yyyy-MM-dd"
format="yyyy-MM-dd"
style="width: 290px"
/>
</el-form-item>
<el-form-item v-if="form.IS_INJURIES_PAY ==='1'" label="上传工伤保险凭证" style="float:left" prop="gongshangbaoxianFile">
<el-upload
ref="gongshangFileList"
:file-list="form.gongshangbaoxianFile"
:limit="4"
:class="{hide:hidegongshangUpload}"
:auto-upload="false"
:before-remove="handlePhotoBeforeRemove"
:on-remove="handleGongshangFileRemove"
:on-change="handleGongshangFileChange"
multiple
action="#"
accept=".jpg,.jpeg,.png"
list-type="picture-card">
<i class="el-icon-plus" />
</el-upload>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="岗位名称(工种)" prop="POST_ID">
@ -1008,6 +1100,33 @@ export default {
}
}
}
if (this.form.IS_INJURIES_PAY === '1') {
if (this.$refs['gongshangFileList'].uploadFiles.length > 0) {
for (let i = 0; i < this.$refs['gongshangFileList'].uploadFiles.length; i++) {
if (this.$refs['gongshangFileList'].uploadFiles[i]) {
formData.append('WORK_INSURANCE_LIST', this.$refs['gongshangFileList'].uploadFiles[i].raw)
}
}
}
}
if (this.form.ISPAY === '1') {
if (this.form.insuranceFileList.length > 0) {
for (let i = 0; i < this.form.insuranceFileList.length; i++) {
if (this.form.insuranceFileList[i]) {
formData.append('insuranceFile', this.form.insuranceFileList[i].raw)
}
}
}
}
if (this.form.IS_SIGN_LABOR === '1') {
if (this.form.contractFileList.length > 0) {
for (let i = 0; i < this.form.contractFileList.length; i++) {
if (this.form.contractFileList[i]) {
formData.append('contractFile', this.form.contractFileList[i].raw)
}
}
}
}
//
if (this.form.IS_SOCIAL === '1') {
if (this.$refs['zhenbaoUpload'].uploadFiles.length > 0) {
@ -1088,24 +1207,24 @@ export default {
this.form.photosOfLevel.push(obj)
})
}
// if (data.gongshangbaoxianFile) {
// data.gongshangbaoxianFile.map(item => {
// const obj = { id: item.IMGFILES_ID, name: item.FILENAME, url: config.fileUrl + item.FILEPATH }
// this.form.gongshangbaoxianFile.push(obj)
// })
// }
// if (data.insuranceFile) {
// data.insuranceFile.map(item => {
// const obj = { id: item.IMGFILES_ID, name: item.FILENAME, url: config.fileUrl + item.FILEPATH }
// this.form.insuranceFileList.push(obj)
// })
// }
// if (data.contractFile) {
// data.contractFile.map(item => {
// const obj = { id: item.IMGFILES_ID, name: item.FILENAME, url: config.fileUrl + item.FILEPATH }
// this.form.contractFileList.push(obj)
// })
// }
if (data.gongshangbaoxianFile) {
data.gongshangbaoxianFile.map(item => {
const obj = { id: item.IMGFILES_ID, name: item.FILENAME, url: config.fileUrl + item.FILEPATH }
this.form.gongshangbaoxianFile.push(obj)
})
}
if (data.insuranceFile) {
data.insuranceFile.map(item => {
const obj = { id: item.IMGFILES_ID, name: item.FILENAME, url: config.fileUrl + item.FILEPATH }
this.form.insuranceFileList.push(obj)
})
}
if (data.contractFile) {
data.contractFile.map(item => {
const obj = { id: item.IMGFILES_ID, name: item.FILENAME, url: config.fileUrl + item.FILEPATH }
this.form.contractFileList.push(obj)
})
}
this.EMPLOYMENT_APPLY_MANAGEMENT_ID = data.pdrelated.EMPLOYMENT_APPLY_MANAGEMENT_ID
const node = {}
node.id = this.form.DEPARTMENT_ID
@ -1149,7 +1268,6 @@ export default {
}
})
},
changeLearnerCategory() {
this.form.LEARNERCATEGORY = ''
if (this.form.LEARNERCATEGORYSTATUS === 'select') {
@ -1166,7 +1284,6 @@ export default {
this.form.LEARNERCATEGORYSTATUS = 'select'
}
},
//
hasButton() {
var keys = 'user:add,user:del,user:edit'
@ -1231,7 +1348,6 @@ export default {
this.form.insuranceFileList.push(file)
this.hideInsuranceUpload = fileList.length >= 4
},
// remove
handleInsuranceFileRemove(file, fileList) {
this.form.insuranceFileList = fileList
@ -1250,7 +1366,6 @@ export default {
this.form.contractFileList.push(file)
this.hideContractUpload = fileList.length >= 4
},
// remove
handleContractFileRemove(file, fileList) {
this.form.contractFileList = fileList

View File

@ -7,8 +7,8 @@
<h1>人员信息</h1>
</div>
<tr>
<th>照片</th>
<td>
<th style="width: 200px">照片</th>
<td style="width: 400px">
<span v-if="imgUrl != ''">
<div class="img-flex">
<viewer>
@ -18,9 +18,9 @@
</span>
<span v-else/>
</td>
<th>姓名</th>
<th style="width: 200px">姓名</th>
<td>{{ dataForm.NAME }}</td>
<th>性别</th>
<th width="200px">性别</th>
<td>{{ dataForm.SEX === '0' ? '男' : '女' }}</td>
</tr>
<tr>
@ -102,6 +102,68 @@
</td>
</tr>
<tr>
<th>是否按期缴纳工伤保险</th>
<td :colspan="dataForm.IS_INJURIES_PAY === '1' ? '':5">{{ formatLabel(dataForm.IS_INJURIES_PAY) }}</td>
<th v-if="dataForm.IS_INJURIES_PAY === '1'"></th>
<td v-if="dataForm.IS_INJURIES_PAY === '1'">{{ dataForm.IS_INJURIES_PAY_TIME }}</td>
<th v-if="dataForm.IS_INJURIES_PAY === '1'"></th>
<td v-if="dataForm.IS_INJURIES_PAY === '1'">
<span>
<viewer>
<img
v-for="item in gongshangbaoxianFile"
:src="config.fileUrl + item.FILEPATH"
:key="item.IMGFILES_ID"
width="40"
height="40"
style="object-fit: cover;">
</viewer>
</span>
</td>
</tr>
<tr>
<th>是否缴纳商业保险</th>
<td :colspan="dataForm.ISPAY === '1' ? '' : 5">
{{ formatLabel(dataForm.ISPAY) }}
</td>
<th v-if="dataForm.ISPAY === '1'"></th>
<td v-if="dataForm.ISPAY === '1'">
<span>
<viewer>
<img
v-for="item in insuranceFileList"
:src="config.fileUrl + item.FILEPATH"
:key="item.IMGFILES_ID"
width="40"
height="40"
style="object-fit: cover;">
</viewer>
</span>
</td>
<th v-if="dataForm.ISPAY === '1'"></th>
<td v-if="dataForm.ISPAY === '1'">{{ dataForm.ISPAY_NUMBER }}</td>
</tr>
<tr>
<th>是否签订劳动合同</th>
<td :colspan="dataForm.IS_SIGN_LABOR === '1' ? '' : 5">
{{ formatLabel(dataForm.IS_SIGN_LABOR) }}
</td>
<th v-if="dataForm.IS_SIGN_LABOR === '1'"></th>
<td v-if="dataForm.IS_SIGN_LABOR === '1'" colspan="3">
<span>
<viewer>
<img
v-for="item in contractFileList"
:src="config.fileUrl + item.FILEPATH"
:key="item.IMGFILES_ID"
width="40"
height="40"
style="object-fit: cover;">
</viewer>
</span>
</td>
</tr>
<tr/><tr>
<th>是否参加三级安全培训</th>
<td >{{ formatLabel(dataForm.IS_LEVEL_THREE) }}</td>
<th>三级安全培训照片</th>
@ -125,7 +187,7 @@
<th>是否特殊工种</th>
<td >{{ formatLabel(dataForm.IS_SPECIAL_JOB) }}</td>
<th>是否流动人员</th>
<td >{{ formatLabel(dataForm.ISFLOW) }}</td>
<td colspan="3">{{ formatLabel(dataForm.ISFLOW) }}</td>
</tr>
</table>
</div>
@ -246,11 +308,11 @@ export default {
this.imgUrl = config.fileUrl + this.userPhotoFile[0].FILEPATH
}
this.photosOfLevel = data.photosOfLevel
// this.insuranceFileList = data.insuranceFile
// this.contractFileList = data.contractFile
this.insuranceFileList = data.insuranceFile
this.contractFileList = data.contractFile
this.userCardIDPhotoFile = data.userCardIDPhotoFile
this.socialPhotoFile = data.socialPhotoFile
// this.gongshangbaoxianFile = data.gongshangbaoxianFile
this.gongshangbaoxianFile = data.gongshangbaoxianFile
}).catch((e) => {
this.listLoading = false
})