import{_ as p}from"./index-CwP5gtrp-D2vs7vDd.js";import{_ as u,d as h,o as c,b as o,w as s,j as f,a as _,e as g,t as b}from"./index-D02r7Zsc.js";import{_ as $}from"./BForm.vue_vue_type_script_setup_true_lang-u44ElAm9-BpNSPhCc.js";import{_ as M}from"./BInputGroupText.vue_vue_type_script_setup_true_lang-BBN5F0A4-C_He_f8L.js";import{_ as R}from"./BFormInput.vue_vue_type_script_setup_true_lang-B9E5yJEs-DBdCBfsp.js";import{_ as v}from"./BButton.vue_vue_type_script_setup_true_lang-D5Eg7-Zv-DDRCX2AG.js";import"./index-C0p9vHHI-DoOEDIMw.js";import"./getElement-DrDVR-jO-jZgQ3Xxs.js";import"./BCloseButton.vue_vue_type_script_setup_true_lang-byZmQ_ot-CWP55Z5N.js";import"./useDefaults-DESCdb0p-CFLjYrdG.js";import"./useId-t29UARy6-BH5d2231.js";import"./dom-DVb-f0ZG-Crdf0-mU.js";import"./useColorVariantClasses-ZDE19TZw-Cvu7SygP.js";import"./useShowHide-717t6y_D-BZTBbOpd.js";import"./classes-BW_GpXTu-AKwVND4h.js";import"./useStateClass-BGbSLWFN-BcKQ8Z3i.js";import"./BSpinner.vue_vue_type_script_setup_true_lang-H1MzHypA-D8AXjJB0.js";import"./BLink.vue_vue_type_script_setup_true_lang-Ct47WhzE-DDPYis_D.js";import"./object-0ALvRU0O-3BORTTD-.js";import"./stringUtils-gJJ6T6UC-g5BZrMym.js";const w={data:function(){return{searchTerm:"",noResultModalData:{show:!1,message:"",title:""}}},methods:{async sendRapidSearch(){this.publish("showOverlay",!0);var t=!1;parseInt(this.getConfig().applimobile_rapid_search_localised)==1&&this.getConfig().localized_empr>0&&(t=!0);let e=await this.getModule("search").sendSimpleSearch(this.get("sessionId"),this.searchTerm,t);if(!e){this.publish("showOverlay",!1),this.noResultModalData=this.getModule("search").noResultModal(this.$t("search.noResultModal.message"),this.$t("search.noResultModal.title"));return}this.$router.push({name:"searchresult",params:{searchId:e}})}}};function y(t,e,S,V,D,r){const i=v,l=R,n=M,d=$,m=p;return c(),h("div",null,[o(d,{onSubmit:e[1]||(e[1]=f(a=>r.sendRapidSearch(),["prevent"]))},{default:s(()=>[o(n,{class:"my-2"},{prepend:s(()=>[o(i,{variant:"outline-third",type:"submit"},{default:s(()=>[...e[4]||(e[4]=[_("i",{"aria-hidden":"true",class:"bi bi-search"},null,-1)])]),_:1})]),default:s(()=>[o(l,{required:"",type:"search",placeholder:t.$t("rapidSearch.rapidSearchPlaceholder"),modelValue:t.searchTerm,"onUpdate:modelValue":e[0]||(e[0]=a=>t.searchTerm=a)},null,8,["placeholder","modelValue"])]),_:1})]),_:1}),o(m,{modelValue:t.noResultModalData.show,"onUpdate:modelValue":e[2]||(e[2]=a=>t.noResultModalData.show=a),title:t.noResultModalData.title,centered:"","no-header-close":"","header-bg-variant":"info","header-class":"text-light title","body-bg-variant":"light","footer-bg-variant":"light","ok-variant":"outline-info","ok-only":"",onOk:e[3]||(e[3]=a=>t.noResultModalData.show=!1)},{default:s(()=>[g(b(t.noResultModalData.message),1)]),_:1},8,["modelValue","title"])])}const Q=u(w,[["render",y]]);export{Q as default};
