PageSourceSearch

https://disktyre.ru/_next/static/chunks/6756-2dce3e1faafdbf5c.js

js disktyre.ru collected 2026-10-08 14:06:47 UTC 11,552 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6756],{86413:function(e,n,a){"use strict";a.d(n,{Z:function(){return o}});var r=a(85893),t=a(67294),s=a(41664),i=a.n(s),l=a(25934),c=a(8146),d=a.n(c);function o(e){let{links:n=[],product:a=null}=e,s=(null==a?void 0:a.category)||"",c=s.includes("Шины/Легковые"),o=s.includes("Диски/Легковые"),u=[];if(a){let{category:e,width:n,height:r,diameter:t,title:s,bolts:i,pcd:l,dia:d,model:h,vendor:m}=a;if(e&&u.push(...e.split("/").map(e=>({name:e}))),c||o){let a=null;c&&(e.includes("Зимние")&&(a="Зима"),e.includes("Летние")&&(a="Лето"));let s=null;if(o&&(e.includes("Литые")&&(s="Литой"),e.includes("Штампованные")&&(s="Штампованный")),m&&u.push({name:m,link:"/catalog/".concat(c?"tires":"disks","?brand=").concat(m)}),h&&u.push({name:h,link:"/catalog/".concat(c?"tires":"disks","?model=").concat(h)}),c&&n&&r&&t){let e="?width=".concat(n,"&height=").concat(r,"&dia=").concat(t);a&&(e+="&season=".concat(a)),u.push({name:"".concat(n,"/").concat(r," R").concat(t),link:"/catalog/tires".concat(e)})}if(o&&t&&i&&l&&d){let e="?diameter=".concat(t,"&bolts=").concat(i,"&pcd=").concat(l,"&dia=").concat(d);s&&(e+="&type=".concat(s)),u.push({name:"".concat(t," ").concat(i,"x").concat(l," ").concat(d),link:"/catalog/disks".concat(e)})}}s&&u.push({name:s})}return(0,r.jsx)("div",{className:"container",children:(0,r.jsxs)("div",{className:d().breadcrumbs,children:[(0,r.jsx)(i(),{href:"/",children:"Главная"},(0,l.Z)()),[...n,...u].map(e=>{var n;let a=(null==e?void 0:null===(n=e.link)||void 0===n?void 0:n.startsWith("/"))?e.link:"/".concat(e.link);return(null==e?void 0:e.link)?(0,r.jsxs)(t.Fragment,{children:[(0,r.jsx)("span",{children:"\xa0>\xa0"}),(0,r.jsx)(i(),{href:a,children:e.name})]},(0,l.Z)()):(0,r.jsxs)(t.Fragment,{children:[(0,r.jsx)("span",{children:"\xa0>\xa0"}),(0,r.jsx)("span",{children:e.name})]},(0,l.Z)())})]})})}},28073:function(e,n,a){"use strict";a.d(n,{Z:function(){return S}});var r=a(85893),t=a(67294),s=a(93454),i=a(76592),l=a(19827),c=a(8863),d=a(25026),o=a(70360),u=a(55355),h=a(46577),m=a(81873),p=a(4336),_=a(41664),f=a.n(_),x=a(15722),v=a(66676),j=a(19781),b=a(67451),k=a.n(b);let y=(e,n,a)=>{if(e.format&&"number"==typeof n)return e.format(n);if("order"===e.id)return(0,r.jsx)(f(),{href:"/panel/orders/".concat(a.id),children:(0,r.jsx)(p.Z,{size:"small",variant:"outlined",children:"Смотреть"})});if("status"===e.id||"accepted"===e.id)return n;if("phone"===e.id)return(0,r.jsx)("span",{style:{whiteSpace:"nowrap"},children:n.replace(/[^\d]/g,"").replace(/^(\d{1})(\d{3})(\d{3})(\d{2})(\d{2})$/,"+$1 ($2) $3-$4-$5")});if("date"===e.id){let e=new Date(n);return new Intl.DateTimeFormat("ru-RU",{day:"2-digit",month:"short",year:"numeric"}).format(e)}if("total"===e.id)return new Intl.NumberFormat("ru-RU",{style:"decimal",currency:"RUB"}).format(n);if("stores"===e.id){let e=n.split(",");return(0,r.jsx)("div",{className:k().storesBox,children:e.map((e,n)=>(0,r.jsx)(m.Z,{label:(0,j.Z)(e),variant:"outlined",size:"small"},n))})}return n},g=new Intl.NumberFormat("ru-RU",{style:"decimal",currency:"RUB"});function S(e){let{}=e,[n,a]=(0,t.useState)([]),[m,p]=(0,t.useState)(0),[_,f]=(0,t.useState)(10),[j,b]=(0,t.useState)(0),[S,P]=(0,t.useState)(0),[I,N]=(0,t.useState)(0),[Z,w]=(0,t.useState)(0),[O,R]=(0,t.useState)(0),[M,B]=(0,t.useState)(0),[K,W]=(0,t.useState)(0),[z,U]=(0,t.useState)(0),T=async()=>{let e=await fetch("/api/orders"),n=await e.json(),r=n.filter(e=>"cancelled"!=e.status),t=n.filter(e=>"cancelled"==e.status),s=r.length,i=r.reduce((e,n)=>e+n.count,0),l=r.reduce((e,n)=>e+n.total,0);b(s),P(i),N(l),w(l/s);let c=t.length,d=t.reduce((e,n)=>e+n.count,0),o=t.reduce((e,n)=>e+n.total,0);R(c),B(d),W(o),U(o/c),a(n.map(e=>{let n=Array.from(new Set(e.products.flatMap(e=>e.order.map(e=>e.store)))).join(", ");return{...e,paymentStatus:(0,v.Z)(e.paymentStatus),status:(0,x.Z)(e.status),stores:n,accepted:e.acceptedby_name?e.acceptedby_name:"Никто"}}))};(0,t.useEffect)(()=>{T()},[]);let D=[{id:"id",label:"№",minWidth:70},{id:"order",label:"Действие",minWidth:70},{id:"stores",label:"Склад",minWidth:100},{id:"status",label:"Статус",minWidth:100},{id:"date",label:"Дата",minWidth:170},{id:"accepted",label:"Кто взял",minWidth:170},{id:"count",label:"Шт",minWidth:80},{id:"total",label:"Сумма",minWidth:100},{id:"firstname",label:"Клиент",minWidth:130},{id:"phone",label:"Телефон",minWidth:170}];return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("h2",{children:"Список заказов"}),(0,r.jsxs)("div",{className:k().successOrdersInfo,children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"Успешных заказов"}),": ",j]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"Продано товаров"}),": ",S]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"На сумму"}),": ",g.format(Math.round(I))," ₽"]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"Средний чек"}),": ",g.format(Math.round(Z))," ₽"]})]}),(0,r.jsxs)("div",{className:k().cancelledOrdersInfo,children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"Отмененных заказов"}),": ",O]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"Не продано товаров"}),": ",M]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"На сумму"}),": ",g.format(Math.round(K))," ","₽"]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"Средний чек"}),": ",g.format(Math.round(z))," ","₽"]})]}),(0,r.jsxs)("div",{className:k().summaryOrdersInfo,children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"Всего заказов"}),": ",O+j]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"Всего товаров"}),":"," ",M+S]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"На сумму"}),":"," ",g.format(Math.round(K+I)),"₽"]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("b",{children:"Средний чек"}),":"," ",g.format(Math.round(z+Z)),"₽"]})]}),(0,r.jsxs)(s.Z,{sx:{width:"100%",overflow:"hidden"},children:[(0,r.jsx)(d.Z,{sx:{},children:(0,r.jsxs)(i.Z,{stickyHeader:!0,"aria-label":"sticky table",children:[(0,r.jsx)(o.Z,{children:(0,r.jsx)(h.Z,{children:D.map((e,n)=>(0,r.jsx)(c.Z,{align:e.align,style:{minWidth:e.minWidth},children:e.label},n))})}),(0,r.jsx)(l.Z,{children:n.slice(m*_,m*_+_).map(e=>
1(0,r.jsx)(h.Z,{hover:!0,role:"checkbox",tabIndex:-1,children:D.map((n,a)=>{let t=e[n.id];return(0,r.jsx)(c.Z,{align:n.align,children:y(n,t,e)},a)})},e.code))})]})}),(0,r.jsx)(u.Z,{rowsPerPageOptions:[10,25,100],component:"div",count:n.length,rowsPerPage:_,labelRowsPerPage:"Строк на странице",labelDisplayedRows:function(e){let{from:n,to:a,count:r}=e;return"".concat(n,"–").concat(a," из ").concat(-1!==r?r:"> чем ".concat(a))},page:m,onPageChange:(e,n)=>{p(n)},onRowsPerPageChange:e=>{f(+e.target.value),p(0)}})]}),n.length<1&&(0,r.jsx)("p",{children:"Заказов нет"})]})}},40886:function(e,n,a){"use strict";a.d(n,{Z:function(){return d}});var r=a(85893),t=a(41664),s=a.n(t),i=a(11163),l=a(88882),c=a.n(l);function d(){let e=(0,i.useRouter)().pathname;return(0,r.jsxs)("div",{className:c().panelNavbar,children:[(0,r.jsx)("div",{children:(0,r.jsx)(s(),{href:"/panel",className:"/panel"===e?c().active:"",children:"Заказы"})}),(0,r.jsx)("div",{children:(0,r.jsx)(s(),{href:"/panel/clients",className:"/panel/clients"===e?c().active:"",children:"Клиенты"})}),(0,r.jsx)("div",{children:(0,r.jsx)(s(),{href:"/panel/banners",className:"/panel/banners"===e?c().active:"",children:"Баннеры"})}),(0,r.jsx)("div",{children:(0,r.jsx)(s(),{href:"/panel/labels",className:"/panel/labels"===e?c().active:"",children:"Ценники"})}),(0,r.jsx)("div",{children:(0,r.jsx)(s(),{href:"/panel/tracking",className:"/panel/tracking"===e?c().active:"",children:"Отслеживание"})}),(0,r.jsx)("div",{children:(0,r.jsx)(s(),{href:"/panel/monitoring",className:"/panel/monitoring"===e?c().active:"",children:"Мониторинг"})}),(0,r.jsx)("div",{children:(0,r.jsx)(s(),{href:"/panel/sellout",className:"/panel/sellout"===e?c().active:"",children:"Распродажа"})})]})}},31247:function(e,n,a){"use strict";a.d(n,{Z:function(){return i}});var r=a(85893),t=a(60198),s=a.n(t);function i(e){let{children:n}=e;return(0,r.jsx)("div",{className:s().content,children:n})}},15722:function(e,n,a){"use strict";function r(e){return"process"===e?"В\xa0работе":"transported"===e?"В\xa0пути\xa0до\xa0клиента":"completed"===e?"Выполнен":"cancelled"===e?"Отменен":void 0}a.d(n,{Z:function(){return r}})},66676:function(e,n,a){"use strict";function r(e){return"paid"===e?"Оплачен":"prepaid"===e?"Оплачен\xa0частично":"notpaid"===e?"Не\xa0оплачен":void 0}a.d(n,{Z:function(){return r}})},19781:function(e,n,a){"use strict";function r(e){var n;return null!==(n=({pauer_samara:"ПауэрСамара",pauer_dav:"pauer_dav",pauer_kaz:"pauer_kaz",pauer_kuch:"pauer_kuch",pauer_MSK:"ПауэрМСК",pauer_MSK2:"ПауэрМСК2",pauer_MSK3:"pauer_MSK3",pauer_MSK15:"pauer_MSK15",SLTLT:"Слик ТЛТ",DSK:"DSK",KDKz:"КД НЧ",KDSM:"КД Сам",КОЛВид:"Колекс Вид",КОЛДем:"Колекс Дем",КОЛДемР:"Колекс Дем Розн",КОЛФизкР:"Колекс Физк роз",КОЛФизк:"Колекс Физк.",RS:"Римэкс",SeverSam:"Север Самара",КОЛТ:"Колобокс Тлт",kievskaya:"Киевская",kievskaya_sammb_oh:"КиевскаяСевер",kievskaya_pauer_oh:"КиевскаяПауэр",kievskaya_kd_oh:"КиевскаяКД",antoshka:"АнтоноваОвсеенко",antoshka_pauer_oh:"АнтоноваОвсеенкоПауэр",antoshka_kd_oh:"АнтоноваОвсеенкоКД",demokraticheskaya:"Демократическая",demokraticheskaya_sammb_oh:"ДемократическаяСевер",demokraticheskaya_pauer_oh:"ДемократическаяПауэр",demokraticheskaya_kd_oh:"ДемократическаяКД",lvovskaya:"Львовская",lvovskaya_sammb_oh:"ЛьвовскаяСевер",lvovskaya_pauer_oh:"ЛьвовскаяПауэр",lvovskaya_kd_oh:"ЛьвовскаяКД",shinservice_m:"Шинсервис Мск",partizanskaya:"Партизанская",partizanskaya_kd_oh:"Партизанская",oh_glvovsk:"Львовская",oh_gkievsk:"Киевская",Rimz:"Rimzona"})[e.trim()])&&void 0!==n?n:e}a.d(n,{Z:function(){return r}})},8146:function(e){e.exports={breadcrumbs:"Breadcrumbs_breadcrumbs__Eid_1"}},60198:function(e){e.exports={content:"Panel_content__LmDQo",top:"Panel_top__wgHa_",userTypeBadge:"Panel_userTypeBadge__oXb39",switcher:"Panel_switcher__Cv_Hx",active:"Panel_active__hG_B5",personalIn
1put:"Panel_personalInput__zmx3B",afterFormText:"Panel_afterFormText__bHcVj",panelTitle:"Panel_panelTitle__V5dGU"}},67451:function(e){e.exports={panelInfoOrders:"PanelInfoOrders_panelInfoOrders__UREPm",panelInfoOrdersLine:"PanelInfoOrders_panelInfoOrdersLine__zCy18",storesBox:"PanelInfoOrders_storesBox__I_R81",successOrdersInfo:"PanelInfoOrders_successOrdersInfo__SBXlf",cancelledOrdersInfo:"PanelInfoOrders_cancelledOrdersInfo__lqJ5U",summaryOrdersInfo:"PanelInfoOrders_summaryOrdersInfo__qKddm"}},88882:function(e){e.exports={panelNavbar:"PanelNavbar_panelNavbar__br4mC",active:"PanelNavbar_active__cGAaK",logoutBtn:"PanelNavbar_logoutBtn__UlJUk"}}}]);

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.