lcny-vue3-antd-admin/dist/assets/week.6c2a462a.js

2 lines
3.7 KiB
JavaScript

var B=Object.defineProperty,D=Object.defineProperties;var S=Object.getOwnPropertyDescriptors;var k=Object.getOwnPropertySymbols;var T=Object.prototype.hasOwnProperty,E=Object.prototype.propertyIsEnumerable;var b=(o,t,e)=>t in o?B(o,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[t]=e,l=(o,t)=>{for(var e in t||(t={}))T.call(t,e)&&b(o,e,t[e]);if(k)for(var e of k(t))E.call(t,e)&&b(o,e,t[e]);return o},C=(o,t)=>D(o,S(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,aC as W,bP as Y,o as d,h as g,p as h,y as f,w as j,j as A,z as I,k as m,l as N,cu as v,eW as V,cI as U,eX as q}from"./index.80d5b8a7.js";import{u as z,B as K}from"./useTable.47f1515f.js";import{T as X}from"./useForm.c0be8dd2.js";import{u as G}from"./index.981c2363.js";import{P as H,c as J,s as L}from"./PriceDrawerWeek.f731ae88.js";import"./index.2eef3e03.js";import"./Checkbox.ecb61dd2.js";import"./index.f86fd20a.js";import"./index.b81c4f99.js";import"./index.9ed9a1ce.js";import"./index.72a1ec09.js";import"./useSize.18c36d63.js";import"./eagerComputed.2afcc68e.js";import"./onMountedOrActivated.9a4e7728.js";import"./useWindowSizeFn.dff138d1.js";import"./useContentViewHeight.1aa83691.js";import"./ArrowLeftOutlined.244b6f1a.js";import"./transButton.dd91eda9.js";import"./index.94cdeb5c.js";import"./index.d3965a8a.js";import"./index.936bcd03.js";import"./index.a1361fe8.js";import"./dateUtil.334acb5f.js";import"./_baseMerge.d787d49c.js";import"./_isIterateeCall.e28bc4c3.js";import"./_baseEach.db363ee6.js";import"./get.9ecf4090.js";import"./index.7365439b.js";import"./FullscreenOutlined.abcb6c9a.js";import"./index.a2f39e1a.js";import"./sortable.esm.2632adaa.js";import"./RedoOutlined.d76b2479.js";import"./index.d9c8bfa0.js";import"./fromPairs.84aabb58.js";import"./CaretUpOutlined.14988d42.js";import"./scrollTo.baf7def3.js";import"./index.d15bc2a6.js";import"./index.e3f23f17.js";import"./index.bfcaa235.js";import"./_baseIteratee.02af8ef8.js";import"./index.a94422d1.js";import"./useRefs.7ceb8caa.js";import"./download.2742eb39.js";import"./index.e3e998e3.js";import"./uniqBy.ea1eebc1.js";import"./index.27983812.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}]=z({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"),F=Y("auth");return d(),g("div",null,[h(m(K),{onRegister:m(n)},{toolbar:f(()=>[j((d(),A(p,{type:"primary",onClick:u},{default:f(()=>[I(" \u65B0\u589E ")]),_:1})),[[F,"endpoint.rice_shrimp_weekly_prices.create"]])]),bodyCell:f(({column:x,record:w})=>[x.key==="action"?(d(),g("div",M,[h(m(X),{actions:[{label:"\u7F16\u8F91",onClick:s.bind(null,w),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,w)}}]},null,8,["actions"])])):N("",!0)]),_:1},8,["onRegister"]),h(H,{onRegister:m(t),onSuccess:c},null,8,["onRegister"])])}}});var Xe=P(O,[["__scopeId","data-v-006cea55"]]);export{Xe as default};