| | |
| | | <template> |
| | | <div class="organ-utilization-detail"> |
| | | <case-basic-info :case-id="caseId" :show-attachment="true" /> |
| | | |
| | | <!-- 基本信息 --> |
| | | <el-card class="detail-card"> |
| | | <div slot="header" class="clearfix"> |
| | | <span class="detail-title">器官利用基本信息</span> |
| | | <div style="float: right;"> |
| | | <el-button type="primary" @click="handleSave" :loading="saveLoading"> |
| | | 保存 |
| | | </el-button> |
| | | <el-button |
| | | type="success" |
| | | @click="handleComplete" |
| | | :disabled="form.recordstate === 'completed'" |
| | | :loading="confirmLoading" |
| | | > |
| | | 完成利用 |
| | | </el-button> |
| | | <el-form :model="form" ref="form" :rules="rules" label-width="120px"> |
| | | <!-- 基本信息 --> |
| | | <el-card class="detail-card"> |
| | | <div slot="header" class="clearfix"> |
| | | <span class="detail-title">器官利用基本信息</span> |
| | | <div style="float: right;"> |
| | | <el-button |
| | | type="primary" |
| | | @click="handleSave" |
| | | :loading="saveLoading" |
| | | > |
| | | 保存 |
| | | </el-button> |
| | | <el-button |
| | | type="success" |
| | | @click="handleComplete" |
| | | :loading="confirmLoading" |
| | | > |
| | | 完成利用 |
| | | </el-button> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | | <el-form :model="form" ref="form" :rules="rules" label-width="120px"> |
| | | <el-row :gutter="20"> |
| | | <el-col :span="6"> |
| | | <el-form-item align="left" label="遗体捐献" prop="isbodydonation"> |
| | | <el-radio-group v-model="form.isbodydonation"> |
| | | <el-radio |
| | | v-for="dict in dict.type.sys_0_1 || []" |
| | | :key="dict.value" |
| | | :label="dict.value" |
| | | >{{ dict.label }}</el-radio |
| | | > |
| | | </el-radio-group> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="18"> |
| | | <el-form-item align="left" label="接收单位" prop="receivingunit"> |
| | | <el-input |
| | | v-model="form.receivingunit" |
| | | placeholder="请输入接收单位" |
| | | :disabled="form.isbodydonation !== '1'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | |
| | | <el-row :gutter="20"> |
| | | <el-col :span="6"> |
| | |
| | | type="datetime" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | style="width: 100%" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | <el-row :gutter="20"> |
| | | <el-col :span="12"> |
| | | <el-form-item label="登记人" prop="createBy"> |
| | | <el-input v-model="form.createBy" readonly /> |
| | | <el-input v-model="form.createBy" /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | type="datetime" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | style="width: 100%" |
| | | readonly |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-form> |
| | | </el-card> |
| | | |
| | | </el-card> |
| | | <el-card class="detail-card"> |
| | | <div slot="header" class="clearfix"> |
| | | <span class="detail-title">遗体捐献信息</span> |
| | | </div> |
| | | <el-row :gutter="20"> |
| | | <el-col :span="6"> |
| | | <el-form-item align="left" label="遗体捐献" prop="isbodydonation"> |
| | | <el-radio-group v-model="form.isbodydonation"> |
| | | <el-radio |
| | | v-for="dict in dict.type.sys_0_1 || []" |
| | | :key="dict.value" |
| | | :label="dict.value" |
| | | >{{ dict.label }}</el-radio |
| | | > |
| | | </el-radio-group> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="18" v-if="form.isbodydonation == 1"> |
| | | <el-form-item |
| | | align="left" |
| | | label="接收单位" |
| | | prop="receivingunitname" |
| | | > |
| | | <el-input |
| | | v-model="form.receivingunitname" |
| | | placeholder="请输入接收单位" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="8" v-else> |
| | | <el-form-item align="left" label="接收家属" prop="relationname"> |
| | | <el-input |
| | | v-model="form.relationname" |
| | | placeholder="请输入接收家属" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-card> |
| | | </el-form> |
| | | <!-- 器官利用记录部分 - 整合受者详情 --> |
| | | <el-card class="utilization-card"> |
| | | <div slot="header" class="clearfix"> |
| | | <span class="detail-title">器官利用记录</span> |
| | | <div style="float: right;"> |
| | | <el-tag :type="getStatusTagType(form.recordstate)"> |
| | | {{ getStatusText(form.recordstate) }} |
| | | </el-tag> |
| | | <dict-tag |
| | | :options="dict.type.utilize_statue" |
| | | :value="form.completeState" |
| | | /> |
| | | </div> |
| | | </div> |
| | | |
| | |
| | | v-for="dict in dict.type.sys_Organ || []" |
| | | :key="dict.value" |
| | | :label="dict.value" |
| | | :disabled="form.recordstate === 'completed'" |
| | | > |
| | | {{ dict.label }} |
| | | </el-checkbox> |
| | |
| | | <el-input |
| | | v-model="scope.row.name" |
| | | placeholder="请输入受者姓名" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | value-format="yyyy-MM-dd" |
| | | placeholder="选择出生日期" |
| | | style="width: 100%" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | v-model="scope.row.sex" |
| | | placeholder="请选择性别" |
| | | style="width: 100%" |
| | | :disabled="form.recordstate === 'completed'" |
| | | > |
| | | <el-option label="男" value="0" /> |
| | | <el-option label="女" value="1" /> |
| | | <el-option label="男" :value="0" /> |
| | | <el-option label="女" :value="1" /> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | <el-input |
| | | v-model="scope.row.age" |
| | | placeholder="年龄" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | v-model="scope.row.idcardtype" |
| | | placeholder="请选择证件类型" |
| | | style="width: 100%" |
| | | :disabled="form.recordstate === 'completed'" |
| | | > |
| | | <el-option label="身份证" value="1" /> |
| | | <el-option label="护照" value="2" /> |
| | | <el-option label="军官证" value="3" /> |
| | | <el-option label="其他" value="4" /> |
| | | <el-option label="身份证" :value="1" /> |
| | | <el-option label="护照" :value="2" /> |
| | | <el-option label="军官证" :value="3" /> |
| | | <el-option label="其他" :value="4" /> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | <el-input |
| | | v-model="scope.row.idcardno" |
| | | placeholder="证件号码" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | <el-input |
| | | v-model="scope.row.hospitalname" |
| | | placeholder="请输入移植中心名称" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | <el-input |
| | | v-model="scope.row.phone" |
| | | placeholder="联系电话" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | :rows="2" |
| | | v-model="scope.row.residenceaddress" |
| | | placeholder="请输入详细地址" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | <el-date-picker |
| | | v-model="scope.row.transplanttime" |
| | | type="datetime" |
| | | value-format="YYYY-MM-DD HH:mm:ss" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | placeholder="选择移植日期" |
| | | style="width: 100%" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | <el-input |
| | | v-model="scope.row.transplantdoct" |
| | | placeholder="请输入移植医生" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | :rows="3" |
| | | v-model="scope.row.abandonreason" |
| | | placeholder="请输入未移植原因" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | style="width: 100%" |
| | | v-model="scope.row.transplanttime" |
| | | type="datetime" |
| | | value-format="YYYY-MM-DD HH:mm:ss" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | placeholder="选择移植时间" |
| | | /> |
| | | </template> |
| | |
| | | |
| | | <el-table-column label="受者姓名" align="center" prop="name"> |
| | | <template slot-scope="scope"> |
| | | <el-input |
| | | v-model="scope.row.name" |
| | | placeholder="受者姓名" |
| | | :disabled="form.recordstate === 'completed'" |
| | | /> |
| | | </template> |
| | | </el-table-column> |
| | | |
| | | <el-table-column |
| | | label="操作" |
| | | align="center" |
| | | class-name="small-padding fixed-width" |
| | | v-if="form.recordstate !== 'completed'" |
| | | > |
| | | <template slot-scope="scope"> |
| | | <el-button |
| | | size="mini" |
| | | type="text" |
| | | icon="el-icon-edit" |
| | | @click="handleEditUtilization(scope.row)" |
| | | > |
| | | 编辑 |
| | | </el-button> |
| | | <el-button |
| | | size="mini" |
| | | type="text" |
| | | icon="el-icon-delete" |
| | | style="color: #F56C6C;" |
| | | @click="handleRemoveOrgan(scope.$index)" |
| | | v-if="!scope.row.id" |
| | | > |
| | | 删除 |
| | | </el-button> |
| | | <el-input v-model="scope.row.name" placeholder="受者姓名" /> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | </div> |
| | | </el-card> |
| | | |
| | | <!-- 编辑利用记录对话框 --> |
| | | <el-dialog |
| | | title="编辑器官利用记录" |
| | | :visible.sync="editDialogVisible" |
| | | width="600px" |
| | | > |
| | | <el-form :model="currentRecord" label-width="120px"> |
| | | <el-row :gutter="20"> |
| | | <el-col :span="12"> |
| | | <el-form-item label="器官名称"> |
| | | <el-input v-model="currentRecord.organname" readonly /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="移植状态"> |
| | | <el-select |
| | | v-model="currentRecord.transplantstate" |
| | | style="width: 100%" |
| | | > |
| | | <el-option |
| | | v-for="dict in transplantStatusList" |
| | | :key="dict.value" |
| | | :label="dict.label" |
| | | :value="dict.value" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-form-item |
| | | label="未移植原因" |
| | | v-if="currentRecord.transplantstate === '0'" |
| | | > |
| | | <el-input |
| | | type="textarea" |
| | | :rows="3" |
| | | v-model="currentRecord.abandonreason" |
| | | placeholder="请输入未移植原因" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item |
| | | label="移植医院" |
| | | v-if="currentRecord.transplantstate === '1'" |
| | | > |
| | | <el-select |
| | | v-model="currentRecord.hospitalno" |
| | | placeholder="请选择移植医院" |
| | | style="width: 100%" |
| | | > |
| | | <el-option |
| | | v-for="hospital in hospitalList" |
| | | :key="hospital.hospitalNo" |
| | | :label="hospital.hospitalName" |
| | | :value="hospital.hospitalNo" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item |
| | | label="受者姓名" |
| | | v-if="currentRecord.transplantstate === '1'" |
| | | > |
| | | <el-input v-model="currentRecord.name" placeholder="请输入受者姓名" /> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div slot="footer"> |
| | | <el-button @click="editDialogVisible = false">取消</el-button> |
| | | <el-button type="primary" @click="handleEditConfirm">确认</el-button> |
| | | </div> |
| | | </el-dialog> |
| | | |
| | | <!-- 文件预览对话框 --> |
| | | <FilePreviewDialog |
| | | :visible="filePreviewVisible" |
| | |
| | | FilePreviewDialog, |
| | | CaseBasicInfo |
| | | }, |
| | | dicts: ["sys_BloodType", "sys_Organ", "sys_0_1"], |
| | | dicts: ["sys_BloodType", "sys_Organ", "sys_0_1", "utilize_statue"], |
| | | data() { |
| | | return { |
| | | caseId: null, |
| | |
| | | id: undefined, |
| | | infoid: undefined, |
| | | inpatientno: "", |
| | | recordstate: "pending", |
| | | completeState: "2", |
| | | caseNo: "", |
| | | donorno: "", |
| | | treatmenthospitalname: "", |
| | |
| | | assessannex: "", |
| | | donateorgan: "", |
| | | isbodydonation: "0", |
| | | receivingunit: "", |
| | | receivingunitname: "", |
| | | createBy: "", |
| | | createTime: "", |
| | | updateBy: "", |
| | |
| | | response.data.length > 0 |
| | | ) { |
| | | const data = response.data[0]; |
| | | if (!data.completeState || data.completeState == 1) { |
| | | data.completeState = "2"; |
| | | } |
| | | // 填充表单数据 |
| | | Object.assign(this.form, data); |
| | | |
| | |
| | | ) |
| | | ? data.serviceDonatecomporganList.map(record => ({ |
| | | ...record, |
| | | transplanttime: record.transplanttime || "", |
| | | transplantstate: record.transplantstate |
| | | ? record.transplantstate.toString() |
| | | : "1" |
| | | })) |
| | | : []; |
| | | } |
| | | console.log(this.utilizationData.serviceDonatecomporganList); |
| | | |
| | | // 初始化附件 |
| | | if (this.form.assessannex) { |
| | |
| | | this.expandedRows = expandedRows.map(item => item.organno); |
| | | }, |
| | | |
| | | // 编辑利用记录 |
| | | handleEditUtilization(row) { |
| | | const index = this.utilizationData.serviceDonatecomporganList.findIndex( |
| | | item => item.organno === row.organno |
| | | ); |
| | | if (index !== -1) { |
| | | this.currentRecord = { ...row }; |
| | | this.currentEditIndex = index; |
| | | this.editDialogVisible = true; |
| | | } |
| | | }, |
| | | |
| | | // 确认编辑 |
| | | handleEditConfirm() { |
| | | if (this.currentEditIndex !== -1) { |
| | | this.utilizationData.serviceDonatecomporganList[ |
| | | this.currentEditIndex |
| | | ] = { |
| | | ...this.currentRecord |
| | | }; |
| | | this.$message.success("利用记录更新成功"); |
| | | this.editDialogVisible = false; |
| | | } |
| | | }, |
| | | |
| | | // 删除器官记录 |
| | | handleRemoveOrgan(index) { |
| | | this.$confirm("确认删除这条器官记录吗?", "提示", { |
| | |
| | | // 获取状态标签类型 |
| | | getStatusTagType(status) { |
| | | const typeMap = { |
| | | completed: "success", |
| | | processing: "warning", |
| | | pending: "info" |
| | | 3: "success", |
| | | 2: "warning", |
| | | 1: "info" |
| | | }; |
| | | return typeMap[status] || "info"; |
| | | }, |
| | |
| | | // 获取状态文本 |
| | | getStatusText(status) { |
| | | const textMap = { |
| | | completed: "已完成", |
| | | processing: "进行中", |
| | | pending: "待处理" |
| | | 3: "已完成", |
| | | 2: "进行中", |
| | | 1: "待处理" |
| | | }; |
| | | return textMap[status] || "未知"; |
| | | }, |
| | |
| | | } |
| | | ); |
| | | |
| | | |
| | | if (incompleteRecords.length > 0) { |
| | | this.$message.warning("请先完善所有利用记录的信息"); |
| | | return; |
| | |
| | | }) |
| | | .then(async () => { |
| | | this.confirmLoading = true; |
| | | this.form.recordstate = "completed"; |
| | | this.form.completeState = "3"; |
| | | this.form.completetime = |
| | | this.form.completetime || |
| | | new Date() |
| | |
| | | this.$message.error( |
| | | "确认利用失败:" + (response.msg || "未知错误") |
| | | ); |
| | | this.form.recordstate = "pending"; |
| | | this.form.completeState = "2"; |
| | | this.form.completetime = ""; |
| | | } |
| | | } catch (error) { |
| | | console.error("确认利用失败:", error); |
| | | this.$message.error("确认利用失败"); |
| | | this.form.recordstate = "pending"; |
| | | this.form.completeState = "2"; |
| | | this.form.completetime = ""; |
| | | } finally { |
| | | this.confirmLoading = false; |
| | |
| | | .recipient-form { |
| | | padding: 15px; |
| | | } |
| | | |
| | | .attachment-header { |
| | | flex-wrap: wrap; |
| | | } |
| | |
| | | margin-top: 8px; |
| | | margin-left: 0; |
| | | } |
| | | |
| | | .form-section { |
| | | margin-bottom: 20px; |
| | | padding-bottom: 15px; |