qx
qx
2025-05-30 caef1ff213da160e818342eceb3d77fac0db280d
src/views/system/packages/index.vue
@@ -8,10 +8,10 @@
      v-show="showSearch"
      label-width="68px"
    >
      <el-form-item label="套餐名称" prop="zhmc">
      <el-form-item label="组合名称" prop="zhmc">
        <el-input
          v-model="queryParams.zhmc"
          placeholder="请输入套餐名称"
          placeholder="请输入组合名称"
          clearable
          @keyup.enter.native="handleQuery"
        />
@@ -94,7 +94,7 @@
      >
        <el-table-column type="selection" width="40" align="center" />
        <el-table-column
          label="套餐名称"
          label="组合名称"
          align="center"
          prop="zhmc"
          width="150px"
@@ -150,7 +150,7 @@
      </div>
    </template>
    <!-- 修改体检套餐对话框 -->
    <!-- 修改体检组合对话框 -->
    <el-dialog
      :title="title"
      :visible.sync="open"
@@ -167,17 +167,17 @@
      >
        <!-- <div class="dialo">
        <div class="dialo1"> -->
        <el-form-item label="套餐名称" prop="zhmc">
        <el-form-item label="组合名称" prop="zhmc">
          <span
            slot="label"
            style="display: inline-block; border-bottom: 2px solid blue"
            @click="handlePackage"
          >
            套餐名称
            组合名称
          </span>
          <el-input
            v-model="form.zhmc"
            placeholder="请输入套餐名称"
            placeholder="请输入组合名称"
            style="width: 150px"
          />
        </el-form-item>
@@ -263,6 +263,8 @@
            >
              <el-table-column prop="propinName" label="检查项目">
              </el-table-column>
              <el-table-column prop="sl" label="数量" width="56px">
              </el-table-column>
              <el-table-column prop="proPrice" label="原价" width="56px">
              </el-table-column>
              <el-table-column prop="proName" label="明细项目" width="260px">
@@ -290,12 +292,8 @@
  getZhList,
  addzhxm,
  modifyzhxm,
  getPacInFo,
  delzhxm,
  addPackage,
  updatePackage,
  updateProject,
  getPacTjProjectList,
} from "@/api/system/package";
import { Message } from "element-ui";
export default {
@@ -350,16 +348,16 @@
      showSearch: true,
      // 总条数
      total: 0,
      // 体检套餐表格数据
      // 体检组合表格数据
      packageList: [],
      // 套餐选中的父项
      // 组合选中的父项
      allpackageList: [],
      // 已选
      newproName: [],
      // 所有体检项目·
      allList: [],
      treeList: [],
      // 所有套餐数据
      // 所有组合数据
      // allpackage:[],
      // 弹出层标题
      title: "",
@@ -424,7 +422,7 @@
        return data.proEngName.indexOf(value) !== -1;
      }
    },
    /** 查询体检套餐列表 */
    /** 查询体检组合列表 */
    getList() {
      this.loading = true;
      getZhList(this.queryParams).then((response) => {
@@ -474,7 +472,7 @@
    handlePackage() {
      this.$refs.aaa.open = true;
      this.$refs.aaa.getList();
      this.$refs.aaa.title = "套餐字典";
      this.$refs.aaa.title = "组合字典";
    },
    handleChanges(param1) {
      this.form.pacName = param1[0].pacName;
@@ -503,7 +501,7 @@
    handleAdd() {
      this.reset();
      this.open = true;
      this.title = "体检套餐信息维护";
      this.title = "体检组合信息维护";
      this.DataList = [];
      this.checkedkey = [];
      this.checkedListkey = [];
@@ -511,7 +509,7 @@
    },
    handleUp() {
      this.title = "体检套餐信息维护";
      this.title = "体检组合信息维护";
      this.open = true;
      // getPacTjProjectList().then((response) => {
      //   this.allList = response.data;
@@ -527,7 +525,7 @@
    },
    /** 修改按钮操作 */
    handleUpdate(row) {
      this.title = "体检套餐信息维护";
      this.title = "体检组合信息维护";
      this.open = true;
      this.form = row;
      this.DataList = [];
@@ -593,7 +591,10 @@
                      });
                      this.pics = 0;
                      this.DataList.forEach((item) => {
                        this.pics += item.proPrice;
                        console.log(this.DataList,8888);
                        this.pics += item.proPrice * item.sl;
                        // this.pics += item.proPrice;
                      });
                    }
                  });
