2 lines
8.5 KiB
JavaScript
2 lines
8.5 KiB
JavaScript
import{I as K,y as Q,J as X,G as Z,H as ee,w as oe,D as te,C as le,L as ae,M as ue,N as ne}from"./element-plus.4ff6f47d.js";import{_ as re}from"./index.vue_vue_type_script_setup_true_lang.7dabd2cb.js";import{_ as se}from"./index.vue_vue_type_script_setup_true_lang.e1e5e943.js";import{f as me,a as ie}from"./index.aaca920c.js";import{u as pe}from"./usePaging.f6660143.js";import{u as de}from"./useDictOptions.c83e2497.js";import{a as ce,b as x,e as _e}from"./customer_demand.1f5762f3.js";import"./lodash.8ea2174a.js";import{_ as fe}from"./edit.vue_vue_type_script_setup_true_name_customerDemandEdit_lang.b3a0cd09.js";import Fe from"./detail.742c3a2c.js";import{d as P,s as A,r as k,a0 as Be,ai as Ce,o as m,c as U,V as e,M as l,O as _,u as i,L as p,S as $,W as ve,a8 as Ee,a as L,k as be,T as c,n as h}from"./@vue.ab566ce7.js";import"./@vueuse.8fcae4c2.js";import"./@element-plus.8497a500.js";import"./lodash-es.49f4af13.js";import"./dayjs.fc5568d8.js";import"./axios.5b893b79.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.82a509e0.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./vue-router.87ebc608.js";import"./pinia.b6700c26.js";import"./vue-demi.ebc8116b.js";import"./css-color-function.4cbccc26.js";import"./color.033abf8c.js";import"./clone.a6258514.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./debug.7eedf28f.js";import"./ms.a9ae1d6d.js";import"./nprogress.93182424.js";import"./vue-clipboard3.6a55d49e.js";import"./clipboard.2986c82d.js";import"./echarts.b30ab882.js";import"./tslib.60310f1a.js";import"./zrender.3760070d.js";import"./highlight.js.4ebdf9a4.js";import"./@highlightjs.62ff6725.js";import"./index.ff7c6188.js";import"./department.a7058b70.js";import"./organization.f9ce12f7.js";import"./index.vue_vue_type_script_setup_true_lang.c07aa9ab.js";import"./project.86812b1a.js";import"./index.f2ff6561.js";import"./custom.01004c04.js";import"./customer_demand_solution.509645bd.js";import"./project_estimate.316c1ddc.js";import"./competitor.33801606.js";const De=c("\u67E5\u8BE2"),we=c("\u91CD\u7F6E"),Ve=c(" \u65B0\u589E "),ke=c(" \u5220\u9664 "),he={class:"mt-4"},ge=c(" \u7F16\u8F91 "),ye=c(" \u5220\u9664 "),xe=c(" \u8BE6\u60C5 "),Ae={class:"flex mt-4 justify-end"},Ue=P({name:"customerDemandLists"}),Ao=P({...Ue,setup($e){const D=A(),B=A(),C=k(!1),w=k(!1),a=Be({theme:"",supplier:"",supplier_contacts:"",org_name:"",dept_name:"",project_name:"",custom_name:"",importance:"",recording_time:""}),V=k([]),j=r=>{V.value=r.map(({id:o})=>o)},{dictData:v}=de("importance"),{pager:f,getLists:E,resetParams:R,resetPage:S}=pe({fetchFun:ce,params:a}),N=async()=>{var r;C.value=!0,await h(),(r=B.value)==null||r.open("add")},T=async r=>{var n,u;let o=await x({id:r.id});C.value=!0,await h(),(n=B.value)==null||n.open("edit"),(u=B.value)==null||u.setFormData(o)},g=async r=>{await me.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await _e({id:r}),E()},M=async r=>{var n,u;let o=await x({id:r.id});w.value=!0,await h(),(n=D.value)==null||n.open(),(u=D.value)==null||u.setFormData(o)};return E(),(r,o)=>{const n=K,u=Q,Y=X,I=Z,O=ee,d=oe,q=te,y=le,G=ie,s=ae,H=se,J=ue,W=re,F=Ce("perms"),z=ne;return m(),U("div",null,[e(y,{class:"!border-none mb-4",shadow:"never"},{default:l(()=>[e(q,{class:"mb-[-16px]",model:a,"label-width":"auto",inline:""},{default:l(()=>[e(u,{label:"\u9700\u6C42\u4E3B\u9898",prop:"theme"},{default:l(()=>[e(n,{class:"w-[250px]",modelValue:a.theme,"onUpdate:modelValue":o[0]||(o[0]=t=>a.theme=t),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u9700\u6C42\u4E3B\u9898"},null,8,["modelValue"])]),_:1}),e(u,{label:"\u9700\u6C42\u63D0\u4F9B\u4EBA",prop:"supplier"},{default:l(()=>[e(n,{class:"w-[250px]",modelValue:a.supplier,"onUpdate:modelValue":o[1]||(o[1]=t=>a.supplier=t),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u9700\u6C42\u63D0\u4F9B\u4EBA"},null,8,["modelValue"])]),_:1}),e(u,{label:"\u63D0\u4F9B\u4EBA\u8054\u7CFB\u65B9\u5F0F",prop:"supplier_contacts"},{default:l(()=>[e(n,{class:"w-[250px]",modelValue:a.supplier_contacts,"onUpdate:modelValue":o[2]||(o[2]=t=>a.supplier_contacts=t),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u63D0\u4F9B\u4EBA\u8054\u7CFB\u65B9\u5F0F"},null,8,["modelValue"])]),_:1}),e(u,{label:"\u7EC4\u7EC7\u540D\u79F0",prop:"org_name"},{default:l(()=>[e(n,{class:"w-[250px]",modelValue:a.org_name,"onUpdate:modelValue":o[3]||(o[3]=t=>a.org_name=t),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u7EC4\u7EC7\u540D\u79F0"},null,8,["modelValue"])]),_:1}),e(u,{label:"\u90E8\u95E8\u540D\u79F0",prop:"dept_name"},{default:l(()=>[e(n,{class:"w-[250px]",modelValue:a.dept_name,"onUpdate:modelValue":o[4]||(o[4]=t=>a.dept_name=t),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u90E8\u95E8\u540D\u79F0"},null,8,["modelValue"])]),_:1}),e(u,{label:"\u9879\u76EE\u540D\u79F0",prop:"project_name"},{default:l(()=>[e(n,{class:"w-[250px]",modelValue:a.project_name,"onUpdate:modelValue":o[5]||(o[5]=t=>a.project_name=t),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u9879\u76EE\u540D\u79F0"},null,8,["modelValue"])]),_:1}),e(u,{label:"\u5BA2\u6237\u540D\u79F0",prop:"custom_name"},{default:l(()=>[e(n,{class:"w-[250px]",modelValue:a.custom_name,"onUpdate:modelValue":o[6]||(o[6]=t=>a.custom_name=t),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u5BA2\u6237\u540D\u79F0"},null,8,["modelValue"])]),_:1}),e(u,{label:"\u8BB0\u5F55\u65F6\u95F4",prop:"recording_time"},{default:l(()=>[e(Y,{class:"w-[250px]",modelValue:a.recording_time,"onUpdate:modelValue":o[7]||(o[7]=t=>a.recording_time=t),clearable:"",type:"date","value-format":"YYYY-MM-DD",placeholder:"\u9009\u62E9\u8BB0\u5F55\u65F6\u95F4"},null,8,["modelValue"])]),_:1}),e(u,{label:"\u91CD\u8981\u7A0B\u5EA6",prop:"importance"},{default:l(()=>[e(O,{class:"w-[250px]",modelValue:a.importance,"onUpdate:modelValue":o[8]||(o[8]=t=>a.importance=t),clearable:"",placeholder:"\u8BF7\u9009\u62E9\u53D1\u7968\u7C7B\u578B"},{default:l(()=>[(m(!0),U(ve,null,Ee(i(v).importance,(t,b)=>(m(),p(I,{key:b,label:t.name,value:t.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(u,null,{default:l(()=>[e(d,{type:"primary",onClick:i(S)},{default:l(()=>[De]),_:1},8,["onClick"]),e(d,{onClick:i(R)},{default:l(()=>[we]),_:1},8,["onClick"])]),_:1})]),_:1},8,["model"])]),_:1}),_((m(),p(y,{class:"!border-none",shadow:"never"},{default:l(()=>[_((m(),p(d,{type:"primary",onClick:N},{icon:l(()=>[e(G,{name:"el-icon-Plus"})]),default:l(()=>[Ve]),_:1})),[[F,["custom/demand.customer_demand/add"]]]),_((m(),p(d,{disabled:!V.value.length,onClick:o[9]||(o[9]=t=>g(V.value))},{default:l(()=>[ke]),_:1},8,["disabled"])),[[F,["custom/demand.customer_demand/delete"]]]),L("div",he,[e(J,{data:i(f).lists,onSelectionChange:j},{default:l(()=>[e(s,{type:"selection",width:"55"}),e(s,{label:"\u5E8F\u53F7",type:"index",width:"55"}),e(s,{label:"\u9879\u76EE\u540D\u79F0",prop:"project_name","show-overflow-tooltip":""}),e(s,{label:"\u5BA2\u6237\u540D\u79F0",prop:"custom_name","show-overflow-tooltip":""}),e(s,{label:"\u9700\u6C42\u4E3B\u9898",prop:"theme","show-overflow-tooltip":""}),e(s,{label:"\u9700\u6C42\u63D0\u4F9B\u4EBA",prop:"supplier","show-overflow-tooltip":""}),e(s,{label:"\u63D0\u4F9B\u4EBA\u8054\u7CFB\u65B9\u5F0F",prop:"supplier_contacts","show-overflow-tooltip":""}),e(s,{label:"\u91CD\u8981\u7A0B\u5EA6",prop:"importance"},{default:l(({row:t})=>[e(H,{options:i(v).importance,value:t.importance},null,8,["options","value"])]),_:1}),e(s,{label:"\u8BB0\u5F55\u65F6\u95F4",prop:"recording_time"}),e(s,{label:"\u9700\u6C42\u5185\u5BB9",prop:"demand_content","show-overflow-tooltip":""}),e(s,{label:"\u64CD\u4F5C",width:"160",fixed:"right"},{default:l(({row:t})=>[_((m(),p(d,{type:"primary",link:"",onClick:b=>T(t)},{default:l(()=>[ge]),_:2},1032,["onClick"])),[[F,["custom/demand.customer_demand/edit"]]]),_((m(),p(d,{type:"danger",link:"",onClick:b=>g(t.id)},{default:l(()=>[ye]),_:2},1032,["onClick"])),[[F,["custom/demand.customer_demand/delete"]]]),_((m(),p(d,{link:"",onClick:b=>M(t)},{default:l(()=>[xe]),_:2},1032,["onClick"])),[[F,["custom/demand.customer_demand/detail"]]])]),_:1})]),_:1},8,["data"])]),L("div",Ae,[e(W,{modelValue:i(f),"onUpdate:modelValue":o[10]||(o[10]=t=>be(f)?f.value=t:null),onChange:i(E)},null,8,["modelValue","onChange"])])]),_:1})),[[z,i(f).loading]]),C.value?(m(),p(fe,{key:0,ref_key:"editRef",ref:B,"dict-data":i(v),onSuccess:i(E),onClose:o[11]||(o[11]=t=>C.value=!1)},null,8,["dict-data","onSuccess"])):$("",!0),w.value?(m(),p(Fe,{key:1,ref_key:"detailRef",ref:D,"dict-data":i(v),onClose:o[12]||(o[12]=t=>w.value=!1)},null,8,["dict-data"])):$("",!0)])}}});export{Ao as default};
|