PageSourceSearch

https://www.myinvoiceonline.co.uk/vite/assets/KsefOverviewBox-HRHQDcV1.js

js myinvoiceonline.co.uk collected 2026-10-02 22:52:37 UTC 8,136 bytes, 21 lines download raw bytes

1import{ap as o,ar as i,cN as n,cO as _,b5 as l,ci as d,cP as c,bh as v}from"./Button-DgIZgSWg.js";import"./_sentry-release-injection-file-DlxsNGob.js";import"./uk-DukXYPB_.js";import"./cs-BHj9zxo3.js";import"./_commonjsHelpers-D7Sok4xY.js";import"./index-yq28UAnt.js";import"./preload-helper-CI83Jo27.js";import"./posthog-CaAkLFEO.js";import"./_commonjs-dynamic-modules-TDtrdbi3.js";import"./actioncable.esm-BMIXSJNp.js";import"./js.cookie-DxONP--r.js";const f=8,u={name:"KsefOverviewBox",data:()=>({PATH_INVOICE_SHOW:d,PATH_INVOICES_OVERVIEW:l,ksefSetting:null,ksefOverview:null,selectedGroup:null,currentPage:1,invoices:[],totalPages:1,invoicesLoading:!1,expandedId:null}),apollo:{ksefSetting:{query:_,fetchPolicy:"network-only"},ksefOverview:{query:n,fetchPolicy:"network-only",skip(){return!this.isConfigured}}},computed:{...i("env",["dateFormats"]),isConfigured(){return v(this.ksefSetting)},loading(){return this.$apollo.queries.ksefOverview.loading},dateFormat(){var r;return((r=this.dateFormats)==null?void 0:r.dateFns)||"dd.MM.yyyy"},tiles(){var r,e,s,t;return[{key:"confirmed",group:"confirmed",color:"green",count:((r=this.ksefOverview)==null?void 0:r.confirmedCount)??0},{key:"inProgress",group:"in_progress",color:"yellow",count:((e=this.ksefOverview)==null?void 0:e.inProgressCount)??0},{key:"failed",group:"failed",color:"red",count:((s=this.ksefOverview)==null?void 0:s.failedCount)??0},{key:"notSent",group:"not_sent",color:"gray",count:((t=this.ksefOverview)==null?void 0:t.notSentCount)??0}]}},methods:{toggleGroup(r){if(this.selectedGroup===r){this.selectedGroup=null;return}this.selectedGroup=r,this.currentPage=1,this.expandedId=null,this.fetchInvoices()},toggleExpand(r){this.expandedId=this.expandedId===r?null:r},hasErrorDetail(r){var e;return(e=r.ksefSubmission)==null?void 0:e.errorMessage},async fetchInvoices(){this.invoicesLoading=!0;try{const{data:r}=await this.$apollo.query({query:c,fetchPolicy:"network-only",variables:{ksefGroup:this.selectedGroup,page:this.currentPage,perPage:f}});this.invoices=r.invoices.collection,this.totalPages=r.invoices.metadata.totalPages}finally{this.invoicesLoading=!1}}},watch:{currentPage(){this.fetchInvoices()}}};var k=function(){var e=this,s=e._self._c;return e.isConfigured?s("div",[s("div",{staticClass:"ksef-report__header"},[s("span",{staticClass:"text--lg text--semibold"},[e._v(e._s(e.$t("dashboard.ksefOverview.title")))]),e._v(" "),s("Button",{attrs:{to:e.PATH_INVOICES_OVERVIEW,"new-design":"",plain:"",size:"small",type:"primary","data-analytics-id":"dashboard.ksefOverview.allInvoices"}},[e._v(`
2      `+e._s(e.$t("dashboard.ksefOverview.allInvoices"))+`
3    `)])],1),e._v(" "),s("div",{staticClass:"ksef-report"},[s("div",{staticClass:"ksef-report__sections"},e._l(e.tiles,function(t){return s("button",{key:t.key,class:["ksef-report__section",{"ksef-report__section--active":e.selectedGroup===t.group}],on:{click:function(a){return e.toggleGroup(t.group)}}},[s("div",{staticClass:"ksef-report__section-label"},[s("span",{class:["ksef-dot",`ksef-dot--${t.color}`]}),e._v(`
4          `+e._s(e.$t(`dashboard.ksefOverview.${t.key}`))+`
5        `)]),e._v(" "),s("div",{staticClass:"ksef-report__section-count text--semibold"},[e.loading?s("span",[e._v("—")]):s("span",[e._v(e._s(t.count))])]),e._v(" "),s("div",{staticClass:"ksef-report__section-sub text--xs text--secondary-color"},[e._v(`
6          `+e._s(e.$t("dashboard.ksefOverview.invoices"))+`
7        `)])])}),0),e._v(" "),e.selectedGroup?s("div",{staticClass:"ksef-report__list"},[e.invoicesLoading?s("div",{staticClass:"ksef-report__list-loader"},[s("ContentLoader",{attrs:{lines:3}})],1):e.invoices.length?[e._l(e.invoices,function(t){return s("div",{key:t.id,staticClass:"ksef-invoice-wrap"},[s("div",{class:["ksef-invoice-row",{"ksef-invoice-row--expandable":e.hasErrorDetail(t)}],on:{click:function(a){e.hasErrorDetail(t)&&e.toggleExpand(t.id)}}},[s("router-link",{staticClass:"ksef-invoice-row__number",attrs:{to:{name:e.PATH_INVOICE_SHOW,params:{invoiceId:t.id}}},nativeOn:{click:function(a){a.stopPropagation()}}},[e._v(`
8              `+e._s(t.number||e.$t("dashboard.ksefOverview.draft"))+`
9            `)]),e._v(" "),s("span",{staticClass:"ksef-invoice-row__buyer"}
9,[e._v(e._s(t.buyer&&t.buyer.name))]),e._v(" "),s("span",{staticClass:"ksef-invoice-row__date text--secondary-color"},[e._v(`
10              `+e._s(e._f("formatDate")(t.issuedOn,e.dateFormat))+`
11            `)]),e._v(" "),t.ksefSubmission&&t.ksefSubmission.errorMessage?s("span",{staticClass:"ksef-invoice-row__error"},[s("i",{staticClass:"icon icon-warning"}),e._v(" "),s("span",{staticClass:"ksef-invoice-row__error-code"},[e._v(e._s(t.ksefSubmission.errorCode))]),e._v(" "),s("span",{staticClass:"ksef-invoice-row__error-msg"},[e._v(e._s(e._f("truncate")(t.ksefSubmission.errorMessage,50)))]),e._v(" "),s("i",{class:["icon ksef-invoice-row__expand-icon",e.expandedId===t.id?"icon-chevron-up-small":"icon-chevron-down-small"]})]):t.ksefReferenceNumber?s("span",{staticClass:"ksef-invoice-row__ref",attrs:{title:t.ksefReferenceNumber}},[e._v(`
12              `+e._s(e._f("truncate")(t.ksefReferenceNumber,28))+`
13            `)]):t.ksefInProgress?s("span",{staticClass:"ksef-invoice-row__pending"},[s("i",{staticClass:"icon icon-time"}),e._v(`
14              `+e._s(e.$t("dashboard.ksefOverview.sending"))+`
15            `)]):s("span",{staticClass:"text--secondary-color"},[e._v("—")])],1),e._v(" "),e.expandedId===t.id&&t.ksefSubmission?s("div",{staticClass:"ksef-error-detail"},[s("div",{staticClass:"ksef-error-detail__row"},[s("span",{staticClass:"ksef-error-detail__label"},[e._v(e._s(e.$t("dashboard.ksefOverview.detail.errorCode")))]),e._v(" "),s("code",{staticClass:"ksef-error-detail__value"},[e._v(e._s(t.ksefSubmission.errorCode||"—"))])]),e._v(" "),s("div",{staticClass:"ksef-error-detail__row"},[s("span",{staticClass:"ksef-error-detail__label"},[e._v(e._s(e.$t("dashboard.ksefOverview.detail.errorMessage")))]),e._v(" "),s("span",{staticClass:"ksef-error-detail__value"},[e._v(e._s(t.ksefSubmission.errorMessage||"—"))])]),e._v(" "),t.ksefSubmission.sessionReferenceNumber?s("div",{staticClass:"ksef-error-detail__row"},[s("span",{staticClass:"ksef-error-detail__label"},[e._v(e._s(e.$t("dashboard.ksefOverview.detail.sessionRef")))]),e._v(" "),s("code",{staticClass:"ksef-error-detail__value ksef-error-detail__value--mono"},[e._v(e._s(t.ksefSubmission.sessionReferenceNumber))])]):e._e(),e._v(" "),s("div",{staticClass:"ksef-error-detail__row"},[s("span",{staticClass:"ksef-error-detail__label"},[e._v(e._s(e.$t("dashboard.ksefOverview.detail.submittedAt")))]),e._v(" "),s("span",{staticClass:"ksef-error-detail__value"},[e._v(e._s(e._f("formatDate")(t.ksefSubmission.submittedAt,e.dateFormat)))])]),e._v(" "),s("div",{staticClass:"ksef-error-detail__row"},[s("span",{staticClass:"ksef-error-detail__label"},[e._v(e._s(e.$t("dashboard.ksefOverview.detail.processedAt")))]),e._v(" "),s("span",{staticClass:"ksef-error-detail__value"},[e._v(e._s(e._f("formatDate")(t.ksefSubmission.processedAt,e.dateFormat)))])]),e._v(" "),s("div",{staticClass:"ksef-error-detail__row"},[s("span",{staticClass:"ksef-error-detail__label"},[e._v(e._s(e.$t("dashboard.ksefOverview.detail.retryCount")))]),e._v(" "),s("span",{staticClass:"ksef-error-detail__value"},[e._v(e._s(t.ksefSubmission.retryCount))])])]):e._e()])}),e._v(" "),e.totalPages>1?s("div",{staticClass:"ksef-report__pagination"},[s("button",{staticClass:"ksef-report__page-btn",attrs:{disabled:e.currentPage<=1},on:{click:function(t){e.currentPage-=1}}},[e._v(`
16            ‹
17          `)]),e._v(" "),s("span",{staticClass:"text--xs text--secondary-color"},[e._v(e._s(e.currentPage)+" / "+e._s(e.totalPages))]),e._v(" "),s("button",{staticClass:"ksef-report__page-btn",attrs:{disabled:e.currentPage>=e.totalPages},on:{click:function(t){e.currentPage+=1}}},[e._v(`
18            ›
19          `)])]):e._e()]:s("div",{staticClass:"ksef-report__empty text--xs text--secondary-color"},[e._v(`
20        `+e._s(e.$t("dashboard.ksefOverview.noInvoices"))+`
21      `)])],2):e._e()])]):e._e()},p=[],m=o(u,k,p,!1,null,"52d15747");const S=m.exports;export{S 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.