lkk
2024-12-16 c7b33db117fd2893d7d1c93bf5d46e87d33e44d0
src/views/hosp/order/index.vue
@@ -13,7 +13,7 @@
          ref="inputName"
          v-model="queryParams.name"
          placeholder="请输入姓名"
          style="width: 120px"
          style="width: 150px"
          clearable
          @keyup.enter.native="handleQuery"
        />
@@ -23,7 +23,7 @@
          ref="inputName"
          v-model="queryParams.tjNum"
          placeholder="请输入体检号"
          style="width: 170px"
          style="width: 150px"
          clearable
          @keyup.enter.native="handleQuery"
          @blur="hb"
@@ -34,12 +34,60 @@
          ref="inputName"
          v-model="queryParams.xmmc"
          placeholder="请输入体检项目"
          style="width: 120px"
          style="width: 150px"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="登记时间" prop="createTimeList">
      <el-form-item
        label="单位名称"
        prop="tjCompName"
        style="margin-left: 20px;margin-right: 500px;"
      >
        <el-select
          :remote-method="getRemoteData"
          v-model="queryParams.tjCompName"
          value-key="drugManufacturerId"
          style="width: 200px"
          remote
          filterable
          placeholder="请选择单位名称"
          clearable
          @change="searchSelect"
        >
          <el-option
            v-for="dict in CompanyList"
            :key="dict.drugManufacturerId"
            :label="dict.cnName"
            :value="dict"
          />
        </el-select>
      </el-form-item>
      <el-form-item
        label="状态"
        prop="zt"
      >
        <el-select
          :remote-method="getRemoteData"
          v-model="queryParams.zt"
          style="width: 150px"
          remote
          filterable
          placeholder="请选择状态"
          clearable
          @change="searchSelect"
        >
          <el-option
            v-for="item in ztList"
            :key="item.id"
            :label="item.name"
            :value="item.id"
          />
        </el-select>
      </el-form-item>
      <el-form-item label="登记时间" prop="createTimeList" style="margin-right: 107px;" >
        <el-date-picker
          v-model="createTimeList"
          type="datetimerange"
@@ -94,7 +142,20 @@
        >
      </el-form-item>
    </el-form>
    <!-- <div class="timeline-wrapper">
    <el-timeline :reverse="false" class="horizontal-timeline">
      <el-timeline-item
        v-for="(item, index) in timelineData"
        :key="index"
        :timestamp="item.timestamp"
        :position="index % 2 === 0 ? 'left' : 'right'">
        <el-card :body-style="{ padding: '20px' }">
          <h3>{{ item.title }}</h3>
          <p>{{ item.description }}</p>
        </el-card>
      </el-timeline-item>
    </el-timeline>
  </div> -->
    <el-row :gutter="10" class="mb8">
      <el-col :span="1.5">
        <el-button
@@ -268,6 +329,18 @@
          :show-overflow-tooltip="true"
          width="160px"
        />
        <el-table-column
          label="单位名称"
          align="center"
          prop="dictCompName"
          :show-overflow-tooltip="true"
        />
        <el-table-column
          label="状态"
          align="center"
          prop="zt"
          :show-overflow-tooltip="true"
        />
        <!-- <el-table-column label="流水号" align="center" prop="tjSerialNumber" /> -->
        <el-table-column
          label="所选套餐"
@@ -329,19 +402,14 @@
        </el-table-column>
        <!-- <el-table-column label="创建人" align="center" prop="createBy" /> -->
        <!-- <el-table-column label="更新人" align="center" prop="updateBy" /> -->
        <el-table-column
       <!--  <el-table-column
          label="单位工号"
          align="center"
          prop="firmWorkId"
          width="100px"
          :show-overflow-tooltip="true"
        />
        <el-table-column
          label="单位名称"
          align="center"
          prop="dictCompName"
          :show-overflow-tooltip="true"
        />
        /> -->
        <!-- <el-table-column label="部门名" align="center" prop="firmDeptName" /> -->
        <!-- <el-table-column label="客户照片" align="center" prop="photo" /> -->
