PageSourceSearch

https://dashboard.transax.com/_nuxt/configure-XzWsLzSY.js

js transax.com collected 2026-09-24 12:19:06 UTC 3,029 bytes, 1 lines download raw bytes

1import{_ as I}from"./TextField-C_dNJHc3.js";import{m as L,ax as M,W as A,bu as U,q as d,bg as z,n as b,j as $,f as V,A as a,k as o,c as g,r as S,E as v,a as s,Z as G,z as W,y as h,g as _,t as F,a1 as Z,bb as H,G as J,o as i}from"./entry-BwZZnLSu.js";import{u as K}from"./index-hq67xhAX.js";import{g as O}from"./errors-D5yabfZ3.js";import{V as Q}from"./VForm-Ctj3S8Sx.js";import{V as C,a as T}from"./VRow-Cf9Zx5GU.js";import"./Label-DjTHcQrj.js";import"./VTooltip-BIl8PzV7.js";/* empty css              */const X={key:0,class:"d-flex tw-justify-center tw-items-center tw-h-screen"},Y={class:"tw-flex tw-flex-col tw-gap-1 mt-5"},ee={class:"tw-text-2xl"},te={class:"tw-p-4 tw-bg-white"},ae={class:"tw-flex tw-justify-end"},me={__name:"configure",setup(oe){const c=L(),E=K(),{$repositories:w}=M(),y=A(),f=U("form"),k=d(!0),m=d([]),p=d(!1),x=d({}),n=E.getSelectedDatalinkProvider;z(async()=>{(!n||n.id!==+c.params.id)&&await b("/integrations/datalink")}),$(async()=>{x.value=await B(),m.value=n.configurationFields.map(t=>({...t,label:t.label??N(t.field),value:x.value[t.field]??""}))});async function B(){const{hasError:t,response:e}=await w.datalinkProviders.getConfigurations(c.params.id);return k.value=!1,t&&(y.setToastDetail({type:"error",toastNotice:"Error while fetching provider configurations."}),await b("/integrations/datalink")),e}function N(t){return t.split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" ")}async function P(){const{valid:t}=await f.value.validate();if(t){const e=m.value.reduce((l,u)=>(l[u.field]=u.value,l),{});p.value=!0,await w.datalinkProviders.saveConfigurations(c.params.id,e),p.value=!1}else y.setToastDetail({type:"warning",toastNotice:O(f)})}return(t,e)=>{const l=S("LoadingIndicator"),u=S("router-link"),q=I,R=J;return i(),V(C,null,{default:a(()=>[o(T,{cols:"12",lg:"12"},{default:a(()=>[k.value?(i(),g("div",X,[o(l,null,{default:a(()=>e[0]||(e[0]=[v(" Fetching configurations... ")])),_:1})])):(i(),g(F,{key:1},[o(u,{to:"/integrations/datalink",class:"back-arrow-link"},{default:a(()=>[o(G,null,{default:a(()=>e[1]||(e[1]=[v("mdi-arrow-left")])),_:1}),e[2]||(e[2]=s("span",null,"Back to Providers",-1))]),_:1}),o(Q,{ref_key:"form",ref:f,class:"tw-flex tw-flex-col tw-gap-4",onSubmit:W(P,["prevent"])},{default:a(()=>[s("div",Y,[s("h3",ee,"Configure "+h(_(n).name),1),s("p",null," Customize your "+h(_(n).name)+" integration with your feed credentials to sync your inventory accurately and keep your stock up to date. ",1)]),s("div",te,[o(C,{dense:""},{default:a(()=>[(i(!0),g(F,null,Z(m.value,(r,j)=>(i(),V(T,{cols:"6",key:j},{default:a(()=>[o(q,{modelValue:r.value,"onUpdate:modelValue":D=>r.value=D,label:r.label,rules:r.isRequired?["notEmptyString"in t?t.notEmptyString:_(H)]:[],required:r.isRequired},null,8,["modelValue","onUpdate:modelValue","label","rules","required"])]),_:2},1024))),128))]),_:1})]),s("div",ae,[o(R,{type:"submit",loading:p.value},{default:a(()=>e[3]||(e[3]=[v(" Save")])),_:1},8,["loading"])])]),_:1},512)],64))]),_:1})]),_:1})}}};export{me 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.