2 lines
6.3 KiB
JavaScript
2 lines
6.3 KiB
JavaScript
import{a4 as L,k as N,B as j,C as q,a1 as H,a2 as K,b as O,G as S,H as $,D as z}from"./element-plus.9816852d.js";import{P as J}from"./index.2d3a3dd9.js";import{i as Q}from"./examined.6dd89177.js";import"./lodash.675f209e.js";import{d as A,r as k,s as F,e as W,$ as v,o as m,c as _,U as e,L as a,u as o,T as C,a7 as x,K as X,R as B}from"./@vue.51d7f2d8.js";import{d as Y}from"./index.4eaf9bd5.js";import"./@vueuse.ec90c285.js";import"./@element-plus.a074d1f6.js";import"./lodash-es.29c53eac.js";import"./dayjs.576af3ba.js";import"./@amap.8a62addd.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.b082b0c1.js";import"./@popperjs.36402333.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./index.vue_vue_type_style_index_0_scoped_95d1884e_lang.0fc4c9f8.js";import"./axios.54f807ba.js";import"./vue-router.9f65afb1.js";import"./pinia.56356cb7.js";import"./vue-demi.b3a9cad9.js";import"./css-color-function.0a5c0f85.js";import"./color.e5eb3bba.js";import"./clone.546d9b81.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./debug.aee266dc.js";import"./ms.a9ae1d6d.js";import"./nprogress.f73355d0.js";import"./vue-clipboard3.dca5bca3.js";import"./clipboard.16e4491b.js";import"./echarts.ac57a99a.js";import"./zrender.d54ce080.js";import"./tslib.60310f1a.js";import"./highlight.js.dba6fa1b.js";import"./@highlightjs.40d5feba.js";const Z={class:"edit-popup"},ee=["src"],te=A({name:"flowEdit"}),ae=A({...te,props:{dictData:{type:Object,default:()=>({})}},emits:["success","close"],setup(le,{expose:w,emit:y}){k(!1);const E=F(),c=F(),p=k("add"),D=W(()=>p.value=="edit"?"\u5BA1\u6838":"\u8BE6\u60C5");k([{content:"\u4EFB\u52A1\u5B8C\u6210",timestamp:"2023-8-28 13:30:00"},{content:"\u5F20\u4E09\u4E09\u5BA1\u6838",timestamp:"2023-8-28 13:30:00"},{content:"\u674E\u601D\u601D\u5BA1\u6838",timestamp:"2023-8-28 13:30:00",type:"primary",hollow:!0}]);const l=v({id:"",task:{},company_name:"",area_manager:"",check_status:1,remark:""}),g=v({check_status:[{required:!0,validator:(d,t,r)=>{t!=2&&t!=3?r("\u8BF7\u9009\u62E9\u5BA1\u6838\u72B6\u6001"):r()},trigger:["blur"]}]}),R=async d=>{for(const t in l)d[t]!=null&&d[t]!=null&&(l[t]=d[t])},U=async d=>{},h=async()=>{var d,t;if(await((d=E.value)==null?void 0:d.validate()),l.check_status==3&&l.remark=="")return N.error("\u9A73\u56DE\u5FC5\u987B\u586B\u5199\u5907\u6CE8");await Q({id:l.id,check_status:l.check_status,remark:l.remark}),(t=c.value)==null||t.close(),y("success")},I=(d="add")=>{var t;p.value=d,(t=c.value)==null||t.open()},M=()=>{y("close")};return w({open:I,setFormData:R,getDetail:U}),(d,t)=>{const r=j,n=q,s=H,f=K,b=L,P=O,V=S,T=$,G=z;return m(),_("div",Z,[e(J,{ref_key:"popupRef",ref:c,title:o(D),async:!0,width:"800px",onConfirm:h,onClose:M,button:o(p)=="edit",clickModalClose:o(p)=="details"},{default:a(()=>[e(G,{ref_key:"formRef",ref:E,model:o(l),rules:o(g),"label-width":"120px"},{default:a(()=>[e(f,null,{default:a(()=>[e(s,{span:12},{default:a(()=>[e(n,{label:"ID",prop:"id"},{default:a(()=>[e(r,{readonly:"",modelValue:o(l).id,"onUpdate:modelValue":t[0]||(t[0]=u=>o(l).id=u)},null,8,["modelValue"])]),_:1})]),_:1}),e(s,{span:12},{default:a(()=>[e(n,{label:"\u4EFB\u52A1\u540D\u79F0",prop:"task.title"},{default:a(()=>[e(r,{readonly:"",modelValue:o(l).task.title,"onUpdate:modelValue":t[1]||(t[1]=u=>o(l).task.title=u)},null,8,["modelValue"])]),_:1})]),_:1}),e(s,{span:12},{default:a(()=>[e(n,{label:"\u4EFB\u52A1\u91D1\u989D",prop:"task.money"},{default:a(()=>[e(r,{readonly:"",modelValue:o(l).task.money,"onUpdate:modelValue":t[2]||(t[2]=u=>o(l).task.money=u)},null,8,["modelValue"])]),_:1})]),_:1}),e(s,{span:12},{default:a(()=>[e(n,{label:"\u6240\u5C5E\u516C\u53F8",prop:"company_name"},{default:a(()=>[e(r,{readonly:"",modelValue:o(l).company_name,"onUpdate:modelValue":t[3]||(t[3]=u=>o(l).company_name=u)},null,8,["modelValue"])]),_:1})]),_:1}),e(s,{span:24},{default:a(()=>[e(n,{label:"\u4EFB\u52A1\u63CF\u8FF0",prop:"task.content"},{default:a(()=>[e(r,{readonly:"",modelValue:o(l).task.content,"onUpdate:modelValue":t[4]||(t[4]=u=>o(l).task.content=u),clearable:"",type:"textarea"},null,8,["modelValue"])]),_:1})]),_:1}),e(s,{span:12},{default:a(()=>[e(n,{label:"\u4EFB\u52A1\u63D0\u4EA4\u65F6\u95F4",prop:"id"},{default:a(()=>[e(r,{readonly:"",modelValue:o(l).task.update_time,"onUpdate:modelValue":t[5]||(t[5]=u=>o(l).task.update_time=u)},null,8,["modelValue"])]),_:1})]),_:1}),e(s,{span:12},{default:a(()=>[e(n,{label:"\u7247\u533A\u7ECF\u7406",prop:"flow_cate"},{default:a(()=>[e(r,{readonly:"",modelValue:o(l).area_manager,"onUpdate:modelValue":t[6]||(t[6]=u=>o(l).area_manager=u)},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),e(b),e(f,null,{default:a(()=>[e(s,{span:24},{default:a(()=>[e(n,{label:"\u8BE6\u60C5\u63CF\u8FF0",prop:"remark"},{default:a(()=>{var u;return[e(r,{readonly:"",value:(u=o(l).task)==null?void 0:u.extend.other.note,clearable:"",type:"textarea"},null,8,["value"])]}),_:1})]),_:1}),e(s,{span:24},{default:a(()=>[e(n,{label:"\u56FE\u7247\u9644\u4EF6"},{default:a(()=>[(m(!0),_(C,null,x(o(l).task.extend.other.annex,(u,i)=>(m(),X(P,{class:"attachment",key:i,src:u,"preview-src-list":o(l).task.extend.other.annex,"initial-index":i,fit:"cover"},null,8,["src","preview-src-list","initial-index"]))),128))]),_:1})]),_:1}),e(s,{span:24},{default:a(()=>[e(n,{label:"\u89C6\u9891\u9644\u4EF6"},{default:a(()=>[(m(!0),_(C,null,x(o(l).task.extend.other.video_annex,(u,i)=>(m(),_("video",{class:"video",src:u,key:i,controls:""},null,8,ee))),128))]),_:1})]),_:1})]),_:1}),e(b),e(s,{span:12},{default:a(()=>[e(n,{label:"\u5BA1\u6838",prop:"check_status",clearable:"",style:{width:"100%"}},{default:a(()=>[e(T,{disabled:o(p)=="details",modelValue:o(l).check_status,"onUpdate:modelValue":t[7]||(t[7]=u=>o(l).check_status=u)},{default:a(()=>[e(V,{label:2},{default:a(()=>[B("\u901A\u8FC7")]),_:1}),e(V,{label:3},{default:a(()=>[B("\u9A73\u56DE")]),_:1})]),_:1},8,["disabled","modelValue"])]),_:1})]),_:1}),e(f,null,{default:a(()=>[e(s,null,{default:a(()=>[e(n,{label:"\u5907\u6CE8",prop:"remark"},{default:a(()=>[e(r,{readonly:o(p)=="details",modelValue:o(l).remark,"onUpdate:modelValue":t[8]||(t[8]=u=>o(l).remark=u),clearable:"",type:"textarea"},null,8,["readonly","modelValue"])]),_:1})]),_:1})]),_:1})]),_:1},8,["model","rules"])]),_:1},8,["title","button","clickModalClose"])])}}});const He=Y(ae,[["__scopeId","data-v-707b58fb"]]);export{He as default};
|