index-41f4d37d.js 8.8 KB

1
  1. import{d as te,h as re,r as p,u as oe,L as ne,l as ue,Q as ie,o as i,c as x,f as e,w as t,a as l,R as B,F as R,q as M,v as s,n as c,x as y,O as pe,t as G,V as se,A as ce,y as de,z as _e,j as me,C as fe,D as ye,W as ve,X as be,G as he,H as we,I as ge,_ as Ce,__tla as xe}from"./index-e3afde76.js";import{_ as Re,__tla as ke}from"./index-51c17e69.js";import{_ as Ve,__tla as Ue}from"./DictTag-715a7ef1.js";import{E as Se,__tla as Te}from"./el-link-6cf0ca3c.js";import{_ as Ne,__tla as Ee}from"./ContentWrap-5f2f4872.js";import{a as O,D as d,__tla as Ie}from"./dict-a141296d.js";import{d as k,__tla as Me}from"./formatTime-cee700cd.js";import{d as Oe}from"./download-20922b56.js";import{d as De,e as ze,f as Le,__tla as Ae}from"./index-f22d75b3.js";import Fe,{__tla as Pe}from"./CustomerForm-c941425b.js";import{u as qe,__tla as Ke}from"./useMessage-0b1b25bd.js";import{__tla as Be}from"./index-2d20a7ff.js";import"./color-6e929987.js";import{__tla as Ge}from"./el-card-6198c22a.js";import{__tla as Ye}from"./Dialog-c20523c4.js";import{__tla as je}from"./el-tree-select-58251b07.js";import{__tla as He}from"./index-28a76ee4.js";import"./tree-0af4953a.js";import{__tla as Qe}from"./index-13bb02f9.js";let Y,We=Promise.all([(()=>{try{return xe}catch{}})(),(()=>{try{return ke}catch{}})(),(()=>{try{return Ue}catch{}})(),(()=>{try{return Te}catch{}})(),(()=>{try{return Ee}catch{}})(),(()=>{try{return Ie}catch{}})(),(()=>{try{return Me}catch{}})(),(()=>{try{return Ae}catch{}})(),(()=>{try{return Pe}catch{}})(),(()=>{try{return Ke}catch{}})(),(()=>{try{return Be}catch{}})(),(()=>{try{return Ge}catch{}})(),(()=>{try{return Ye}catch{}})(),(()=>{try{return je}catch{}})(),(()=>{try{return He}catch{}})(),(()=>{try{return Qe}catch{}})()]).then(async()=>{Y=Ce(te({name:"CrmCustomer",__name:"index",setup(Xe){const V=qe(),{t:j}=re(),U=p(!0),D=p(0),z=p([]),r=p({pageNo:1,pageSize:10,name:"",mobile:"",industryId:void 0,level:void 0,source:void 0,sceneType:void 0,pool:void 0}),L=p(),S=p(!1),T=p("1"),H=u=>{switch(u.paneName){case"1":b(()=>{r.value.sceneType=1});break;case"2":b(()=>{r.value.sceneType=2});break;case"3":b(()=>{r.value.sceneType=3})}},_=async()=>{U.value=!0;try{const u=await De(r.value);z.value=u.list,D.value=u.total}finally{U.value=!1}},v=()=>{r.value.pageNo=1,_()},b=(u=void 0)=>{L.value.resetFields(),r.value={pageNo:1,pageSize:10,name:"",mobile:"",industryId:void 0,level:void 0,source:void 0,sceneType:void 0,pool:void 0},u&&u(),v()},{currentRoute:Q,push:W}=oe(),A=p(),F=(u,o)=>{A.value.open(u,o)},X=async()=>{try{await V.exportConfirm(),S.value=!0;const u=await Le(r.value);Oe.excel(u,"\u5BA2\u6237.xls")}catch{}finally{S.value=!1}};return ne(()=>Q.value,()=>{_()}),ue(()=>{_()}),(u,o)=>{const P=se,m=ce,N=de,E=_e,h=me,f=fe,J=ye,q=Ne,I=ve,Z=be,n=he,$=Se,w=Ve,ee=we,ae=Re,g=ie("hasPermi"),le=ge;return i(),x(R,null,[e(q,null,{default:t(()=>[e(J,{ref_key:"queryFormRef",ref:L,inline:!0,model:l(r),class:"-mb-15px","label-width":"68px"},{default:t(()=>[e(m,{label:"\u5BA2\u6237\u540D\u79F0",prop:"name"},{default:t(()=>[e(P,{modelValue:l(r).name,"onUpdate:modelValue":o[0]||(o[0]=a=>l(r).name=a),class:"!w-240px",clearable:"",placeholder:"\u8BF7\u8F93\u5165\u5BA2\u6237\u540D\u79F0",onKeyup:B(v,["enter"])},null,8,["modelValue"])]),_:1}),e(m,{label:"\u624B\u673A",prop:"mobile"},{default:t(()=>[e(P,{modelValue:l(r).mobile,"onUpdate:modelValue":o[1]||(o[1]=a=>l(r).mobile=a),class:"!w-240px",clearable:"",placeholder:"\u8BF7\u8F93\u5165\u624B\u673A",onKeyup:B(v,["enter"])},null,8,["modelValue"])]),_:1}),e(m,{label:"\u6240\u5C5E\u884C\u4E1A",prop:"industryId"},{default:t(()=>[e(E,{modelValue:l(r).industryId,"onUpdate:modelValue":o[2]||(o[2]=a=>l(r).industryId=a),class:"!w-240px",clearable:"",placeholder:"\u8BF7\u9009\u62E9\u6240\u5C5E\u884C\u4E1A"},{default:t(()=>[(i(!0),x(R,null,M(l(O)(l(d).CRM_CUSTOMER_INDUSTRY),a=>(i(),s(N,{key:a.value,label:a.label,value:a.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(m,{label:"\u5BA2\u6237\u7B49\u7EA7",prop:"level"},{default:t(()=>[e(E,{modelValue:l(r).level,"onUpdate:modelValue":o[3]||(o[3]=a=>l(r).level=a),class:"!w-240px",clearable:"",placeholder:"\u8BF7\u9009\u62E9\u5BA2\u6237\u7B49\u7EA7"},{default:t(()=>[(i(!0),x(R,null,M(l(O)(l(d).CRM_CUSTOMER_LEVEL),a=>(i(),s(N,{key:a.value,label:a.label,value:a.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(m,{label:"\u5BA2\u6237\u6765\u6E90",prop:"source"},{default:t(()=>[e(E,{modelValue:l(r).source,"onUpdate:modelValue":o[4]||(o[4]=a=>l(r).source=a),class:"!w-240px",clearable:"",placeholder:"\u8BF7\u9009\u62E9\u5BA2\u6237\u6765\u6E90"},{default:t(()=>[(i(!0),x(R,null,M(l(O)(l(d).CRM_CUSTOMER_SOURCE),a=>(i(),s(N,{key:a.value,label:a.label,value:a.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(m,null,{default:t(()=>[e(f,{onClick:v},{default:t(()=>[e(h,{class:"mr-5px",icon:"ep:search"}),c(" \u641C\u7D22 ")]),_:1}),e(f,{onClick:o[5]||(o[5]=a=>b(void 0))},{default:t(()=>[e(h,{class:"mr-5px",icon:"ep:refresh"}),c(" \u91CD\u7F6E ")]),_:1}),y((i(),s(f,{type:"primary",onClick:o[6]||(o[6]=a=>F("create"))},{default:t(()=>[e(h,{class:"mr-5px",icon:"ep:plus"}),c(" \u65B0\u589E ")]),_:1})),[[g,["crm:customer:create"]]]),y((i(),s(f,{loading:l(S),plain:"",type:"success",onClick:X},{default:t(()=>[e(h,{class:"mr-5px",icon:"ep:download"}),c(" \u5BFC\u51FA ")]),_:1},8,["loading"])),[[g,["crm:customer:export"]]])]),_:1})]),_:1},8,["model"])]),_:1}),e(q,null,{default:t(()=>[e(Z,{modelValue:l(T),"onUpdate:modelValue":o[7]||(o[7]=a=>pe(T)?T.value=a:null),onTabClick:H},{default:t(()=>[e(I,{label:"\u6211\u8D1F\u8D23\u7684",name:"1"}),e(I,{label:"\u6211\u53C2\u4E0E\u7684",name:"2"}),e(I,{label:"\u4E0B\u5C5E\u8D1F\u8D23\u7684",name:"3"})]),_:1},8,["modelValue"]),y((i(),s(ee,{data:l(z),"show-overflow-tooltip":!0,stripe:!0},{default:t(()=>[e(n,{align:"center",label:"\u7F16\u53F7",prop:"id"}),e(n,{align:"center",label:"\u5BA2\u6237\u540D\u79F0",prop:"name",width:"160"},{default:t(a=>[e($,{underline:!1,type:"primary",onClick:K=>{return C=a.row.id,void W({name:"CrmCustomerDetail",params:{id:C}});var C}},{default:t(()=>[c(G(a.row.name),1)]),_:2},1032,["onClick"])]),_:1}),e(n,{align:"center",label:"\u624B\u673A",prop:"mobile",width:"120"}),e(n,{align:"center",label:"\u7535\u8BDD",prop:"telephone",width:"120"}),e(n,{align:"center",label:"\u5BA2\u6237\u6765\u6E90",prop:"source",width:"100"},{default:t(a=>[e(w,{type:l(d).CRM_CUSTOMER_SOURCE,value:a.row.source},null,8,["type","value"])]),_:1}),e(n,{align:"center",label:"\u6240\u5C5E\u884C\u4E1A",prop:"industryId",width:"120"},{default:t(a=>[e(w,{type:l(d).CRM_CUSTOMER_INDUSTRY,value:a.row.industryId},null,8,["type","value"])]),_:1}),e(n,{align:"center",label:"\u5BA2\u6237\u7B49\u7EA7",prop:"level",width:"120"},{default:t(a=>[e(w,{type:l(d).CRM_CUSTOMER_LEVEL,value:a.row.level},null,8,["type","value"])]),_:1}),e(n,{align:"center",label:"\u7F51\u5740",prop:"website",width:"200"}),e(n,{formatter:l(k),align:"center",label:"\u4E0B\u6B21\u8054\u7CFB\u65F6\u95F4",prop:"contactNextTime",width:"180px"},null,8,["formatter"]),e(n,{align:"center",label:"\u5907\u6CE8",prop:"remark",width:"200"}),e(n,{align:"center",label:"\u6210\u4EA4\u72B6\u6001",prop:"dealStatus"},{default:t(a=>[e(w,{type:l(d).INFRA_BOOLEAN_STRING,value:a.row.dealStatus},null,8,["type","value"])]),_:1}),e(n,{align:"center",label:"\u8DDD\u79BB\u8FDB\u5165\u516C\u6D77",prop:"poolDay"},{default:t(a=>[c(G(a.row.poolDay)+" \u5929",1)]),_:1}),e(n,{formatter:l(k),align:"center",label:"\u6700\u540E\u8DDF\u8FDB\u65F6\u95F4",prop:"contactLastTime",width:"180px"},null,8,["formatter"]),e(n,{formatter:l(k),align:"center",label:"\u521B\u5EFA\u65F6\u95F4",prop:"updateTime",width:"180px"},null,8,["formatter"]),e(n,{formatter:l(k),align:"center",label:"\u521B\u5EFA\u65F6\u95F4",prop:"createTime",width:"180px"},null,8,["formatter"]),e(n,{align:"center",label:"\u8D1F\u8D23\u4EBA",prop:"ownerUserName",width:"100px"}),e(n,{align:"center",label:"\u6240\u5C5E\u90E8\u95E8",prop:"ownerUserDeptName",width:"100px"}),e(n,{align:"center",label:"\u521B\u5EFA\u4EBA",prop:"creatorName",width:"100px"}),e(n,{align:"center",fixed:"right",label:"\u64CD\u4F5C","min-width":"150"},{default:t(a=>[y((i(),s(f,{link:"",type:"primary",onClick:K=>F("update",a.row.id)},{default:t(()=>[c(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[g,["crm:customer:update"]]]),y((i(),s(f,{link:"",type:"danger",onClick:K=>(async C=>{try{await V.delConfirm(),await ze(C),V.success(j("common.delSuccess")),await _()}catch{}})(a.row.id)},{default:t(()=>[c(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[g,["crm:customer:delete"]]])]),_:1})]),_:1},8,["data"])),[[le,l(U)]]),e(ae,{limit:l(r).pageSize,"onUpdate:limit":o[8]||(o[8]=a=>l(r).pageSize=a),page:l(r).pageNo,"onUpdate:page":o[9]||(o[9]=a=>l(r).pageNo=a),total:l(D),onPagination:_},null,8,["limit","page","total"])]),_:1}),e(Fe,{ref_key:"formRef",ref:A,onSuccess:_},null,512)],64)}}}),[["__file","D:/zx/mall-newfeifan-zx-admin/src/views/crm/customer/index.vue"]])});export{We as __tla,Y as default};