2 lines
4.1 KiB
JavaScript
2 lines
4.1 KiB
JavaScript
import{R as V,L as C,N as D,T as O,M as S}from"./element-plus-DXf-o39Q.js";import{_ as B}from"./index.vue_vue_type_script_setup_true_lang-ChjxJLXp.js";import{u as j}from"./usePaging-BIG1oWvJ.js";import{j as A}from"./tcm-CvoU9azU.js";import{f as M,w as z,ak as l,I as _,a as r,F as R,aP as q,G,aN as s,J as b,O as c,A as w}from"./@vue/runtime-core-tF_2qJHK.js";import{y as d,a as H,r as J}from"./@vue/reactivity-BmZ-20sQ.js";import{Q as m}from"./@vue/shared-mAAVTE9n.js";import{_ as Q}from"./index-FHdEJBvh.js";import"./@vue/runtime-dom-CEiKlVMn.js";import"./lodash-D3kF6u-c.js";import"./@element-plus/icons-vue-DjaAJPkG.js";import"./lodash-es-C2A-Pj28.js";import"./@popperjs/core-C5az9QE8.js";import"./dayjs-DG77mNTn.js";import"./@ctrl/tinycolor-BuyEbX8F.js";import"./async-validator-CFA_igpM.js";import"./normalize-wheel-es-BQoi3Ox2.js";import"./jspdf-BsthCvR5.js";import"./@babel/runtime-BanGtE2-.js";import"./fflate-_ayOYiT1.js";import"./vue-router-BjeWxBI0.js";import"./pinia-CTWOnonq.js";import"./axios-C80V62Fs.js";import"./@vueuse/core-QlbCbZWN.js";import"./@vueuse/shared-Bl-RnC0s.js";import"./css-color-function-DI01JAaZ.js";import"./balanced-match-BdS7OldZ.js";import"./color-B2zxaWkI.js";import"./clone-DBZ6_OiU.js";import"./color-convert-OrFsTA_V.js";import"./color-name-Dju3oUBS.js";import"./color-string-pUQDDJII.js";import"./ms-CzQ2E3wO.js";import"./vue-clipboard3-DByT_rEQ.js";import"./clipboard-CHgxszqY.js";import"./echarts-CNLwa9wG.js";import"./tslib-BDyQ-Jie.js";import"./zrender-DRNXw7y3.js";import"./highlight.js-Bxt7hFFy.js";import"./@highlightjs/vue-plugin-Bm7NQW9r.js";const U={class:"patient-order-list"},Y={key:0,class:"po-empty-tip"},K={class:"text-red-500 font-semibold"},W={class:"flex justify-end mt-3"},X=M({__name:"PatientOrderList",props:{diagnosisId:{},patientId:{}},setup(y,{expose:v}){const g=y,u=w(()=>{const e=Number(g.patientId);return Number.isFinite(e)&&e>0?e:0}),f=w(()=>u.value>0),p=J({}),{pager:a,getLists:h,resetPage:N}=j({fetchFun:A,params:p,size:10}),x=()=>{Object.keys(p).forEach(e=>delete p[e]),f.value&&(p.patient_id=u.value)},I=e=>{const t=Number(e);return Number.isFinite(t)?t.toFixed(2):"0.00"},T=e=>{if(e==null||e==="")return"—";if(typeof e=="number"&&e>1e9&&e<1e11){const t=new Date(e*1e3),n=i=>String(i).padStart(2,"0");return`${t.getFullYear()}-${n(t.getMonth()+1)}-${n(t.getDate())} ${n(t.getHours())}:${n(t.getMinutes())}:${n(t.getSeconds())}`}return String(e)},k=e=>({1:"待双审通过",2:"待发货",3:"已完成",4:"已取消",5:"已发货",6:"已签收",7:"进行中",8:"暂不制药",9:"拒收",10:"退款",11:"保留药方",12:"制药缓发"})[Number(e)]??"—",E=e=>{const t=Number(e);return t===3||t===6?"success":t===5?"primary":t===4||t===9||t===10?"danger":t===2||t===7?"warning":"info"};return z(()=>[g.diagnosisId,u.value],()=>{if(!f.value){a.lists=[],a.count=0;return}x(),N()},{immediate:!0}),v({refresh:()=>h()}),(e,t)=>{const n=V,i=D,F=O,P=S,$=B,L=C;return l(),_("div",U,[f.value?(l(),_(R,{key:1},[q((l(),G(P,{data:d(a).lists,border:"",stripe:"","empty-text":"暂无业务订单"},{default:s(()=>[r(i,{label:"订单编号",prop:"order_no","min-width":"200","show-overflow-tooltip":""}),r(i,{label:"金额",width:"120",align:"right"},{default:s(({row:o})=>[b("span",K,"¥"+m(I(o.amount)),1)]),_:1}),r(i,{label:"医生",prop:"doctor_name",width:"110","show-overflow-tooltip":""},{default:s(({row:o})=>[c(m(o.doctor_name||"—"),1)]),_:1}),r(i,{label:"医助",prop:"assistant_name",width:"110","show-overflow-tooltip":""},{default:s(({row:o})=>[c(m(o.assistant_name||"—"),1)]),_:1}),r(i,{label:"履约状态",width:"110"},{default:s(({row:o})=>[r(F,{type:E(o.fulfillment_status),size:"small",effect:"light"},{default:s(()=>[c(m(k(o.fulfillment_status)),1)]),_:2},1032,["type"])]),_:1}),r(i,{label:"创建时间","min-width":"170"},{default:s(({row:o})=>[c(m(T(o.create_time)),1)]),_:1})]),_:1},8,["data"])),[[L,d(a).loading]]),b("div",W,[r($,{modelValue:d(a),"onUpdate:modelValue":t[0]||(t[0]=o=>H(a)?a.value=o:null),onChange:d(h)},null,8,["modelValue","onChange"])])],64)):(l(),_("div",Y,[r(n,{description:"当前诊单未携带患者ID,无法列出业务订单"})]))])}}}),At=Q(X,[["__scopeId","data-v-8efc8fc0"]]);export{At as default};
|