1"use strict";(self.webpackChunkDashboard=self.webpackChunkDashboard||[]).push([[964],{77098:(e,t,s)=>{s.a(e,(async e=>{s.d(t,{Z:()=>a});var o=s(76610),r=s(4267),i=s(79386),n=e([i]);const a={name:"ServiceModuleBookstoreList",mixins:[(i=(n.then?await n:n)[0]).default.ServiceManager],props:{type:{type:Number,required:!0},max:{type:Number,default:5}},data:function(){return{zip:"",bookstores:{},selected:{}}},computed:{showBookstoreList:function(){return Object.keys(this.bookstores).length>0},hasErrors:function(){return Object.keys(this.selected).length!=this.max}},mounted:function(){this.getServiceData("BookstoreList"),this.zip&&Object.keys(this.selected).length>0&&this.getBookstoreList(!1)},methods:{formatNumber:r.uf,getBookstoreList:function(){var e=this,t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];o.hi.get("/v1/services/bookstores",{zip:this.zip}).then((function(s){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:s.data;e.bookstores=o,t&&(e.selected=e.bookstores.slice(0,e.max)),e.update(e.selected)})).catch((function(e){console.error(e)}))},findBookstore:function(e,t){return e.Firma.includes(t.Firma)&&e.Strasse.includes(t.Strasse)&&e.Ort.includes(t.Ort)},isBookstoreSelected:function(e){var t=this;return this.selected.find((function(s){return t.findBookstore(s,e)}))},getBookstoreIndex:function(e){var t=this;return this.selected.findIndex((function(s){return t.findBookstore(s,e)}))},addSelectedStore:function(e){this.isBookstoreSelected(e)||this.selected.push(e)},removeSelectedStore:function(e){this.isBookstoreSelected(e)&&this.selected.splice(this.getBookstoreIndex(e),1)},update:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.$emit("input",{zip:this.zip,selected:e})}}}}))},85657:(e,t,s)=>{s.a(e,(async e=>{s.r(t),s.d(t,{default:()=>a});var o=s(88307),r=s(38703),i=s(51900),n=e([r]);r=(n.then?await n:n)[0];const a=(0,i.Z)(r.Z,o.s,o.x,!1,null,null,null).exports}))},38703:(e,t,s)=>{s.a(e,(async e=>{s.d(t,{Z:()=>i});var o=s(77098),r=e([o]);const i=(o=(r.then?await r:r)[0]).Z}))},88307:(e,t,s)=>{s.d(t,{s:()=>o,x:()=>r});var o=function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",{staticClass:"service-module-bookstore-list"},[s("h2",{staticClass:"text-bodblue-dark"},[e._v("\n "+e._s(e.serviceModule.$t("bookstore.title",!0,{max:e.max}))+"\n ")]),e._v(" "),s("div",{staticClass:"row g-3"},[s("ValidationProvider",{attrs:{vid:"zip",name:e.serviceModule.$t("bookstore.zip"),rules:"required",slim:""},scopedSlots:e._u([{key:"default",fn:function(t){var o=t.errors,r=t.classes;return[s("div",{staticClass:"col-auto"},[s("label",{staticClass:"visually-hidden",attrs:{for:"zip"}},[e._v(e._s(e.serviceModule.$t("bookstore.zip"))+"*")]),e._v(" "),s("input",{directives:[{name:"model",rawName:"v-model",value:e.zip,expression:"zip"}],class:["form-control"].concat(r),attrs:{type:"text",id:"zip",name:"zip",placeholder:e.serviceModule.$t("bookstore.zip")},domProps:{value:e.zip},on:{input:function(t){t.target.composing||(e.zip=t.target.value)}}}),e._v(" "),s("span",{staticClass:"invalid-feedback"},[e._v("\n "+e._s(o[0])+"\n ")])])]}}])}),e._v(" "),s("div",{staticClass:"col-auto"},[s("button",{staticClass:"btn btn-bodorange rounded-pill px-4",attrs:{id:"bookstore-search",disabled:!e.zip},on:{click:function(t){return t.preventDefault(),e.getBookstoreList()}}},[e._v("\n "+e._s(e.serviceModule.$t("bookstore.btnSearch"))+"\n ")])])],1),e._v(" "),e.showBookstoreList?[s("div",{class:["bookstore-list-wrapper border border-2 rounded-3 overflow-auto mt-4",{"border-danger":e.hasErrors}]},e._l(e.bookstores,(function(t,o){return s("div",{class:["border border-bottom p-3",{"bg-bodblue-light-50":e.isBookstoreSelected(t)}]},[s("h3",[s("span",{staticClass:"badge bg-dark me-1"},[e._v(e._s(o+1))]),e._v("\n "+e._s(t.Firma)+"\n "),s("span",{class:["badge rounded-pill",{"text-bg-light":e.isBookstoreSelected(t),"text-bg-bodblue-light":!e.isBookstoreSelected(t)}]},[s("i",{staticClass:"fa-regular fa-location-dot"}),e._v(" "+e._s(e.formatNumber(t.Entfernung,2))+" km\n ")])]),e._v(" "),s("p",[e._v("\n "+e._s(t.Strasse)+", "+e._s(t.Ort)),s("br"),e._v("\n "+e._s(t.OeZeiten)),s("br"),e._v(" "),s("a",{attrs:{href:"http://"+t.URL,target:"_blank"}},[s("i",{staticClass:"fa-regular fa-arrow-up-right-from-square me-2"}),e._v(e._s(t.URL)+"\n ")])]),e._v(" "),e.isBookstoreSelected(t)?[s("button",{staticClass:"btn btn-sm btn-outline-bodorange rounded-pill px-4",attrs:{id:"remove"},on:{click:function(s){return s.preventDefault(),e.removeSelectedStore(t)}}},[e._v("\n "+e._s(e.serviceModule.$t("bookstore.btn
1Remove"))+"\n ")])]:[s("button",{staticClass:"btn btn-sm btn-dark rounded-pill px-4",attrs:{id:"add"},on:{click:function(s){return s.preventDefault(),e.addSelectedStore(t)}}},[e._v("\n "+e._s(e.serviceModule.$t("bookstore.btnAdd"))+"\n ")])]],2)})),0),e._v(" "),s("span",{class:["invalid-feedback",{"d-block":e.hasErrors}]},[e._v("\n "+e._s(e.serviceModule.$t("bookstore.validation",!0,{max:e.max}))+"\n ")])]:e._e()],2)},r=[]}}]);
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.