1 |
- import{b as y,T as g}from"./baTable-MdxYOkAk.js";import{u as I,a as k,P as L}from"./popupForm-ho2k6TXO.js";import{T as w}from"./index-K8IR974I.js";import{a1 as v}from"./index-EwE51S_X.js";import{d as E,a2 as C,a as N,a1 as T,r as q,av as x,aJ as R,w as S,K as u,aq as U,e as n,f as z,u as o,y as m,C as i,j as l,L as p,N as A,t as D,i as P,am as B}from"./vue-A59npLRR.js";import"./index-r6iTpmP6.js";import"./validate-_EUdkMt3.js";import"./index-XALue448.js";import"./echarts-cxb9vJr1.js";const F={class:"default-main ba-table-box"},G={class:"table-header-operate-text"},Y=E({name:"user/moneyLog",__name:"index",setup(K){const{t:e}=C(),d=N(),b=T().query.user_id??"",t=q({userInfo:{}}),r=new y(new v(I),{column:[{type:"selection",align:"center",operator:!1},{label:e("Id"),prop:"id",align:"center",operator:"=",operatorPlaceholder:e("Id"),width:70},{label:e("user.moneyLog.User ID"),prop:"user_id",align:"center",width:70},{label:e("user.moneyLog.User name"),prop:"user.username",align:"center",operator:"LIKE",operatorPlaceholder:e("Fuzzy query")},{label:e("user.moneyLog.User nickname"),prop:"user.nickname",align:"center",operator:"LIKE",operatorPlaceholder:e("Fuzzy query")},{label:e("user.moneyLog.Change balance"),prop:"money",align:"center",operator:"RANGE",sortable:"custom"},{label:e("user.moneyLog.Before change"),prop:"before",align:"center",operator:"RANGE",sortable:"custom"},{label:e("user.moneyLog.After change"),prop:"after",align:"center",operator:"RANGE",sortable:"custom"},{label:e("user.moneyLog.remarks"),prop:"memo",align:"center",operator:"LIKE",operatorPlaceholder:e("Fuzzy query"),showOverflowTooltip:!0},{label:e("Create time"),prop:"create_time",align:"center",render:"datetime",sortable:"custom",operator:"RANGE",width:160}],dblClickNotEditColumn:["all"]},{defaultItems:{user_id:b,memo:""}},{},{onSubmit:()=>{s(r.comSearch.form.user_id)}});r.mount(),r.getIndex(),x("baTable",r);const s=a=>{a&&R(a)>0?k(a).then(c=>{t.userInfo=c.data.user}):t.userInfo={}};return s(r.comSearch.form.user_id),S(()=>r.comSearch.form.user_id,a=>{r.form.defaultItems.user_id=a,s(a)}),(a,c)=>{const f=u("el-alert"),h=u("el-button"),_=U("blur");return n(),z("div",F,[o(r).table.remark?(n(),m(f,{key:0,class:"ba-table-alert",title:o(r).table.remark,type:"info","show-icon":""},null,8,["title"])):i("",!0),l(w,{buttons:["refresh","add","comSearch","quickSearch","columnDisplay"],"quick-search-placeholder":o(e)("Quick search placeholder",{fields:o(e)("user.moneyLog.User name")+"/"+o(e)("user.moneyLog.User nickname")})},{default:p(()=>[o(A)(t.userInfo)?i("",!0):B((n(),m(h,{key:0,class:"table-header-operate"},{default:p(()=>[P("span",G,D(t.userInfo.username+"(ID:"+t.userInfo.id+") "+o(e)("user.moneyLog.balance")+":"+t.userInfo.money),1)]),_:1})),[[_]])]),_:1},8,["quick-search-placeholder"]),l(g,{ref_key:"tableRef",ref:d},null,512),l(L)])}}});export{Y as default};
|