Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

2 lignes
5.1KB

  1. var R=Object.defineProperty,$=Object.defineProperties;var H=Object.getOwnPropertyDescriptors;var y=Object.getOwnPropertySymbols;var M=Object.prototype.hasOwnProperty,B=Object.prototype.propertyIsEnumerable;var q=(u,t,o)=>t in u?R(u,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):u[t]=o,C=(u,t)=>{for(var o in t||(t={}))M.call(t,o)&&q(u,o,t[o]);if(y)for(var o of y(t))B.call(t,o)&&q(u,o,t[o]);return u},U=(u,t)=>$(u,H(t));var v=(u,t,o)=>new Promise((_,p)=>{var l=s=>{try{f(o.next(s))}catch(c){p(c)}},b=s=>{try{f(o.throw(s))}catch(c){p(c)}},f=s=>s.done?_(s.value):Promise.resolve(s.value).then(l,b);f((o=o.apply(u,t)).next())});import{s as O}from"./carManage.c8decc6b.js";import{u as T}from"./useTreeSelectData.70197ccd.js";import{d as N,r as w,z as F,R as I,f as d,g as P,n as S,w as n,e as a,v as A,h as Y,i as G}from"./index.47ab9a02.js";const J=Y(" \u63D0\u4EA4 "),K=Y(" \u5173\u95ED "),L=N({name:"vehicleDemandDialog"}),E=Object.assign(L,{props:{visible:{type:Boolean,default:!1,required:!0},data:Object},emits:["close"],setup(u,{emit:t}){const o=u,{proxy:_}=G(),p=w(),l=w({}),b={title:[{required:!0,message:"\u8BF7\u8F93\u5165\u9700\u6C42\u6807\u9898",trigger:"blur"}],project:[{required:!0,message:"\u8BF7\u9009\u62E9\u5173\u8054\u9879\u76EE",trigger:"change"}],number:[{required:!0,message:"\u8BF7\u8F93\u5165\u7528\u8F66\u6570\u91CF",trigger:"change"}],times:[{required:!0,message:"\u8BF7\u9009\u62E9\u7528\u8F66\u65F6\u95F4",trigger:"change"}],regionCode:[{required:!0,message:"\u8BF7\u9009\u62E9\u7528\u8F66\u533A\u57DF",trigger:"change"}],contacts:[{required:!0,message:"\u8BF7\u9009\u62E9\u7528\u8F66\u533A\u57DF",trigger:"change"}],phone:[{required:!0,message:"\u8BF7\u9009\u62E9\u7528\u8F66\u533A\u57DF",trigger:"change"}]},f=g=>v(this,null,function*(){!g||(yield g.validate(e=>v(this,null,function*(){var m;e&&(yield O(U(C({},l.value),{regionCode:(m=l.value.regionCode)==null?void 0:m.at(-1)})),_.$message.success(`${o.data&&o.data.id?"\u7F16\u8F91":"\u65B0\u589E"}\u6210\u529F\uFF01`),t("close",!0))})))}),{cascaderProps:s}=T(),c=w([]);return F(()=>o.visible,g=>v(this,null,function*(){var e;g?(c.value=(yield I()).data,(e=o.data)!=null&&e.id&&(l.value=C({},o.data))):(l.value={},p.value.resetFields())})),(g,e)=>{const m=d("el-input"),i=d("el-form-item"),V=d("el-option"),h=d("el-select"),k=d("el-date-picker"),D=d("el-cascader"),j=d("el-form"),x=d("el-button"),z=d("el-dialog");return P(),S(z,{"model-value":u.visible,title:"\u53D1\u5E03\u9700\u6C42",width:"840px","destroy-on-close":"",onClose:e[10]||(e[10]=r=>t("close"))},{footer:n(()=>[a(x,{type:"primary",size:"small",onClick:e[8]||(e[8]=r=>f(p.value))},{default:n(()=>[J]),_:1}),a(x,{type:"info",size:"small",onClick:e[9]||(e[9]=r=>t("close"))},{default:n(()=>[K]),_:1})]),default:n(()=>[a(j,{ref_key:"formRef",ref:p,model:l.value,rules:b,"label-width":"100px","label-suffix":":",size:"small"},{default:n(()=>[a(i,{label:"\u9700\u6C42\u6807\u9898",prop:"title"},{default:n(()=>[a(m,{modelValue:l.value.title,"onUpdate:modelValue":e[0]||(e[0]=r=>l.value.title=r),placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1}),a(i,{label:"\u5173\u8054\u9879\u76EE",prop:"project"},{default:n(()=>[a(h,{modelValue:l.value.project,"onUpdate:modelValue":e[1]||(e[1]=r=>l.value.project=r),clearable:"",placeholder:"\u8BF7\u9009\u62E9",class:"w-full"},{default:n(()=>[a(V,{label:"\u6D4B\u8BD5\u5173\u8054\u9879\u76EE1",value:1}),a(V,{label:"\u6D4B\u8BD5\u5173\u8054\u9879\u76EE2",value:2}),a(V,{label:"\u6D4B\u8BD5\u5173\u8054\u9879\u76EE3",value:3})]),_:1},8,["modelValue"])]),_:1}),a(i,{label:"\u7528\u8F66\u6570\u91CF",prop:"number"},{default:n(()=>[a(m,{modelValue:l.value.number,"onUpdate:modelValue":e[2]||(e[2]=r=>l.value.number=r),placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1}),a(i,{label:"\u7528\u8F66\u65F6\u95F4",prop:"times"},{default:n(()=>[a(k,{modelValue:l.value.times,"onUpdate:modelValue":e[3]||(e[3]=r=>l.value.times=r),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}),a(i,{label:"\u7528\u8F66\u533A\u57DF",prop:"regionCode"},{default:n(()=>[a(D,{modelValue:l.value.regionCode,"onUpdate:modelValue":e[4]||(e[4]=r=>l.value.regionCode=r),props:A(s),options:c.value,clearable:"",class:"w-full"},null,8,["modelValue","props","options"])]),_:1}),a(i,{label:"\u9879\u76EE\u8054\u7CFB\u4EBA",prop:"contacts"},{default:n(()=>[a(m,{modelValue:l.value.contacts,"onUpdate:modelValue":e[5]||(e[5]=r=>l.value.contacts=r),placeholder:"\u8BF7\u8F93\u5165",maxlength:"10"},null,8,["modelValue"])]),_:1}),a(i,{label:"\u8054\u7CFB\u65B9\u5F0F",prop:"phone"},{default:n(()=>[a(m,{modelValue:l.value.phone,"onUpdate:modelValue":e[6]||(e[6]=r=>l.value.phone=r),placeholder:"\u8BF7\u8F93\u5165",maxlength:"12"},null,8,["modelValue"])]),_:1}),a(i,{label:"\u5907\u6CE8"},{default:n(()=>[a(m,{modelValue:l.value.desc,"onUpdate:modelValue":e[7]||(e[7]=r=>l.value.desc=r),autosize:{minRows:2,maxRows:4},type:"textarea",placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["model-value"])}}});export{E as default};