lcny-vue3-antd-admin/dist/assets/index.ffd83ae2.js

2 lines
3.6 KiB
JavaScript

var k=Object.defineProperty,B=Object.defineProperties;var D=Object.getOwnPropertyDescriptors;var w=Object.getOwnPropertySymbols;var E=Object.prototype.hasOwnProperty,Y=Object.prototype.propertyIsEnumerable;var g=(r,e,t)=>e in r?k(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,l=(r,e)=>{for(var t in e||(e={}))E.call(e,t)&&g(r,t,e[t]);if(w)for(var t of w(e))Y.call(e,t)&&g(r,t,e[t]);return r},d=(r,e)=>B(r,D(e));var _=(r,e,t)=>new Promise((m,a)=>{var u=i=>{try{s(t.next(i))}catch(o){a(o)}},c=i=>{try{s(t.throw(i))}catch(o){a(o)}},s=i=>i.done?m(i.value):Promise.resolve(i.value).then(u,c);s((t=t.apply(r,e)).next())});import{J as R,a as S,aA as A,bN as N,o as f,h as v,p as h,x as y,w as j,j as V,y as I,k as n,l as U,cs as x,eL as G,cG as J,eM as K}from"./index.edc0759d.js";import{u as L,B as M}from"./useTable.0c2c6d52.js";import{T as W}from"./useForm.7f0ae6dc.js";import{u as q}from"./index.a0f5fb0c.js";import{T as z,c as H,s as O}from"./TownDrawer.a9e0756b.js";import"./index.259be51b.js";import"./Checkbox.21426845.js";import"./index.d81cdb5e.js";import"./index.14c1dc69.js";import"./index.18485147.js";import"./index.06eb6349.js";import"./useSize.1a6ae380.js";import"./eagerComputed.5106fd59.js";import"./onMountedOrActivated.45dfe467.js";import"./useWindowSizeFn.8be10011.js";import"./useContentViewHeight.0b992366.js";import"./ArrowLeftOutlined.727536a9.js";import"./transButton.0f38a3d6.js";import"./index.adbf4a0d.js";import"./index.debcb6b3.js";import"./index.111c4059.js";import"./index.ad97f9f1.js";import"./dateUtil.9d098b41.js";import"./_baseMerge.1131d091.js";import"./_isIterateeCall.31ed91a4.js";import"./_baseEach.8bca3c51.js";import"./get.9ede912b.js";import"./index.2b67a644.js";import"./FullscreenOutlined.219f2fe1.js";import"./index.abbd0c37.js";import"./sortable.esm.2632adaa.js";import"./RedoOutlined.8d3634d3.js";import"./index.18f69ddd.js";import"./fromPairs.84aabb58.js";import"./CaretUpOutlined.9c736fd9.js";import"./scrollTo.477b98df.js";import"./index.ac2947d4.js";import"./index.231a60da.js";import"./index.a048a7b7.js";import"./_baseIteratee.4b889e9a.js";import"./index.d03a2449.js";import"./useRefs.9a2b8e46.js";import"./download.8be5a7d1.js";import"./index.935fa161.js";import"./uniqBy.004e8f3d.js";import"./index.0b95b2ab.js";const P={key:0,class:"flex items-center justify-center"},Q=S({__name:"index",setup(r){const[e,{openDrawer:t}]=q(),[m,{reload:a}]=L({api:o=>_(this,null,function*(){o.year&&(o.year=J(o.year).format("YYYY"));const{data:C,meta:p}=yield K(d(l({},o),{type:2}));return{items:C,total:p==null?void 0:p.total}}),rowKey:"id",columns:H,formConfig:{labelWidth:120,schemas:O},useSearchForm:!0,showTableSetting:!0,bordered:!0,showIndexColumn:!0}),u=()=>{x.success("\u64CD\u4F5C\u6210\u529F"),a()},c=()=>{t(!0,{isUpdate:!1})},s=o=>{t(!0,d(l({},o),{isUpdate:!0}))},i=o=>_(this,null,function*(){yield G(o.id),x.success("\u5220\u9664\u6210\u529F"),a()});return(o,C)=>{const p=A("a-button"),F=N("auth");return f(),v("div",null,[h(n(M),{title:"\u57CE\u9547\u603B\u4EA7\u91CF",onRegister:n(m)},{toolbar:y(()=>[j((f(),V(p,{type:"primary",onClick:c},{default:y(()=>[I(" \u65B0\u589E ")]),_:1})),[[F,"endpoint.town_crops_output.create"]])]),bodyCell:y(({column:T,record:b})=>[T.key==="action"?(f(),v("div",P,[h(n(W),{actions:[{label:"\u7F16\u8F91",onClick:s.bind(null,b),auth:"endpoint.town_crops_output.edit"},{label:"\u5220\u9664",auth:"endpoint.town_crops_output.destroy",popConfirm:{title:"\u662F\u5426\u786E\u8BA4\u5220\u9664",placement:"topRight",confirm:i.bind(null,b)}}]},null,8,["actions"])])):U("",!0)]),_:1},8,["onRegister"]),h(z,{onRegister:n(e),onSuccess:u},null,8,["onRegister"])])}}});var Wt=R(Q,[["__scopeId","data-v-743fac10"]]);export{Wt as default};