1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498 |
- <template>
- <view class="Scanning_ins">
- <view class="Scanning">
- <view class="Scanning_top" id="Scanning_tops" :animation="animationData">
- <view class="Scanning_top_icon">
- <text class="cubeic-ok newicon newicon-duigou"></text>
- </view>
- <view class="Scanning_top_text">
- <view class="text1">扫描成功</view>
- <view class="success_tips">
- (请您评估患者的意识状况、生命体征、配合程度,如有异常请及时联系护士!)
- </view>
- </view>
- <view class="Scanning_cont">
- <view>
- <text>患者姓名 : {{ infoDATA.patientName || "-" }}
- <text v-if="infoDATA.residenceNo">
- ({{
- infoDATA.bedNum || "-"
- }})
- </text>
- <text v-if="!infoDATA.residenceNo">
- ({{
- infoDATA.cardNo || "-"
- }})
- </text>
- </text>
- </view>
- <view v-if="infoDATA.residenceNo">住院号 : {{ infoDATA.residenceNo || "-" }}</view>
- <view v-if="!infoDATA.residenceNo">身份证号 : {{ infoDATA.identityCardNo || "-" }}</view>
- <view v-if="infoDATA.residenceNo">住院科室 : {{ infoDATA.department ? infoDATA.department.dept : "-" }}</view>
- <view>注意事项 : {{ infoDATA.remark || "-" }}</view>
- </view>
- </view>
- <!-- ------------------未完成工单 start----------------- -->
- <view class="page_items" v-if="
- workData.length === 0 && patientOrders && patientOrders.length > 0
- ">
- <view class="page_item" v-for="(infoDATA, i) of patientOrders" :key="i">
- <view class="page_item_top">
- <view class="page_item_top_L">
- <text class="L_text">单号:{{ infoDATA.gdcode }}</text>
- </view>
- <view class="page_item_top_R">
- <button class="L_iocn" @click="notice(infoDATA)">通知</button>
- </view>
- <view class="L"></view>
- <view class="R"></view>
- </view>
- <view class="page_item_cont">
- <view class="page_item_cont_T">
- <view class="page_item_cont_title">
- <text> <text class="starting">起</text> 点科室 </text>
- <text class="text_big">{{ infoDATA.startDept.dept }}</text>
- </view>
- </view>
- <view class="line"></view>
- <view class="page_item_cont_B">
- <template v-if="infoDATA.taskType.associationType.value == 'inspect'">
- <view class="page_item_cont_title" v-for="(dept, i) of infoDATA.middleDept" :key="i">
- <text> <text class="End">检</text> 查科室 </text>
- <text class="text_big">{{ dept.dept }}</text>
- <view></view>
- </view>
- </template>
- <template v-if="infoDATA.taskType.associationType.value != 'inspect'">
- <view class="page_item_cont_title" v-for="(dept, i) of infoDATA.endDepts" :key="i">
- <text> <text class="End">终</text> 点科室 </text>
- <text class="text_big">{{ dept.dept }}</text>
- </view>
- </template>
- </view>
- </view>
- <view class="page_item_foot">
- <view class="page_item_foot_text">
- <text class="text1">状态</text>
- <text class="text2" v-if="
- !(
- infoDATA.gdState.value == '5' &&
- infoDATA.taskType.associationType.value == 'inspect'
- )
- ">{{ infoDATA.gdState.name }}</text>
- <text class="text2" v-if="
- infoDATA.gdState.value == '5' &&
- infoDATA.taskType.associationType.value == 'inspect'
- ">待送回</text>
- </view>
- <view class="page_item_foot_text" v-if="infoDATA.taskType.associationType.value == 'inspect'">
- <text class="text1">预约时间</text>
- <text class="text2">{{
- infoDATA.checkList &&
- infoDATA.checkList[0] &&
- infoDATA.checkList[0].yyTime
- ? infoDATA.checkList[0].yyTime
- : "-"
- }}</text>
- </view>
- </view>
- </view>
- </view>
- <!-- ------------------未完成工单 end----------------- -->
- <view class="title" v-if="workData && workData.length > 0">
- <text class="span1">工单信息</text>
- </view>
- <view class="page_items" v-if="!workData" style="font-size: 18px; margin-top: 15%">
- <view class="zwsj">
- <image class="zwsj_img" mode="widthFix" src="../../static/img/zanwushuju.png"></image>
- <view class="zwsj_txt">暂无工单</view>
- </view>
- </view>
- <view class="page_items" v-if="workData && workData.length > 0">
- <view class="page_item" v-for="(infoDATA, i) of workData" :key="i">
- <view class="page_item_top">
- <view class="page_item_top_L" @click="ac1(infoDATA, i, acType)">
- <text class="ac">
- <text :class="{ acSpan: idTYPE == infoDATA.id }"></text>
- </text>
- <text class="L_text">单号:{{ infoDATA.gdcode }}</text>
- <!-- emergencyType.value 1是正常,2是急,3是加急 -->
- <view class="page_item_cont_start emergency1" v-if="infoDATA.emergencyType.value == 1">
- <text>
- <text class="cubeic-star newicon newicon-shiwujiaoxing"></text>
- {{ infoDATA.emergencyType.name }}
- </text>
- </view>
- <view class="page_item_cont_start emergency" v-if="infoDATA.emergencyType.value == 2">
- <text>
- <text class="cubeic-star newicon newicon-shiwujiaoxing"></text>
- {{ infoDATA.emergencyType.name }}
- </text>
- </view>
- <view class="page_item_cont_start emergencys" v-if="infoDATA.emergencyType.value == 3">
- <text>
- <text class="cubeic-star newicon newicon-shiwujiaoxing"></text>
- {{ infoDATA.emergencyType.name }}
- </text>
- </view>
- </view>
- <view class="page_item_top_R">
- <text class="L_iocn" v-if="infoDATA.taskType.associationType.value == 'inspect'">患者陪检</text>
- <text class="L_iocn" v-if="
- infoDATA.taskType.associationType.value == 'patientTransport'
- ">患者转运</text>
- </view>
- <view class="L"></view>
- <view class="R"></view>
- </view>
- <view class="page_item_cont">
- <view class="page_item_cont_T">
- <view class="page_item_cont_title">
- <text> <text class="starting">起</text> 点科室 </text>
- <text class="text_big">{{ infoDATA.startDept.dept }}</text>
- </view>
- </view>
- <view class="line"></view>
- <view class="page_item_cont_B">
- <template v-if="infoDATA.taskType.associationType.value == 'inspect'">
- <view class="page_item_cont_title" v-for="(dept, i) of infoDATA.middleDept" :key="i">
- <text> <text class="End">检</text> 查科室 </text>
- <text class="text_big">{{ dept.dept }}</text>
- <view></view>
- </view>
- </template>
- <template v-if="infoDATA.taskType.associationType.value != 'inspect'">
- <view class="page_item_cont_title" v-for="(dept, i) of infoDATA.endDepts" :key="i">
- <text> <text class="End">终</text> 点科室 </text>
- <text class="text_big">{{ dept.dept }}</text>
- </view>
- </template>
- </view>
- </view>
- <view class="page_item_foot">
- <view class="page_item_foot_text">
- <text class="text1">状态</text>
- <text class="text2" v-if="
- !(
- infoDATA.gdState.value == '5' &&
- infoDATA.taskType.associationType.value == 'inspect'
- )
- ">{{ infoDATA.gdState.name }}</text>
- <text class="text2" v-if="
- infoDATA.gdState.value == '5' &&
- infoDATA.taskType.associationType.value == 'inspect'
- ">待送回</text>
- </view>
- <view class="page_item_foot_text" v-if="infoDATA.gdState.value == '2'">
- <text class="text1">预计响应时间</text>
- <text class="text2">{{ infoDATA.estimeResponseTime || '无' }}</text>
- </view>
- <view class="page_item_foot_text" v-if="infoDATA.gdState.value == '5'">
- <text class="text1" v-if="!(infoDATA.taskType.associationType.value == 'inspect')">预计送达时间</text>
- <text class="text1" v-if="infoDATA.taskType.associationType.value == 'inspect'">预计送回时间</text>
- <text class="text2">{{ infoDATA.estimeCompleteTime || '无' }}</text>
- </view>
- <view class="page_item_foot_text" v-if="infoDATA.gdState.value == '4'">
- <text class="text1">预计到达时间</text>
- <text class="text2">{{ infoDATA.estimateArriveTime || '无' }}</text>
- </view>
- <view class="page_item_foot_text">
- <text class="text1">创建时间</text>
- <text class="text2">{{ infoDATA.startTime || '无' }}</text>
- </view>
- </view>
- </view>
- </view>
- <view class="foot_btn1" v-if="infoDATA.residenceNo && batchCreationAndReturn == 1">
- <view class="btn3" @click="scanDept('all')">批量送回病房</view>
- <view class="btn3" @click="getInspectList()">查看检查</view>
- </view>
- <view class="foot_btn2" v-if="workData && workData.length > 0 && isShow">
- <view class="btn1" :class="(!infoDATA.residenceNo && addService==0)?'btn5':''" @click="getInspectAndPatientTransform(typeData)">一键操作</view>
- <view class="btn1" v-if="infoDATA.residenceNo" @click="scanDept()">送回病房</view>
- <view class="btn1" v-if="!infoDATA.residenceNo && addService==1" @click="additional()">追加服务</view>
- <view class="btn2" :class="(!infoDATA.residenceNo && addService==0)?'btn5':''" @click="showAlert">知道了</view>
- </view>
- <view class="foot_btn2" v-if="workData && workData.length === 0 && isShow">
- <view class="btn3" v-if="infoDATA.residenceNo" @click="scanDept()">送回病房</view>
- <view class="btn3" v-if="!infoDATA.residenceNo && addService==1" @click="additional()">追加服务</view>
- <view class="btn3" :class="(!infoDATA.residenceNo && addService==0)?'btn4':''" @click="showAlert">知道了</view>
- </view>
- <view class="foot_btn2" v-if="!isShow">
- <view class="btn3" v-if="infoDATA.residenceNo" @click="scanDept()">送回病房</view>
- <view class="btn3" v-if="!infoDATA.residenceNo && addService==1" @click="additional()">追加服务</view>
- <view class="btn3" :class="(!infoDATA.residenceNo && addService==0)?'btn4':''" @click="showAlert">知道了</view>
- </view>
- </view>
- <showModel :title="models.title" :icon="models.icon" :disjunctor="models.disjunctor" :content="models.content"
- @know="know" :operate="models.operate"></showModel>
- <!-- 送回病房弹窗 -->
- <showModel :title="models1.title" :icon="models1.icon" :disjunctor="models1.disjunctor" :content="models1.content"
- :operate="models1.operate" @ok="ok1" @cancel="cancel1"></showModel>
- <!-- 送回病房建单弹窗 -->
- <showModel :title="models2.title" :icon="models2.icon" :disjunctor="models2.disjunctor" :content="models2.content"
- :operate="models2.operate" @ok="ok2" @cancel="cancel2"></showModel>
- <!-- 送回病房建单弹窗-扫描科室 -->
- <showModel :title="models3.title" :icon="models3.icon" :disjunctor="models3.disjunctor" :content="models3.content"
- :operate="models3.operate" @ok="ok3" @cancel="cancel3"></showModel>
- <!-- 弹窗 -->
- <showModel :title="models4.title" :icon="models4.icon" :disjunctor="models4.disjunctor"
- :radioInspectionDistanceItem="models4.radioInspectionDistanceItem" @ok="ok4" @cancel="cancel4"
- @radioChange="radioChange4" :operate="models4.operate">
- </showModel>
- </view>
- </template>
- <script>
- import showModel from "../../components/showModel/showModel.vue";
- import {
- get,
- post,
- SM,
- webHandle
- } from "../../http/http.js";
- export default {
- data() {
- return {
- isInspectAndPatientTransform: false, //是否是一键操作
- selectRadio: [], //单选框选中的数据,第一项是qrcode,第二项是名称
- // 单选框弹窗model1
- models4: {
- disjunctor: false,
- },
- currentCode: '', //当前小扫描的科室二维码
- SMFlag: true,
- options: {},
- // wechatFocusSwitch: 0,
- hosId: "",
- // 弹窗model
- models: {
- disjunctor: false,
- },
- // 送回病房弹窗model
- models1: {
- disjunctor: false,
- },
- // 送回病房建单弹窗model
- models2: {
- disjunctor: false,
- },
- // 送回病房建单弹窗model-扫描科室
- models3: {
- disjunctor: false,
- },
- infoDATA: {},
- workData: [],
- patientOrders: [],
- acType: Number,
- tabType: 1,
- idTYPE: "",
- userId: {
- ids: [],
- },
- typeData: null,
- types: false,
- code: "",
- animationData: {}, //动画
- isShow: true, //是否显示“一键操作”
- currentStartDept: {}, //扫描的起点科室
- addService:null, //是否开启允许追加服务
- batchCreationAndReturn:null //批量建立送回
- };
- },
- methods: {
- // 获取是否需要选择陪检方式
- getInspectAndPatientTransformSend() {
- let infoDATA = JSON.parse(this.options.infoDATA);
- const postData = {
- "idx": 0,
- "sum": 1,
- "taskTypeConfig": {
- "taskTypeDTO": {
- "hosId": {
- "id": this.hosId
- },
- "associationType": {
- "key": "association_types",
- "value": "inspect",
- },
- },
- },
- };
- uni.showLoading({
- mask: true,
- title: '加载中'
- })
- post("/simple/data/fetchDataList/taskTypeConfig", postData).then((res) => {
- console.log(res)
- if (res.status == 200) {
- res.list = res.list || [];
- if (res.list[0] && res.list[0].signTypeIds) {
- // 如果开启
- const postData = {
- "idx": 0,
- "sum": 9999,
- "workOrderInspectScore": {
- "hosId": this.hosId,
- },
- };
- post("/simple/data/fetchDataList/workOrderInspectScore", postData).then((res) => {
- console.log(res)
- uni.hideLoading();
- if (res.status == 200) {
- res.list = res.list || [];
- let radioInspectionDistanceItem = res.list.map(v => ({
- id: v.id + "__" + v.inspectMode,
- inspectMode: v.inspectMode
- }));
- this.models4 = {
- disjunctor: true,
- title: "请选择陪检方式",
- radioInspectionDistanceItem,
- icon: "",
- operate: {
- ok: "确定",
- cancel: "取消",
- },
- };
- } else {
- uni.showToast({
- icon: "none",
- title: res.msg || "接口获取数据失败!",
- });
- }
- })
- } else {
- this.ok3Result();
- }
- } else {
- uni.hideLoading();
- uni.showToast({
- icon: "none",
- title: res.msg || "接口获取数据失败!",
- });
- }
- })
- },
- // 获取是否需要选择陪检方式
- getInspectAndPatientTransform() {
- this.isInspectAndPatientTransform = true;
- console.log(this.typeData);
- if (this.typeData) {
- const postData = {
- "idx": 0,
- "sum": 1,
- "taskTypeConfig": {
- "taskTypeDTO": {
- "hosId": {
- "id": this.hosId
- },
- "associationType": {
- "key": "association_types",
- "value": "inspect",
- },
- },
- },
- };
- uni.showLoading({
- mask: true,
- title: '加载中'
- })
- post("/simple/data/fetchDataList/taskTypeConfig", postData).then((res) => {
- console.log(res)
- if (res.status == 200) {
- res.list = res.list || [];
- if (res.list[0] && res.list[0].signTypeIds && this.typeData.gdState.value == 4) {
- // 如果开启并且工单状态是待到达
- const postData = {
- "idx": 0,
- "sum": 9999,
- "workOrderInspectScore": {
- "hosId": this.hosId,
- },
- };
- post("/simple/data/fetchDataList/workOrderInspectScore", postData).then((res) => {
- console.log(res)
- uni.hideLoading();
- if (res.status == 200) {
- res.list = res.list || [];
- let radioInspectionDistanceItem = res.list.map(v => ({
- id: v.id + "__" + v.inspectMode,
- inspectMode: v.inspectMode
- }));
- this.models4 = {
- disjunctor: true,
- title: "请选择陪检方式",
- radioInspectionDistanceItem,
- icon: "",
- operate: {
- ok: "确定",
- cancel: "取消",
- },
- };
- } else {
- uni.showToast({
- icon: "none",
- title: res.msg || "接口获取数据失败!",
- });
- }
- })
- } else {
- this.allStart(this.typeData);
- }
- } else {
- uni.hideLoading();
- uni.showToast({
- icon: "none",
- title: res.msg || "接口获取数据失败!",
- });
- }
- })
- } else {
- this.models = {
- disjunctor: true,
- content: "请选择工单",
- icon: "warn",
- operate: {
- know: "知道了",
- },
- };
- }
- },
- // 选中单选框
- radioChange4(item) {
- console.log(item);
- this.selectRadio = item.split("__");
- },
- // 确定
- ok4() {
- console.log(this.selectRadio);
- if (!this.selectRadio.length) {
- return;
- }
- this.models4.disjunctor = false;
- // 判断是一键操作还是送回病房
- if(this.isInspectAndPatientTransform){
- this.allStart(this.typeData);
- }else{
- this.ok3Result();
- }
- },
- cancel4() {
- this.models4.disjunctor = false;
- },
- ok2() {
- this.models2.disjunctor = false;
- this.getInspectAndPatientTransformSend();
- },
- cancel2() {
- this.models2.disjunctor = false;
- },
- ok3Result() {
- uni.showLoading({
- mask: true,
- title: '加载中'
- })
- let userId = uni.getStorageSync("userData").user.id;
- let postData = {
- "workOrder": [{
- sourceId: 4,
- "hosId": this.hosId,
- "startDept": {
- "id": this.options.id || this.currentStartDept.id
- },
- "createDept": this.options.id || this.currentStartDept.id,
- "patient": {
- "patientCode": this.infoDATA.patientCode
- },
- "worker": {
- "id": userId
- },
- }],
- "inspectMode": this.selectRadio.length > 0 ? this.selectRadio[0] : undefined,
- };
- post("/workerOrder/returnSickRoom", postData).then((res) => {
- console.log(res)
- uni.hideLoading();
- if (res.status == 200) {
- uni.showToast({
- icon: 'success',
- title: '建单成功',
- });
- } else {
- uni.showToast({
- icon: "none",
- title: res.msg || "接口获取数据失败!",
- });
- }
- })
- },
- ok3() {
- this.models3.disjunctor = false;
- this.getInspectAndPatientTransformSend();
- },
- cancel3() {
- this.models3.disjunctor = false;
- },
- // 送回病房-建单
- sendBuild() {
- let infoDATA = JSON.parse(this.options.infoDATA);
- this.models2 = {
- disjunctor: true,
- title: "提示",
- content: `您选择的起点科室为【${this.options.dept}】,您将从【${this.options.dept}】把【${infoDATA.patientName}】送回【${infoDATA.department.dept}】,如您确认请点击“确认建单”。`,
- icon: "warn",
- operate: {
- ok: "确认建单",
- cancel: "取消",
- },
- };
- },
- // 追加服务
- additional(){
- uni.navigateTo({
- url: `/pages/outpatient/outpatientEndTaskType/outpatientEndTaskType?model=${encodeURIComponent(JSON.stringify(this.infoDATA))}`,
- });
- },
- // 送回病房-扫描科室
- scanDept(type = '') {
- if(type === 'all'){
- // 批量送回
- let infoDATA = JSON.parse(this.options.infoDATA);
- uni.navigateTo({
- url: `/pages/newSendBack/sendBackPatient/sendBackPatient?patientId=${infoDATA.id}&patientName=${infoDATA.patientName}&patientResidenceNo=${infoDATA.residenceNo}&patientCode=${infoDATA.patientCode}`,
- });
- return;
- }
- this.isInspectAndPatientTransform = false;
- if (!this.SMFlag) {
- return;
- }
- this.SMFlag = false;
- let infoDATA = JSON.parse(this.options.infoDATA);
- let code = "";
- SM().then((ress1) => {
- uni.showLoading({
- title: "加载中",
- mask: true,
- });
- //检验二维码的有效性
- post("/dept/scanning", {
- content: ress1,
- }).then((result) => {
- this.SMFlag = true;
- if (result.state == 200 || result.state == 201) {
- let ress = result.code;
- if (ress) {
- code = ress;
- // 科室扫描
- let postData = {
- "type": "query",
- "qrCode": code,
- "patientCode": infoDATA.patientCode,
- };
- post("/dept/scanChangeDept", postData).then((res) => {
- uni.hideLoading();
- if (res.status == 200) {
- if (res.data) {
- if(res.data.deptDTO){
- this.currentStartDept = res.data.deptDTO;
- }else{
- this.currentStartDept = res.data;
- }
- this.models3 = {
- disjunctor: true,
- title: "提示",
- content: `您选择的起点科室为【${this.currentStartDept.dept}】,您将从【${this.currentStartDept.dept}】把【${infoDATA.patientName}】送回【${infoDATA.department.dept}】,如您确认请点击“确认建单”。`,
- icon: "warn",
- operate: {
- ok: "确认建单",
- cancel: "取消",
- },
- };
- } else {
- uni.hideLoading();
- uni.showToast({
- icon: "none",
- title: "请扫描正确的科室码!",
- });
- }
- } else if(res.status == 400){
- // 校验患者是否没有住院科室
- uni.showToast({
- icon: "none",
- title: res.msg,
- });
- } else {
- uni.hideLoading();
- uni.showToast({
- icon: "none",
- title: res.msg || "接口获取数据失败!",
- });
- }
- });
- }
- } else {
- uni.hideLoading();
- uni.showToast({
- icon: "none",
- title: result.info || "接口获取数据失败!",
- });
- }
- });
- }).catch(err => {
- this.SMFlag = true;
- });
- },
- // 送回病房-选择起点科室
- sendBack() {
- let infoDATA = JSON.parse(this.options.infoDATA);
- this.models1 = {
- disjunctor: true,
- title: "提示",
- content: `您好,您是要将【${infoDATA.patientName}】送回病房吗?如确认请您点击“选择起点科室”建立工单。`,
- icon: "warn",
- operate: {
- ok: "选择起点科室",
- cancel: "取消",
- },
- };
- },
- ok1() {
- this.models1.disjunctor = false;
- uni.navigateTo({
- url: `../search/search?type=sendBack&code=${this.options.code}&infoDATA=${this.options.infoDATA}&patientOrders=${this.options.patientOrders}&workData=${this.options.workData}`,
- });
- },
- cancel1() {
- this.models1.disjunctor = false;
- },
- // 查看检查
- getInspectList() {
- // uni.navigateTo({
- // url: `../inspectList/inspectList?id=${this.infoDATA.department.id}&dept=${this.infoDATA.department.dept}&patientCode=${this.infoDATA.patientCode}`,
- // });
- uni.navigateTo({
- url: `../patientInformationInfo/patientInformationInfo?patientCode=${this.infoDATA.patientCode}`,
- });
- },
- // 通知
- notice(info) {
- let postData = {
- wechatConfigType: "hsms",
- userIds: info.worker.id + "",
- content: `您负责护送的患者${info.patient.patientName}(${info.patient.bedNum})已经检查完毕,请尽快执行工单的下一步。`,
- };
- post("/wechat/sendCustomMessage", postData).then((res) => {
- if (res.status == 200) {
- uni.showToast({
- title: "通知成功",
- duration: 2000,
- });
- } else {
- uni.showToast({
- icon: "none",
- title: res.msg || "接口获取数据失败!",
- });
- }
- });
- },
- //需要帮助、无需帮助
- // help() {
- // this.models = {
- // disjunctor: true,
- // title: "提示",
- // content: this.infoDATA.focusPatient == 1 ?
- // "如设置为“无需帮助”则后期此患者检查将不会自动进行建单,可通过“需要帮助”设置自动建单" : "如设置为“需要帮助”则后期此患者检查会自动进行建单,可通过“无需帮助”取消设置",
- // icon: "warn",
- // operate: {
- // ok: "确定",
- // cancel: "取消",
- // },
- // };
- // },
- //需要帮助,无需帮助确定
- // ok() {
- // this.models.disjunctor = false;
- // post("/nurse/updData/patient", {
- // patient: {
- // id: this.infoDATA.id,
- // focusPatient: this.infoDATA.focusPatient == 1 ? 0 : 1,
- // },
- // }).then((res) => {
- // let msg = "设置失败";
- // let icon = "error";
- // if (res.status == 200) {
- // msg = "设置成功";
- // icon = "success";
- // this.infoDATA.focusPatient = res.data.focusPatient;
- // }
- // this.models = {
- // disjunctor: true,
- // content: msg,
- // icon: icon,
- // operate: {
- // know: "知道了",
- // },
- // };
- // });
- // },
- //需要帮助,无需帮助取消
- // cancel() {
- // this.models.disjunctor = false;
- // },
- //知道了
- know() {
- this.models.disjunctor = false;
- },
- // 知道了
- showAlert() {
- uni.navigateTo({
- url: "../receiptpage/receiptpage",
- });
- },
- //一键操作
- allStart(data) {
- console.log(data)
- let list = {};
- if (data) {
- let type = "";
- if (data.gdState.value == "8") {
- if (!this.SMFlag) {
- return;
- }
- this.SMFlag = false;
- SM().then((ress1) => {
- // ----------------
- uni.showLoading({
- title: "加载中",
- mask: true,
- });
- //检验二维码的有效性
- post("/dept/scanning", {
- content: ress1,
- }).then((result) => {
- this.SMFlag = true;
- this.currentCode = result.code;
- if (result.state == 200 || result.state == 201) {
- let ress = result.code;
- if (ress) {
- var ids = [];
- ids.push(data.id);
- type = "orderSign/" + ress;
- list = {
- ids
- };
- // 科室签到
- post("/workerOrder/" + type, list).then((res) => {
- uni.hideLoading();
- if (res.status == 200) {
- // model: JSON.stringify(res), //签到返回的信息
- // type: data.taskType.associationType.value, //关联类型
- // code: ress, //二维码code
- // ids //科室ID数组
- uni.navigateTo({
- url: `../scanning_djEnd/scanning_djEnd?type=${
- data.taskType.associationType.value
- }&code=${ress}&ids=${ids}&model=${encodeURIComponent(
- JSON.stringify(res)
- )}`,
- });
- } else {
- uni.navigateTo({
- url: `../scanning_djEnd/scanning_djEnd?model=${encodeURIComponent(
- JSON.stringify(res)
- )}&qrcode=${this.currentCode}`,
- });
- }
- });
- }
- } else {
- uni.hideLoading();
- uni.showToast({
- icon: "none",
- title: result.info || "接口获取数据失败!",
- });
- }
- });
- // ------------------------------
- }).catch(err => {
- this.SMFlag = true;
- });
- } else {
- if (data.taskType.associationType.value == "patientTransport") {
- type = "handleTrans";
- let data = {
- ids: this.userId.ids,
- // "11789558|51131895|7|黄石城乡|陈琛|女|19981003|20180803081051|Z消化内科Ⅰ"
- code: this.code,
- inspectMode: this.selectRadio.length > 0 ? this.selectRadio[0] : undefined,
- };
- list = data;
- }
- if (data.taskType.associationType.value == "inspect") {
- type = "handleIns";
- let data = {
- ids: this.userId.ids,
- // "11789558|51131895|7|黄石城乡|陈琛|女|19981003|20180803081051|Z消化内科Ⅰ"
- code: this.code,
- inspectMode: this.selectRadio.length > 0 ? this.selectRadio[0] : undefined,
- };
- list = data;
- }
- uni.showLoading({
- title: "加载中",
- mask: true,
- });
- post("/workerOrder/" + type, list).then((res) => {
- console.log(1111,res)
- uni.hideLoading();
- if (res.status == 200) {
- if(data.gdState.value == 4 && data.taskType.associationType.value === 'patientTransport'){
- // 门诊服务点
- if(res.orderList){
- uni.navigateTo({
- url: `/pages/outpatient/outpatientStartSignIn/outpatientStartSignIn?model=${encodeURIComponent(JSON.stringify(res))}`,
- });
- }else{
- uni.navigateTo({
- url: `../scanning_insEnd/scanning_insEnd?type=${
- data.taskType.associationType.value
- }&model=${encodeURIComponent(JSON.stringify(res))}`,
- });
- }
- }else{
- uni.navigateTo({
- url: `../scanning_insEnd/scanning_insEnd?type=${
- data.taskType.associationType.value
- }&model=${encodeURIComponent(JSON.stringify(res))}`,
- });
- }
- } else {
- uni.navigateTo({
- url: `../scanning_insEnd/scanning_insEnd?model=${encodeURIComponent(
- JSON.stringify(res)
- )}`,
- });
- }
- }).catch(err=>{
- console.log(9999,err)
- })
- }
- } else {
- this.models = {
- disjunctor: true,
- content: "请选择工单",
- icon: "warn",
- operate: {
- know: "知道了",
- },
- };
- }
- },
- //选中
- ac(data, i, type) {
- this.idTYPE = "";
- },
- //未选中
- ac1(data, i, type) {
- if (this.idTYPE == data.id) {
- //显示
- this.isShow = true;
- this.idTYPE = "";
- this.userId.ids = [];
- this.typeData = null;
- } else {
- if (data.gdState.value >= 5) {
- //隐藏
- this.isShow = false;
- } else {
- //显示
- this.isShow = true;
- }
- this.idTYPE = data.id;
- this.typeData = data;
- this.userId.ids[0] = this.idTYPE;
- }
- },
- texiao() {
- if (this.workData && this.workData.length > 0) {
- setTimeout(() => {
- this.animation.height(0).opacity(0).step();
- this.animationData = this.animation.export();
- }, 15000);
- }
- },
- // 获取需要帮助权限
- // getWechatFocusSwitch() {
- // let postData = {
- // idx: 0,
- // sum: 1,
- // taskType: {
- // hosIds: this.hosId,
- // associationType: {
- // id: 260,
- // },
- // },
- // };
- // post("/configuration/fetchDataList/taskType", postData).then((res) => {
- // if (res.status == 200) {
- // this.wechatFocusSwitch = res.list[0].wechatFocusSwitch || 0;
- // } else {
- // uni.showToast({
- // icon: "none",
- // title: res.msg || "接口获取数据失败!",
- // });
- // }
- // });
- // },
- // 获取检查页面控制
- getTaskTypeConfig(){
- uni.showLoading({
- title: "加载中",
- mask: true,
- });
- post("/simple/data/fetchDataList/taskTypeConfig", {
- "idx": 0,
- "sum": 10,
- "taskTypeConfig": {
- "taskTypeDTO": {
- "hosId": {
- "id": this.hosId
- },
- "associationType": {
- "key": "association_types",
- "value": "inspect"
- }
- }
- }
- }).then((result) => {
- uni.hideLoading();
- if (result.status == 200) {
- let configs = result.list || [];
- if(configs.length){
- this.addService = configs[0].addService;
- this.batchCreationAndReturn = configs[0].batchCreationAndReturn;
- }
- } else {
- uni.showToast({
- icon: "none",
- title: result.msg || "接口获取数据失败!",
- });
- }
- });
- }
- },
- onLoad(options) {
- console.log(options);
- this.options = options;
- // 送回病房建单 start
- if (options.id && options.dept) {
- this.sendBuild();
- }
- // 送回病房建单 end
- this.hosId = uni.getStorageSync("userData").user.currentHospital.id;
- // this.getWechatFocusSwitch();
- this.getTaskTypeConfig()
- this.infoDATA = JSON.parse(options.infoDATA);
- console.log(this.infoDATA);
- this.workData = JSON.parse(options.workData);
- if (options.patientOrders != 'undefined') {
- this.patientOrders = JSON.parse(options.patientOrders);
- }
- this.code = options.code;
- // #ifdef APP-PLUS
- webHandle("no", "app");
- // #endif
- // #ifdef H5
- webHandle("no", "wx");
- // #endif
- },
- onShow() {
- this.SMFlag = true;
- // 创建动画
- this.animation = uni.createAnimation({
- duration: 500,
- timingFunction: "ease",
- delay: 2000,
- });
- setTimeout(() => {
- this.texiao();
- }, 500);
- },
- onHide() {
- this.animationData = {};
- },
- onUnload() {
- // 页面关闭后清空数据
- this.animationData = {};
- },
- };
- </script>
- <style lang="less">
- ::-webkit-scrollbar {
- width: 0px;
- }
- ::-webkit-scrollbar-track {
- background-color: none;
- }
- ::-webkit-scrollbar-thumb {
- background-color: none;
- }
- ::-webkit-scrollbar-thumb:hover {
- background-color: none;
- }
- ::-webkit-scrollbar-thumb:active {
- background-color: none;
- }
- .Scanning_ins {
- .title {
- font-size: 36rpx;
- margin-top: 20rpx;
- margin-bottom: 20rpx;
- font-weight: 700;
- position: relative;
- height: 40rpx;
- .span1 {
- position: absolute;
- left: 0;
- font-weight: 700;
- }
- .span2 {
- position: absolute;
- right: 20%;
- color: rgb(73, 184, 86);
- }
- .span3 {
- position: absolute;
- right: 0;
- color: rgb(73, 184, 86);
- }
- }
- .Scanning {
- padding: 0 20rpx;
- .Scanning_top {
- // height: 500rpx;
- .Scanning_top_icon {
- width: 140rpx;
- height: 140rpx;
- margin: 0 auto;
- margin-top: 36rpx;
- border-radius: 50%;
- line-height: 140rpx;
- .cubeic-ok {
- font-size: 140rpx;
- color: #35b34a;
- }
- }
- .Scanning_top_text {
- .text1 {
- margin-top: 30rpx;
- font-size: 48rpx;
- text-align: center;
- }
- .success_tips {
- color: red;
- font-size: 30rpx;
- }
- }
- .Scanning_cont {
- font-size: 32rpx;
- margin-top: 16rpx;
- view {
- margin-bottom: 8rpx;
- display: flex;
- justify-content: center;
- align-items: center;
- button {
- font-size: 32rpx;
- height: 52rpx;
- line-height: 52rpx;
- margin: 0;
- color: rgb(7, 134, 60);
- font-weight: 700;
- }
- }
- .text {
- margin-top: 24rpx;
- color: #35b34a;
- }
- .text1 {
- margin-top: 24rpx;
- color: #ff3b53;
- }
- }
- }
- .page_items {
- padding-bottom: 200rpx;
- .zwsj {
- margin-top: 180rpx;
- display: flex;
- flex-direction: column;
- align-items: center;
- .zwsj_txt {
- font-size: 36rpx;
- font-weight: 700;
- margin-top: 20rpx;
- }
- .zwsj_img {
- width: 582rpx;
- }
- }
- .page_item {
- margin-top: 16rpx;
- min-height: 310rpx;
- background: #fff;
- border-radius: 8rpx;
- overflow: hidden;
- padding: 0 16rpx;
- border: 2rpx solid #e5e9ed;
- .L {
- width: 40rpx;
- height: 40rpx;
- border-radius: 50%;
- background: #f9fafb;
- position: relative;
- left: -50rpx;
- top: 66rpx;
- }
- .R {
- width: 40rpx;
- height: 40rpx;
- border-radius: 50%;
- background: #f9fafb;
- position: relative;
- float: right;
- right: -50rpx;
- top: 26rpx;
- }
- .starting {
- width: 50rpx;
- height: 50rpx;
- color: #fff;
- background: #49b856;
- display: inline-block;
- border-radius: 50%;
- text-align: center;
- line-height: 46rpx;
- font-size: 32rpx;
- margin-right: 6rpx;
- }
- .End {
- width: 50rpx;
- height: 50rpx;
- color: #fff;
- background: #39b199;
- display: inline-block;
- border-radius: 50%;
- text-align: center;
- line-height: 46rpx;
- font-size: 32rpx;
- margin-right: 6rpx;
- }
- .page_item_top {
- height: 86rpx;
- border-bottom: 2rpx dashed #e5e9ed;
- padding: 0 16rpx;
- .page_item_top_L {
- height: 100%;
- float: left;
- line-height: 88rpx;
- display: flex;
- align-items: center;
- .ac {
- width: 32rpx;
- height: 32rpx;
- border: 2rpx solid #ccc;
- display: flex;
- justify-content: center;
- align-items: center;
- position: relative;
- .acSpan {
- width: 24rpx;
- height: 24rpx;
- background: #39b199;
- display: block;
- }
- }
- .ac1 {
- width: 32rpx;
- height: 32rpx;
- border: 2rpx solid #ccc;
- display: inline-block;
- position: relative;
- }
- .emergencys {
- background: #ff3b53 !important;
- width: 124rpx !important;
- }
- .emergency {
- background: #ff3b53 !important;
- }
- .emergency1 {
- background: #49b856 !important;
- }
- .page_item_cont_start {
- text-align: center;
- height: 44rpx;
- width: 104rpx;
- line-height: 44rpx;
- border-radius: 8rpx;
- background: #49b856;
- color: #fff;
- display: inline-block;
- font-size: 28rpx;
- }
- .L_time {
- color: #6cc076;
- font-size: 32rpx;
- }
- .L_text {
- font-size: 32rpx;
- display: inline-block;
- font-weight: 700;
- }
- }
- .page_item_top_R {
- height: 60rpx;
- float: right;
- padding-top: 20rpx;
- font-size: 32rpx;
- position: absolute;
- right: 50rpx;
- .L_iocn {
- display: inline-block;
- height: 52rpx;
- line-height: 48rpx;
- color: rgb(7, 134, 60);
- font-size: 36rpx;
- font-weight: 700;
- }
- }
- }
- .page_item_cont {
- min-height: 180rpx;
- max-height: 424rpx;
- padding: 0 16rpx;
- text-align: left;
- position: relative;
- .text_big {
- font-size: 32rpx;
- position: absolute;
- right: 16rpx;
- font-weight: 700;
- margin-top: 10rpx;
- }
- .text_big2 {
- font-size: 32rpx;
- position: absolute;
- right: 16rpx;
- font-weight: 700;
- }
- .line {
- height: 20rpx;
- width: 2rpx;
- border-left: 2rpx solid #e5e9ed;
- position: absolute;
- top: 82rpx;
- left: 40rpx;
- }
- .lines {
- height: 40%;
- width: 2rpx;
- border-left: 2rpx solid #e5e9ed;
- position: absolute;
- top: 23%;
- left: 36rpx;
- }
- .page_item_cont_T {
- padding-top: 28rpx;
- font-size: 28rpx;
- .page_item_cont_title {
- height: 100%;
- font-size: 32rpx;
- }
- }
- .page_item_cont_B {
- padding-top: 28rpx;
- margin-bottom: 28rpx;
- .page_item_cont_title {
- height: 60rpx;
- font-size: 32rpx;
- }
- .page_item_cont_title1 {
- height: 60rpx;
- line-height: 60rpx;
- font-size: 32rpx;
- padding-left: 64rpx;
- }
- }
- }
- .page_item_foot {
- border-top: 2rpx dashed #e5e9ed;
- border-bottom: 2rpx dashed #e5e9ed;
- padding: 28rpx 16rpx;
- text-align: left;
- .page_item_foot_text {
- height: 48rpx;
- font-size: 32rpx;
- line-height: 48rpx;
- margin-bottom: 20rpx;
- .text1 {
- color: rgb(102, 102, 102);
- }
- .text2 {
- float: right;
- font-weight: 700;
- }
- }
- }
- #infos {
- display: none;
- }
- .page_item_infos {
- padding-bottom: 20rpx;
- border-bottom: 2rpx dashed #e5e9ed;
- .page_item_info2 {
- text-align: left;
- line-height: 60rpx;
- font-size: 32rpx;
- padding-left: 16rpx;
- .page_item_foot_text {
- height: 48rpx;
- font-size: 32rpx;
- line-height: 48rpx;
- margin-bottom: 20rpx;
- .text1 {
- color: rgb(102, 102, 102);
- }
- .text2 {
- float: right;
- font-weight: 700;
- }
- }
- }
- }
- }
- }
- .foot_btn1 {
- position: fixed;
- bottom: 84rpx;
- right: 20rpx;
- left: 20rpx;
- line-height: 66rpx;
- height: 100rpx;
- border-top: 2rpx solid #e5e9ed;
- background: #f9fafb;
- display: flex;
- justify-content: space-between;
- .btn1,
- .btn2,
- .btn3,
- .btn4,
- .btn5 {
- height: 66rpx;
- flex: 1;
- background-image: linear-gradient(to right, #72c172, #3bb197);
- color: #fff;
- border-radius: 8rpx;
- font-size: 32rpx;
- margin: 16rpx 1% 0;
- text-align: center;
- }
- }
- .foot_btn2 {
- position: fixed;
- bottom: 0;
- right: 20rpx;
- left: 20rpx;
- line-height: 66rpx;
- height: 100rpx;
- background: #f9fafb;
- display: flex;
- justify-content: space-between;
- .btn1,
- .btn2,
- .btn3,
- .btn4,
- .btn5 {
- height: 66rpx;
- flex: 1;
- background-image: linear-gradient(to right, #72c172, #3bb197);
- color: #fff;
- border-radius: 8rpx;
- font-size: 32rpx;
- margin: 16rpx 1% 0;
- text-align: center;
- }
- }
- }
- }
- </style>
|