lkk
2025-01-14 ad4fe11495d320e59d137f9fa1019792c21d12ea
src/views/hosp/project/index.vue
@@ -12,7 +12,23 @@
            style="margin-bottom: 15px"
          />
        </div>
        <el-scrollbar style="height: 629px; width: 100%">
        <div class="scrollable-container">
          <div class="content">
            <el-tree
              :data="deptOptions"
              :props="defaultProps"
              :expand-on-click-node="false"
              :filter-node-method="filterNode"
              ref="tree"
              node-key="id"
              :default-expanded-keys="treeId"
              highlight-current
              @node-click="handleNodeClick"
              :render-content="renderContent"
            />
          </div>
        </div>
        <!-- <el-scrollbar style="height: 629px; width: 100%">
          <div class="head-container">
            <el-tree
              :data="deptOptions"
@@ -26,7 +42,7 @@
              @node-click="handleNodeClick"
            />
          </div>
        </el-scrollbar>
        </el-scrollbar> -->
      </el-col>
      <el-col :span="20" :xs="24">
        <el-form
@@ -144,10 +160,17 @@
            :width="flexColumnWidth('rwdtypeName')"
          />
          <el-table-column
            label="项目价格(单位/元)"
            label="价格(/元)"
            align="center"
            prop="proPrice"
            width="75px"
            :show-overflow-tooltip="true"
          ></el-table-column>
          <el-table-column
            label="数量"
            align="center"
            prop="sl"
            width="65px"
            :show-overflow-tooltip="true"
          ></el-table-column>
          <!-- <el-table-column label="科室名称" align="center" prop="deptName" width="110px" :show-overflow-tooltip="true" /> -->
@@ -166,12 +189,20 @@
            :show-overflow-tooltip="true"
          />
          <el-table-column
            label="临床意义"
            label="结果类型"
            align="center"
            prop="proMeaning"
            width="350px"
            prop="resultType"
            width="80px"
            :show-overflow-tooltip="true"
          />
          >
            <template slot-scope="scope">
              <dict-tag
                :options="dict.type.tj_result_type"
                :value="scope.row.resultType"
              />
            </template>
          </el-table-column>
          <!-- <el-table-column label="检查方式" align="center" prop="proCheckMethod" :show-overflow-tooltip="true"
            width="110px" /> -->
          <el-table-column
@@ -179,7 +210,7 @@
            align="center"
            prop="needReport"
            :show-overflow-tooltip="true"
            width="110px"
            width="75px"
          >
            <template slot-scope="scope">
              <dict-tag
@@ -193,7 +224,7 @@
            align="center"
            prop="proCheckMethod"
            :show-overflow-tooltip="true"
            width="110px"
            width="75px"
          >
            <template slot-scope="scope">
              <dict-tag
@@ -211,19 +242,12 @@
          >
          </el-table-column>
          <el-table-column
            label="项目类型"
            label="临床意义"
            align="center"
            prop="resultType"
            width="110px"
            prop="proMeaning"
            width="350px"
            :show-overflow-tooltip="true"
          >
            <template slot-scope="scope">
              <dict-tag
                :options="dict.type.tj_result_type"
                :value="scope.row.resultType"
              />
            </template>
          </el-table-column>
          />
          <el-table-column
            label="备注"
            prop="remark"
@@ -313,13 +337,17 @@
            @select="obtain"
          />
        </el-form-item>
        <el-form-item label="明细项目" prop="proName">
          <el-input v-model="form.proName" placeholder="请输入明细项目">
          </el-input>
        </el-form-item>
        <el-form-item label="项目价格" prop="proPrice">
          <el-input v-model="form.proPrice" placeholder="请输入项目价格" />
          <el-input
            v-model="form.proPrice"
            :disabled="isPriceDisabled"
            placeholder="请输入项目价格"
          />
        </el-form-item>
        <el-form-item label="检查类别" prop="proCheckType">
          <el-input
@@ -471,18 +499,32 @@
            ></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="单位" prop="proMetering">
          <el-input
            v-model="form.proMetering"
            placeholder="请输入单位"
            style="width: 260px"
          />
        </el-form-item>
        <el-form-item label="参考范围" prop="proScope">
          <el-input
            v-model="form.proScope"
            placeholder="请输入参考范围"
            style="width: 200px"
          />
        </el-form-item>
        <el-form-item label="数量" prop="sl">
          <el-input
            v-model="form.sl"
            placeholder="请输入数量"
            style="width: 260px"
            style="width: 200px"
          />
        </el-form-item>
        <el-form-item label="组合标志" prop="sfzhfy">
          <el-select
            v-model="form.sfzhfy"
            placeholder="请选择是否组合标志"
            style="width: 200px"
            style="width: 260px"
          >
            <el-option
              v-for="dict in dict.type.sys_yes_no"
@@ -492,7 +534,7 @@
            ></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="结果类型" prop="resultType">
          <el-select
            v-model="form.resultType"
@@ -515,22 +557,29 @@
            style="display: inline-block; border-bottom: 2px solid blue"
            @click="getDetailed"
          >
          his项目名称
            his项目名称
          </span>
          <el-input v-model="form.hisXmmc" placeholder="his项目名称" style="width: 260px;">
          <el-input
            v-model="form.hisXmmc"
            placeholder="his项目名称"
            style="width: 200px"
          >
          </el-input>
        </el-form-item>
        <el-form-item label="his项目名称" prop="hisXmmc" v-if="key == 'N'">
          <el-input v-model="form.hisXmmc" placeholder="请输入明细项目" style="width: 260px;">
          <el-input
            v-model="form.hisXmmc"
            placeholder="请输入明细项目"
            style="width: 260px"
          >
          </el-input>
        </el-form-item>
        <el-form-item label="his编码" prop="hisXmbm">
          <el-input
            v-model="form.hisXmbm"
            placeholder="请输入his编码"
            style="width: 200px"
            style="width: 260px"
          />
        </el-form-item>
        <el-form-item label="his单价" prop="hisdj">