@@ -616,7 +617,7 @@
              });
              this.pics = 0;
              this.DataList.forEach((item) => {
                this.pics += item.proPrice;
                this.pics += item.proPrice * item.sl;
              });
            });
          });
@@ -627,6 +628,8 @@
    handleCurrentChecked(data, checked, checkedNodes) {
      this.dataObj = data;
      this.checkedObj = checked;
      console.log(checked,555);
      if (checked == true) {
        // this.$refs.tree.setCheckedKeys([data.proId]);
        let proId = data.proId;
@@ -639,7 +642,7 @@
            this.spliceData();
            this.pics = 0;
            this.DataList.forEach((item1) => {
              this.pics += item1.proPrice;
              this.pics += item1.proPrice * item1.sl;
              if (item1.proParentId == data.proId) {
                item1.propinName = data.proName;
                item1.propinPrice = this.dataObj.proPrice;
@@ -652,7 +655,7 @@
            this.list1 = false;
            this.DataList.forEach((item) => {
              this.TotalPrice1 = item.proPrice + this.TotalPrice1;
              this.pics += item.proPrice;
              this.pics += item.proPrice * item.sl;
            });
          }
        });
@@ -671,7 +674,7 @@
          });
          this.pics = 0;
          this.DataList.forEach((item, index) => {
            this.pics += item.proPrice;
            this.pics += item.proPrice * item.sl;
          });
        });
      }
@@ -699,7 +702,7 @@
            this.TotalPrice1 = 0;
            this.pics = 0;
            this.DataList.forEach((item1) => {
              this.pics += item1.proPrice;
              this.pics + item1.proPrice * item1.sl;
              // this.TotalPrice1 = item1.proPrice + this.TotalPrice1;
            });
          }
@@ -708,7 +711,7 @@
        this.DataList.push(data);
        this.pics = 0;
        this.DataList.forEach((item1) => {
          this.pics += item1.proPrice;
          this.pics += item1.proPrice * item1.sl;
          if (item1.proParentId == this.dataObj.proId) {
            item1.propinName = this.dataObj.proName;
            item1.propinPrice = this.dataObj.proPrice;
@@ -719,7 +722,7 @@
        this.pics = 0;
        this.DataList.forEach((item1) => {
          // this.TotalPrice1 = item1.proPrice + this.TotalPrice1;
          this.pics += item1.proPrice;
          this.pics += item1.proPrice * item1.sl;
        });
      }
    },
@@ -784,14 +787,14 @@
          }
        });
      } else {
        Message.warning("请先填写套餐名称");
        Message.warning("请先填写组合名称");
      }
    },
    /** 删除按钮操作 */
    handleDelete(row) {
      const pacIds = row.id || this.ids;
      this.$modal
        .confirm('是否确认删除体检套餐编号为"' + pacIds + '"的数据项?')
        .confirm('是否确认删除体检组合编号为"' + pacIds + '"的数据项?')
        .then(function () {
          return delzhxm(pacIds);
        })
@@ -802,7 +805,7 @@
        .catch(() => {});
    },
    /** 分配套餐内项目操作 */
    /** 分配组合内项目操作 */
    handleProject: function (row) {
      const pacId = row.pacId;
      this.$router.push("/system/user-auth/role/" + pacId);
@@ -818,7 +821,7 @@
        `package_${new Date().getTime()}.xlsx`
      );
    },
    // 套餐详情
    // 组合详情
    // handleSeach(row) {
    //   this.Seachopen = true;
    //   this.loading = true;