Sindbad~EG File Manager

Current Path : /home/infinitibizsol/public_html/auction-flow.com/static/js/
Upload File :
Current File : /home/infinitibizsol/public_html/auction-flow.com/static/js/265.37ceb70b.chunk.js

(self.webpackChunk_minimal_material_kit_react=self.webpackChunk_minimal_material_kit_react||[]).push([[265],{9686:(e,i,n)=>{"use strict";n.r(i),n.d(i,{default:()=>U});n(3536);var t=n(5043),l=n(9252),o=n(8911),s=n(5865),a=n(2110),r=n(8977),d=n(1637),c=n(9650),u=n(1806),h=n(3460),v=n(8076),x=n(2420),g=n(8185),p=n(8613),m=n(3336),A=n(7625),j=n(6446),f=n(1017),b=n.n(f),y=n(2450),_=n(2500),w=n(7894),k=n(3216),S=n(9588),C=n(9456),I=n(1036),D=n(3568),N=n(9907),R=n(3383),F=n(2812),V=n(5565),L=n(9276);var z=n(579);const T={position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:400,bgcolor:"background.paper",border:"2px solid black",borderRadius:2,boxShadow:24,p:4},U=()=>{const[e,i]=(0,t.useState)([]),n=(0,k.Zp)(),f=(0,C.wA)(),{userInfo:U}=(0,C.d4)((e=>e.auth)),{userData:B,filterType:E}=(0,C.d4)((e=>e.users)),[W,P]=(0,t.useState)(!1),{state:O}=(0,k.zy)();(0,t.useEffect)((()=>{O||n("/dashboard/opportunities");let e=[];"auctioneer"===E&&(e=[{id:"auctioneer",label:"Name",alignRight:!1},{id:"units",label:"Units",alignRight:!1},{id:"view",label:"View",alignRight:!1},{id:"action",label:"Action",alignRight:!1}]),"condition_light"===E&&(e=[{id:"conditionLight",label:"Condition Light"},{id:"conditionLightUnits",label:"Units"},{id:"viewConditionLight",label:"View"}]),"auction"===E&&(e=[{id:"auctionName",label:"Auction Name"},{id:"auctionUnits",label:"Units"},{id:"viewAuction",label:"View"}]),"sale_status"===E&&(e=[{id:"saleStatus",label:"Sale Status"},{id:"saleUnits",label:"Units"},{id:"viewSale",label:"View"}]),i(e)}),[B]);const Y=(e,i)=>{n("/dashboard/opportunities/users/cars",{state:{name:i,startDate:null===O||void 0===O?void 0:O.startDate,endDate:null===O||void 0===O?void 0:O.endDate,weekId:null===O||void 0===O?void 0:O.week,filterValue:"conditonLight",filterId:e.opportunity_id,filterData:e.condition_light}})},M=(e,i)=>{n("/dashboard/opportunities/users/cars",{state:{name:i,startDate:null===O||void 0===O?void 0:O.startDate,endDate:null===O||void 0===O?void 0:O.endDate,weekId:null===O||void 0===O?void 0:O.week,filterValue:"saleStatus",filterId:e.opportunity_id,filterData:"false"===e.sale_status?0:1}})},[H,G]=(0,t.useState)(!1),[q,K]=(0,t.useState)("asc"),[Z,J]=(0,t.useState)("name"),[Q,X]=(0,t.useState)(""),[$,ee]=(0,t.useState)([]),[ie,ne]=(0,t.useState)(!0),te=(0,L.b5)(B,(0,L.hz)(q,Z),Q),le=!(null!==te&&void 0!==te&&te.length)&&!!Q;return(0,z.jsx)(z.Fragment,{children:(0,z.jsxs)(l.A,{children:[(0,z.jsxs)(o.A,{direction:"row",alignItems:"flex-start",justifyContent:"space-between",children:[(0,z.jsxs)(s.A,{variant:"h4",sx:{mb:3},children:[null===O||void 0===O?void 0:O.startDate," - ",null===O||void 0===O?void 0:O.endDate]}),(0,z.jsx)(F.A,{loading:W,variant:"contained",color:"info",onClick:async()=>{P(!0);let e=[];const i=async i=>{try{var n;const t={headers:{"Content-Type":"application/json",Accept:"application/json"}},l=await V.A.post("".concat(S.VY,"/").concat(i),{userId:null===U||void 0===U?void 0:U.user_id,weekId:null===O||void 0===O?void 0:O.week},t);e=null===l||void 0===l||null===(n=l.data)||void 0===n?void 0:n.data}catch(t){return P(!1),void I.oR.error("Error while fetching details from DB!")}};"auctioneer"===E?await i("user/export-by-auctioneer"):"auction"===E?await i("user/export-by-auctions"):"condition_light"===E?await i("user/export-by-condition-light"):"sale_status"===E&&await i("user/export-by-sale-status");const{primary:n,secondary:t}={auctioneer:{primary:"Auctioneer's Business Name",secondary:["Auction Name","Condition Light","Sale Status","VIN","Vehicle Name","Color","Mileage","Announcements","Reserve","Sale Price","Total Fee","Lane","Run #"]},auction:{primary:"Auction Name",secondary:["Auctioneer's Business Name","Condition Light","Sale Status","VIN","Vehicle Name","Color","Mileage","Announcements","Reserve","Sale Price","Total Fee","Lane","Run #"]},condition_light:{primary:"Condition Light",secondary:["Auctioneer's Business Name","Auction Name","Sale Status","VIN","Vehicle Name","Color","Mileage","Announcements","Reserve","Sale Price","Total Fee","Lane","Run #"]},sale_status:{primary:"Sale Status",secondary:["Auctioneer's Business Name","Auction Name","Condition Light","VIN","Vehicle Name","Color","Mileage","Announcements","Reserve","Sale Price","Total Fee","Lane","Run #"]}}[E],l=[n,...t],o=[];o.push([...l]);const s=[];(0,L.lC)(e,E,o,s),((e,i,n)=>{const t=b().utils.book_new(),l=b().utils.aoa_to_sheet(e);l["!merges"]=i;const o=b().utils.decode_range(l["!ref"]);for(let d=o.s.r;d<=o.e.r;++d)for(let e=o.s.c;e<=o.e.c;++e){const i={r:d,c:e},n=b().utils.encode_cell(i);l[n]&&(l[n].s||(l[n].s={}),l[n].s.alignment={horizontal:"center",vertical:"center"})}for(let d=0;d<e[0].length;d++)l[b().utils.encode_cell({c:d,r:0})].s={font:{name:"Calibri",bold:!0,sz:12},alignment:{horizontal:"center"}};const s=e[0].map(((e,i)=>({wch:e.length+10})));l["!cols"]=s,b().utils.book_append_sheet(t,l,"Sheet1");const a=b().write(t,{bookType:"xlsx",type:"array"}),r=new Blob([a],{type:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=UTF-8"});y.saveAs(r,n+".xlsx")})(o,s,"Auctioneers and Cars Data"),P(!1)},children:"Export To Excel"})]}),(0,z.jsxs)(a.A,{children:[(0,z.jsxs)(o.A,{direction:"row",alignItems:"center",justifyContent:"space-between",margin:"0px 10px",children:[(0,z.jsx)(r.A,{variant:"contained",onClick:()=>{n("/dashboard/opportunities/add-auctioneer",{state:{weekId:null===O||void 0===O?void 0:O.week,startDate:null===O||void 0===O?void 0:O.startDate,endDate:null===O||void 0===O?void 0:O.endDate}})},children:"Submit to Sale"}),(0,z.jsxs)(o.A,{direction:"row",alignItems:"center",justifyContent:"space-between",children:[ie&&(0,z.jsx)(d.A,{}),(0,z.jsx)(w.H,{filterName:Q,weekId:null===O||void 0===O?void 0:O.week,userId:null===U||void 0===U?void 0:U.user_id,setLoader:ne})]})]}),(0,z.jsx)(_.A,{children:(0,z.jsx)(c.A,{sx:{maxHeight:"46vh"},children:(0,z.jsxs)(u.A,{size:"small",stickyHeader:!0,children:[(0,z.jsx)(w.K,{order:q,orderBy:Z,headLabel:e,rowCount:null===B||void 0===B?void 0:B.length}),ie?(0,z.jsx)(h.A,{children:[...Array(3)].map(((i,n)=>(0,z.jsx)(v.A,{children:null===e||void 0===e?void 0:e.map(((e,i)=>(0,z.jsx)(x.A,{children:(0,z.jsx)(g.A,{variant:"h1",sx:{fontSize:"2rem",borderRadius:"12px"}})},i)))},n)))}):(0,z.jsxs)(h.A,{children:[null===te||void 0===te?void 0:te.map(((e,i)=>{const{user_id:l,business_name:o,units:a,auction_id:d,auctioneer_id:c,auction_name:u}=e;return(0,z.jsx)(t.Fragment,{children:"auctioneer"===E?(0,z.jsxs)(v.A,{hover:!0,tabIndex:-1,role:"checkbox",children:[(0,z.jsx)(x.A,{align:"left",children:(0,z.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:"10px"},children:[(0,z.jsx)(p.A,{src:null!==e&&void 0!==e&&e.business_logo?"https://autocrm.infinitibizsol.com/images/"+(null===e||void 0===e?void 0:e.business_logo):"/assets/images/avatars/avatar_placeholder.png",alt:"autioneer_photo"}),o]})}),(0,z.jsx)(x.A,{align:"left",children:a}),(0,z.jsxs)(x.A,{align:"left",children:[(0,z.jsx)(r.A,{variant:"contained",onClick:()=>{return i=null===e||void 0===e?void 0:e.opportunity_id,t=c,void n("/dashboard/opportunities/users/cars",{state:{name:o,totalUnits:a,startDate:null===O||void 0===O?void 0:O.startDate,endDate:null===O||void 0===O?void 0:O.endDate,weekId:null===O||void 0===O?void 0:O.week,opportunity_id:i,filterValue:"auctioneer",filterId:i,auctioneerId:t}});var i,t},children:"View"})," "]}),(0,z.jsx)(x.A,{align:"left",children:(0,z.jsx)("img",{width:"40px",style:{cursor:"pointer"},alt:"Delete Auctioneer",src:D,onClick:()=>{G(!0),ee([null===e||void 0===e?void 0:e.auctioneer_id])}})})]},l):u?(0,z.jsxs)(v.A,{hover:!0,tabIndex:-1,role:"checkbox",children:[(0,z.jsx)(x.A,{align:"left",children:(0,z.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:"10px"},children:[(0,z.jsx)(p.A,{src:null!==e&&void 0!==e&&e.business_logo?"https://autocrm.infinitibizsol.com/images/"+(null===e||void 0===e?void 0:e.business_logo):"/assets/images/avatars/avatar_placeholder.png",alt:"autioneer_photo"}),u||""]})}),(0,z.jsx)(x.A,{align:"left",children:a}),(0,z.jsxs)(x.A,{align:"left",children:[(0,z.jsx)(r.A,{variant:"contained",onClick:()=>{return i=null===e||void 0===e?void 0:e.auction_id,void n("/dashboard/opportunities/users/cars",{state:{name:u,totalUnits:a,startDate:null===O||void 0===O?void 0:O.startDate,endDate:null===O||void 0===O?void 0:O.endDate,weekId:null===O||void 0===O?void 0:O.week,filterValue:"auction",filterId:i}});var i},children:"View"})," "]})]},d):"condition_light"===E?(0,z.jsxs)(z.Fragment,{children:[1===(null===e||void 0===e?void 0:e.condition_light)&&(0,z.jsxs)(v.A,{children:[(0,z.jsx)(x.A,{children:(0,z.jsxs)("div",{style:{display:"flex",alignItems:"center"},children:[(0,z.jsx)(R.A,{style:{color:"#FF0000",fontSize:"30px",marginRight:"5px"}}),(0,z.jsx)(s.A,{sx:{color:"#FF0000",fontWeight:"bold"},children:"Red Status"})]})}),(0,z.jsx)(x.A,{children:null===e||void 0===e?void 0:e.units}),(0,z.jsx)(x.A,{children:(0,z.jsx)("div",{children:(0,z.jsx)(r.A,{variant:"contained",onClick:()=>Y(e,"Red"),children:"View"})})})]}),2===(null===e||void 0===e?void 0:e.condition_light)&&(0,z.jsxs)(v.A,{children:[(0,z.jsx)(x.A,{children:(0,z.jsxs)("div",{style:{display:"flex",alignItems:"center"},children:[(0,z.jsx)(R.A,{style:{color:"#FFBF00",fontSize:"30px",marginRight:"5px"}}),(0,z.jsx)(s.A,{sx:{color:"#FFBF00",fontWeight:"bold"},children:"Yellow Status"})]})}),(0,z.jsx)(x.A,{children:null===e||void 0===e?void 0:e.units}),(0,z.jsx)(x.A,{children:(0,z.jsx)("div",{children:(0,z.jsx)(r.A,{variant:"contained",onClick:()=>Y(e,"Yellow"),children:"View"})})})]}),3===(null===e||void 0===e?void 0:e.condition_light)&&(0,z.jsxs)(v.A,{children:[(0,z.jsx)(x.A,{children:(0,z.jsxs)("div",{style:{display:"flex",alignItems:"center"},children:[(0,z.jsx)(R.A,{style:{color:"#008000",fontSize:"30px",marginRight:"5px"}}),(0,z.jsx)(s.A,{sx:{color:"#008000",fontWeight:"bold"},children:"Green Status"})]})}),(0,z.jsx)(x.A,{children:null===e||void 0===e?void 0:e.units}),(0,z.jsx)(x.A,{children:(0,z.jsx)("div",{children:(0,z.jsx)(r.A,{variant:"contained",onClick:()=>Y(e,"Green"),children:"View"})})})]}),4===(null===e||void 0===e?void 0:e.condition_light)&&(0,z.jsxs)(v.A,{children:[(0,z.jsx)(x.A,{children:(0,z.jsxs)("div",{style:{display:"flex",alignItems:"center"},children:[(0,z.jsx)(R.A,{style:{color:"gray",fontSize:"30px",marginRight:"5px"}}),(0,z.jsx)(s.A,{sx:{color:"gray",fontWeight:"bold"},children:"Not Provided"})]})}),(0,z.jsx)(x.A,{children:null===e||void 0===e?void 0:e.units}),(0,z.jsx)(x.A,{children:(0,z.jsx)("div",{children:(0,z.jsx)(r.A,{variant:"contained",onClick:()=>Y(e,"Not Provided"),children:"View"})})})]})]}):2===(null===B||void 0===B?void 0:B.length)?(0,z.jsxs)(z.Fragment,{children:["true"===(null===e||void 0===e?void 0:e.sale_status)&&(0,z.jsxs)(v.A,{children:[(0,z.jsx)(x.A,{children:(0,z.jsxs)("div",{style:{display:"flex",alignItems:"center"},children:[(0,z.jsx)(R.A,{style:{color:"#008000",fontSize:"30px",marginRight:"5px"}}),(0,z.jsx)(s.A,{sx:{color:"#008000",fontWeight:"bold"},children:"Sold"})]})}),(0,z.jsx)(x.A,{children:null===e||void 0===e?void 0:e.units}),(0,z.jsx)(x.A,{children:(0,z.jsx)("div",{children:(0,z.jsx)(r.A,{variant:"contained",onClick:()=>M(e,"Sold"),children:"View"})})})]}),"false"===(null===e||void 0===e?void 0:e.sale_status)&&(0,z.jsxs)(v.A,{children:[(0,z.jsx)(x.A,{children:(0,z.jsxs)("div",{style:{display:"flex",alignItems:"center"},children:[(0,z.jsx)(R.A,{style:{color:"#FF0000",fontSize:"30px",marginRight:"5px"}}),(0,z.jsx)(s.A,{sx:{color:"#FF0000",fontWeight:"bold"},children:"Not Sold"})]})}),(0,z.jsx)(x.A,{children:null===e||void 0===e?void 0:e.units}),(0,z.jsx)(x.A,{children:(0,z.jsx)("div",{children:(0,z.jsx)(r.A,{variant:"contained",onClick:()=>M(e,"Not Sold"),children:"View"})})})]})]}):null},i)})),!(null!==B&&void 0!==B&&B.length)>0&&(0,z.jsx)(v.A,{style:{height:53},children:(0,z.jsx)(x.A,{align:"center",colSpan:6,sx:{py:5},children:(0,z.jsx)(m.A,{sx:{textAlign:"center"},children:(0,z.jsx)(s.A,{variant:"h4",paragraph:!0,children:"No results found"})})})})]}),le&&!ie&&(0,z.jsx)(h.A,{children:(0,z.jsx)(v.A,{children:(0,z.jsx)(x.A,{align:"center",colSpan:6,sx:{py:3},children:(0,z.jsxs)(m.A,{sx:{textAlign:"center"},children:[(0,z.jsx)(s.A,{variant:"h6",paragraph:!0,children:"Not found"}),(0,z.jsxs)(s.A,{variant:"body2",children:["No results found for \xa0",(0,z.jsxs)("strong",{children:['"',Q,'"']}),".",(0,z.jsx)("br",{})," Try checking for typos or using complete words."]})]})})})})]})})}),(0,z.jsx)(A.A,{open:H,onClose:()=>G(!1),"aria-labelledby":"modal-modal-title","aria-describedby":"modal-modal-description",children:(0,z.jsxs)(j.A,{sx:T,children:[(0,z.jsx)(s.A,{id:"modal-modal-title",variant:"h6",component:"h2",sx:{color:"#1976D2",mb:1,textAlign:"center"},children:"Are you sure you want to remove"}),(0,z.jsx)(s.A,{id:"modal-modal-description",variant:"h6",component:"h2",align:"center",children:"this Auctioneer?"}),(0,z.jsxs)(o.A,{spacing:2,direction:"row",justifyContent:"center",alignItems:"flex-end",sx:{mt:2},children:[(0,z.jsx)(r.A,{variant:"contained",style:{width:"150px",backgroundColor:"#E53935",borderRadius:"30px",color:"white",marginRight:"8px",fontWeight:"bold"},onClick:async()=>{if($.length>0)try{G(!1);const e={headers:{"Content-Type":"application/json"}},{data:i}=await V.A.post("".concat(S.VY,"/user/remove-auctioneer-from-opportunity"),{auctioneer_ids:$,weekId:null===O||void 0===O?void 0:O.week,user_id:null===U||void 0===U?void 0:U.user_id},e);if(i)return f((0,N.Np)({userId:null===U||void 0===U?void 0:U.user_id,weekId:null===O||void 0===O?void 0:O.week})),void I.oR.success("Auctioneer removed successfully!")}catch(e){console.log(e),G(!1),I.oR.error("Error while removing Auctioneer!")}console.log("Deleted!")},children:"Yes"}),(0,z.jsx)(r.A,{variant:"contained",style:{width:"150px",backgroundColor:"#4CAF50",borderRadius:"30px",color:"white",fontWeight:"bold"},onClick:()=>G(!1),children:"No"})]})]})})]})]})})}},9276:(e,i,n)=>{"use strict";n.d(i,{In:()=>u,b5:()=>a,hz:()=>s,lC:()=>c});var t=n(3536),l=n(8421);function o(e,i,n){return i[n]<e[n]?-1:i[n]>e[n]?1:0}function s(e,i){return"desc"===e?(e,n)=>o(e,n,i):(e,n)=>-o(e,n,i)}function a(e,i,n){const l=null===e||void 0===e?void 0:e.map(((e,i)=>[e,i]));return null===l||void 0===l||l.sort(((e,n)=>{const t=i(e[0],n[0]);return 0!==t?t:e[1]-n[1]})),n?(0,t.filter)(e,(e=>{var i;return-1!==(null===e||void 0===e||null===(i=e.firstname)||void 0===i?void 0:i.toLowerCase().indexOf(n.toLowerCase()))})):null===l||void 0===l?void 0:l.map((e=>e[0]))}const r=e=>1===e?"Red":2===e?"Yellow":3===e?"Green":"Not Provided",d=e=>!0===e?"SOLD":"NOT SOLD";function c(e,i,n,t){if(!e||!e.length)return[];let l=1,o=1;null===e||void 0===e||e.forEach((e=>{const s=[...null===e||void 0===e?void 0:e.tblVehicles];if(s.length){let a=!1,c=!1;s.forEach((l=>{const s=(null===l||void 0===l?void 0:l.vehicles)||[];if(s.length){const u=s.length;s.length>0&&(null===s||void 0===s||s.map((t=>{const o=["","",null===t||void 0===t?void 0:t.vin,"".concat((null===t||void 0===t?void 0:t.year)||""," ").concat((null===t||void 0===t?void 0:t.make)||""," ").concat((null===t||void 0===t?void 0:t.model)||""," ").concat((null===t||void 0===t?void 0:t.trim)||""),null===t||void 0===t?void 0:t.color_name,null===t||void 0===t?void 0:t.mileage,null===t||void 0===t?void 0:t.announcements,null===t||void 0===t?void 0:t.reserve,null===t||void 0===t?void 0:t.sale_price,null===t||void 0===t?void 0:t.vehicle_total_fee,null===t||void 0===t?void 0:t.lane_name,null===t||void 0===t?void 0:t.run_no];"auctioneer"===i?(a||(o[0]=null===e||void 0===e?void 0:e.auctioneer_business_name),o[1]=null===t||void 0===t?void 0:t.auction_name,o.splice(2,0,r(null===t||void 0===t?void 0:t.condition_light),d(null===t||void 0===t?void 0:t.sale_status))):"auction"===i?(a||(o[0]=null===e||void 0===e?void 0:e.auction_name),c||(o[1]=null===l||void 0===l?void 0:l.auctioneer_business_name),o.splice(2,0,r(null===l||void 0===l?void 0:l.condition_light),d(null===l||void 0===l?void 0:l.sale_status),null===e||void 0===e?void 0:e.business_name)):"condition_light"===i?(a||(o[0]=r(null===e||void 0===e?void 0:e.condition_light)),c||(o[1]=null===l||void 0===l?void 0:l.auctioneer_business_name),o.splice(2,0,null===t||void 0===t?void 0:t.auction_name,d(null===t||void 0===t?void 0:t.sale_status))):"sale_status"===i&&(a||(o[0]=d(null===e||void 0===e?void 0:e.sale_status)),c||(o[1]=null===l||void 0===l?void 0:l.auctioneer_business_name),o.splice(2,0,null===t||void 0===t?void 0:t.auction_name,r(null===t||void 0===t?void 0:t.condition_light))),a||(a=!0),c||(c=!0),n.push(o)}))),"auctioneer"!==i&&(t.push({s:{r:o,c:1},e:{r:o+u-1,c:1}}),o+=u)}})),n.length>1&&(t.push({s:{r:l,c:0},e:{r:n.length-1,c:0}}),l=n.length)}console.log("\ud83d\ude80 ~ _vehicles?.map ~ data:",n)}))}const u=e=>{if(!e)return null;const i=e.toDate(),n=(0,l.tq)(i);let{day:t,week:o,year:s}=n;const a=new Date(s,0,1),r=a.getDay();let d=1;7===t&&(d=0);const c=new Date(a-24*r*60*60*1e3+7*(o-d)*24*60*60*1e3),u=new Date(c);u.setDate(c.getDate()+6);return{week:o,startDate:c.toLocaleDateString("en-US",{month:"short",day:"numeric"}),endDate:u.toLocaleDateString("en-US",{month:"short",day:"numeric"})}}},7894:(e,i,n)=>{"use strict";n.d(i,{K:()=>a,H:()=>y});var t=n(4882),l=n(8076),o=n(2420),s=n(579);function a(e){let{order:i,orderBy:n,rowCount:a,headLabel:r,numSelected:d,onRequestSort:c,onSelectAllClick:u}=e;return(0,s.jsx)(t.A,{children:(0,s.jsx)(l.A,{children:r.map(((e,t)=>(0,s.jsx)(o.A,{align:e.alignRight?"right":"left",sortDirection:n===e.id&&i,children:e.label},t)))})})}var r=n(4535),d=n(5263),c=n(5865),u=n(5869),h=n(5043),v=n(8977),x=n(688),g=n(2143),p=n(9456),m=n(9907),A=n(3178);const j=[{value:"auctioneer",label:"Auctioneer"},{value:"auction",label:"Auction"},{value:"condition_light",label:"Condition Light"},{value:"sale_status",label:"Sale Status"}];function f(e){let{weekId:i,userId:n,setLoader:t}=e;const[l,o]=(0,h.useState)(null),[a,r]=(0,h.useState)("auctioneer"),d=(0,p.wA)(),{filterType:f}=(0,p.d4)((e=>e.users)),b=(e,l)=>{t(!0),"auctioneer"===e?d((0,m.Np)({userId:n,weekId:i})).finally((()=>t(!1))):"auction"===e?d((0,m.x1)({user_id:n,week_id:i})).finally((()=>t(!1))):"condition_light"===e?d((0,m.S4)({user_id:n,week_id:i})).finally((()=>t(!1))):"sale_status"===e&&d((0,m.yh)({user_id:n,week_id:i})).finally((()=>t(!1))),r(l),d((0,A.T)(e)),o(null)};(0,h.useEffect)((()=>{const e=j.find((e=>e.value===f)),i=e?e.label:"Auctioneer";b(f||"auctioneer",i)}),[]);return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)(v.A,{color:"inherit",disableRipple:!0,onClick:e=>{o(e.currentTarget)},endIcon:(0,s.jsx)(u.A,{icon:l?"eva:chevron-up-fill":"eva:chevron-down-fill"}),children:["Filter by \xa0",(0,s.jsx)(c.A,{component:"span",variant:"subtitle2",sx:{color:"text.secondary"},children:a})]}),(0,s.jsx)(x.A,{keepMounted:!0,anchorEl:l,open:Boolean(l),onClose:()=>{o(null)},anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},children:j.map((e=>(0,s.jsx)(g.A,{selected:e.value===a,onClick:()=>b(e.value,e.label),sx:{typography:"body2"},children:e.label},e.value)))})]})}const b=(0,r.Ay)(d.A)((e=>{let{theme:i}=e;return{height:60,display:"flex",justifyContent:"flex-end",padding:i.spacing(0,1,0,3)}}));function y(e){let{numSelected:i,weekId:n,userId:t,setLoader:l}=e;return(0,s.jsx)(b,{sx:{...i>0&&{color:"primary.main",bgcolor:"primary.lighter"}},children:i>0?(0,s.jsxs)(c.A,{component:"div",variant:"subtitle1",children:[i," selected"]}):(0,s.jsx)(s.Fragment,{children:(0,s.jsx)(f,{weekId:n,userId:t,setLoader:l})})})}},3568:(e,i,n)=>{"use strict";e.exports=n.p+"static/media/trash.5795bffc2e3ba17cfc33.png"},1976:()=>{},1581:()=>{}}]);
//# sourceMappingURL=265.37ceb70b.chunk.js.map

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists