12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223 |
- <template>
- <div class="main-contain">
- <div class="position">
- <bread-crumb :crumbs='crumbs'></bread-crumb>
- </div>
- <div class="app-container ">
-
- <div class="dataTitle">透析模板</div>
-
- <div
- class="app-container"
- style="margin-left: -20px;margin-top: -20px"
- v-loading="pageLoading"
- element-loading-text="拼命加载中"
- >
- <el-row :gutter="20">
- <el-col :span="7">
- <el-table
- :header-cell-style="{
- backgroundColor: 'rgb(245, 247, 250)',
- color: '#606266'
- }"
- height="450"
- :row-style="{ color: '#303133' }"
- :data="treatment_mode"
- border
- style="width: 100%"
- highlight-current-row
- :row-class-name="tableRows"
- @row-click="onRowClicks"
- ref="singleTable"
- >
- <el-table-column label="透析模式" align="center">
- <template slot-scope="scope">
- {{ scope.row.name }}
- </template>
- </el-table-column>
-
- <el-table-column label="状态" width="80" align="center">
- <template slot-scope="scope">
- {{ getModeStatus(scope.row.id) }}
- </template>
- </el-table-column>
- </el-table>
- </el-col>
- <el-col :span="17" v-loading="itemLoading">
- <div class="filter-container">
- <el-row :gutter="20">
- <el-col :span="16">
- <div>{{ mode_name }}</div>
- </el-col>
- <el-col :span="8">
- <el-button
- style="float: right;visibility: hidden"
- size="small"
- class="filter-item"
- type="primary"
- icon="el-icon-edit-outline"
- @click="openEdit()"
- >修改
- </el-button>
- </el-col>
- </el-row>
- </div>
- <div class="filter-container" style="float:right">
- <el-form
- ref="addPlan"
- :model="addPlan"
- label-width="160px"
- style="border: black"
- >
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="透析时长(h):" prop="dialysis_duration">
- <el-time-picker
- v-model="dialysisTimeShow"
- :picker-options="{
- selectableRange: '00:01:00 - 23:59:00'
- }"
- placeholder="透析时长"
- style="width:100%;"
- value-format="H:m"
- format="H:m"
- @change="selectnDialysisTime"
- >
- </el-time-picker>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item
- label="血流量(ml/min):"
- prop="blood_flow_volume"
- >
- <el-input v-model="addPlan.blood_flow_volume"></el-input>
- </el-form-item>
- </el-col>
- <!--<el-col :span="8" v-if="this.$store.getters.xt_user.template_info.template_id == 6">-->
- <!--<el-form-item label="目标超滤量(ml) : ">-->
- <!--<el-input v-model="addPlan.target_ultrafiltration" type="number" ></el-input>-->
- <!--</el-form-item>-->
- <!--</el-col>-->
-
- <!--<el-col :span="8" v-if="this.$store.getters.xt_user.template_info.template_id != 6">-->
- <!--<el-form-item label="目标超滤量(L) : ">-->
- <!--<el-input v-model="addPlan.target_ultrafiltration" type="number" ></el-input>-->
- <!--</el-form-item>-->
- <!--</el-col>-->
-
- <el-col :span="8">
- <el-form-item label="透析液配方:">
- <el-select v-model="addPlan.dialysate_formulation">
- <el-option
- v-for="(item, index) in dialysate_formulation"
- :label="item.name"
- :key="index"
- :value="item.id"
- ></el-option>
- </el-select>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="抗凝剂:" prop="anticoagulant">
- <el-select
- v-model="addPlan.anticoagulant"
- @change="changeThisAnticoagulant"
- >
- <el-option
- v-for="(item, index) in anticoagulantsConfit"
- :label="item.name"
- :key="index"
- :value="item.id"
- ></el-option>
- </el-select>
- </el-form-item>
- </el-col>
- <el-col :span="8" v-if="anticoagulant.shouji != -1">
- <el-form-item
- :label="'首剂(' + anticoagulant.shouji_unit + '): '"
- prop="anticoagulant_shouji"
- >
- <el-input
- v-model="addPlan.anticoagulant_shouji"
- :disabled="anticoagulant.shouji == 1 ? false : true"
- type="number"
- ></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8" v-if="anticoagulant.weichi != -1">
- <el-form-item
- :label="'维持(' + anticoagulant.weichi_unit + '): '"
- prop="anticoagulant_weichi"
- >
- <el-input
- v-model="addPlan.anticoagulant_weichi"
- :disabled="anticoagulant.weichi == 1 ? false : true"
- type="number"
- ></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8" v-if="anticoagulant.zongliang != -1">
- <el-form-item
- :label="'总量(' + anticoagulant.zongliang_unit + '): '"
- prop="anticoagulant_zongliang"
- >
- <el-input
- v-model="addPlan.anticoagulant_zongliang"
- :disabled="anticoagulant.zongliang == 1 ? false : true"
- type="number"
- ></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8" v-if="anticoagulant.gaimingcheng != -1">
- <el-form-item
- label="钙名称:"
- prop="anticoagulant_gaimingcheng"
- >
- <el-input
- v-model="addPlan.anticoagulant_gaimingcheng"
- :disabled="anticoagulant.gaimingcheng == 1 ? false : true"
- placeholder="钙名称"
- ></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8" v-if="anticoagulant.gaijiliang != -1">
- <el-form-item
- :label="
- '钙剂量(' + anticoagulant.gaimingcheng_unit + '): '
- "
- prop="anticoagulant_gaijiliang"
- >
- <el-input
- v-model="addPlan.anticoagulant_gaijiliang"
- :disabled="anticoagulant.gaijiliang == 1 ? false : true"
- placeholder="钙剂量"
- ></el-input>
- </el-form-item>
- </el-col>
- <el-col
- :span="8"
- v-if="
- current_select == 2 ||
- current_select == 5 ||
- current_select == 12
- "
- >
- <el-form-item label="置换量(L) : " prop="replacement_total">
- <el-input
- v-model="addPlan.replacement_total"
- type="number"
- ></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="钾(mmol/L): " prop="kalium">
- <el-input v-model="addPlan.kalium"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="钠(mmol/L): " prop="sodium">
- <el-input v-model="addPlan.sodium"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="钙(mmol/L): " prop="calcium">
- <el-input v-model="addPlan.calcium"></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="透析器/灌流器:">
- <el-input
- v-model="addPlan.dialyzer_perfusion_apparatus" @focus="showInnerDialog('5')"></el-input>
- </el-form-item>
- </el-col>
-
-
- <el-col :span="8" v-if="this.$store.getters.xt_user.template_info.org_id == 9987 || this.$store.getters.xt_user.template_info.org_id == 3877">
- <el-form-item label="透析器:">
- <el-input
- v-model="dialysis_dialyszers" @focus="showInnerDialog('6')"></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8" v-if="this.$store.getters.xt_user.template_info.org_id == 9987 || this.$store.getters.xt_user.template_info.org_id == 3877">
- <el-form-item label="灌流器:">
- <el-input
- v-model="dialysis_irrigation" @focus="showInnerDialog('7')"></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="碳酸氢盐(mmol/L): " prop="bicarbonate">
- <el-input v-model="addPlan.bicarbonate"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="葡萄糖(mmol/L): " prop="glucose">
- <el-input v-model="addPlan.glucose"></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item
- label="透析液流量(ml/min): "
- prop="dialysate_flow"
- >
- <el-input v-model="addPlan.dialysate_flow"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item
- label="透析液温度(℃): "
- prop="dialysate_temperature"
- >
- <el-input
- v-model="addPlan.dialysate_temperature"
- ></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="电导度(mS/cm): " prop="conductivity">
- <el-input v-model="addPlan.conductivity"></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="体液过多症状:">
- <el-select v-model="addPlan.body_fluid">
- <el-option
- v-for="(item, index) in body_fluid_option"
- :label="item.name"
- :key="index"
- :value="item.id"
- ></el-option>
- </el-select>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="体液过多其他症状">
- <el-input v-model="addPlan.body_fluid_other"></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="透析前使用特殊药物">
- <el-select
- v-model="addPlan.special_medicine"
- placeholder="请选择"
- style="width:100%;"
- >
- <el-option :key="0" label="请选择" :value="0"></el-option>
- <el-option
- v-for="(item, index) in special_medicine_option"
- :label="item.name"
- :key="index"
- :value="item.id"
- ></el-option>
- </el-select>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="使用其他特殊药物">
- <el-input
- v-model="addPlan.special_medicine_other"
- ></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item
- label="置换液:"
- v-if="
- (current_select == 2 ||
- current_select == 5 ||
- current_select == 12) &&
- this.$store.getters.xt_user.template_info.template_id !=
- 6
- "
- >
- <el-select
- v-model="addPlan.displace_liqui_part"
- placeholder="请选择"
- >
- <el-option :key="0" label="请选择" :value="0"></el-option>
- <el-option
- v-for="(option, index) in displace_liqui_part_option"
- :key="index"
- :label="option.name"
- :value="option.id"
- ></el-option>
- </el-select>
- </el-form-item>
-
- <el-form-item
- label="置换方式:"
- v-if="
- current_select == 2 &&
- this.$store.getters.xt_user.template_info.template_id ==
- 6
- "
- >
- <el-select
- v-model="addPlan.displace_liqui_part"
- placeholder="请选择"
- >
- <el-option :key="0" label="请选择" :value="0"></el-option>
- <el-option
- v-for="(option, index) in displace_liqui_part_option"
- :key="index"
- :label="option.name"
- :value="option.id"
- ></el-option>
- </el-select>
- </el-form-item>
- </el-col>
-
- <el-col
- :span="8"
- v-if="
- current_select == 2 ||
- current_select == 5 ||
- current_select == 12
- "
- >
- <el-form-item label="置换液总量(L)">
- <el-input v-model="addPlan.displace_liqui_value"></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="血管通路:">
- <el-select
- v-model="addPlan.blood_access"
- placeholder="请选择"
- >
- <el-option :key="0" label="请选择" :value="0"></el-option>
-
- <el-option
- v-for="(option, index) in blood_access_option"
- :key="index"
- :label="option.name"
- :value="option.id"
- ></el-option>
- </el-select>
- </el-form-item>
- </el-col>
-
- <!-- </el-row>
- <el-row :gutter="20" > -->
- <el-col :span="8">
- <el-form-item label="实际超滤量(L)">
- <el-input v-model="addPlan.ultrafiltration"></el-input>
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="目标KT/V">
- <el-input v-model="addPlan.target_ktv"></el-input>
- </el-form-item>
- </el-col>
- </el-row>
- </el-form>
- <el-button
- style="float: right"
- size="small"
- class="filter-item"
- type="primary"
- icon="el-icon-edit-outline"
- @click="savePrescription()"
- >保存
- </el-button>
- </div>
- </el-col>
- </el-row>
- </div>
- <multi-select-box
- :propsForm="InnerDialogProps"
- v-on:dialog-comfirm="innerDialogComfirm"
- v-on:dialog-cancle="innerDialogCancle"
- >
- </multi-select-box>
- </div>
- </div>
- </template>
-
- <script>
- import BreadCrumb from '@/xt_pages/components/bread-crumb'
- import { calculateAnticoagulantZL, uParseTime } from "@/utils/tools";
- import {
- getAllSystemPrescription,
- getSystemPrescription,
- postSystemPrescription,
- updateSystemPrescription
- } from "@/api/config";
- import { getDataConfig } from '@/utils/data'
- import MultiSelectBox from '../dialysis/details/dialog/MultiSelectBox/index'
-
-
- export default {
- name: "prescription",
- components: { MultiSelectBox,BreadCrumb },
-
- data() {
- return {
- crumbs: [
- { path: false, name: '配置管理' },
- { path: false, name: '处方模板' }
- ],
- InnerDialogProps: {
- values: [],
- visibility: false,
- isShowTextArea: true,
- customContent: '',
- titles: '',
- type: '' // 不同弹框类型,用来匹配数据
- },
- dialysisTimeShow: new Date(2018, 1, 1, 3, 0),
- modeOptions: null,
- current_select: 0,
- mode_name: "HD",
- pageLoading: false,
- itemLoading: false,
- dialyzerPerfusionApparatus:[],
- treatment_mode: [
- // 治疗模式
- {
- id: 1,
- name: "HD",
- dialysis_duration: 1,
- replacement_way: 2,
- hemodialysis_machine: 1,
- blood_filter: 2,
- perfusion_apparatus: 2,
- blood_flow_volume: 1,
- dialysate_flow: 1,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- },
- {
- id: 2,
- name: "HDF",
- dialysis_duration: 1,
- replacement_way: 1,
- hemodialysis_machine: 2,
- blood_filter: 1,
- perfusion_apparatus: 2,
- blood_flow_volume: 1,
- dialysate_flow: 1,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- },
- {
- id: 3,
- name: "HD+HP",
- dialysis_duration: 1,
- replacement_way: 2,
- hemodialysis_machine: 1,
- blood_filter: 2,
- perfusion_apparatus: 1,
- blood_flow_volume: 1,
- dialysate_flow: 1,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- },
- {
- id: 4,
- name: "HP",
- dialysis_duration: 1,
- replacement_way: 2,
- hemodialysis_machine: 2,
- blood_filter: 2,
- perfusion_apparatus: 1,
- blood_flow_volume: 1,
- dialysate_flow: 2,
- kalium: 2,
- sodium: 2,
- calcium: 2,
- bicarbonate: 2
- },
- {
- id: 5,
- name: "HF",
- dialysis_duration: 1,
- replacement_way: 1,
- hemodialysis_machine: 2,
- blood_filter: 1,
- perfusion_apparatus: 2,
- blood_flow_volume: 1,
- dialysate_flow: 2,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- },
- {
- id: 6,
- name: "SCUF",
- dialysis_duration: 1,
- replacement_way: 2,
- hemodialysis_machine: 1,
- blood_filter: 2,
- perfusion_apparatus: 2,
- blood_flow_volume: 1,
- dialysate_flow: 2,
- kalium: 2,
- sodium: 2,
- calcium: 2,
- bicarbonate: 2
- },
- {
- id: 7,
- name: "IUF",
- dialysis_duration: 1,
- replacement_way: 2,
- hemodialysis_machine: 1,
- blood_filter: 2,
- perfusion_apparatus: 2,
- blood_flow_volume: 2,
- dialysate_flow: 2,
- kalium: 2,
- sodium: 2,
- calcium: 2,
- bicarbonate: 2
- },
- {
- id: 8,
- name: "HFHD",
- dialysis_duration: 1,
- replacement_way: 2,
- hemodialysis_machine: 1,
- blood_filter: 2,
- perfusion_apparatus: 2,
- blood_flow_volume: 1,
- dialysate_flow: 1,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- },
- {
- id: 9,
- name: "HFHD+HP",
- dialysis_duration: 1,
- replacement_way: 2,
- hemodialysis_machine: 1,
- blood_filter: 2,
- perfusion_apparatus: 1,
- blood_flow_volume: 1,
- dialysate_flow: 1,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- },
- {
- id: 10,
- name: "PHF",
- dialysis_duration: 1,
- replacement_way: 1,
- hemodialysis_machine: 2,
- blood_filter: 1,
- perfusion_apparatus: 2,
- blood_flow_volume: 1,
- dialysate_flow: 1,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- },
- {
- id: 11,
- name: "HFR",
- dialysis_duration: 1,
- replacement_way: 2,
- hemodialysis_machine: 2,
- blood_filter: 1,
- perfusion_apparatus: 1,
- blood_flow_volume: 1,
- dialysate_flow: 1,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- },
- {
- id: 12,
- name: "HDF+HP",
- dialysis_duration: 1,
- replacement_way: 1,
- hemodialysis_machine: 2,
- blood_filter: 1,
- perfusion_apparatus: 1,
- blood_flow_volume: 1,
- dialysate_flow: 1,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- },
- {
- id: 13,
- name: "CRRT",
- dialysis_duration: 1,
- replacement_way: 1,
- hemodialysis_machine: 2,
- blood_filter: 1,
- perfusion_apparatus: 2,
- blood_flow_volume: 1,
- dialysate_flow: 2,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- },
- {
- id: 14,
- name: "腹水回输",
- dialysis_duration: 1,
- replacement_way: 2,
- hemodialysis_machine: 1,
- blood_filter: 2,
- perfusion_apparatus: 2,
- blood_flow_volume: 2,
- dialysate_flow: 2,
- kalium: 2,
- sodium: 2,
- calcium: 2,
- bicarbonate: 2
- },
- // {
- // id: 15,
- // name: "HD前置换",
- // dialysis_duration: 1,
- // replacement_way: 2,
- // hemodialysis_machine: 1,
- // blood_filter: 2,
- // perfusion_apparatus: 2,
- // blood_flow_volume: 1,
- // dialysate_flow: 1,
- // kalium: 1,
- // sodium: 1,
- // calcium: 1,
- // bicarbonate: 1
- // },
- // {
- // id: 16,
- // name: "HD后置换",
- // dialysis_duration: 1,
- // replacement_way: 2,
- // hemodialysis_machine: 1,
- // blood_filter: 2,
- // perfusion_apparatus: 2,
- // blood_flow_volume: 1,
- // dialysate_flow: 1,
- // kalium: 1,
- // sodium: 1,
- // calcium: 1,
- // bicarbonate: 1
- // },
- // {
- // id: 17,
- // name: "HDF前置换",
- // dialysis_duration: 1,
- // replacement_way: 1,
- // hemodialysis_machine: 2,
- // blood_filter: 1,
- // perfusion_apparatus: 2,
- // blood_flow_volume: 1,
- // dialysate_flow: 1,
- // kalium: 1,
- // sodium: 1,
- // calcium: 1,
- // bicarbonate: 1
- // },
- // {
- // id: 18,
- // name: "HDF后置换",
- // dialysis_duration: 1,
- // replacement_way: 1,
- // hemodialysis_machine: 2,
- // blood_filter: 1,
- // perfusion_apparatus: 2,
- // blood_flow_volume: 1,
- // dialysate_flow: 1,
- // kalium: 1,
- // sodium: 1,
- // calcium: 1,
- // bicarbonate: 1
- // },
- {
- id: 19,
- name: "IUF+HD",
- dialysis_duration: 1,
- replacement_way: 2,
- hemodialysis_machine: 1,
- blood_filter: 2,
- perfusion_apparatus: 2,
- blood_flow_volume: 1,
- dialysate_flow: 1,
- kalium: 1,
- sodium: 1,
- calcium: 1,
- bicarbonate: 1
- }
- ],
- addPlan: {
- id: 0,
- mode: "",
- dialyzer: "",
- dialysis_duration: "",
- dialysis_duration_hour: "",
- dialysis_duration_minute: "",
- hemodialysis_machine: "",
- perfusion_apparatus: "",
- dialysate_formulation: "",
- blood_flow_volume: "",
- dewater: "",
- displace_liqui: 0,
- replacement_way: "",
- anticoagulant: "",
- anticoagulant_shouji: "",
- anticoagulant_weichi: "",
- anticoagulant_zongliang: "",
- anticoagulant_gaimingcheng: "",
- anticoagulant_gaijiliang: "",
- kalium: "",
- replacement_total: "",
- sodium: "",
- calcium: "",
- bicarbonate: "",
- glucose: "",
- dry_weight: "",
- dialysate_flow: "",
- dialysate_temperature: "",
- conductivity: "",
- doctor: "",
- remark: "",
- target_ktv: "",
- target_ultrafiltration: "",
- dialyzer_perfusion_apparatus: "",
- body_fluid: "",
- body_fluid_other: "",
- special_medicine: "",
- special_medicine_other: "",
- displace_liqui_part: "",
- displace_liqui_value: "",
- ultrafiltration: "",
- blood_access: "",
- dialysis_dialyszers:"",
- dialysis_irrigation:""
- },
- system_prescription: [],
- isEdit: false,
- anticoagulant: {
- id: 0,
- name: "",
- type: 1,
- shouji: 1,
- weichi: 1,
- zongliang: 1,
- gaimingcheng: -1,
- gaijiliang: -1,
- shouji_unit: "mg",
- weichi_unit: "mg/h",
- zongliang_unit: "mg",
- gaimingcheng_unit: "",
- gaijiliang_unit: ""
- },
- anticoagulantsSet: {
- type: 1
- },
- replacementWays: null,
- anticoagulantsConfit: null,
- dialysate_formulation: [],
- body_fluid_option: [],
- special_medicine_option: [],
- displace_liqui_part_option: [],
- blood_access_option: [],
- dialysis_dialyszers:"",
- dialysis_irrigation:"",
- };
- },
- computed: {},
- methods: {
- showInnerDialog: function(val) {
- this.InnerDialogProps.visibility = true
- switch (val) {
- case '5': // 透析器/灌流器
- this.InnerDialogProps.values = this.dialyzerPerfusionApparatus
- this.InnerDialogProps.titles = '透析器/灌流器'
- this.InnerDialogProps.type = 'dialyzer_perfusion_apparatus'
- this.InnerDialogProps.selected = this.addPlan.dialyzer_perfusion_apparatus
- this.InnerDialogProps.isShowTextArea = false
- break
- case '6':
- for(let i=0;i<this.dialyzers.length;i++){
- this.dialyzers[i].name = this.dialyzers[i].specification_name
- }
- this.InnerDialogProps.values = this.dialyzers
- this.InnerDialogProps.titles = '透析器'
- this.InnerDialogProps.type = 'dialyzers'
- this.InnerDialogProps.selected = this.dialysis_dialyszers
- this.InnerDialogProps.isShowTextArea = false
-
- break
- case '7':
- for(let i=0;i<this.irrigations.length;i++){
- this.irrigations[i].name = this.irrigations[i].specification_name
- }
- this.InnerDialogProps.values = this.irrigations
- this.InnerDialogProps.titles = '灌流器'
- this.InnerDialogProps.type = 'irrigations'
- this.InnerDialogProps.selected = this.dialysis_irrigation
- this.InnerDialogProps.isShowTextArea = false
-
- break
- }
- },
- innerDialogComfirm: function(val) {
- this.InnerDialogProps.visibility = false
- switch (val.type) {
- case 'dialyzer_perfusion_apparatus':
- this.addPlan.dialyzer_perfusion_apparatus = val.value.join(',')
- break
- case 'dialyzers':
- this.dialysis_dialyszers = val.value.join(',')
- break
- case 'irrigations':
- this.dialysis_irrigation = val.value.join(',')
- break
- }
- },
- innerDialogCancle: function() {
- this.InnerDialogProps.visibility = false
- },
- openEdit() {},
- tableRows({ row, rowIndex }) {
- // 把每一行的索引放进row
- row.index = rowIndex;
- },
- onRowClicks(row, event, column) {
- this.current_select = row.id;
- this.mode_name = row.name;
- this.isEdit = false;
- this.addPlan.mode = row.id;
- this.getSystemPrescription(row.id);
- },
- getSystemPrescription(id) {
- var tempAddPlan = {
- id: 0,
- mode: "",
- dialyzer: "",
- dialysis_duration: "",
- dialysis_duration_hour: "",
- dialysis_duration_minute: "",
- hemodialysis_machine: "",
- dialysate_formulation: "",
- perfusion_apparatus: "",
- blood_flow_volume: "",
- dewater: "",
- displace_liqui: 0,
- replacement_way: "",
- anticoagulant: "",
- anticoagulant_shouji: "",
- anticoagulant_weichi: "",
- anticoagulant_zongliang: "",
- anticoagulant_gaimingcheng: "",
- anticoagulant_gaijiliang: "",
- kalium: "",
- replacement_total: "",
- sodium: "",
- calcium: "",
- bicarbonate: "",
- glucose: "",
- dry_weight: "",
- dialysate_flow: "",
- dialysate_temperature: "",
- conductivity: "",
- doctor: "",
- remark: "",
- target_ktv: "",
- target_ultrafiltration: "",
- dialyzer_perfusion_apparatus: "",
- body_fluid: "",
- body_fluid_other: "",
- special_medicine: "",
- special_medicine_other: "",
- displace_liqui_part: "",
- displace_liqui_value: "",
- ultrafiltration: "",
- blood_access: "",
- stockType:[],
- irrigations:[],
- dialyzers:[],
- };
-
- for (const key in tempAddPlan) {
- this.addPlan[key] = tempAddPlan[key];
- }
- this.isEdit = false;
- let params = {
- id: id
- };
-
- this.dialysisTimeShow = new Date(
- 2018,
- 1,
- 1,
- this.addPlan.dialysis_duration_hour,
- this.addPlan.dialysis_duration_minute
- );
-
- getSystemPrescription(params).then(response => {
-
- if (response.data.state == 0) {
- this.$message.error(response.data.msg);
- return false;
- } else {
- var prescription = response.data.data.prescription
- console.log("prescription",prescription)
- prescription.dialysis_duration = parseFloat(prescription.dialysis_duration_hour) + parseFloat((prescription.dialysis_duration_minute / 60).toFixed(2))
- if(prescription.dialysate_formulation == 0){
- prescription.dialysate_formulation = ""
- }
- if(prescription.body_fluid ==0 ){
- prescription.body_fluid = ""
- }
- if(prescription.anticoagulant == 0){
- prescription.anticoagulant = ""
- }
- if(prescription.anticoagulant == 3){
- prescription.anticoagulant = "低分子肝素"
- }
- if (prescription.id > 0) {
-
- for (const key in prescription) {
- this.addPlan[key] = prescription[key];
- }
-
- this.dialysisTimeShow = new Date(
- 2018,
- 1,
- 1,
- this.addPlan.dialysis_duration_hour,
- this.addPlan.dialysis_duration_minute
- );
- if (this.addPlan.id > 0) {
- this.isEdit = true;
- }
- }
- this.addPlan.mode = id;
- this.addPlan.dialysis_dialyszers = prescription.dialysis_dialyszers
- this.addPlan.dialysis_irrigation = prescription.dialysis_irrigation
- this.dialysis_dialyszers = prescription.dialysis_dialyszers
- this.dialysis_irrigation = prescription.dialysis_irrigation
- }
- });
- },
- getModeStatus: function(id) {
- for (let i = 0; i < this.system_prescription.length; i++) {
- if (this.system_prescription[i].mode_id == id) {
- return "已保存";
- }
- }
- return "未保存";
- },
- getAllSystemPrescription() {
- getAllSystemPrescription().then(response => {
- if (response.data.state == 0) {
- this.$message.error(response.data.msg);
- return false;
- } else {
- this.system_prescription = response.data.data.prescriptions;
-
- for (let i = 0; i < this.system_prescription.length; i++) {
- if (this.system_prescription[i].mode == 1) {
- this.isEdit = true;
- }
- }
- this.stockType = response.data.data.stockType
- console.log("2333555555555",this.stockType)
- if(this.stockType.length >0 ){
- var arr = []
- var arrTwo = []
- for(let i=0;i<this.stockType.length;i++){
- if(this.stockType[i].stock_attribute == 2){
- arr.push(this.stockType[i])
- }
- if(this.stockType[i].stock_attribute == 3){
- arrTwo.push(this.stockType[i])
- }
- }
- var dialyzator = []
- var irrigation = []
- for(let i=0;i<arr.length;i++){
- for(let j=0;j<arr[i].GoodInfo.length;j++){
- dialyzator.push(arr[i].GoodInfo[j])
- }
- }
- console.log("透析器",dialyzator)
- this.dialyzers = dialyzator
-
- for(let i=0;i<arrTwo.length;i++){
- for(let j=0;j<arrTwo[i].GoodInfo.length;j++){
- irrigation.push(arrTwo[i].GoodInfo[j])
- }
- }
- console.log("灌流器",irrigation)
- this.irrigations = irrigation
- }
- }
- });
- },
- selectnDialysisTime(val) {
- var valTime = val.split(":");
- this.addPlan.dialysis_duration =
- parseFloat(valTime[0]) + parseFloat((valTime[1] / 60).toFixed(2));
- this.addPlan.dialysis_duration_hour = valTime[0];
- this.addPlan.dialysis_duration_minute = valTime[1];
- },
- changeThisAnticoagulant() {
- var thismode = parseInt(this.addPlan.anticoagulant);
-
- if (isNaN(thismode) || thismode <= 0) {
- return false;
- }
- if (
- typeof this.anticoagulantsConfit[thismode] == "undefined" ||
- this.anticoagulantsConfit[thismode] == null
- ) {
- return false;
- }
- this.anticoagulant = this.anticoagulantsConfit[thismode];
- },
- savePrescription: function() {
- this.addPlan.anticoagulant_zongliang = this.addPlan.anticoagulant_zongliang.toString();
- if (!this.isEdit) {
- this.addPlan.dialysis_dialyszers = this.dialysis_dialyszers
- this.addPlan.dialysis_irrigation = this.dialysis_irrigation
- postSystemPrescription(this.addPlan).then(response => {
- if (response.data.state == 0) {
- this.$message.error(response.data.msg);
- return false;
- } else {
- this.$notify({
- title: "成功",
- message: "创建成功",
- type: "success",
- duration: 2000
- });
- this.isEdit = true;
- this.system_prescription = [];
- this.system_prescription = response.data.data.prescriptions;
- this.addPlan.id = response.data.data.prescription.id;
- return false;
- }
- });
- } else {
- this.addPlan.dialysis_irrigation = this.dialysis_irrigation
- this.addPlan.dialysis_dialyszers = this.dialysis_dialyszers
- updateSystemPrescription(this.addPlan.id, this.addPlan).then(
- response => {
- if (response.data.state == 0) {
- this.$message.error(response.data.msg);
- return false;
- } else {
- this.isEdit = true;
- this.addPlan.id = response.data.data.prescription.id;
- this.$notify({
- title: "成功",
- message: "编辑成功",
- type: "success",
- duration: 2000
- });
- return false;
- }
- }
- );
- }
- }
- },
- mounted() {
- this.$refs.singleTable.setCurrentRow(this.treatment_mode[0]);
- this.mode_name = this.treatment_mode[0].name;
- this.current_select = this.treatment_mode[0].id;
- },
- created() {
- this.anticoagulantsSet = this.$store.getters.anticoagulants_set;
- this.replacementWays = this.$store.getters.replacement_ways;
- this.anticoagulantsConfit = this.$store.getters.anticoagulants_confit;
-
- this.blood_filters = this.$store.getters.blood_filters;
- this.dialysate_formulation = this.$store.getters.dialysate_formulation;
-
- this.body_fluid_option = this.$store.getters.body_fluid;
- this.special_medicine_option = this.$store.getters.special_medicine;
- this.displace_liqui_part_option = this.$store.getters.displace_liqui;
- this.blood_access_option = this.$store.getters.vascular_access_desc;
- console.log("列表33333333血管通路",this.blood_access_option)
- this.addPlan.mode = 1;
- this.dialyzerPerfusionApparatus = getDataConfig(
- 'hemodialysis',
- 'dialyzer_perfusion_apparatus'
- )
- this.getAllSystemPrescription();
- this.getSystemPrescription(this.addPlan.mode);
-
-
- },
- watch: {
- "addPlan.dialysis_duration": function() {
- // console.log(this.addPlan.anticoagulant_shouji);
- // console.log(this.addPlan.dialysis_duration);
- // console.log(this.addPlan.anticoagulant_weichi);
-
- this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(
- 1,
- this.addPlan.anticoagulant_shouji,
- this.addPlan.dialysis_duration,
- this.addPlan.anticoagulant_weichi
- );
- },
- "addPlan.anticoagulant_shouji": function() {
- // console.log("首剂", this.addPlan.anticoagulant_shouji);
- // console.log("维持", this.addPlan.anticoagulant_weichi);
- // console.log("总量", this.addPlan.dialysis_duration);
- this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(
- 1,
- this.addPlan.anticoagulant_shouji,
- this.addPlan.dialysis_duration,
- this.addPlan.anticoagulant_weichi
- );
- // console.log("总量----", this.addPlan.anticoagulant_zongliang);
- },
- "addPlan.anticoagulant_weichi": function() {
- // console.log(this.addPlan.anticoagulant_shouji);
- // console.log(this.addPlan.dialysis_duration);
- // console.log(this.addPlan.anticoagulant_weichi);
- this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(
- 1,
- this.addPlan.anticoagulant_shouji,
- this.addPlan.dialysis_duration,
- this.addPlan.anticoagulant_weichi
- );
- }
- }
- };
- </script>
-
- <style rel="stylesheet/scss" lang="scss" scoped></style>
|