Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

index.6c60a18a.js 4.9KB

2 månader sedan
1
  1. var J=Object.defineProperty,K=Object.defineProperties;var Q=Object.getOwnPropertyDescriptors;var O=Object.getOwnPropertySymbols;var X=Object.prototype.hasOwnProperty,Y=Object.prototype.propertyIsEnumerable;var $=(n,t,l)=>t in n?J(n,t,{enumerable:!0,configurable:!0,writable:!0,value:l}):n[t]=l,N=(n,t)=>{for(var l in t||(t={}))X.call(t,l)&&$(n,l,t[l]);if(O)for(var l of O(t))Y.call(t,l)&&$(n,l,t[l]);return n},S=(n,t)=>K(n,Q(t));var h=(n,t,l)=>new Promise((C,v)=>{var r=d=>{try{_(l.next(d))}catch(m){v(m)}},p=d=>{try{_(l.throw(d))}catch(m){v(m)}},_=d=>d.done?C(d.value):Promise.resolve(d.value).then(r,p);_((l=l.apply(n,t)).next())});import{l as Z,d as ee}from"./carManage.18590e23.js";import{u as ae}from"./useTreeSelectData.55c00ed4.js";import{d as te,y as le,z as oe,r as y,a as se,o as ne,R as re,f as i,g as T,c as B,e,w as a,F as ie,s as de,p as ce,x as L,b as k,h as V,O as P,i as ue}from"./index.6d448f34.js";import pe from"./carDialog.718f0cba.js";import"./userManage.d1e919e5.js";import"./uploadAction.46257434.js";const _e={class:"carManage"},me=V("\u67E5\u8BE2"),fe=V("\u91CD\u7F6E"),be={class:"flex justify-between items-center"},ve=k("span",null,"\u8F66\u8F86\u5217\u8868",-1),ye=V(" \u65B0\u589E\u8F66\u8F86 "),we=["onClick"],ge=["onClick"],he=te({name:"carManage"}),Oe=Object.assign(he,{setup(n){const{proxy:t}=ue(),{cascaderProps:l}=ae(),{dictList:C}=le(oe.dictStore),v=y([]),r=y({}),p=y(),_=y(0),d=[{label:"\u5E8F\u53F7",type:"index",width:"80"},{label:"\u8F66\u724C\u53F7\u7801",key:"carNo",prop:"carNo",width:"120"},{label:"\u8F66\u8F86\u7C7B\u578B",key:"carTypeName",prop:"carTypeName",width:"160"},{label:"\u6240\u5C5E\u533A\u57DF",key:"regionDisplayName",prop:"regionDisplayName",minWidth:"180",showOverflowTooltip:!0},{label:"\u9A7E\u9A76\u5458",key:"driverName",render:o=>P("span",`${o.driverName} / ${o.mobile}`),minWidth:"220",showOverflowTooltip:!0},{label:"obd\u72B6\u6001",key:"obdState",render:o=>P("span",o.obdState?o.obdState:"-"),width:"120"},{label:"\u521B\u5EFA\u65F6\u95F4",key:"createOn",prop:"createOn",width:"180"},{label:"\u64CD\u4F5C",key:"action",slot:"action",width:"120",fixed:"right"}],m=y([]),f=(...b)=>h(this,[...b],function*(o=p.value.pageParams){var u;const w=yield Z(S(N(N({},o),r.value),{regionCode:(u=r.value.regionCode)==null?void 0:u.at(-1)}));_.value=w.data.total,m.value=w.data.records}),z=()=>{f()},R=()=>{r.value={},p.value.pageParams.pageNumber=1,p.value.pageParams.pageSize=10,f()},c=se({visible:!1,rowData:void 0}),F=()=>{c.visible=!0,c.rowData=void 0},M=o=>{c.visible=!0,c.rowData=o},U=o=>{t.$messageBox.confirm("\u662F\u5426\u5220\u9664\u8BE5\u6570\u636E?","\u63D0\u793A\uFF01",{type:"warning"}).then(()=>h(this,null,function*(){yield ee({id:o.id}),t.$message.success("\u5220\u9664\u6210\u529F\uFF01"),yield f()}))},j=o=>{c.visible=!1,o&&f()};return ne(()=>h(this,null,function*(){v.value=(yield re()).data,yield f()})),(o,b)=>{const w=i("el-input"),u=i("el-form-item"),g=i("el-col"),W=i("el-option"),E=i("el-select"),G=i("el-cascader"),x=i("el-button"),I=i("el-row"),q=i("el-form"),D=i("el-card"),A=i("table-list");return T(),B("div",_e,[e(D,{shadow:"never",class:"search mb-16"},{default:a(()=>[e(q,{"label-suffix":":",model:r.value,size:"small"},{default:a(()=>[e(I,{gutter:16},{default:a(()=>[e(g,{span:6},{default:a(()=>[e(u,{label:"\u8F66\u724C\u53F7\u7801"},{default:a(()=>[e(w,{modelValue:r.value.carNo,"onUpdate:modelValue":b[0]||(b[0]=s=>r.value.carNo=s),maxlength:"10",placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1})]),_:1}),e(g,{span:8},{default:a(()=>[e(u,{label:"\u8F66\u8F86\u7C7B\u578B"},{default:a(()=>[e(E,{modelValue:r.value.carType,"onUpdate:modelValue":b[1]||(b[1]=s=>r.value.carType=s),clearable:"",placeholder:"\u8BF7\u9009\u62E9",class:"w-full"},{default:a(()=>[(T(!0),B(ie,null,de(L(C).find(s=>s.dictType==="car_type").dictData,s=>(T(),ce(W,{key:s.id,label:s.dictLabel,value:s.dictValue},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1}),e(g,{span:10,class:"mb-16"},{default:a(()=>[e(u,{label:"\u6240\u5C5E\u533A\u57DF"},{default:a(()=>[e(G,{modelValue:r.value.regionCode,"onUpdate:modelValue":b[2]||(b[2]=s=>r.value.regionCode=s),props:L(l),options:v.value,clearable:"",class:"w-full"},null,8,["modelValue","props","options"])]),_:1})]),_:1}),e(g,{span:24},{default:a(()=>[e(u,{class:"btn"},{default:a(()=>[e(x,{type:"primary",onClick:z},{default:a(()=>[me]),_:1}),e(x,{type:"info",onClick:R},{default:a(()=>[fe]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),e(D,{shadow:"never"},{header:a(()=>[k("div",be,[ve,e(x,{type:"primary",icon:"Plus",size:"small",onClick:F},{default:a(()=>[ye]),_:1})])]),default:a(()=>[e(A,{ref_key:"tableListRef",ref:p,column:d,data:m.value,total:_.value,onGetTableData:f},{action:a(({scope:s})=>[k("a",{class:"text-primary",onClick:H=>M(s.row)},"\u7F16\u8F91",8,we),k("a",{class:"text-danger",onClick:H=>U(s.row)},"\u5220\u9664",8,ge)]),_:1},8,["data","total"])]),_:1}),e(pe,{visible:c.visible,data:c.rowData,onClose:j},null,8,["visible","data"])])}}});export{Oe as default};