@@ -1441,11 +1509,17 @@
import { getInfo } from "@/api/login";
import ViewPdf from "@/components/ViewPdf";
import {
  projectGetList,
  shijianzhou,
  getaddtTransition,
  getProParentIdDxList,
  getProSonDxList,
} from "@/api/system/tijian";
import {
  SubmitCompany,
  getCompany,
  queryCompany,
  addbatch,
} from "@/api/team/tuanti";
import { createLogger } from "vuex";
export default {
  components: {
@@ -1455,6 +1529,18 @@
  name: "Order",
  data() {
    return {
      ztList: [
        {name:'未检',id: 0},{name:'在检',id: 1},{name:'已完成',id: 2},{name:'已审核',id: 3},{name:'生成报告',id: 4},{name:'报告核收',id: 5},{name:'已出报告',id: 6},
      ],
      timelineData: [
        { timestamp: '2024-01-01', title: '未检', description: 'This is event 1 description' },
        { timestamp: '2024-01-05', title: '在检', description: 'This is event 2 description' },
        { timestamp: '2024-01-10', title: '已完成', description: 'This is event 3 description' },
        { timestamp: '2024-01-15', title: '已审核', description: 'This is event 4 description' },
        { timestamp: '2024-01-15', title: '生成报告', description: 'This is event 4 description' },
        { timestamp: '2024-01-15', title: '报告核收', description: 'This is event 4 description' },
        { timestamp: '2024-01-15', title: '已出报告', description: 'This is event 4 description' },
      ],
      DataList3: [],
      bldhid: "",
      budadaozhen: false,
@@ -1462,6 +1548,7 @@
      DataLists: [],
      infoList: [],
      bldhs: [],
      CompanyList: [],
      filterage: "",
      activeName1: "second",
      filterText: "",
@@ -1509,6 +1596,7 @@
      TreedataList: [],
      discount: 10,
      DataList: [],
      tjNUms: [],
      // 套餐提交按钮
      confirm: false,
      list1: true,
@@ -1519,6 +1607,7 @@
      TotalPrice7: 0,
      numberList: [],
      dialogVisible: false,
      CheckBox: {},
      // 遮罩层
      loading: true,
      // 选中数组
@@ -1555,6 +1644,8 @@
        bgbeginTime: null,
        bgendTime: null,
        xmmc: null,
        tjCompName:'',
        dw:null
      },
      startTime: "",
      startTime1: "",
@@ -1617,9 +1708,27 @@
    });
  },
  methods: {
    // 搜索
    getRemoteData(query) {
      if (query) {
        let compName = query;
        queryCompany(compName).then((response) => {
          this.CompanyList = response.data;
          this.CompanyList.forEach((item) => {
            this.queryParams = item;
          });
        });
      }
    },
    // 选框数据
    searchSelect(val) {
      this.CheckBox = val;
      this.queryParams.dw = this.CheckBox.cnName;
      console.log(this.CheckBox,9999);
    },
    onPayTypeChange() {
      if (this.payType === "6" && this.form.tjType !== 3) {
        this.cannotSelectPayType = true;
        this.$message.warning("该付款类型在此体检类型下不允许选择!");
        this.payType = this.dict.type.dict_pay_type[0]?.value || null;
@@ -1686,6 +1795,47 @@
    },
    /** 查询体检记录列表 */
    getList() {
      this.queryParams.compId = this.CheckBox.drugManufacturerId;
      if (this.startTime) {
        this.queryParams.djbeginTime = this.startTime[0];
        this.queryParams.djendTime = this.startTime[1];
      } else if (this.createTimeList) {
        this.queryParams.djbeginTime = this.createTimeList[0];
        this.queryParams.djendTime = this.createTimeList[1];
      } else if (this.createTimeList == null) {
        this.queryParams.djbeginTime = null;
        this.queryParams.djendTime = null;
      }
      if (this.startTime1) {
        this.queryParams.bgbeginTime = this.startTime1[0];
        this.queryParams.bgendTime = this.startTime1[1];
      }
      this.loading = true;
      getOrderList(this.queryParams).then((response) => {
        this.orderList = response.data.list;
        if (this.orderList) {
          this.orderList.forEach((item, index) => {
            item.newID =
              (this.queryParams.pageNum - 1) * this.queryParams.pageSize +
              index +
              1;
          });
        }
        this.total = response.data.total;
        this.loading = false;
      });
       // 获取单位信息集合
       getCompany(this.queryParams).then((response) => {
        this.CompanyList = response.data;
        console.log( this.CompanyList,555);
        this.loading = false;
      });
    },
    sub() {
      this.queryParams.compId = this.CheckBox.drugManufacturerId;
      if (this.startTime) {
        this.queryParams.djbeginTime = this.startTime[0];
        this.queryParams.djendTime = this.startTime[1];
@@ -1783,7 +1933,7 @@
      })
        .then(() => {
          revokeTjOrderByTjNum(this.tjnumbers).then((res) => {
            this.$modal.msgSuccess(res.msg);
            this.$modal.msgSuccess("撤销成功");
            this.getList();
          });
        })
@@ -1877,6 +2027,7 @@
        djendTime: null,
        bgbeginTime: null,
        bgendTime: null,
        dw: null
      };
      this.resetForm("form");
    },