@@ -549,15 +598,19 @@
            LIS项目
          </span>
          <el-input v-model="form.lisXmmc" placeholder="请输入LIS项目" style="width: 260px;">
          <el-input
            v-model="form.lisXmmc"
            placeholder="请输入LIS项目"
            style="width: 200px"
          >
          </el-input>
        </el-form-item>
        <el-form-item label="LIS编码" prop="lisXmbm">
          <el-input
            v-model="form.LISXmbm"
            placeholder="请输入his编码"
            style="width: 200px"
            style="width: 260px"
          />
        </el-form-item>
        <el-form-item label="备注" prop="proRemark">
@@ -931,6 +984,7 @@
      // 部门树选项
      deptOptions: undefined,
      dialogTableVisible: false,
      isPriceDisabled: false,
      sfxmList: [],
      deptOptionstree: [],
      defaultPropstree: {
@@ -1024,6 +1078,10 @@
        sfxmId: "",
        lisXmbm: "",
        lisXmmc: "",
        proMetering: "",
        proScope: "",
        proSex: "2",
        resultType: "", // 初始值
      },
      // 表单校验
      rules: {
@@ -1086,6 +1144,9 @@
    this.getDeptList();
    this.getDeptTree();
  },
  mounted() {
    this.getDeptTree();
  },
  methods: {
    handleQuerys() {
      this.$refs.aaa.open = true;
@@ -1123,6 +1184,8 @@
      };
      getAllChildListById(data).then((response) => {
        // this.projectList = this.handleTree(response.data.list, "proId");
        console.log(response, 1122);
        this.projectList = response.data.list;
        this.loading = false;
      });
@@ -1138,15 +1201,16 @@
    /** 新增按钮操作 */
    handleAdd(row) {
      this.form.hisXmbm = '';
        this.form.hisXmmc = '';
        this.form.hisdj = '';
      this.form.hisXmbm = "";
      this.form.hisXmmc = "";
      this.form.hisdj = "";
      // this.reset();
      this.loading = true;
      this.proParent = false;
      this.form.proPrice = 0.0;
      this.form.proName = "";
      this.form.proId = null;
      this.form.resultType = "1";
      //  ProjectTree
      getlist().then((response) => {
        if (response.code == 200) {
@@ -1209,8 +1273,8 @@
    // 打开input弹框
    getDetailed() {
      this.querycharge.xmmc = ''
      this.querycharge.pym = ''
      this.querycharge.xmmc = "";
      this.querycharge.pym = "";
      if (this.selectList) {
        if (this.selectList.proName === "主类目") {
          this.dialogTableVisible = false;
@@ -1257,6 +1321,7 @@
      this.List = true;
      listSfxm(this.querycharge).then((response) => {
        this.sfxmList = response.rows;
        response.rows.forEach((item, index) => {
          item.newID =
            (this.querycharge.pageNum - 1) * this.querycharge.pageSize +
@@ -1282,6 +1347,7 @@
    handleNodecharge(data) {
      this.queryParam.id = data.id;
      this.List = false;
      this.getListByXmId();
    },
@@ -1339,6 +1405,19 @@
        this.deptOptions = response.data;
        this.treeId.push(this.deptOptions[0].id);
      });
    },
    renderContent(h, { node, data }) {
      return h(
        "span",
        {
          style: {
            color: data.status === "1" ? "red" : "inherit", // 动态设置颜色
            fontSize: "14px",
          },
        },
        data.label // 显示节点的 label
      );
    },
    // 筛选节点
@@ -1447,6 +1526,7 @@
        consumablesList: [],
        tjStandardList: [],
        proStatus: "0",
        resultType: "1",
      };
      this.resetForm("form");
    },
@@ -1580,8 +1660,11 @@
    handleUpdate1() {
      this.open = true;
      this.form = this.xiugaiList;
      this.form.proStatus = this.form.proStatus.toString();
      this.proParent = true;
      // 设置项目价格禁用
      this.isPriceDisabled = true;
      // if(){
      //   this.proParent = true
      // }
@@ -1603,6 +1686,7 @@
      // this.form = row;
      const proId = row.proId || this.ids;
      this.proParent = false;
      this.isPriceDisabled = false;
      getProject(proId).then((response) => {
        this.form = response.data;
        if (this.form.proParentId === "0") {
@@ -1886,10 +1970,27 @@
};
</script>
<style scoped>
.scrollable-container {
  width: 200px; /* 设置容器的宽度 */
  height: 629px; /* 设置容器的高度 */
  overflow: auto; /* 允许内容溢出时显示滚动条 */
  border: 1px solid #ccc; /* 可选:添加边框以更好地显示容器 */
  position: relative; /* 可选:使容器内的绝对定位元素能够正确显示 */
}
.content {
  width: 1000px; /* 设置内容的宽度,以触发水平滚动条 */
  height: 1000px; /* 设置内容的高度,以触发垂直滚动条 */
}
.el-table__header-wrapper .el-checkbox {
  display: none;
}
.red-text {
  color: red !important;
}
.pag {
  display: flex;
  justify-content: center;