1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9335],{35823:function(e){e.exports=function(e,t,n,a){var i=new Blob(void 0!==a?[a,e]:[e],{type:n||"application/octet-stream"});if(void 0!==window.navigator.msSaveBlob)window.navigator.msSaveBlob(i,t);else{var o=window.URL&&window.URL.createObjectURL?window.URL.createObjectURL(i):window.webkitURL.createObjectURL(i),r=document.createElement("a");r.style.display="none",r.href=o,r.setAttribute("download",t),void 0===r.download&&r.setAttribute("target","_blank"),document.body.appendChild(r),r.click(),setTimeout(function(){document.body.removeChild(r),window.URL.revokeObjectURL(o)},200)}}},66405:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/contact",function(){return n(31183)}])},50349:function(e,t,n){"use strict";var a=n(85893),i=n(83473),o=n(7851),r=n(76920),s=n(67294);let c=(0,s.forwardRef)((e,t)=>{let{url:n,search:c,pageSize:d=10,className:l,rowKey:u,pageSizeOptions:p=[10,20,50,100],setCustomLoading:h=()=>{},onLoad:g}=e,f={current:1,pageSize:d,pageSizeOptions:p,showSizeChanger:!0,showTotal:e=>"Total ".concat((0,i.W_)(e))}
1,[m,x]=(0,s.useState)([]),[j,w]=(0,s.useState)(!1),[v,y]=(0,s.useState)({pagination:f}),b=(e,t,n)=>{y({pagination:e,filters:t,...n})},Z=()=>{w(!0),h&&h(!0),n&&o.api.get(n,{params:{search:JSON.stringify(c),current:v.pagination.current,pageSize:v.pagination.pageSize,sort:v.field?"".concat(v.field,":").concat(v.order||"descend"):void 0}}).then(e=>{let{data:t,total:n}=e.data;w(!1),h&&h(!1),x(t),g&&"function"==typeof g&&g(e.data),y({...v,pagination:{...f,...v.pagination,total:n}})}).catch(e=>{w(!1),h&&h(!1)})};(0,s.useEffect)(()=>{Z()},[v.field,v.order,v.pagination.current,v.pagination.pageSize]);let _=(0,s.useRef)(!0);return(0,s.useEffect)(()=>{if(_.current){_.current=!1;return}v.pagination.current>1?y(e=>({...e,pagination:{...e.pagination,current:1}})):Z()},[c,n]),t&&(t.reload=Z,t.loading=j),(0,a.jsx)("div",{className:l,children:(0,a.jsx)(r.Z,{...e,rowKey:e=>"function"==typeof u?u(e):e.id||e._id,pagination:v.pagination,dataSource:m,loading:j,onChange:b,scroll:{x:!0}})})});t.Z=c},31183:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return Z}});var a=n(85893),i=n(67294),o=n(9008),r=n.n(o),s=n(11486),c=n(92477),d=n(71230),l=n(15746),u=n(4393),p=n(71577),h=n(50349),g=n(97175),f=n(27484),m=n.n(f),x=n(35823),j=n.n(x),w=n(7851);let{Search:v}=s.Z;var y=function(){let[e]=c.Z.useForm(),t={q:""},[n,o]=(0,i.useState)(t),[r,s]=(0,i.useState)(!1),f=()=>{s(!0),w.api.post("/api/customer",{},{responseType:"blob"}).then(e=>{s(!1);let t=m()().format("YYYYMMDD"),n=m()().unix();j()(e.data,"export-customer-".concat(t,"_").concat(n,".xlsx"))}).catch(e=>{var t;let{response:n}=e;(null==n?void 0:null===(t=n.data)||void 0===t?void 0:t.message)&¬ification.warning({message:null==n?void 0:n.data.message}),s(!1)})};return(0,a.jsx)(d.Z,{gutter:[16,16],children:(0,a.jsx)(l.Z,{span:24,children:(0,a.jsx)(u.Z,{title:"Daftar Kontak",style:{width:"100%"},children:(0,a.jsxs)(d.Z,{gutter:[16,16],children:[(0,a.jsx)(l.Z,{span:24,children:(0,a.jsx)(c.Z,{form:e,initialValues:t,onValuesChange:function(t){let n=e.getFieldsValue();t.search?setTimeout(()=>{let t=e.getFieldsValue();o(t)},1e3):o(n)},children:(0,a.jsxs)(d.Z,{justify:"space-between",gutter:[16,16],align:"middle",children:[(0,a.jsx)(l.Z,{xs:24,lg:12,children:(0,a.jsx)(p.ZP,{loading:r,onClick:f,icon:(0,a.jsx)(g.Z,{}),type:"primary",children:"Export"})}),(0,a.jsx)(l.Z,{xs:24,lg:6,children:(0,a.jsx)(c.Z.Item,{name:"q",noStyle:!0,children:(0,a.jsx)(v,{placeholder:"Cari Nama",enterButton:!0})})})]})})}),(0,a.jsx)(l.Z,{span:24,children:(0,a.jsx)(h.Z,{url:"/api/customer",columns:[{title:"Nama",dataIndex:"name",key:"name"},{title:"No. HP",dataIndex:"phone",key:"phone"},{title:"Alamat",dataIndex:"address",key:"address",render:(e,t)=>(0,a.jsxs)("div",{children:[(0,a.jsx)("div",{children:t.address}),(0,a.jsx)("div",{children:t.district_text})]})}],search:n})})]})})})})};function b(){return(0,a.jsxs)(i.Fragment,{children:[(0,a.jsxs)(r(),{children:[(0,a.jsx)("title",{children:"Customer"}),(0,a.jsx)("meta",{name:"Customer",content:"Customer Lincah.id"})]}),(0,a.jsx)("main",{children:(0,a.jsx)(y,{})})]})}b.layout="main";var Z=b}},function(e){e.O(0,[4310,4393,2808,5742,4533,6920,9774,2888,179],function(){return e(e.s=66405)}),_N_E=e.O()}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.