HEX
Server: Apache/2.4.6 (CentOS) OpenSSL/1.0.2k-fips PHP/8.2.20
System: Linux 825a8fd6cf8c 3.10.0-1160.95.1.el7.x86_64 #1 SMP Mon Jul 24 13:59:37 UTC 2023 x86_64
User: apache (48)
PHP: 8.2.20
Disabled: NONE
Upload Files
File: /var/www/html/public/static/js/hookHealth-fe7e7b5c.js
import{getCompanyListWeb as G,addCompanyWeb as Q,getHealthFormDataWebapi as V,submitHealthFormModelWebApi as X,deleteCompanyWeb as Y}from"./po-76b72710.js";import{d as A,u as $}from"./vue-router-a383d220.js";import{b7 as s}from"./message-2472a54a.js";import{o as ee}from"./index-81e4a901.js";import{r as o,A as a,o as te}from"./runtime-core.esm-bundler-6128546f.js";import"./index-37b926b2.js";import"./preload-helper-78dc9057.js";import"./vue-i18n.runtime.esm-bundler-6949bcab.js";import"./index-b7f916e1.js";import"./_commonjsHelpers-87174ba5.js";import"./utils-2ab4f76a.js";import"./focus-trap-53f1c6ab.js";import"./error-78e43d3e.js";function ge(){const{query:C,params:ae}=A(),f=$();A();const c=o(!1),P=o(!1),y=o(!1),d=o(!1),w=o(!1),W=o(""),m=o(""),g=o([]),S=o([]),u=o([]),D=a({}),O=a({}),_=a({tableIndex:0,note:""}),p=a({name:"",today_date:"",hear_about:"",chief_complaint:"",rashes_bruise:!1,address:"",Birth:"",Code_ZIP:"",Occupation:"",Phone:"",Work_Phone:"",Physician:"",Phone1:"",City:""}),r=a({company_name:"",first_name:"",last_name:"",phone:"",email:"",address:"",state:"Ontraio",city:"",hst:"",r_ac:"",rmt_register:"",country:"Canada",postal:"L3S 0E2",company_id:"",number_companyname:""});a({destination_comp:"",state:"",city:"",address:"",phone:"",contact:"",customer_id:""});const k=a({}),E=a({}),H=a({}),j=a({qo_item_str:"",name:"",address:"",way:"",shipping:[],itemsDetail:[],trackingNo:"",courier:"",comment:""}),h=a({total:0,pageSize:10,currentPage:1,background:!0,currentPage:1,pageSizes:[10,25,50,100]}),x=o([{name:"Practice Location",id:1},{name:"Setup",id:2},{name:"Email Config",id:3}]),L=[{type:"selection",width:55,align:"left",hide:({checkList:e})=>!e.includes("勾选列")},{label:"序号列",type:"index",width:70,hide:({checkList:e})=>!e.includes("序号列")},{label:"Company",prop:"company_name",minWidth:100,hide:({checkList:e})=>!e.includes("Company")},{label:"HST#",prop:"hst",minWidth:100,hide:({checkList:e})=>!e.includes("HST#")},{label:"Name",prop:"first_name",minWidth:100,hide:({checkList:e})=>!e.includes("Name")},{label:"Postal",prop:"postal",minWidth:100,hide:({checkList:e})=>!e.includes("Postal")},{label:"Phone",prop:"phone",minWidth:150,slot:"slotAction",hide:({checkList:e})=>!e.includes("Phone")},{label:"Email",prop:"email",minWidth:120,hide:({checkList:e})=>!e.includes("Email")},{label:"Address",prop:"address",minWidth:120,hide:({checkList:e})=>!e.includes("Address")},{label:"Provice",prop:"state",minWidth:120,hide:({checkList:e})=>!e.includes("Provice")},{label:"City",prop:"city",minWidth:120,hide:({checkList:e})=>!e.includes("City")},{label:"Action",fixed:"right",width:120,slot:"operation",hide:({checkList:e})=>!e.includes("Action")}],T=["勾选列","Company","HST#","Name","Postal","Phone","Email","Address","Provice","City","Action"],b=a({order_key:"",material_key:"",truck_key:"",truck_id:"",comment:"",show:"",searchKey:""});function z(){l()}function I(e){h.pageSize=e,l()}function N(e){h.currentPage=e,l()}async function l(){c.value=!0;const{data:e}=await G(Object.assign(D,{searchKey:b.searchKey}));g.value=e.data,c.value=!1}const R=(e,t)=>{if(e.length>1){const i=e.shift();singleTableRef.value.toggleRowSelection(i,!1)}C.note&&f.push({path:"/crm/yuyue/note",query:{location_id:t.id,location:encodeURIComponent(JSON.stringify(t))}})};function q(e){_.tableIndex=e}function B(){Object.keys(r).map(e=>{r[e]=""}),d.value=!0}async function F(){const{data:e}=await Q(Object.assign(k,{data_row:r}));e.code==1?(l(),d.value=!1,s({type:"success",message:e.msg})):s({type:"error",message:e.msg})}function M(e){Object.keys(e).map(t=>{r[t]=e[t]}),d.value=!0}async function v(e){const{data:t}=await V(Object.assign(O,{customer_id:e}));t.code==1&&(u.value=t.model.health_info,Object.keys(t.model.information).map(i=>{p[i]=t.model.information[i]}))}async function K(e){let t={information:p,health_info:u.value};c.value=!0;const{data:i}=await X(Object.assign(H,{customer_id:m.value,data_row:t}));i.code==1&&(u.value=i.data,s({type:"success",message:i.msg}),y.value=!0,c.value=!1)}async function J(e){const{data:t}=await Y(Object.assign(E,{company_id:e.id}));t.code==1?(l(),s({type:"success",message:t.msg})):s({type:"error",message:t.msg})}const U=e=>{ee.confirm("Are you sure you want to delete this location",{confirmButtonText:"confirm",cancelButtonText:"cancel",type:"warning"}).then(()=>{J(e)}).catch(()=>{s({type:"info",message:"Canceled"})})};function Z(e,t){t.is_selected==1?t.is_selected=0:t.is_selected==0&&(t.is_selected=1)}return te(()=>{const e=f.options.history.location.split("?");e.length>1&&(e[1].split("&").forEach((i,oe)=>{const n=i.split("=");n[0]=="zIf_Fi"?m.value=n[1]:n[0]=="password"?password=n[1]:n[0]=="code"&&(code=n[1])}),v(m.value))}),{searchDetail:b,btnSearchPart:z,loading:c,small:w,selectList:T,columns:L,pagination:h,handleSizeChange:I,handleCurrentChange:N,PartList:g,order_date:W,deliverDialog:P,selectClick:R,deliverDataArr:j,btnDeliverConfirm:F,locationData:x,itemArr:_,infoData:S,onHealth:Z,health_info:u,onSituationArr:q,addLocationDialog:d,btnHealthConfirm:K,customer_id:m,btnAdd:B,onHealthForm:v,locationArr:r,EditLocation:M,btnDellocation:U,HealthArr:p,healthDialog:y}}export{ge as useEqu};