lcny-vue3-antd-admin/dist/assets/week.28f8c53c.js

2 lines
3.7 KiB
JavaScript

var F=Object.defineProperty,x=Object.defineProperties;var E=Object.getOwnPropertyDescriptors;var w=Object.getOwnPropertySymbols;var S=Object.prototype.hasOwnProperty,T=Object.prototype.propertyIsEnumerable;var b=(o,t,e)=>t in o?F(o,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[t]=e,l=(o,t)=>{for(var e in t||(t={}))S.call(t,e)&&b(o,e,t[e]);if(w)for(var e of w(t))T.call(t,e)&&b(o,e,t[e]);return o},C=(o,t)=>x(o,E(t));var _=(o,t,e)=>new Promise((n,a)=>{var c=i=>{try{s(e.next(i))}catch(r){a(r)}},u=i=>{try{s(e.throw(i))}catch(r){a(r)}},s=i=>i.done?n(i.value):Promise.resolve(i.value).then(c,u);s((e=e.apply(o,t)).next())});import{q as P,a as R,aE as W,bP as Y,o as d,h as g,p as h,B as f,y as j,j as A,D as I,k as m,l as N,cu as v,eW as V,cI as U,eX as q}from"./index.ed5deffd.js";import{u as K,B as X}from"./useTable.0fe7b343.js";import{T as z}from"./useForm.501f3f59.js";import{u as G}from"./index.a73969f1.js";import{P as H,c as J,s as L}from"./PriceDrawerWeek.40defcc7.js";import"./index.57e79dcc.js";import"./Checkbox.0ade27c0.js";import"./index.dfe580e1.js";import"./index.271eb465.js";import"./index.0292c9d3.js";import"./index.78c12dec.js";import"./useSize.f4cf68f5.js";import"./eagerComputed.890ab31a.js";import"./onMountedOrActivated.9d9d02f7.js";import"./useWindowSizeFn.a262cec0.js";import"./useContentViewHeight.b8e37cbd.js";import"./ArrowLeftOutlined.9abfd432.js";import"./transButton.f4575a26.js";import"./index.d726974a.js";import"./index.8d83801a.js";import"./index.cf1b1f15.js";import"./index.afc21ce4.js";import"./dateUtil.91a9b59f.js";import"./_baseMerge.9fac86cf.js";import"./_isIterateeCall.779fe698.js";import"./_baseEach.aed94d5c.js";import"./get.b38b45ae.js";import"./index.5b432cd4.js";import"./FullscreenOutlined.a18420c1.js";import"./index.cca952d1.js";import"./sortable.esm.2632adaa.js";import"./RedoOutlined.a1f78ebd.js";import"./index.af1b13fa.js";import"./fromPairs.84aabb58.js";import"./CaretUpOutlined.51b9ef19.js";import"./scrollTo.707f46cf.js";import"./index.3b4e2932.js";import"./index.09a74575.js";import"./index.f6ae7164.js";import"./_baseIteratee.7c3a5712.js";import"./index.272fae53.js";import"./useRefs.045d664d.js";import"./download.b80ee91a.js";import"./index.c3b59272.js";import"./uniqBy.6fa12436.js";import"./index.141e5e7b.js";const M={key:0,class:"flex items-center justify-center"},O=R({__name:"week",setup(o){const[t,{openDrawer:e}]=G(),[n,{reload:a}]=K({title:"\u7A3B\u867E\u4EF7\u683C - \u5217\u8868",api:r=>_(this,null,function*(){r.year&&(r.year=U(r.year).format("YYYY"));const{data:y,meta:p}=yield q(l({},r));return{items:y,total:p==null?void 0:p.total}}),rowKey:"id",columns:J,formConfig:{labelWidth:120,schemas:L},useSearchForm:!0,showTableSetting:!0,bordered:!0,showIndexColumn:!0}),c=()=>{v.success("\u64CD\u4F5C\u6210\u529F"),a()},u=()=>{e(!0,{isUpdate:!1})},s=r=>{e(!0,C(l({},r),{isUpdate:!0}))},i=r=>_(this,null,function*(){yield V(r.id),v.success("\u5220\u9664\u6210\u529F"),a()});return(r,y)=>{const p=W("a-button"),B=Y("auth");return d(),g("div",null,[h(m(X),{onRegister:m(n)},{toolbar:f(()=>[j((d(),A(p,{type:"primary",onClick:u},{default:f(()=>[I(" \u65B0\u589E ")]),_:1})),[[B,"endpoint.rice_shrimp_weekly_prices.create"]])]),bodyCell:f(({column:D,record:k})=>[D.key==="action"?(d(),g("div",M,[h(m(z),{actions:[{label:"\u7F16\u8F91",onClick:s.bind(null,k),auth:"endpoint.rice_shrimp_weekly_prices.edit"},{label:"\u5220\u9664",auth:"endpoint.rice_shrimp_weekly_prices.destroy",popConfirm:{title:"\u662F\u5426\u786E\u8BA4\u5220\u9664",placement:"topRight",confirm:i.bind(null,k)}}]},null,8,["actions"])])):N("",!0)]),_:1},8,["onRegister"]),h(H,{onRegister:m(t),onSuccess:c},null,8,["onRegister"])])}}});var ze=P(O,[["__scopeId","data-v-006cea55"]]);export{ze as default};