@@ -1888,7 +2039,8 @@
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNum = 1;
      this.getList();
      // this.getList();
      this.sub();
    },
    renderContents(h, { node, data, store }) {
      return (
@@ -1943,10 +2095,23 @@
      this.startTime1 = [];
      this.createTimeList = [];
      this.resetForm("queryForm");
      this.queryParams = {
        pageNum: 1,
        pageSize: 10,
        djbeginTime: null,
        djendTime: null,
        tjNum: null,
        bgbeginTime: null,
        bgendTime: null,
        xmmc: null,
        tjCompName:'',
        dw:null
      }
      this.handleQuery();
    },
    // 多选框选中数据
    handleSelectionChange(selection) {
      this.tjNUms = selection.map(item => item.tjNumber);
      selection.forEach((item) => {
        this.orderIds = item.orderId;
        this.tjnumbers = item.tjNumber;
@@ -1958,11 +2123,15 @@
        this.cusSex = item.tjCustomerSex;
        this.form.tjType = parseInt(item.tjType);
      });
      this.ids = selection.map((item) => item.orderId);
      // this.tjNumbers = selection.map((item) => item.tjNumber);
      this.single = selection.length !== 1;
      this.multiple = !selection.length;
      shijianzhou({
        tjNUms: this.tjNUms
      }).then((res) => {
        console.log(res)
      })
    },
    /** 新增按钮操作 */
    // handleAdd() {
@@ -2588,6 +2757,7 @@
    handleProjectssChange(selection) {
      this.DataListss = [];
      this.selection = [];
      this.bldhs = selection.map((item) => item.bldh);
      selection.forEach((item) => {
        item.projectList.forEach((item1) => {
@@ -2740,4 +2910,45 @@
  display: flex;
  flex-direction: column;
}
.timeline-wrapper {
  overflow-x: auto;
  padding: 20px;
  width: 100%;
}
.horizontal-timeline {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: nowrap;
  padding: 20px 0;
  width: 100%;
}
.el-timeline-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 0 20px;
}
.el-timeline-item .el-card {
  width: 150px;
  border-radius: 10px;
}
.el-timeline-item .el-timeline-item-tail {
  display: none;
}
.el-timeline-item .el-timeline-item-dot {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 12px;
  height: 12px;
  background-color: #409EFF;
  border-radius: 50%;
}
</style>