"use strict";(self.webpackChunkwheelsmart_admin_react=self.webpackChunkwheelsmart_admin_react||[]).push([[5109],{85109:(e,a,s)=>{s.r(a),s.d(a,{default:()=>f});var t=s(65043),i=s(68493),n=s(5835),r=s(47419),l=s(11645),c=s(26655),d=s(5397),p=s(83003),m=s(60273),o=s(16876),h=s(53033),g=s(20541),u=s(59665),x=s(70579);const f=function(){const e=(0,p.wA)(),a=(0,m.MD)("masters","item").itemlist,s=((0,p.d4)((e=>e.masters.item.noofpages)),(0,p.d4)((e=>e.masters.item.listCount))),f=(0,p.d4)((e=>e.masters.item.itemParams)),A=(0,p.d4)((e=>e.masters.item.loading)),[j]=((0,p.d4)((e=>e.system.userAccessList)),i.A.useForm());(0,t.useEffect)((()=>{e((0,h.a0)({page:1,search:"",page_size:10}))}),[]);const w=[{title:"S.No",dataIndex:"index",width:"5%"},{title:"Name",render:e=>(0,x.jsx)("span",{children:null===e||void 0===e?void 0:e.name}),filterMode:"tree",filterSearch:!0,width:"30%"}],_=null===a||void 0===a?void 0:a.map(((e,a)=>({...e,index:(f.page-1)*f.page_size+a+1}))),{Search:v}=n.A;return(0,x.jsxs)(r.A,{gutter:[12,12],className:"hp-mt-32",children:[(0,x.jsx)(o.A,{prefix:"Masters",postfix:"item",pageTitle:"Item",goBack:!0}),(0,x.jsx)(l.A,{span:24,children:(0,x.jsx)(c.A,{children:(0,x.jsxs)(r.A,{children:[(0,x.jsx)(l.A,{span:12,xs:24,sm:24,md:12,className:"hp-mb-12",children:(0,x.jsx)(v,{placeholder:"Search...",allowClear:!0,onChange:a=>{""==a.target.value&&(e((0,h.a0)({...f,page:1,search:""})),e((0,u.if)({...f,page:1,search:""})))},onSearch:a=>{var s;s=a,e((0,u.if)({...f,page:1,search:s})),e((0,h.a0)({...f,page:1,search:s}))}})}),(0,x.jsx)(l.A,{span:24,children:(0,x.jsx)(d.A,{tip:"Loading...",spinning:A,delay:500,children:(0,x.jsx)(g.A,{page:f.page,count:s,pageSize:f.page_size,columns:w,data:_,loading:A,onPageChange:function(a,s){e((0,u.if)({...f,page_size:s,page:0==a?1:a})),e((0,h.a0)({...f,page_size:s,page:0==a?1:a}))},showTotal:function(e){return"Total "+e+" items"},scroll:!0})})})]})})})]})}}}]);
//# sourceMappingURL=5109.bdef61fa.chunk.js.map