You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 lines
7.9 KiB
1 lines
7.9 KiB
import{d as I,v as D,l as B,r as b,h as v,c as F,e as a,w as n,a as f,t as p,u as e,i as h,k as l,J as z,m as A,M as $,E as L,D as N,G as j,H as M,K as S,O as G,P as H,Q as J,L as K}from"./index-f5d841af.js";/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import"./el-tooltip-4ed993c7.js";/* empty css *//* empty css *//* empty css */import"./el-form-item-4ed993c7.js";/* empty css */import{_ as O,g as Q,d as q}from"./communication-records-edit.vue_vue_type_style_index_0_lang-bdcf1518.js";import{_ as W}from"./_plugin-vue_export-helper-c27b6911.js";/* empty css *//* empty css */const X={class:"main-container"},Y={class:"flex justify-between items-center"},Z={class:"text-lg"},ee={class:"mt-[10px]"},ae={class:"mt-[16px] flex justify-end"},le=I({__name:"communication_records",setup(oe){const P=D().meta.title;let o=B({page:1,limit:10,total:0,loading:!0,data:[],searchParam:{staff_id:"",resource_id:"",resource_type:"",communication_type:"",communication_result:"",communication_time:"",remarks:"",tag:"",business_id:"",created_at:"",updated_at:""}});const g=b();b([]);const u=(s=1)=>{o.loading=!0,o.page=s,Q({page:o.page,limit:o.limit,...o.searchParam}).then(t=>{o.loading=!1,o.data=t.data.data,o.total=t.data.total}).catch(()=>{o.loading=!1})};u();const c=b(null),y=()=>{c.value.setFormData(),c.value.showDialog=!0},V=s=>{c.value.setFormData(s),c.value.showDialog=!0},k=s=>{$.confirm(l("communicationRecordsDeleteTips"),l("warning"),{confirmButtonText:l("confirm"),cancelButtonText:l("cancel"),type:"warning"}).then(()=>{q(s).then(()=>{u()}).catch(()=>{})})},C=s=>{s&&(s.resetFields(),u())};return(s,t)=>{const _=L,m=N,i=j,x=M,w=S,d=G,T=H,R=J,E=K;return v(),F("div",X,[a(w,{class:"box-card !border-none",shadow:"never"},{default:n(()=>[f("div",Y,[f("span",Z,p(e(P)),1),a(_,{type:"primary",onClick:y},{default:n(()=>[h(p(e(l)("addCommunicationRecords")),1)]),_:1})]),a(w,{class:"box-card !border-none my-[10px] table-search-wrap",shadow:"never"},{default:n(()=>[a(x,{inline:!0,model:e(o).searchParam,ref_key:"searchFormRef",ref:g},{default:n(()=>[a(i,{label:e(l)("staffId"),prop:"staff_id"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.staff_id,"onUpdate:modelValue":t[0]||(t[0]=r=>e(o).searchParam.staff_id=r),placeholder:e(l)("staffIdPlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,{label:e(l)("resourceId"),prop:"resource_id"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.resource_id,"onUpdate:modelValue":t[1]||(t[1]=r=>e(o).searchParam.resource_id=r),placeholder:e(l)("resourceIdPlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,{label:e(l)("resourceType"),prop:"resource_type"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.resource_type,"onUpdate:modelValue":t[2]||(t[2]=r=>e(o).searchParam.resource_type=r),placeholder:e(l)("resourceTypePlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,{label:e(l)("communicationType"),prop:"communication_type"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.communication_type,"onUpdate:modelValue":t[3]||(t[3]=r=>e(o).searchParam.communication_type=r),placeholder:e(l)("communicationTypePlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,{label:e(l)("communicationResult"),prop:"communication_result"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.communication_result,"onUpdate:modelValue":t[4]||(t[4]=r=>e(o).searchParam.communication_result=r),placeholder:e(l)("communicationResultPlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,{label:e(l)("communicationTime"),prop:"communication_time"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.communication_time,"onUpdate:modelValue":t[5]||(t[5]=r=>e(o).searchParam.communication_time=r),placeholder:e(l)("communicationTimePlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,{label:e(l)("remarks"),prop:"remarks"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.remarks,"onUpdate:modelValue":t[6]||(t[6]=r=>e(o).searchParam.remarks=r),placeholder:e(l)("remarksPlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,{label:e(l)("tag"),prop:"tag"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.tag,"onUpdate:modelValue":t[7]||(t[7]=r=>e(o).searchParam.tag=r),placeholder:e(l)("tagPlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,{label:e(l)("businessId"),prop:"business_id"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.business_id,"onUpdate:modelValue":t[8]||(t[8]=r=>e(o).searchParam.business_id=r),placeholder:e(l)("businessIdPlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,{label:e(l)("createdAt"),prop:"created_at"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.created_at,"onUpdate:modelValue":t[9]||(t[9]=r=>e(o).searchParam.created_at=r),placeholder:e(l)("createdAtPlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,{label:e(l)("updatedAt"),prop:"updated_at"},{default:n(()=>[a(m,{modelValue:e(o).searchParam.updated_at,"onUpdate:modelValue":t[10]||(t[10]=r=>e(o).searchParam.updated_at=r),placeholder:e(l)("updatedAtPlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(i,null,{default:n(()=>[a(_,{type:"primary",onClick:t[11]||(t[11]=r=>u())},{default:n(()=>[h(p(e(l)("search")),1)]),_:1}),a(_,{onClick:t[12]||(t[12]=r=>C(g.value))},{default:n(()=>[h(p(e(l)("reset")),1)]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),f("div",ee,[z((v(),A(T,{data:e(o).data,size:"large"},{empty:n(()=>[f("span",null,p(e(o).loading?"":e(l)("emptyData")),1)]),default:n(()=>[a(d,{prop:"staff_id",label:e(l)("staffId"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{prop:"resource_id",label:e(l)("resourceId"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{prop:"resource_type",label:e(l)("resourceType"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{prop:"communication_type",label:e(l)("communicationType"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{prop:"communication_result",label:e(l)("communicationResult"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{prop:"communication_time",label:e(l)("communicationTime"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{prop:"remarks",label:e(l)("remarks"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{prop:"tag",label:e(l)("tag"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{prop:"business_id",label:e(l)("businessId"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{prop:"created_at",label:e(l)("createdAt"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{prop:"updated_at",label:e(l)("updatedAt"),"min-width":"120","show-overflow-tooltip":!0},null,8,["label"]),a(d,{label:e(l)("operation"),fixed:"right","min-width":"120"},{default:n(({row:r})=>[a(_,{type:"primary",link:"",onClick:U=>V(r)},{default:n(()=>[h(p(e(l)("edit")),1)]),_:2},1032,["onClick"]),a(_,{type:"primary",link:"",onClick:U=>k(r.id)},{default:n(()=>[h(p(e(l)("delete")),1)]),_:2},1032,["onClick"])]),_:1},8,["label"])]),_:1},8,["data"])),[[E,e(o).loading]]),f("div",ae,[a(R,{"current-page":e(o).page,"onUpdate:current-page":t[13]||(t[13]=r=>e(o).page=r),"page-size":e(o).limit,"onUpdate:page-size":t[14]||(t[14]=r=>e(o).limit=r),layout:"total, sizes, prev, pager, next, jumper",total:e(o).total,onSizeChange:t[15]||(t[15]=r=>u()),onCurrentChange:u},null,8,["current-page","page-size","total"])])]),a(O,{ref_key:"editCommunicationRecordsDialog",ref:c,onComplete:u},null,512)]),_:1})])}}});const xe=W(le,[["__scopeId","data-v-e8187d60"]]);export{xe as default};
|
|
|