|
@@ -230,7 +230,7 @@
|
|
|
<el-row>
|
|
|
<el-col :span="6">
|
|
|
<el-form-item label="现有资格证书编码" prop="existingCertificate">
|
|
|
- <el-input v-model="baseInfoForm.existingCertificate" maxlength="40" show-word-limit placeholder="请填写医师资格证书编码"/>
|
|
|
+ <el-input v-model="baseInfoForm.existingCertificate" maxlength="40" show-word-limit placeholder="请填写现有资格证书编码"/>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="6">
|
|
@@ -241,7 +241,7 @@
|
|
|
</el-col>
|
|
|
<el-col :span="6">
|
|
|
<el-form-item label="护士执业证书编码" prop="nursePracticingCertificate">
|
|
|
- <el-input v-model="baseInfoForm.nursePracticingCertificate" maxlength="40" show-word-limit placeholder="请填写医师执业证书编码"/>
|
|
|
+ <el-input v-model="baseInfoForm.nursePracticingCertificate" maxlength="40" show-word-limit placeholder="请填写护士执业证书编码"/>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="6">
|
|
@@ -314,7 +314,7 @@
|
|
|
<div class="layout_display_flex_y">
|
|
|
<div class="layout_flex_1-y">
|
|
|
<el-table :data="hlfirstData" border style="width: 100%; height: 100%" stripe highlight-current-row :key="hlfirstKey">
|
|
|
- <el-table-column type="index" label="序号" width="100" />
|
|
|
+ <el-table-column prop="id" type="index" label="序号" width="100" />
|
|
|
<el-table-column prop="socialNo" label="身份证号" width="200">
|
|
|
<template v-slot="scope">
|
|
|
<el-input v-if="scope.row.isEdit" size="small" v-model="scope.row.socialNo"></el-input>
|
|
@@ -379,11 +379,11 @@
|
|
|
<div v-else class="demo-image__preview">
|
|
|
<el-image
|
|
|
style="width: 100px; height: 100px"
|
|
|
- :src="url"
|
|
|
+ :src="scope.row.url"
|
|
|
:zoom-rate="1.2"
|
|
|
:max-scale="7"
|
|
|
:min-scale="0.2"
|
|
|
- :preview-src-list="srcList"
|
|
|
+ :preview-src-list="scope.row.srcList"
|
|
|
:preview-teleported="true"
|
|
|
fit="cover"
|
|
|
/>
|
|
@@ -461,53 +461,6 @@
|
|
|
<span v-else>{{ scope.row.workTime }}</span>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="image" label="受聘证书" min-width="180" >
|
|
|
- <template v-slot="scope">
|
|
|
- <div v-if="scope.row.isEdit">
|
|
|
- <el-upload
|
|
|
- ref="upload"
|
|
|
- v-model:file-list="hl2fileList"
|
|
|
- list-type="picture-card"
|
|
|
- :action="apiUrl + `/hltechnologyArchives/putHL2CertificateImage?socialNo=` + scope.row.socialNo + `&id=` + scope.row.id"
|
|
|
- :headers="header"
|
|
|
- :on-success="hl2uploadSuccess"
|
|
|
- :on-preview="handlePreviewhl2"
|
|
|
- :on-remove="handleRemove"
|
|
|
- :before-upload="beforeUpload"
|
|
|
- :auto-upload="false"
|
|
|
- :multiple
|
|
|
- :show-file-list="true"
|
|
|
- >
|
|
|
- <el-icon> <Plus /></el-icon>
|
|
|
- <template #tip>
|
|
|
- <div class="el-upload__tip">只能上传 jpg/png 文件,且不超过 2MB</div>
|
|
|
- </template>
|
|
|
- </el-upload>
|
|
|
- <el-button style="margin-top: 10px" type="success" icon="Upload" @click="hl4submitUpload(scope.row)">上传到服务器</el-button>
|
|
|
- <el-dialog v-model="dialogVisible" append-to-body >
|
|
|
- <img w-full :src="dialogImageUrl" />
|
|
|
- </el-dialog>
|
|
|
- </div>
|
|
|
- <div v-else class="demo-image__preview">
|
|
|
- <el-image
|
|
|
- style="width: 100px; height: 100px"
|
|
|
- :src="workurl"
|
|
|
- :zoom-rate="1.2"
|
|
|
- :max-scale="7"
|
|
|
- :min-scale="0.2"
|
|
|
- :preview-src-list="hl2srcList"
|
|
|
- :preview-teleported="true"
|
|
|
- fit="cover"
|
|
|
- />
|
|
|
- </div>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
- <!-- <el-table-column prop="speciality" label="专业">
|
|
|
- <template v-slot="scope">
|
|
|
- <el-input v-if="scope.row.isEdit" size="small" v-model="scope.row.speciality"></el-input>
|
|
|
- <span v-else>{{ scope.row.speciality }}</span>
|
|
|
- </template>
|
|
|
- </el-table-column> -->
|
|
|
<el-table-column fixed="right" label="操作" min-width="180" width="180" center>
|
|
|
<template #default="scope">
|
|
|
<el-button type="primary" size="small" v-if="!scope.row.isEdit"
|
|
@@ -692,8 +645,9 @@
|
|
|
ref="upload"
|
|
|
v-model:file-list="hl4fileList"
|
|
|
list-type="picture-card"
|
|
|
- :action="apiUrl + `/hltechnologyArchives/putHL4CertificateImage?socialNo=` + scope.row.socialNo + `&name=` + scope.row.name"
|
|
|
+ :action="apiUrl + `/hltechnologyArchives/putHL4CertificateImage` "
|
|
|
:headers="header"
|
|
|
+ :data="{ socialNo: scope.row.socialNo, name: scope.row.name }"
|
|
|
:on-success="hl4uploadSuccess"
|
|
|
:on-preview="handlePreviewhl4"
|
|
|
:on-remove="handleRemove"
|
|
@@ -714,12 +668,12 @@
|
|
|
</div>
|
|
|
<div v-else class="demo-image__preview">
|
|
|
<el-image
|
|
|
- style="width: 100px; height: 100px"
|
|
|
- :src="trainingurl"
|
|
|
+ style="width: 100px; height: 100px"
|
|
|
+ :src="scope.row.url"
|
|
|
:zoom-rate="1.2"
|
|
|
:max-scale="7"
|
|
|
:min-scale="0.2"
|
|
|
- :preview-src-list="hl4srcList"
|
|
|
+ :preview-src-list="scope.row.srcList"
|
|
|
:preview-teleported="true"
|
|
|
fit="cover"
|
|
|
/>
|
|
@@ -1456,12 +1410,12 @@
|
|
|
</div>
|
|
|
<div v-else class="demo-image__preview">
|
|
|
<el-image
|
|
|
- style="width: 100px; height: 100px"
|
|
|
- :src="holidayurl"
|
|
|
+ style="width: 100px; height: 100px"
|
|
|
+ :src="scope.row.url"
|
|
|
:zoom-rate="1.2"
|
|
|
:max-scale="7"
|
|
|
:min-scale="0.2"
|
|
|
- :preview-src-list="hl7srcList"
|
|
|
+ :preview-src-list="scope.row.srcList"
|
|
|
:preview-teleported="true"
|
|
|
fit="cover"
|
|
|
/>
|
|
@@ -1534,7 +1488,7 @@ import {
|
|
|
saveTechnologyArchivesHL6,
|
|
|
saveTechnologyArchivesHL7,
|
|
|
saveTechnologyArchivesHL9,
|
|
|
- selectDictInfo,
|
|
|
+ selectHLDictInfo,
|
|
|
selectHLEmployeeInfo,
|
|
|
selectTechnologyArchives10,
|
|
|
selectTechnologyArchives12,
|
|
@@ -1578,7 +1532,7 @@ onMounted(() => {
|
|
|
selectHLImage1(baseInfoForm.value.socialNo)
|
|
|
.then((res1) => {
|
|
|
console.log(res1)
|
|
|
- if(res1.data.image1){
|
|
|
+ if(res1.data.image1 && res1.data != null){
|
|
|
personalimageurl.value = res1.data.image1
|
|
|
personalsrcList.value = [res1.data.image1]
|
|
|
}else{
|
|
@@ -1644,7 +1598,7 @@ const queryEmployeeInfo = () => {
|
|
|
}
|
|
|
selectHLImage1(baseInfoForm.value.socialNo)
|
|
|
.then((res1) => {
|
|
|
- if(res1.data.image1){
|
|
|
+ if(res1.data.image1 && res1.data !=null){
|
|
|
personalimageurl.value = res1.data.image1
|
|
|
personalsrcList.value = [res1.data.image1]
|
|
|
}else{
|
|
@@ -1654,7 +1608,7 @@ const queryEmployeeInfo = () => {
|
|
|
})
|
|
|
}
|
|
|
const queryDictInfo = () => {
|
|
|
- selectDictInfo()
|
|
|
+ selectHLDictInfo()
|
|
|
.then((res) => {
|
|
|
if (res) {
|
|
|
dictData.value = res
|
|
@@ -1901,27 +1855,40 @@ const queryTechnologyArchives14 = () => {
|
|
|
fourteenthData.value = []
|
|
|
})
|
|
|
}
|
|
|
-const imageList1 = ref([])
|
|
|
const queryTechnologyArchiveshl1 = () => {
|
|
|
selectTechnologyArchivesHL1()
|
|
|
.then((res) => {
|
|
|
- res.forEach(row => {
|
|
|
- // 是否标记
|
|
|
- row['isEdit'] = false
|
|
|
- // 是否新增
|
|
|
- row['isAdd'] = false
|
|
|
+ // 为每行初始化图片数据属性
|
|
|
+ const processedRows = res.map(row => {
|
|
|
+ // 使用响应式对象
|
|
|
+ return reactive({
|
|
|
+ ...row,
|
|
|
+ isEdit: false,
|
|
|
+ isAdd: false,
|
|
|
+ imageList: [], // 存储分割后的图片名
|
|
|
+ srcList: [], // 存储完整图片URL
|
|
|
+ url: '' // 当前显示的图片URL
|
|
|
+ });
|
|
|
+ });
|
|
|
+
|
|
|
+ // 并行处理所有图片请求
|
|
|
+ Promise.all(processedRows.map(row =>
|
|
|
selectHL1Image(row.socialNo, row.getTime)
|
|
|
- .then((res1)=>{
|
|
|
- imageList1.value = res1.data.image.split(',')
|
|
|
- for(let i=0; i<imageList1.value.length; i++){
|
|
|
- srcList.value[i] = uploadurl + imageList1.value[i]
|
|
|
- }
|
|
|
- url.value = srcList.value[0]
|
|
|
- console.log(res1.data.image.length)
|
|
|
- console.log(srcList.value[0])
|
|
|
- })
|
|
|
- })
|
|
|
- hlfirstData.value = res
|
|
|
+ .then(res1 => {
|
|
|
+ // 处理图片数据,过滤空值
|
|
|
+ console.log(res1)
|
|
|
+ const images = res1.data.image.split(',').filter(img => img.trim());
|
|
|
+ row.imageList = images;
|
|
|
+ row.srcList = images.map(img => uploadurl + img);
|
|
|
+ row.url = row.srcList[0] || ''; // 默认显示第一张图
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ row.srcList = []
|
|
|
+ row.url = ''
|
|
|
+ })
|
|
|
+ )).then(() => {
|
|
|
+ hlfirstData.value = processedRows
|
|
|
+ });
|
|
|
})
|
|
|
.catch(() => {
|
|
|
hlfirstData.value = []
|
|
@@ -1935,13 +1902,13 @@ const queryTechnologyArchiveshl2 = () => {
|
|
|
row['isEdit'] = false
|
|
|
// 是否新增
|
|
|
row['isAdd'] = false
|
|
|
- selectHL2Image(row.socialNo, row.workTime)
|
|
|
- .then((res1)=>{
|
|
|
- workurl.value = row.image
|
|
|
- hl2srcList.value = [res1.data.image]
|
|
|
- console.log(row)
|
|
|
- console.log(hl2srcList.value)
|
|
|
- })
|
|
|
+ // selectHL2Image(row.socialNo, row.workTime)
|
|
|
+ // .then((res1)=>{
|
|
|
+ // workurl.value = row.image
|
|
|
+ // hl2srcList.value = [res1.data.image]
|
|
|
+ // console.log(row)
|
|
|
+ // console.log(hl2srcList.value)
|
|
|
+ // })
|
|
|
})
|
|
|
hlsecondData.value = res
|
|
|
})
|
|
@@ -1967,20 +1934,37 @@ const queryTechnologyArchiveshl3 = () => {
|
|
|
const queryTechnologyArchiveshl4 = () => {
|
|
|
selectTechnologyArchivesHL4()
|
|
|
.then((res) => {
|
|
|
- res.forEach(row => {
|
|
|
- // 是否标记
|
|
|
- row['isEdit'] = false
|
|
|
- // 是否新增
|
|
|
- row['isAdd'] = false
|
|
|
- selectHL4Image(row.socialNo, row.id)
|
|
|
- .then((res1)=>{
|
|
|
- trainingurl.value = row.image
|
|
|
- hl4srcList.value = [res1.data.image]
|
|
|
- console.log(row)
|
|
|
- console.log(res1.data.image)
|
|
|
+ // 为每行初始化图片数据属性
|
|
|
+ const processedRows = res.map(row => {
|
|
|
+ // 使用响应式对象
|
|
|
+ return reactive({
|
|
|
+ ...row,
|
|
|
+ isEdit: false,
|
|
|
+ isAdd: false,
|
|
|
+ imageList: [], // 存储分割后的图片名
|
|
|
+ srcList: [], // 存储完整图片URL
|
|
|
+ url: '' // 当前显示的图片URL
|
|
|
+ });
|
|
|
+ });
|
|
|
+
|
|
|
+ // 并行处理所有图片请求
|
|
|
+ Promise.all(processedRows.map(row =>
|
|
|
+ selectHL4Image(row.socialNo, row.id)
|
|
|
+ .then(res1 => {
|
|
|
+ // 处理图片数据,过滤空值
|
|
|
+ console.log(row)
|
|
|
+ const images = res1.data.image.split(',').filter(img => img.trim());
|
|
|
+ row.imageList = images;
|
|
|
+ row.srcList = images.map(img => uploadurl + img);
|
|
|
+ row.url = row.srcList[0] || ''; // 默认显示第一张图
|
|
|
})
|
|
|
- })
|
|
|
- hlfourthData.value = res
|
|
|
+ .catch(() => {
|
|
|
+ row.srcList = []
|
|
|
+ row.url = ''
|
|
|
+ })
|
|
|
+ )).then(() => {
|
|
|
+ hlfourthData.value = processedRows
|
|
|
+ });
|
|
|
})
|
|
|
.catch(() => {
|
|
|
hlfourthData.value = []
|
|
@@ -2016,27 +2000,40 @@ const queryTechnologyArchiveshl6 = () => {
|
|
|
hlsixthData.value = []
|
|
|
})
|
|
|
}
|
|
|
-const imageList7 = ref([])
|
|
|
const queryTechnologyArchiveshl7 = () => {
|
|
|
selectTechnologyArchivesHL7()
|
|
|
.then((res) => {
|
|
|
- res.forEach(row => {
|
|
|
- // 是否标记
|
|
|
- row['isEdit'] = false
|
|
|
- // 是否新增
|
|
|
- row['isAdd'] = false
|
|
|
- selectHL7Image(row.socialNo, row.id)
|
|
|
- .then((res1)=>{
|
|
|
- imageList7.value = res1.data.image.split(',')
|
|
|
- for(let i=0; i<imageList7.value.length; i++){
|
|
|
- hl7srcList.value[i] = uploadurl + imageList7.value[i]
|
|
|
- }
|
|
|
- holidayurl.value = hl7srcList.value[0]
|
|
|
- console.log(res1.data.image.length)
|
|
|
- console.log(hl7srcList.value[0])
|
|
|
- })
|
|
|
- })
|
|
|
- hlseventhData.value = res
|
|
|
+ // 为每行初始化图片数据属性
|
|
|
+ const processedRows = res.map(row => {
|
|
|
+ // 使用响应式对象
|
|
|
+ return reactive({
|
|
|
+ ...row,
|
|
|
+ isEdit: false,
|
|
|
+ isAdd: false,
|
|
|
+ imageList: [], // 存储分割后的图片名
|
|
|
+ srcList: [], // 存储完整图片URL
|
|
|
+ url: '' // 当前显示的图片URL
|
|
|
+ });
|
|
|
+ });
|
|
|
+
|
|
|
+ // 并行处理所有图片请求
|
|
|
+ Promise.all(processedRows.map(row =>
|
|
|
+ selectHL7Image(row.socialNo, row.id)
|
|
|
+ .then(res1 => {
|
|
|
+ // 处理图片数据,过滤空值
|
|
|
+ console.log(res1)
|
|
|
+ const images = res1.data.image.split(',').filter(img => img.trim());
|
|
|
+ row.imageList = images;
|
|
|
+ row.srcList = images.map(img => uploadurl + img);
|
|
|
+ row.url = row.srcList[0] || ''; // 默认显示第一张图
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ row.srcList = []
|
|
|
+ row.url = ''
|
|
|
+ })
|
|
|
+ )).then(() => {
|
|
|
+ hlseventhData.value = processedRows
|
|
|
+ });
|
|
|
})
|
|
|
.catch(() => {
|
|
|
hlseventhData.value = []
|
|
@@ -2421,11 +2418,6 @@ function uploadSuccess1(response: any, uploadFile: UploadFile) {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-//查看图片
|
|
|
-const srcList = ref([])
|
|
|
-const url = ref("")
|
|
|
-
|
|
|
-
|
|
|
// 保存
|
|
|
const updatehlfirstInfo = (row) => {
|
|
|
if (!row.socialNo || !row.getTime) {
|
|
@@ -2532,7 +2524,7 @@ const deletehlfirstInfo = (row) => {
|
|
|
distinguishCancelAndClose: true,
|
|
|
dangerouslyUseHTMLString: true
|
|
|
}).then(() => {
|
|
|
- delTechnologyArchivesHL6ByCode(row.socialNo, row.getTime).then((res) => {
|
|
|
+ delTechnologyArchivesHL1ByCode(row.socialNo, row.getTime).then((res) => {
|
|
|
ElMessage({
|
|
|
type: "success",
|
|
|
message: res.cg,
|
|
@@ -2674,7 +2666,7 @@ const callSavehlsecondInfo = (row) => {
|
|
|
showClose: true,
|
|
|
});
|
|
|
queryTechnologyArchiveshl2()
|
|
|
- setHL2Image(row.socialNo,row.workTime,hl2url.value)
|
|
|
+ // setHL2Image(row.socialNo,row.workTime,hl2url.value)
|
|
|
hl2fileList.value = []
|
|
|
})
|
|
|
}).catch((action) => {
|
|
@@ -3431,6 +3423,7 @@ const hl4submitUpload = (row) => {
|
|
|
if(row.isOversize && !row.isJPG){
|
|
|
row.isUpload = false
|
|
|
}else{
|
|
|
+ upload.value!.action = `${apiUrl}/hltechnologyArchives/putHL4CertificateImage?socialNo=${row.socialNo}&name=${row.name}`
|
|
|
upload.value!.submit();
|
|
|
row.isUpload = true
|
|
|
}
|
|
@@ -3438,26 +3431,29 @@ const hl4submitUpload = (row) => {
|
|
|
|
|
|
//上传图片
|
|
|
const hl4fileList = ref([])
|
|
|
-
|
|
|
+
|
|
|
+const hl4urls = ref([])
|
|
|
const hl4url = ref("")
|
|
|
-function hl4uploadSuccess(response: any, uploadFile: UploadFile, uploadFiles: UploadFiles) {
|
|
|
- hl4url.value = response.data.data.path
|
|
|
+function hl4uploadSuccess(response: any, uploadFile: UploadFile) {
|
|
|
+ console.log(response.data.urls.length)
|
|
|
+ hl4urls.value.push(response.data.urls)
|
|
|
+ console.log(hl4urls.value)
|
|
|
+ hl4url.value = hl4urls.value.join(",")
|
|
|
+ console.log(hl4url.value)
|
|
|
const index = XEUtils.findLastIndexOf(hl4fileList.value, (item: UploadUserFile) => {
|
|
|
return item.uid === uploadFile.uid;
|
|
|
})
|
|
|
if (response.code === 200) {
|
|
|
- hl4fileList.value[index].url = uploadurl + hl4url.value
|
|
|
+ for(let i=0; i<hl4urls.value.length; i++){
|
|
|
+ hl4fileList.value[index].url = uploadurl + hl4urls.value[i]
|
|
|
+ }
|
|
|
ElMessage.success("上传成功");
|
|
|
} else {
|
|
|
- hl4fileList.value[index].status = 'fail'
|
|
|
+ fileList.value[index].status = 'fail'
|
|
|
ElMessage.error("上传失败");
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-//查看图片
|
|
|
-const hl4srcList = ref([])
|
|
|
-const trainingurl = ref("")
|
|
|
-
|
|
|
// 保存
|
|
|
const updatehlfourthInfo = (row) => {
|
|
|
if (!row.socialNo) {
|
|
@@ -3521,7 +3517,8 @@ const callSavehlfourthInfo = (row) => {
|
|
|
showClose: true,
|
|
|
});
|
|
|
setHL4Image(row.socialNo,row.beginTime,hl4url.value)
|
|
|
- hl4fileList.value = []
|
|
|
+ hl4fileList.value = []
|
|
|
+ hl4urls.value = []
|
|
|
queryTechnologyArchiveshl4()
|
|
|
})
|
|
|
}).catch((action) => {
|
|
@@ -3819,10 +3816,6 @@ function hl7uploadSuccess(response: any, uploadFile: UploadFile, uploadFiles: Up
|
|
|
|
|
|
}
|
|
|
|
|
|
-//查看图片
|
|
|
-const hl7srcList = ref([])
|
|
|
-const holidayurl = ref("")
|
|
|
-
|
|
|
|
|
|
// 保存
|
|
|
const updatehlseventhInfo = (row) => {
|