| | |
| | | <el-col :span="11"> |
| | | <el-table v-loading="loading" ref="tb" :data="pictureList" highlight-current-row |
| | | :row-class-name="tableRowClassName" @current-change="handleCurrentChange" border height="520px"> |
| | | <el-table-column label="体检号" align="center" prop="tjNumber" min-width="160" /> |
| | | <el-table-column label="体检号" align="center" prop="tjNumber" min-width="130" /> |
| | | <el-table-column label="姓名" align="center" prop="cusName" min-width="80" /> |
| | | <el-table-column label="性别" align="center" prop="cusSex" min-width="50"> |
| | | <template slot-scope="scope"> |
| | |
| | | <span v-if="scope.row.cusSex == '9'">未说明性别</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="手机号" align="center" prop="cusPhone" min-width="100" /> |
| | | <el-table-column label="身份证号" align="center" prop="cusIdcard" min-width="190" /> |
| | | <el-table-column label="套餐名" align="center" prop="tcm" min-width="100" /> |
| | | <el-table-column label="登记时间" align="center" prop="tjTime" min-width="120" /> |
| | | <el-table-column label="审核状态" align="center" prop="confirmStatus" min-width="80"> |
| | |
| | | <el-button type="primary" @click="imagePreviewVisible = false">确定</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <Public ref="aaa" :check-status="checkStatus" :pro-result="form.proResult" :conclusion="form.conclusion" |
| | | @add="handleChanges" :project-list="projectList" /> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import { |
| | | getListPicture, |
| | |
| | | tupian(formData) |
| | | .then(response => { |
| | | console.log('成功了', response); |
| | | if (response.code === 200 && response.base64) { |
| | | if (response.code === 200) { |
| | | this.$message.success('图片上传成功!'); |
| | | const index = this.tableList.findIndex(item => item.proId === proId); |
| | | if (index !== -1) { |
| | | const base64Image = `data:image/${fileExtension};base64,${response.base64}`; |
| | | this.$set(this.tableList[index], 'imageUrl', base64Image); |
| | | // 保存 base64 图像用于显示 |
| | | if (response.base64) { |
| | | const base64Image = `data:image/${fileExtension};base64,${response.base64}`; |
| | | this.$set(this.tableList[index], 'imageUrl', base64Image); |
| | | } |
| | | // 保存返回的 url |
| | | if (response.url) { |
| | | this.$set(this.tableList[index], 'url', response.url); |
| | | } |
| | | } |
| | | } else { |
| | | this.$message.error('图片上传失败!'); |
| | |
| | | let tjNumber = val; |
| | | this.loading = true; |
| | | getYxJcXx(tjNumber).then((res) => { |
| | | this.tableList = res.data; |
| | | this.tableList = res.data.map(item => { |
| | | // 如果 imageUrl 存在且是纯 Base64 字符串,添加 data:image 前缀 |
| | | if (item.imageUrl && !item.imageUrl.startsWith('data:image')) { |
| | | // 假设图片类型为 png,如果接口提供类型,可以替换为动态值 |
| | | item.imageUrl = `data:image/png;base64,${item.imageUrl}`; |
| | | } |
| | | return item; |
| | | }); |
| | | this.loading = false; |
| | | this.$nextTick(() => { |
| | | const headerCheckbox = this.$refs.mu.$el.querySelector( |
| | |
| | | const proId = this.selectedRow.proId; |
| | | const jcsj = this.form.proResult || " "; |
| | | const jcjl = this.form.conclusion || " "; |
| | | const url = this.selectedRow.url || ""; // 获取 url,如果不存在则为空字符串 |
| | | |
| | | addYxJcXx({ |
| | | proId: proId, |
| | | tjNumber: this.selectedTjNumber, |
| | | jcsj: jcsj, |
| | | jcjl: jcjl, |
| | | url: url // 添加 url 参数 |
| | | }) |
| | | .then((response) => { |
| | | this.form.proResult = ""; |
| | |
| | | console.error("提交失败", error); |
| | | }); |
| | | }, |
| | | handleDelete() {}, |
| | | handleExport() {}, |
| | | handleDelete() { }, |
| | | handleExport() { }, |
| | | }, |
| | | }; |
| | | </script> |