| | |
| | | <template> |
| | | <div> |
| | | <el-dialog |
| | | :title="title" |
| | | :visible.sync="open" |
| | | width="1080px" |
| | | append-to-body |
| | | > |
| | | <el-dialog :title="title" :visible.sync="open" width="1080px" append-to-body> |
| | | <h3 v-if="fList.proResult">检测项目 :{{ fList.project.proName }}</h3> |
| | | <h3 v-if="fList.proResult"> |
| | | 检测结果 :{{ fList.proResult }}{{ fList.project.proMetering }} |
| | |
| | | <h2 style="text-align: center">{{ proName || "暂无项目名称" }}</h2> |
| | | <div style="display: flex; width: 100%"> |
| | | <div style="width: 50%; margin-right: 40px"> |
| | | <el-form |
| | | :model="queryParams" |
| | | ref="queryForm" |
| | | size="small" |
| | | :inline="true" |
| | | label-width="68px" |
| | | > |
| | | <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" label-width="68px"> |
| | | <!-- <el-form-item label="病种名称" prop="bingzhong"> |
| | | <el-input |
| | | v-model="queryParams.bingzhong" |
| | |
| | | /> |
| | | </el-form-item>--> |
| | | <el-form-item label="检查结论" prop="ruleStr"> |
| | | <el-input |
| | | v-model="queryParams.ruleStr" |
| | | placeholder="请输入检查结论" |
| | | clearable |
| | | @keyup.enter.native="getList" |
| | | style="width: 130px" |
| | | /> |
| | | <el-input v-model="queryParams.ruleStr" placeholder="请输入检查结论" clearable @keyup.enter.native="getList" |
| | | style="width: 130px" /> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button |
| | | type="primary" |
| | | icon="el-icon-search" |
| | | size="mini" |
| | | @click="getList" |
| | | >搜索</el-button |
| | | > |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="getList">搜索</el-button> |
| | | </el-form-item> |
| | | <!-- <el-form-item> |
| | | <h3 >{{ queryParams.proName || '暂无项目名称' }}</h3> |
| | |
| | | <h3 style="margin-left: 160px">已选项目</h3> |
| | | </el-form-item> --> |
| | | </el-form> |
| | | <el-table |
| | | :data="dataList" |
| | | ref="multipleTable" |
| | | v-loading="loading" |
| | | @selection-change="handleSelectionChange" |
| | | border |
| | | height="480px" |
| | | > |
| | | <el-table-column type="selection" width="40" align="center" /> |
| | | <el-table-column |
| | | label="序号" |
| | | type="index" |
| | | align="center" |
| | | width="50px" |
| | | /> |
| | | <el-table :data="dataList" ref="multipleTable" row-key="aid" v-loading="loading" @selection-change="handleSelectionChange" |
| | | border height="480px"> |
| | | <el-table-column type="selection" width="40" align="center" :reserve-selection="true"/> |
| | | <el-table-column label="序号" type="index" align="center" width="50px" /> |
| | | <!-- <el-table-column label="规则" align="center" prop="ruleStr" /> --> |
| | | <el-table-column label="检查所见" align="center" prop="yxbx" /> |
| | | <el-table-column label="检查结论" align="center" prop="ruleStr" /> |
| | | </el-table> |
| | | <div class="pag"> |
| | | <div class="pag1" style="margin-left: 630px"> |
| | | <pagination |
| | | small |
| | | v-show="total > 0" |
| | | :total="total" |
| | | :page.sync="queryParams.pageNum" |
| | | :limit.sync="queryParams.pageSize" |
| | | @pagination="getList" |
| | | /> |
| | | <pagination small v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" |
| | | :limit.sync="queryParams.pageSize" @pagination="getList" /> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="jianc"> |
| | | <!-- <h3 style="margin-top: -30px;">已选项目</h3> --> |
| | | <el-form |
| | | :model="form" |
| | | ref="queryForm" |
| | | size="small" |
| | | label-width="68px" |
| | | :label-position="labelPosition" |
| | | > |
| | | <el-form :model="form" ref="queryForm" size="small" label-width="68px" :label-position="labelPosition"> |
| | | <!-- :inline="true" --> |
| | | <!-- <el-form-item> |
| | | <el-input |
| | |
| | | ></el-input> |
| | | </el-form-item> --> |
| | | <el-form-item label="检查所见" prop="jcsj"> |
| | | <el-input |
| | | v-model="form.jcsj" |
| | | clearable |
| | | type="textarea" |
| | | :autosize="{ minRows: 7 }" |
| | | style="width: 380px" |
| | | /> |
| | | <el-input v-model="form.jcsj" clearable type="textarea" :autosize="{ minRows: 7 }" style="width: 380px" /> |
| | | </el-form-item> |
| | | <el-form-item label="检查结论" prop="desc"> |
| | | <el-input |
| | | v-model="form.desc" |
| | | clearable |
| | | type="textarea" |
| | | :autosize="{ minRows: 7 }" |
| | | style="width: 380px" |
| | | /> |
| | | <el-input v-model="form.desc" clearable type="textarea" :autosize="{ minRows: 7 }" style="width: 380px" /> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | queryParams: { |
| | | ruleStr: "", |
| | | pageNum: 1, |
| | | pageSize: 10, |
| | | pageSize: 50, |
| | | }, |
| | | list: [], |
| | | fList: {}, |
| | |
| | | }, |
| | | watch: { |
| | | checkStatus(newValue) { |
| | | console.log(565658); |
| | | if (newValue === "1") { |
| | | this.updateData(this.proResult, this.conclusion); |
| | | }else{ |
| | | |
| | | } |
| | | }, |
| | | projectList: { |
| | | immediate: true, |
| | | deep: true, |
| | | handler(newVal) { |
| | | console.log("收到的项目数据:", newVal); |
| | | // 你可以在这里处理数据,比如保存到 data 或做逻辑判断 |
| | | if (newVal && newVal.length > 0) { |
| | | const firstProject = newVal[0]; // 你也可以遍历所有项目,看你业务需求 |
| | |
| | | }, |
| | | mounted() {}, |
| | | |
| | | created() {}, |
| | | created() { |
| | | |
| | | }, |
| | | methods: { |
| | | async getList() { |
| | | try { |
| | |
| | | }, |
| | | |
| | | updateData(proResult, conclusion) { |
| | | console.log(proResult, conclusion, 5658); |
| | | if (this.checkStatus == 1) { |
| | | this.form.jcsj = proResult; // 更新检查所见 |
| | | this.form.desc = conclusion; // 更新检查结论 |
| | | } else { |
| | | this.form.desc = ""; |
| | | this.form.jcsj = ""; |
| | | } |
| | | |
| | | |
| | | if (this.list.length != 0) { |
| | | let desc = ""; |
| | |
| | | .map((item) => item.yxbx) |
| | | .filter(Boolean) |
| | | .join(","); |
| | | this.form.jcsj = this.form.jcsj + jcsj; // 更新检查所见 |
| | | this.form.desc = this.form.desc + desc; |
| | | } |
| | | }, |
| | | this.form.jcsj = jcsj; // 更新检查所见 |
| | | this.form.desc = desc; |
| | | // if (this.queryParams.pageNum == 1) { |
| | | |
| | | // } else { |
| | | // this.form.jcsj = this.form.jcsj + jcsj; // 更新检查所见 |
| | | // this.form.desc = this.form.desc + desc; |
| | | // this.form.jcsj = this.uniqueStrings(this.form.jcsj) |
| | | // this.form.desc = this.uniqueStrings(this.form.desc) |
| | | // } |
| | | }else{ |
| | | this.form.jcsj = ""; // 更新检查所见 |
| | | this.form.desc = ""; |
| | | } |
| | | |
| | | }, |
| | | // uniqueStrings(strings) { |
| | | // // 使用Set来去重 |
| | | // const uniqueSet = new Set(strings); |
| | | // return Array.from(uniqueSet).join("") |
| | | // }, |
| | | handleSelectionChange(selection) { |
| | | this.list = selection; |
| | | this.list = selection |
| | | this.updateFormContent(selection); |
| | | }, |
| | | |
| | |
| | | console.error("处理数据失败:", error); |
| | | this.$message.error("操作失败"); |
| | | } |
| | | this.$refs.multipleTable?.clearSelection(); |
| | | }, |
| | | |
| | | resetForm() { |
| | |
| | | }, |
| | | callcolos() { |
| | | this.open = false; |
| | | this.$refs.multipleTable?.clearSelection(); |
| | | }, |
| | | }, |
| | | computed: { |