|
- var J=Object.defineProperty,K=Object.defineProperties;var Q=Object.getOwnPropertyDescriptors;var x=Object.getOwnPropertySymbols;var X=Object.prototype.hasOwnProperty,Z=Object.prototype.propertyIsEnumerable;var B=(d,s,r)=>s in d?J(d,s,{enumerable:!0,configurable:!0,writable:!0,value:r}):d[s]=r,j=(d,s)=>{for(var r in s||(s={}))X.call(s,r)&&B(d,r,s[r]);if(x)for(var r of x(s))Z.call(s,r)&&B(d,r,s[r]);return d},R=(d,s)=>K(d,Q(s));var C=(d,s,r)=>new Promise((T,w)=>{var q=p=>{try{g(r.next(p))}catch(a){w(a)}},U=p=>{try{g(r.throw(p))}catch(a){w(a)}},g=p=>p.done?T(p.value):Promise.resolve(p.value).then(q,U);g((r=r.apply(d,s)).next())});import{_ as ee,d as le,x as $,y as z,r as D,z as ae,R as te,f as m,g as c,n as N,w as o,e as l,c as b,q as y,v as M,F as V,b as oe,B as re,h as _,i as se}from"./index.18b48fb5.js";import{s as de}from"./carManage.430858e5.js";const ue=_("\u9009\u62E9"),ne=_("\u9009\u62E9"),ie=_("\u9009\u62E9"),pe=["onClick"],me=_(" \u5220\u9664 "),ce=_("\u6DFB\u52A0\u6CBF\u9014\u70B9"),ve=_(" \u63D0\u4EA4 "),_e=_(" \u5173\u95ED "),fe=le({name:"releaseOrderDialog"}),ge=Object.assign(fe,{props:{visible:{type:Boolean,default:!1,required:!0},data:Object},emits:["close"],setup(d,{emit:s}){const r=d,{proxy:T}=se(),{jobTypeOptions:w}=$(z.dictStore),q={1:"\u6D4B\u8BD51",2:"\u6D4B\u8BD52",3:"\u6D4B\u8BD53"},U={1:"\u53F8\u673A1",2:"\u53F8\u673A2",3:"\u53F8\u673A3"},{dictList:g}=$(z.dictStore),p=D(),a=D({ways:[]}),A={demand:[{required:!0,message:"\u8BF7\u9009\u62E9\u5173\u8054\u9700\u6C42",trigger:"change"}],project:[{required:!0,message:"\u8BF7\u9009\u62E9\u9879\u76EE",trigger:"change"}],times:[{required:!0,message:"\u8BF7\u9009\u62E9\u7528\u8F66\u65F6\u95F4",trigger:"change"}],carType:[{required:!0,message:"\u8BF7\u9009\u62E9\u8F66\u8F86\u7C7B\u578B",trigger:"change"}],jobType:[{required:!0,message:"\u8BF7\u9009\u62E9\u5DE5\u4F5C\u7C7B\u578B",trigger:"blur"}],userName:[{required:!0,message:"\u8BF7\u9009\u62E9\u4E58\u8F66\u4EBA",trigger:"change"}],driverName:[{required:!0,message:"\u8BF7\u9009\u62E9\u53F8\u673A",trigger:"change"}],addresses:[{required:!0,message:"\u8BF7\u9009\u62E9\u4E0A\u8F66\u5730\u70B9",trigger:"change"}],downAddresses:[{required:!0,message:"\u8BF7\u9009\u62E9\u4E0B\u8F66\u5730\u70B9",trigger:"change"}]},H=()=>{a.value.ways.push({})},F=v=>{a.value.ways.splice(v,1)},L=v=>C(this,null,function*(){!v||(yield v.validate(t=>C(this,null,function*(){var u;t&&(yield de(R(j({},a.value),{regionCode:(u=a.value.regionCode)==null?void 0:u.at(-1)})),T.$message.success(`${r.data&&r.data.id?"\u7F16\u8F91":"\u65B0\u589E"}\u6210\u529F\uFF01`),s("close",!0))})))}),I=D([]);return ae(()=>r.visible,v=>C(this,null,function*(){var t;v?(I.value=(yield te()).data,(t=r.data)!=null&&t.id&&(a.value=j({},r.data))):(a.value={},p.value.resetFields())})),(v,t)=>{var O;const u=m("el-option"),f=m("el-select"),i=m("el-form-item"),S=m("el-date-picker"),k=m("el-input"),P=m("Delete"),W=m("el-icon"),h=m("el-button"),E=m("el-form"),G=m("el-dialog");return c(),N(G,{"model-value":d.visible,title:(O=r==null?void 0:r.data)!=null&&O.id?"\u5173\u8054\u8BA2\u5355":"\u53D1\u5E03\u8BA2\u5355",width:"840px","destroy-on-close":"",onClose:t[12]||(t[12]=e=>s("close"))},{footer:o(()=>[l(h,{type:"primary",size:"small",onClick:t[10]||(t[10]=e=>L(p.value))},{default:o(()=>[ve]),_:1}),l(h,{type:"info",size:"small",onClick:t[11]||(t[11]=e=>s("close"))},{default:o(()=>[_e]),_:1})]),default:o(()=>[l(E,{ref_key:"formRef",ref:p,model:a.value,rules:A,"label-width":"90px","label-suffix":":",size:"small"},{default:o(()=>[l(i,{label:"\u5173\u8054\u9700\u6C42",prop:"demand"},{default:o(()=>[l(f,{modelValue:a.value.demand,"onUpdate:modelValue":t[0]||(t[0]=e=>a.value.demand=e),clearable:"",placeholder:"\u8BF7\u9009\u62E9",class:"w-full"},{default:o(()=>[l(u,{label:"\u5173\u8054\u9700\u6C42\u6D4B\u8BD51",value:1}),l(u,{label:"\u5173\u8054\u9700\u6C42\u6D4B\u8BD52",value:2}),l(u,{label:"\u5173\u8054\u9700\u6C42\u6D4B\u8BD53",value:3})]),_:1},8,["modelValue"])]),_:1}),l(i,{label:"\u9879\u76EE",prop:"project"},{default:o(()=>[l(f,{modelValue:a.value.project,"onUpdate:modelValue":t[1]||(t[1]=e=>a.value.project=e),clearable:"",placeholder:"\u8BF7\u9009\u62E9",class:"w-full"},{default:o(()=>[l(u,{label:"\u6D4B\u8BD5\u9879\u76EE1",value:1}),l(u,{label:"\u6D4B\u8BD5\u9879\u76EE2",value:2}),l(u,{label:"\u6D4B\u8BD5\u9879\u76EE3",value:3})]),_:1},8,["modelValue"])]),_:1}),l(i,{label:"\u7528\u8F66\u65F6\u95F4",prop:"times"},{default:o(()=>[l(S,{modelValue:a.value.times,"onUpdate:modelValue":t[2]||(t[2]=e=>a.value.times=e),format:"YYYY-MM-DD HH:mm","value-format":"YYYY-MM-DD HH:mm",type:"datetimerange","start-placeholder":"\u5F00\u59CB\u65F6\u95F4","end-placeholder":"\u7ED3\u675F\u65F6\u95F4"},null,8,["modelValue"])]),_:1}),l(i,{label:"\u8F66\u8F86\u7C7B\u578B",prop:"carType"},{default:o(()=>[l(f,{modelValue:a.value.carType,"onUpdate:modelValue":t[3]||(t[3]=e=>a.value.carType=e),clearable:"",placeholder:"\u8BF7\u9009\u62E9",class:"w-full"},{default:o(()=>[(c(!0),b(V,null,y(M(g).find(e=>e.dictType==="car_type").dictData,e=>(c(),N(u,{key:e.id,label:e.dictLabel,value:e.dictValue},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),l(i,{label:"\u5DE5\u4F5C\u7C7B\u578B",prop:"jobType"},{default:o(()=>[l(f,{modelValue:a.value.jobType,"onUpdate:modelValue":t[4]||(t[4]=e=>a.value.jobType=e),clearable:"",placeholder:"\u8BF7\u9009\u62E9",class:"w-full"},{default:o(()=>[(c(!0),b(V,null,y(M(w),(e,n)=>(c(),N(u,{key:n,label:e,value:n},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),l(i,{label:"\u4E58\u8F66\u4EBA",prop:"userName"},{default:o(()=>[l(f,{modelValue:a.value.userName,"onUpdate:modelValue":t[5]||(t[5]=e=>a.value.userName=e),clearable:"",placeholder:"\u8BF7\u9009\u62E9",class:"w-full"},{default:o(()=>[(c(),b(V,null,y(q,(e,n)=>l(u,{key:n,label:e,value:n},null,8,["label","value"])),64))]),_:1},8,["modelValue"])]),_:1}),l(i,{label:"\u53F8\u673A",prop:"driverName"},{default:o(()=>[l(f,{modelValue:a.value.driverName,"onUpdate:modelValue":t[6]||(t[6]=e=>a.value.driverName=e),clearable:"",placeholder:"\u8BF7\u9009\u62E9",class:"w-full"},{default:o(()=>[(c(),b(V,null,y(U,(e,n)=>l(u,{key:n,label:e,value:n},null,8,["label","value"])),64))]),_:1},8,["modelValue"])]),_:1}),l(i,{label:"\u4E0A\u8F66\u5730\u70B9",prop:"addresses"},{default:o(()=>[l(k,{modelValue:a.value.addresses,"onUpdate:modelValue":t[7]||(t[7]=e=>a.value.addresses=e),placeholder:"\u8BF7\u9009\u62E9\u5730\u70B9"},{append:o(()=>[ue]),_:1},8,["modelValue"])]),_:1}),l(i,{label:"\u4E0B\u8F66\u5730\u70B9",prop:"downAddresses"},{default:o(()=>[l(k,{modelValue:a.value.downAddresses,"onUpdate:modelValue":t[8]||(t[8]=e=>a.value.downAddresses=e),placeholder:"\u8BF7\u9009\u62E9\u5730\u70B9"},{append:o(()=>[ne]),_:1},8,["modelValue"])]),_:1}),(c(!0),b(V,null,y(a.value.ways,(e,n)=>(c(),N(i,{key:n,label:"\u6CBF\u9014\u70B9"+(n+1),prop:"ways."+n+".value",rules:{required:!0,message:"\u8BF7\u9009\u62E9",trigger:"blur"}},{default:o(()=>[l(k,{modelValue:e.value,"onUpdate:modelValue":Y=>e.value=Y,placeholder:"\u8BF7\u9009\u62E9\u5730\u70B9",style:{width:"90%"}},{append:o(()=>[ie]),_:2},1032,["modelValue","onUpdate:modelValue"]),oe("div",{class:"ml-12 del",onClick:Y=>F(n)},[l(W,null,{default:o(()=>[l(P)]),_:1}),me],8,pe)]),_:2},1032,["label","prop"]))),128)),l(i,null,{default:o(()=>[l(h,{icon:"Plus",onClick:re(H,["prevent"])},{default:o(()=>[ce]),_:1},8,["onClick"])]),_:1}),l(i,{label:"\u5907\u6CE8"},{default:o(()=>[l(k,{modelValue:a.value.desc,"onUpdate:modelValue":t[9]||(t[9]=e=>a.value.desc=e),autosize:{minRows:2,maxRows:4},type:"textarea",placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["model-value","title"])}}}),we=ee(ge,[["__scopeId","data-v-a3c8f0a8"]]);export{we as default};
|