1import{_ as v}from"./TextField-DTP5qN9N.js";import{d as h,ax as V,W as D,q as _,c as l,o as n,a as o,k as r,A as c,t as d,a1 as T,y as L,g as k,h7 as C,E as F,G as M,l as f,f as b}from"./entry-BPpzu7Al.js";import{a as B}from"./useLeadStatusMappingStore-BjRHA0C0.js";import{V as A}from"./VForm-1vPvN296.js";import{_ as E}from"./CategoryGroupsList-D_fDPq5c.js";import"./Label-BUhFDx1h.js";import"./VTooltip-BFCN09Rf.js";import"./useTaskStatusActionsApi-B8WwFLnc.js";import"./query-cache-awNgePv1.js";const $={class:"tw-flex tw-flex-col tw-w-full tw-space-y-4"},G={class:"tw-w-[20%]"},U={class:"tw-w-[80%] tw-flex tw-items-center"},q={class:"bottom-button-bar"},I=h({__name:"LeadStatusMapping",setup(w){const{$repositories:p}=V(),e=D(),t=_(),u=_(),x=B();t.value=x.data;const y=async()=>{const{valid:m}=await u.value.validate();if(!m){e.setToastDetail({type:"error",toastNotice:"Please correct the error first."});return}const{hasError:a}=await p.settingsLeadStatusDisplayNameMapping.createLeadStatusDisplayNameMapping({mappings:t.value.map(function(s){return{lead_status:s.status,display_name:s.displayName}})});a&&e.setToastDetail({type:"error",toastNotice:"Something is wrong when updating display name, please try again!"})};return(m,a)=>{const s=v,g=M;return n(),l(d,null,[o("div",$,[r(A,{ref_key:"form",ref:u},{default:c(()=>[(n(!0),l(d,null,T(t.value,(i,N)=>(n(),l("div",{key:N,class:"tw-flex tw-items-center tw-w-full tw-min-h-[80px] tw-border tw-border-gray-200 tw-rounded"},[o("div",G,L(i.mappingName),1),o("div",U,[r(s,{modelValue:i.displayName,"onUpdate:modelValue":S=>i.displayName=S,class:"w-75",rules:k(C)},null,8,["modelValue","onUpdate:modelValue","rules"])])]))),128))]),_:1},512)]),o("div",q,[r(g,{class:"tw-w-60",onClick:y},{default:c(()=>a[0]||(a[0]=[F("Save")])),_:1})])],64)}}}),P=f(I,[["__scopeId","data-v-35412fe8"]]),R={};function W(w,p){const e=P,t=E;return n(),b(t,null,{default:c(()=>[r(e)]),_:1})}const Z=f(R,[["render",W]]);export{Z 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.