1 |
- import{_ as U,r as E,D as d,bq as M,v as s,as as T,o as p,M as v,J as r,q as c,w as l,N as q,x as a,bm as O,p as R,L as I,K as j,W as C}from"./index.ef4119aa.js";import{d as J}from"./index.8ebd581f.js";import{C as K}from"./tragelog.14676dc9.js";const W={flex:"","mb-2":""},G={flex:"","flex-1":"",gap:"5",pr:"20px"},H={flex:"",width:"120px"},Q=C("\u641C\u7D22"),X=C("\u91CD\u7F6E"),Y={flex:"","justify-between":"","mt-2":""},Z=C("\u786E\u5B9A"),$=E({__name:"capital-modal",emits:["on-add-order"],setup(ee,{expose:N,emit:V}){const u=d(!1),_=d([]),D=K.filter(({field:o})=>o!=="status"),m=d(null),{run:w,data:h,getPaginationParams:k,loading:P,pagination:i}=M({initalData:[],isList:!0,initalPagination:{currentPage:1,pageSize:10,total:0}}),n=d({tradNo:"",logNo:""}),f=()=>{w(J({status:"2",...n.value,...k()}))};function z(){u.value=!1,V("on-add-order",a(_.value[0]))}function B(o){if(o.length>1){const e=o.pop();m.value.clearSelection(),m.value.toggleRowSelection(e,!0),_.value=[e]}else _.value=[o[0]]}function b(o=!1){o&&(n.value={tradNo:"",logNo:""}),i.currentPage=1,f()}return N({onDisplay:()=>u.value=!0}),(o,e)=>{const x=s("el-input"),g=s("el-button"),y=s("el-table-column"),S=s("el-pagination"),A=s("el-dialog"),F=T("loading");return p(),v(A,{modelValue:u.value,"onUpdate:modelValue":e[5]||(e[5]=t=>u.value=t),title:"\u8D44\u91D1\u8BA4\u9886",center:"",onOpen:e[6]||(e[6]=()=>f())},{default:r(()=>[c("div",W,[c("div",G,[l(x,{placeholder:"\u8D44\u91D1\u7F16\u53F7",size:"small",modelValue:n.value.tradNo,"onUpdate:modelValue":e[0]||(e[0]=t=>n.value.tradNo=t)},null,8,["modelValue"]),l(x,{placeholder:"\u8BA4\u9886\u7F16\u53F7",size:"small",modelValue:n.value.logNo,"onUpdate:modelValue":e[1]||(e[1]=t=>n.value.logNo=t)},null,8,["modelValue"])]),c("div",H,[l(g,{size:"small",type:"primary",onClick:e[2]||(e[2]=()=>b())},{default:r(()=>[Q]),_:1}),l(g,{size:"small",onClick:e[3]||(e[3]=()=>b(!0))},{default:r(()=>[X]),_:1})])]),q((p(),v(a(O),{border:"",ref_key:"tableRef",ref:m,data:a(h),size:"small","row-key":"id",onSelectionChange:B},{default:r(()=>[l(y,{type:"selection",width:"55"}),(p(!0),R(j,null,I(a(D),({field:t,label:L})=>(p(),v(y,{key:t,prop:t,label:L,"show-overflow-tooltip":""},null,8,["prop","label"]))),128))]),_:1},8,["data"])),[[F,a(P)]]),c("div",Y,[l(S,{total:a(i).total,"current-page":a(i).currentPage,"onUpdate:current-page":e[4]||(e[4]=t=>a(i).currentPage=t),onCurrentChange:f},null,8,["total","current-page"]),l(g,{type:"primary",size:"small",onClick:z},{default:r(()=>[Z]),_:1})])]),_:1},8,["modelValue"])}}});var le=U($,[["__scopeId","data-v-3dfd57a5"]]);export{le as default};
|