Files
appco_dist/.output/public/_nuxt/BX9gx1np.js
T

2 lines
21 KiB
JavaScript
Raw Normal View History

2026-02-22 22:14:30 +03:30
import{B as M}from"./QUhGCrSp.js";import{_ as V}from"./Daapjrxw.js";import{d as N,H as E,r as y,I as Y,a0 as F,af as j,o as L,z as _,G as m,E as r,B as i,C as p,K as e,D as a,S as z,dI as T,F as B,ed as Z,T as f,Q as G,J as X,a3 as U,a8 as D,u as ee,A,a9 as $}from"./-RbsLPyt.js";import{B as O}from"./6Xh9SRKr.js";import{B as H}from"./CnXnMz5t.js";import{S as W}from"./CcrdeB0W.js";import{F as J}from"./B8TsKvIX.js";import{_ as K}from"./DOsrpEZB.js";import{_ as Q}from"./DGy_5tDw.js";import{_ as q}from"./DlAUqK2U.js";import{B as te}from"./DmfaORC9.js";import{M as h}from"./CXyls3LY.js";import{C as se}from"./C-LfAiQ0.js";import"./Q8yYtUDy.js";import{_ as ae,R as le}from"./RQgNmPBP.js";/* empty css */import"./CscEAC8U.js";import"./CE83mZdK.js";import"./CjY-7I2W.js";import"./JJQK7i5c.js";import"./Wcw3J8fd.js";import"./Dq5x3n6V.js";import"./DLiMuej2.js";import"./Bl7vIxJP.js";import"./BLP1giO7.js";import"./CD5vwehm.js";import"./D-LfK-bl.js";import"./CXbftn7q.js";import"./B1y7omzc.js";import"./CeGdre4t.js";import"./Cv9XbkGK.js";import"./DcdAEMdF.js";import"./Cj99RmFE.js";import"./BdGZJXoD.js";import"./Ckb9ma-L.js";import"./CYkCc_Wi.js";import"./DSAq_11H.js";import"./Cr1VzkIV.js";const ie={class:"h-30vh px-5 mt3"},ne={class:"font-semibold text-xl"},oe={class:"mt5 rounded-xl border-gray-200 border-1px py-2"},re={class:"flex justify-between"},ue=N({__name:"TaxAndSilverProfit",props:{open:{type:Boolean}},emits:["update:open"],setup(P,{emit:o}){const n=E(),d=y(null);y("default");const c=Y(),C=P,x=o,t=y({has_silver_tax:!1,tax_silver_profit:0});F(C,v=>{v.open?b():k()});async function b(){await j(),await d.value?.setOpen()}async function k(){await j(),await d.value?.setClose(),x("update:open",!1)}function l(){console.log(c.user),t.value.has_silver_tax=!!c.user?.has_silver_tax,t.value.tax_silver_profit=c.user?.tax_silver_profit??0}async function w(){try{t.value.tax_silver_profit&&parseInt(t.value.tax_silver_profit),z.value=!0,await Z({id:c.user.id,...t.value}),await k()}catch(v){console.log(v)}finally{z.value=!1}}return L(()=>{l()}),(v,s)=>{const S=Q,g=K,R=J,I=W;return _(),m(M,{title:"",ref_key:"sheetRef",ref:d,headerCls:"",closeOnClickOutside:"",onOnClickOutside:s[2]||(s[2]=u=>x("update:open",!1))},{header:r(()=>[s[3]||(s[3]=i("div",{flex:"","justify-center":"","items-center":"","flex-col":"","p-2":""},[i("div",{"bg-gray-500":"","h-2px":"","w-2.5rem":""})],-1)),i("div",null,[a(V,{class:"w-1rem mt-5 ms-5",onClick:k})])]),default:r(()=>[i("div",ie,[i("div",ne,p(e(n).useString("specifySilverTaxAndProfit")),1),i("div",oe,[a(I,{spinning:e(z)},{default:r(()=>[a(R,{ref:"formRef",model:t.value,autocomplete:"off",layout:"vertical"},{default:r(()=>[a(g,{name:"has_silver_tax"},{default:r(()=>[i("div",re,[i("span",null,p(e(n).useString("hasTax")),1),a(S,{class:"h-6",checked:t.value.has_silver_tax,"onUpdate:checked":s[0]||(s[0]=u=>t.value.has_silver_tax=u),"checked-children":e(n).useString("enable"),"un-checked-children":e(n).useString("disable")},null,8,["checked","checked-children","un-checked-children"])])]),_:1}),a(g,{label:e(n).useString("profit"),name:"profit"},{default:r(()=>[a(O,{value:t.value.tax_silver_profit,"onUpdate:value":s[1]||(s[1]=u=>t.value.tax_silver_profit=u),type:"number","addon-before":"%",onClick:e(T)},null,8,["value","onClick"])]),_:1},8,["label"]),a(H,{size:"50px",block:"",type:"primary",onClick:w},{default:r(()=>[B(p(e(n).useString("submit")),1)]),_:1})]),_:1},8,["model"])]),_:1},8,["spinning"])])])]),_:1},512)}}}),de=Object.assign(q(ue,[["__scopeId","data-v-c071ba2a"]]),{__name:"TaxAndSilverProfit"}),ce={class:"flex items-center pb-2 relative"},pe={class:"font-semibold text-xl absolute w-full text-center"},_e={class:"h-40vh px-5 mt3 overflow-y-auto pb-20"},ve={class:"mt5 rounded-xl border-gray-200 border-1px py-2"},ge={class:"flex justify-between"},he={class:"flex justify-between"},fe={class:"flex justify-between"},me={class:"flex justify-between"},ye={class:"flex justify-between"},xe={class:"flex justify-between"},ke={class:"flex justify-between"},be={class:"fixed bottom-0 right-0 left-0 p-2"},Se=N({__name:"GatewaysMo