PageSourceSearch

https://account.corriereadriatico.it/assets/MyPayments-CJeWfeon.js

js corriereadriatico.it collected 2026-09-27 21:32:00 UTC 5,602 bytes, 1 lines download raw bytes

1import{r as e,v as a,j as t,t as s,V as r,o,m as d,A as n,l as i,C as l}from"./index-r-KClxtY.js";/* empty css             */import{O as c}from"./OrdersFilter-BYxa_WCa.js";/* empty css              */import m from"./Paginator-Bi6ARBma.js";import{F as p}from"./FilterProvider-Cj0Dgj2t.js";import h from"./TableHeader-mJRejKOb.js";/* empty css              */import{F as u}from"./Faq-IKrRPNMT.js";import"./SpoilerCard-BPSzUAeY.js";import"./Grid-DKkSbsMs.js";const x=d=>{const n=s.user,i=d.data,l=d.states,u={year:"numeric",month:"2-digit",day:"2-digit"},[x,j]=e.useState(i.data),[b,g]=e.useState(i.data),{device:y}=a(),[v,f]=e.useState("desc"),[N,O]=e.useState(!1);return e.useEffect((()=>{if(i.data){const e=i.data.sort(((e,a)=>{const t=e.data?Date.parse(e.data):-1/0;return(a.data?Date.parse(a.data):-1/0)-t}));j(e)}}),[i.data]),t.jsx(t.Fragment,{children:t.jsxs(p,{children:[t.jsx(c,{items:i.data,setItems:j}),t.jsx("div",{className:"TableWrapper",children:t.jsxs("table",{children:[t.jsx("thead",{className:"TableHeaders",children:t.jsxs("tr",{children:[-1!==["tab","lap","desk"].indexOf(y)&&t.jsx("th",{className:"TableHeader order-number",children:n.payments.order_number}),t.jsxs("th",{className:"TableHeader order-date",children:[n.payments.order_date,t.jsx("i",{className:"icon icon-order",onClick:()=>{let e=[...x];"none"===v||"asc"===v?(e.sort(((e,a)=>{const t=e.data?Date.parse(e.data):-1/0;return(a.data?Date.parse(a.data):-1/0)-t})),f("desc")):"desc"===v?(e.sort(((e,a)=>(e.data?Date.parse(e.data):-1/0)-(a.data?Date.parse(a.data):-1/0))),f("asc")):(e=[...i.data],f("none")),g(e)}})]}),t.jsxs("th",{className:"TableHeader order-status",children:[n.payments.order_status,t.jsx("i",{className:"icon icon-filter",onClick:()=>O(!N)}),t.jsx(h,{className:"compact ".concat(N?"visible":"hidden"),states:l,getExtendedState:r,total:i.data.length,items:i.data,setItems:j,defaultActive:"A",filter:"kStato",setShow:O})]}),-1!==["tab","lap","desk"].indexOf(y)&&t.jsx("th",{className:"TableHeader order-desc",children:n.payments.order_description}),-1!==["tab","lap","desk"].indexOf(y)&&t.jsx("th",{className:"TableHeader order-payment-method",children:n.payments.order_payment_method}),t.jsx("th",{className:"TableHeader order-total",children:n.payments.order_total})]})}),t.jsx("tbody",{className:"TableBody",children:b.map(((e,a)=>t.jsxs("tr",{children:[-1!==["tab","lap","desk"].indexOf(y)&&t.jsx("td",{className:"order-number",children:(null==e?void 0:e.numero)||""}),t.jsxs("td",{className:"order-date",children:[(null==e?void 0:e.data)?o(e.data,u):null,-1!==["mob","tab"].indexOf(y)&&(null==e?void 0:e.righeOrdine)&&t.jsx("span",{className:"onlyMobile order-desc",children:(null==e?void 0:e.righeOrdine)&&e.righeOrdine[0]?e.righeOrdine[0].prodotto:""}),-1!==["mob","tab"].indexOf(y)&&(null==e?void 0:e.descrizionePagamento)&&t.jsxs("span",{className:"onlyMobile order-payment-method",children:[t.jsx("i",{className:"".concat((null==e?void 0:e.tipopag)?e.tipopag.toLowerCase():""," ").concat((null==e?void 0:e.tipoCarta)?e.tipoCarta.toLowerCase():"")})," ",null==e?void 0:e.descrizionePagamento]})]}),t.jsxs("td",{className:"order-status",children:[t.jsx("span",{className:"".concat((null==e?void 0:e.datapagamento)?"paid":"unpaid"),children:(null==e?void 0:e.datapagamento)?s.common.paid:s.common.unpaid}),-1!==["mob","tab"].indexOf(y)&&t.jsxs("span",{className:"onlyMobile",children:["n. ",(null==e?void 0:e.kOrdine)||""]})]}),-1!==["tab","lap","desk"].indexOf(y)&&(null==e?void 0:e.righeOrdine)&&t.jsx("td",{className:"order-desc",children:(null==e?void 0:e.righeOrdine)&&e.righeOrdine[0]?e.righeOrdine[0].prodotto:""}),-1!==["tab","lap","desk"].indexOf(y)&&t.jsxs("td",{className:"order-payment-method ".concat((null==e?void 0:e.tipopag)?(null==e?void 0:e.tipopag).toLowerCase():""," ").concat((null==e?void 0:e.tipoCarta)?e.tipoCarta.toLowerCase():""," ").concat((null==e?void 0:e.descrizionePagamento)?e.descrizionePagamento.toLowerCase():""),children:[t.jsx("i",{className:"".concat((null==e?void 0:e.tipopag)?e.tipopag.toLowerCase():""," ").concat((null==e?void 0:e.tipoCarta)?e.tipoCarta.toLowerCase():"")}),null==e?void 0:e.descrizionePagamento]}),t.jsxs("td",{className:"order-total",children:[(null==e?void 0:e.imponibile)&&(null==e?void 0:e.iva)&&(parseFloat(e.imponibile)+parseFloat(e.iva)).toFixed(2)," €"]})]},a)))})]})}),t.jsx(m,{items:x,setItems:g,itemsPerPage:10})]})})},j=a=>{const r=s.user,[o,c]=e.useState(null),[m,p]=e.useState(!1),h=d();e.useEffect((()=>{Promise.resolve(h.orders).then((e=>{const a=e.map((e=>({...e,kStato:null!==e.datapagamento?"paid":"unpaid"})));c(a)}))}),[h]),e.useEffect((()=>
1{if(o){const e=o.reduce(((e,a)=>{const t=a.kStato;return e[t]||(e[t]=0),e[t]++,e}),{});p(e)}}),[o]);const j=[r.payments.order_number,r.payments.order_date,r.payments.order_status,r.payments.order_description,r.payments.order_payment_method,r.payments.order_total,r.payments.order_invoice];return t.jsxs(t.Fragment,{children:[t.jsx("h2",{className:"page-title",children:r.titles.payments}),t.jsxs("div",{className:"MyPayments-wrapper route-wrapper",children:[t.jsx(e.Suspense,{fallback:t.jsx(l,{spinner:!0,labelPrimary:"",labelSecondary:"",minHeight:100}),children:t.jsxs(n,{resolve:h.orders,errorElement:t.jsx(i,{labelPrimary:s.notices.no_data,labelSecondary:"",bgColor:"warning",type:"warning",index:0}),children:[o&&m&&t.jsx(x,{data:{data:o,headers:j},states:m}),o&&0===o.length&&t.jsx(i,{labelPrimary:r.payments.no_payments,labelSecondary:"",bgColor:"light",type:"notice",index:0})]})}),t.jsx(u,{category:"metodi di pagamento",textLength:5})]})]})};export{j as default};

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.