123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945 |
- <template>
- <!-- 配送目录记录 -->
- <div style="display: flex">
- <el-card style="width: 18%; margin-right: 18px; border-radius: 6px">
- <el-tabs v-model="activeNametree" type="card" @tab-click="tabClick" stretch>
- <!-- <el-tab-pane label="按分类" name="grp"></el-tab-pane> -->
- <el-tab-pane label="按机构" name="org"></el-tab-pane>
- </el-tabs>
- <el-tree
- :data="data"
- :props="defaultProps"
- node-key="spdId"
- @node-click="handleNodeClick"
- default-expand-all="true"
- style="margin-top: 10px"
- ></el-tree>
- </el-card>
- <div class="right-common-box">
- <el-form :model="listQuery" ref="listQuery" :inline="true" label-width="90px">
- <!-- <el-form-item size="mini" label="医保编码" prop="hiCode" class="long">
- <el-input v-model="listQuery.hiCode" placeholder="请输入医保编码"></el-input>
- </el-form-item> -->
- <el-form-item size="mini" label="耗材信息" prop="prodName" class="long">
- <el-input v-model="listQuery.prodName" placeholder="请输入耗材名称/医保编码"></el-input>
- </el-form-item>
- <el-form-item size="mini" label="规格" prop="spec" class="long">
- <el-input v-model="listQuery.spec" placeholder="请输入规格"></el-input>
- </el-form-item>
- <el-form-item size="mini" label="型号" prop="mol" class="long">
- <el-input v-model="listQuery.mol" placeholder="请输入型号"></el-input>
- </el-form-item>
- <el-form-item size="mini" label="生产企业" prop="prodEntp" class="long">
- <el-input v-model="listQuery.prodEntp" placeholder="请输入生产企业"></el-input>
- </el-form-item>
-
- <el-form-item size="mini" label="是否集采" prop="isFas" class="long">
- <el-select v-model="listQuery.isFas" placeholder="请选择是否集采" clearable>
- <el-option
- v-for="item in isFasData"
- :key="item.value"
- :label="item.name"
- :value="item.value"
- ></el-option>
- </el-select>
- </el-form-item>
- <el-form-item size="mini" label="耗材类别" prop="mcsType" class="long">
- <el-select v-model="listQuery.mcsType" placeholder="请选择耗材类别" clearable>
- <el-option
- v-for="item in mcsTypeData"
- :key="item.value"
- :label="item.name"
- :value="item.value"
- ></el-option>
- </el-select>
- </el-form-item>
- <el-form-item size="mini" label="生产来源" prop="prodSouc" class="long">
- <el-select v-model="listQuery.prodSouc" placeholder="请选择生产来源" clearable>
- <el-option
- v-for="item in SoucData"
- :key="item.value"
- :label="item.name"
- :value="item.value"
- ></el-option>
- </el-select>
- </el-form-item>
- <el-form-item size="mini" label="材质" prop="matl" class="long">
- <el-input v-model="listQuery.matl" placeholder="请输入材质"></el-input>
- </el-form-item>
- <el-form-item size="mini" label="注册证号" prop="regcertno" class="long">
- <el-input v-model="listQuery.regcertno" placeholder="请输入注册证号"></el-input>
- </el-form-item>
- <el-form-item size="mini" label="目录来源" prop="isPub" class="long">
- <el-select v-model="listQuery.isPub" placeholder="请选择目录来源" clearable>
- <el-option
- v-for="item in isPubData"
- :key="item.value"
- :label="item.name"
- :value="item.value"
- ></el-option>
- </el-select>
- </el-form-item>
-
- <el-form-item size="mini" label="当前状态" prop="status" class="long">
- <el-select v-model="listQuery.status" placeholder="请选择当前状态" clearable>
- <el-option
- v-for="item in statusData"
- :key="item.value"
- :label="item.name"
- :value="item.value"
- ></el-option>
- </el-select>
- </el-form-item>
- </el-form>
- <div class="right-button">
- <el-button type="primary" @click="getHospConsum('search')">查询</el-button>
- <el-button @click="reset('consumableData')">重置</el-button>
- </div>
- <!-- <div class="right-button" v-if="btnShow">
- <el-button type="primary" icon="el-icon-plus" @click="handleUpdate('search')"
- >挂网目录新增
- </el-button>
- <el-button type="primary" icon="el-icon-plus" @click="handleFadd('search')"
- >非挂网目录新增
- </el-button>
- </div> -->
- <el-table
- v-loading="listLoading"
- element-loading-text="加载中"
- :data="list"
- fit
- height="500"
- stripe
- border
- >
- <template slot="empty">
- <img src="@/assets/nopage.png" alt />
- <p>暂无数据</p>
- </template>
- <el-table-column fixed type="index" label="序号" width="60" />
- <el-table-column label="耗材信息" min-width="340">
- <template slot-scope="scope">
- <mcs-info :info="scope.row"></mcs-info>
- </template>
- </el-table-column>
- <el-table-column label="医保编码" prop="hiCode" width="80" />
- <el-table-column label="规格" prop="spec" width="80" />
- <el-table-column label="型号" prop="mol" width="80" />
- <el-table-column label="材质" prop="matl" width="80" />
- <el-table-column label="是否集采" prop="isFas" width="80">
- <template #default="{ row }">
- <span v-if="row.isFas == '0'">否</span>
- <span v-if="row.isFas == '1'">是</span>
- </template>
- </el-table-column>
- <el-table-column label="采购单位" prop="purcUnt" width="80" />
- <el-table-column label="采购价" prop="purcPric" width="80" />
- <el-table-column label="驳回原因" prop="rejtRea" width="80" />
- <el-table-column label="目录来源" prop="isPub" width="80" fixed="right">
- <template #default="{ row }">
- <span v-if="row.isPub == '1'">挂网</span>
- <span v-if="row.isPub == '0'">非挂网</span>
- </template>
- </el-table-column>
- <el-table-column label="保存时间" prop="saveTime" width="140" />
- <el-table-column label="提交时间" prop="sbmtTime" width="140" />
- <el-table-column label="操作类型" prop="opeType" width="80" fixed="right">
- </el-table-column>
- <el-table-column label="当前状态" prop="status" width="80" fixed="right">
- <template #default="{ row }">
- <span v-if="row.status == 'A'">待提交</span>
- <span v-if="row.status == 'B'">待审核</span>
- <span v-if="row.status == 'C'">审核通过</span>
- <span v-if="row.status == 'R'">驳回
- </span>
- </template>
- </el-table-column>
- <el-table-column fixed="right" label="操作" width="160">
- <template slot-scope="scope">
- <div>
- <el-button type="text" @click="handleDui(scope.row)" v-if="scope.row.status=='C'">详情</el-button>
- <el-button type="text" @click="handleDui(scope.row)" v-else>编辑</el-button>
- </div>
- </template>
- </el-table-column>
- </el-table>
- <!--分页-->
- <yl-pagination
- v-show="total > 0"
- :total="total"
- :page.sync="listQuery.current"
- :limit.sync="listQuery.size"
- @pagination="getHospConsum"
- />
- </div>
- <el-dialog title="调价申请" :visible.sync="dialogPrice" width="55%">
- <el-form
- ref="dataForm"
- :rules="rules"
- :model="temp"
- label-position="right"
- label-width="80px"
- >
- <el-row>
- <el-col :span="8">
- <el-form-item label="药品编码" prop="drugListId">
- <el-input v-model.trim="temp.drugListId" readonly placeholder="请输入" />
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="药品名称" prop="drugName">
- <el-input v-model.trim="temp.drugName" readonly placeholder="请输入" />
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="剂型" prop="dosformName">
- <el-input v-model.trim="temp.dosformName" readonly placeholder="请输入" />
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="规格" prop="specName">
- <el-input v-model.trim="temp.specName" readonly placeholder="请输入" />
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="包装单位" prop="pacUnt">
- <el-input v-model.trim="temp.pacUnt" readonly placeholder="请输入" />
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="生产企业" prop="prodEntp">
- <el-input v-model.trim="temp.prodEntp" readonly placeholder="请输入" />
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="当前价格" prop="pricInit">
- <el-input v-model.trim="temp.pricInit" readonly placeholder="请输入" />
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="调整价格" prop="pricCurr">
- <el-input v-model.trim="temp.pricCurr" placeholder="请输入调整后价格" />
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-form-item label="申请原因" prop="appyRea">
- <el-input
- type="textarea"
- v-model.trim="temp.appyRea"
- placeholder="请输入调价原因"
- />
- </el-form-item>
- </el-row>
- <el-row>
- <el-form-item label="上传文件" prop="fileId" :rules="rules.uploadRequired">
- <yl-upload :fileId="temp.fileId" @getUpload="getUpload" urlName="acco">
- <template v-slot:dec>只能上传pdf文件</template>
- </yl-upload>
- </el-form-item>
- </el-row>
- </el-form>
- <div slot="footer" class="dialog-footer">
- <el-button @click="dialogPrice = false">取消</el-button>
- <el-button type="primary" @click="commitData()" :loading="ccLoad">确认</el-button>
- </div>
- </el-dialog>
- <el-dialog title="选择耗材" :visible.sync="dialogAdd" width="70%">
- <template>
- <el-form :model="listQueryadd" ref="listQueryadd" :inline="true" label-width="90px">
- <el-form-item size="mini" label="耗材名称" prop="prodName" class="long">
- <el-input
- v-model="listQueryadd.prodName"
- placeholder="请输入耗材名称"
- ></el-input>
- </el-form-item>
- <el-form-item size="mini" label="规格" prop="spec" class="long">
- <el-input v-model="listQueryadd.spec" placeholder="请输入耗材规格"></el-input>
- </el-form-item>
- <!-- <el-form-item label="耗材编码" prop="materialId" class="long">
- <el-input
- v-model="listQueryadd.materialId"
- placeholder="请输入耗材编码"
- ></el-input>
- </el-form-item> -->
- <el-form-item size="mini" label="医保编码" prop="hiCode" class="long">
- <el-input
- v-model="listQueryadd.hiCode"
- placeholder="请输入医保编码"
- ></el-input>
- </el-form-item>
- <el-form-item size="mini" label="是否集采" prop="isFas" class="long">
- <el-select
- v-model="listQueryadd.isFas"
- placeholder="请选择是否集采"
- clearable
- >
- <el-option
- v-for="item in isFasData"
- :key="item.value"
- :label="item.name"
- :value="item.value"
- ></el-option>
- </el-select>
- </el-form-item>
- <el-form-item size="mini" label="注册证号" prop="regcertno" class="long">
- <el-input
- v-model="listQueryadd.regcertno"
- placeholder="请输入注册证号"
- ></el-input>
- </el-form-item>
- <el-form-item size="mini" label="生产企业" prop="prodEntp" class="long">
- <el-input
- v-model="listQueryadd.prodEntp"
- placeholder="请输入生产企业"
- ></el-input>
- </el-form-item>
- <el-form-item size="mini" label="型号" prop="mol" class="long">
- <el-input
- v-model="listQueryadd.mol"
- placeholder="请输入型号"
- ></el-input>
- </el-form-item>
- <!-- <el-form-item label="对码状态" prop="stas">
- <el-select
- v-model="listQuery.stas"
- placeholder="请选择对码状态"
- clearable
- >
- <el-option
- v-for="item in crspFlgOption"
- :key="item.value"
- :label="item.name"
- :value="item.value"
- ></el-option>
- </el-select>
- </el-form-item> -->
- <el-form-item>
- <el-button type="primary" @click="getdialog('search')">查询</el-button>
- <el-button @click="resetdialog('consumableData')">重置</el-button>
- </el-form-item>
- </el-form>
- <el-table
- ref="multipleTable"
- v-loading="listdialogLoading"
- element-loading-text="加载中"
- fit
- stripe
- border
- :data="consumableData"
- border
- style="width: 100%"
- row-key="id"
- height="500"
- @selection-change="handleSelectionChange"
- highlight-current-row
- >
- <el-table-column
- type="selection"
- :selectable="selected"
- :reserve-selection="true"
- width="55"
- ></el-table-column>
- <el-table-column prop="hiCode" label="医保编码"> </el-table-column>
- <el-table-column prop="prodName" label="耗材名称" width="180">
- </el-table-column>
- <el-table-column prop="pubonlnPric" label="挂网价格">
- </el-table-column>
- <el-table-column prop="isFas" label="是否集采">
- <template #default="{ row }">
- <span v-if="row.isFas == '0'">否</span>
- <span v-if="row.isFas == '1'">是</span>
- </template>
- </el-table-column>
- <el-table-column prop="fasBtch" label="集采批次"> </el-table-column>
- <!-- <el-table-column prop="splb" label="商品类别">
- </el-table-column>
- <el-table-column prop="spfl" label="商品分类">
- </el-table-column> -->
- <el-table-column prop="spec" label="规格"> </el-table-column>
- <el-table-column prop="mol" label="型号"> </el-table-column>
- <el-table-column prop="matl" label="材质"> </el-table-column>
- <el-table-column prop="pacmatl" label="包装材质"> </el-table-column>
- <el-table-column prop="prodSouc" label="生产来源">
- <template #default="{ row }">
- <span v-if="row.prodSouc == '1'">国产</span>
- <span v-if="row.prodSouc == '2'">进口</span>
- </template>
- </el-table-column>
- <el-table-column prop="regcertno" label="注册证号"> </el-table-column>
- <el-table-column prop="prodEntp" label="生产企业" width="120">
- </el-table-column>
- <el-table-column prop="agnt" label="代理企业" width="150"> </el-table-column>
- </el-table>
- <div slot="footer" class="dialog-footer">
- <el-button type="primary" @click="handleConfirm" :loading="addLoading"
- >确认</el-button
- >
- </div>
- <!--分页-->
- <yl-pagination
- v-show="totalC > 0"
- :total="totalC"
- :page.sync="listQueryadd.current"
- :limit.sync="listQueryadd.size"
- @pagination="getdialog"
- />
- </template>
- </el-dialog>
- </div>
- </template>
- <script>
- import ylPagination from "@/components/yl-pagination";
- import mcsInfo from "@/views/components/mcs-info.vue"
- import {
- selectSplerMcsListIntf,
- selectMcsList,
- saveSplerMcs,
- PricChg,
- QueryHospList,
- QueryHospDrugList,
- QuerySplerDrugList,
- DrugMatch,
- CancMatch,
- selectSpdList,
- } from "@/api/consumCataManage-sup/index";
- import rulesR from "@/utils/rules";
- import ylUpload from "@/components/yl-upload";
- export default {
- components: {
- ylPagination,
- ylUpload,
- mcsInfo,
- },
- data() {
- return {
- activeName: "grp",
- rulesR,
- spdId: null,
- data: [],
- defaultProps: {
- children: "children",
- label: "spdName",
- },
- listQuery: {
- current: 1,
- size: 10,
- spec: "",
- // hiCode: "",
- isFas: "",
- mol: "",
- prodSouc: "",
- mcsType: "",
- matl: "",
- prodEntp: "",
- prodName: "",
- status: "",
- regcertno:"",
- isPub:"",
- },
- listLoading: false,
- list: [],
- total: 0,
- tableLoading: false,
- supLoading: false,
- tableData: [],
- // crspFlgOption: [
- // { value: "0", name: "未对码" },
- // { value: "1", name: "已对码" },
- // ],
- isFasData: [
- { value: "1", name: "是" },
- { value: "0", name: "否" },
- ],
- mcsTypeData: [
- { value: "0", name: "普通耗材" },
- { value: "1", name: "高值耗材" },
- { value: "2", name: "试剂" },
- ],
- SoucData: [
- { value: "1", name: "国产" },
- { value: "2", name: "进口" },
- ],
- statusData: [
- { value: "A", name: "待提交" },
- { value: "B", name: "待审核" },
- { value: "C", name: "审核通过" },
- { value: "R", name: "驳回" },
- ],
- isPubData: [
- { value: "1", name: "挂网" },
- { value: "0", name: "非挂网" },
- ],
- dialogPrice: false,
- dialogDui: false,
- ccLoad: false,
- temp: {
- drugListId: "",
- drugName: "",
- dosformName: "",
- specName: "",
- pacUnt: "",
- prodEntp: "",
- pricInit: "",
- pricCurr: "",
- appyRea: "",
- fileId: "",
- },
- rules: {
- pricCurr: [
- {
- required: true,
- message: "调整价格不能为空",
- trigger: "blur",
- },
- {
- pattern: /(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/,
- message: "请输入数字,最多两位小数",
- trigger: "blur",
- },
- ],
- appyRea: [
- {
- required: true,
- message: "申请原因不能为空",
- trigger: "blur",
- },
- ],
- num: [
- {
- required: true,
- message: "请输入转换比",
- trigger: "change",
- },
- ],
- uploadRequired: [{ required: true, message: "请上传文件", trigger: "change" }],
- },
- tableData: [
- {
- date: "2016-05-02",
- name: "王小虎",
- province: "上海",
- city: "普陀区",
- address: "上海市普陀区金沙江路 1518 弄",
- zip: 200333,
- },
- {
- date: "2016-05-04",
- name: "王小虎",
- province: "上海",
- city: "普陀区",
- address: "上海市普陀区金沙江路 1517 弄",
- zip: 200333,
- },
- {
- date: "2016-05-01",
- name: "王小虎",
- province: "上海",
- city: "普陀区",
- address: "上海市普陀区金沙江路 1519 弄",
- zip: 200333,
- },
- {
- date: "2016-05-03",
- name: "王小虎",
- province: "上海",
- city: "普陀区",
- address: "上海市普陀区金沙江路 1516 弄",
- zip: 200333,
- },
- ],
- consumableData: [],
- form: {
- splerData: [],
- },
- // 省平台目录
- listdialogLoading: false,
- dialogAdd: false,
- listQueryadd: {
- materialId: "",
- spec: "",
- hiCode: "",
- isFas: "",
- fasBtch: "",
- mol: "",
- current: 1,
- size: 10,
- },
- totalC: false,
- addLoading: false,
- insertMcsList: [],
- // tree
- activeNametree: "org",
- btnShow: false,
- routespdId:"",
- };
- },
- methods: {
- tabClick(tab) {
- if (tab.label == "按机构") {
- this.defaultProps.label = "spdName";
- }
- // else if(tab.label == "按分类"){
- // // this.getData4();
- // // this.defaultProps.label = 'orgGrpName'
- // // this.listQuery.type = 'grp';
- // }
- },
- // 上传文件
- getUpload(id) {
- this.temp.fileId = id;
- if (id) {
- this.$refs.dataForm.clearValidate("fileId");
- } else {
- this.$refs.dataForm.validateField("fileId");
- }
- },
- validateField(form, index) {
- let result = true;
- for (let item of this.$refs[form].fields) {
- if (item.prop.split(".")[1] == index) {
- this.$refs[form].validateField(item.prop, (error) => {
- if (error != "") {
- result = false;
- }
- });
- }
- if (!result) break;
- }
- return result;
- },
- // 搜索获取医院药品列表
- getHospConsum(type) {
- if (type == "search") {
- this.listQuery.current = 1;
- }
- this.listLoading = true;
- // this.spdId = this.$route.query.spdId;
- this.listQuery.spdId = this.spdId;
- selectSplerMcsListIntf(this.listQuery)
- .then((res) => {
- this.list = res.data.records;
- this.total = res.data.total;
- this.listLoading = false;
- })
- .catch((err) => {
- this.listLoading = false;
- });
- },
- // 获取新增目录弹框数据
- getdialog(type) {
- if (type == "search") {
- this.listQueryadd.current = 1;
- }
- this.listdialogLoading = true;
- // this.listQuery.spdId = this.spdId;
- selectMcsList(this.listQueryadd)
- .then((res) => {
- this.consumableData = res.data.records;
- this.totalC = res.data.total;
- this.listdialogLoading = false;
- })
- .catch((err) => {
- this.listdialogLoading = false;
- });
- },
- // 点击获取医院药品列表
- handleNodeClick(data) {
- console.log(data, "data");
- this.listLoading = true;
- this.spdId = data.spdId;
- this.listQuery.spdId = this.spdId;
- selectSplerMcsListIntf(this.listQuery)
- .then((res) => {
- this.list = res.data.records;
- this.total = res.data.total;
- this.listLoading = false;
- console.log(res, "医院目录");
- this.btnShow = true;
- })
- .catch((err) => {
- this.listLoading = false;
- });
- },
- // 获取医院列表
- getData(type) {
- this.data = [];
- this.listLoading = true;
- selectSpdList()
- .then((res) => {
- this.listQuery.spdId = res.data[0].spdId;
- this.data = res.data;
- console.log(this.data, "dadad");
- this.listLoading = false;
- })
- .catch((err) => {
- this.listLoading = false;
- });
- },
- reset(type) {
- if (type === "consumableData") {
- this.$refs.listQuery.resetFields();
- this.getHospConsum();
- } else {
- this.$refs.supQuery.resetFields();
- this.searchSup();
- }
- },
- resetdialog(type) {
- if (type === "consumableData") {
- this.$refs.listQueryadd.resetFields();
- this.getdialog();
- } else {
- this.$refs.supQuery.resetFields();
- this.searchSup();
- }
- },
- // 多选
- handleSelectionChange(e) {
- console.log(this.spdId,"sodpdp")
- this.insertMcsList = e;
- newArr = this.insertMcsList.push({spdId:this.spdId});
- // console.log(e, "ee");
- },
- // 多选后选过的禁用
- selected(row, index) {
- if (
- this.list.some((el) => {
- return el.hiCode === row.hiCode;
- })
- ) {
- return false;
- } else {
- return true;
- }
- },
- // 新增目录
- handleUpdate(type) {
- if (type == "search") {
- this.listQueryadd.current = 1;
- }
- this.dialogAdd = true;
- this.getdialog();
- },
- // 新增目录确认
- handleConfirm() {
- if (this.insertMcsList.length == 0) {
- this.$message({
- message: "请选择要添加的数据",
- type: "warning",
- });
- } else {
- this.$confirm("确认提交", "提示", {
- confirmButtonText: "确定",
- cancelButtonText: "取消",
- type: "warning",
- }).then(() => {
- this.addLoading = true;
- saveSplerMcs({ insertMcsList: this.insertMcsList })
- .then((res) => {
- if (res.success === true) {
- this.addLoading = false;
- this.getHospConsum();
- this.insertMcsList = [];
- this.dialogAdd = false;
- this.$refs.multipleTable.clearSelection();
- } else {
- this.addLoading = false;
- this.$refs.multipleTable.clearSelection();
- // this.$message({
- // message: res.message || "操作失败",
- // type: "error",
- // });
- }
- })
- .catch(() => {
- this.addLoading = false;
- this.dialogAdd = false;
- this.$refs.multipleTable.clearSelection();
- });
- });
- }
- // saveSplerMcs
- // this.addLoading = false;
- // this.dialogAdd = false;
- },
- // 非挂网目录新增
- handleFadd() {
- this.$router.push({
- name: "catalogdetailsadd",
- query: { spdId: this.spdId },
- });
- },
- // 申请调价
- handlePrice(row) {
- this.dialogPrice = true;
- this.temp.drugListId = row.drugListId;
- this.temp.drugName = row.drugName;
- this.temp.dosformName = row.dosformName;
- this.temp.specName = row.specName;
- this.temp.pacUnt = row.pacUnt;
- this.temp.prodEntp = row.prodEntp;
- this.temp.pricInit = row.pricCurr ? row.pricCurr : 0;
- this.$nextTick(() => {
- this.$refs.dataForm.resetFields();
- });
- },
- // 调价申请 确认
- commitData() {
- this.$refs["dataForm"].validate((valid) => {
- if (valid) {
- this.ccLoad = true;
- let data = {
- drugListId: this.temp.drugListId,
- pricInit: this.temp.pricInit,
- pricCurr: this.temp.pricCurr,
- appyRea: this.temp.appyRea,
- spdId: this.spdId,
- fileId: this.temp.fileId,
- };
- PricChg(data)
- .then((res) => {
- if (res.success === true) {
- this.$message("调价已申请");
- this.ccLoad = false;
- this.dialogPrice = false;
- this.getHospConsum();
- }
- })
- .catch((err) => {
- this.ccLoad = false;
- });
- }
- });
- },
- // 对码弹窗获取供应商列表
- handleDui(row) {
- if (this.spdId) {
- this.routespdId = this.spdId;
- } else {
- this.routespdId = this.$route.query.spdId;
- }
- console.log(this.routespdId, "编辑");
- this.$router.push({
- name: "catalogdetails",
- query: { id: row.id, status: row.status,
- spdId: this.routespdId, isPub: row.isPub,
- opeType:row.opeType,type:"edit",
- current:this.listQuery.current,page:"2" },
- });
- },
- // 对码操作
- handleClick(item, index) {
- let DrugMatchObj = {
- spdId: this.spdId,
- drugListId: this.consumableData[0].drugListId,
- splerDrugListId: item.splerDrugListId,
- convrat: item.convrat,
- };
- if (!this.validateField("form", index)) {
- return;
- } else {
- DrugMatch(DrugMatchObj).then((res) => {
- if (res.success === true) {
- this.dialogDui = false;
- this.getHospConsum();
- this.$message({
- message: "对码成功",
- type: "success",
- });
- } else {
- this.$message.error("对码失败");
- }
- });
- }
- },
- // 取消对码
- handleCanc(row) {
- this.$confirm("此操作会取消该药品对码, 是否继续?", "提示", {
- confirmButtonText: "确定",
- cancelButtonText: "取消",
- type: "warning",
- })
- .then(() => {
- CancMatch({ spdId: this.spdId, drugListId: row.drugListId }).then((res) => {
- if (res.success) {
- this.getHospConsum();
- this.$message({
- type: "success",
- message: "取消对码成功",
- });
- }
- });
- })
- .catch(() => {});
- },
- //搜索供应商列表
- searchSup() {
- this.supLoading = true;
- this.supQuery.spdId = this.spdId;
- QuerySplerDrugList(this.supQuery)
- .then((res) => {
- this.form.splerData = res.data.records;
- this.total = res.data.total;
- this.supLoading = false;
- })
- .catch((err) => {
- this.supLoading = false;
- });
- },
- },
- mounted() {
- this.getData();
- // this.getHospConsum();
- if (this.$route.query.spdId) {
- this.listQuery.spdId = this.$route.query.spdId;
- selectSplerMcsListIntf(this.listQuery)
- .then((res) => {
- this.list = res.data.records;
- this.total = res.data.total;
- this.listLoading = false;
- console.log(res, "医院目录");
- this.btnShow = true;
- })
- .catch((err) => {
- this.listLoading = false;
- });
- }
- },
- };
- </script>
- <style lang="scss" scoped>
- ::v-deep .el-card__body {
- padding: 12px;
- }
- ::v-deep .el-tree-node__content {
- height: 35px;
- }
- ::v-deep .el-input__suffix {
- display: flex;
- align-items: center;
- cursor: pointer;
- font-size: 15px;
- }
- ::v-deep .long .el-form-item__content {
- width: 220px;
- }
- ::v-deep .long .el-input__inner {
- width: 199px;
- }
- </style>
|