import{b as t,d as a,e,o as s,c as l,f as r,i,h as n,x as u,l as c,m as o,F as m,k as p,j as _,n as d,t as f,v,y,z as x}from"./index-b1399800.js";import{_ as g}from"./right.5b5369cb.js";import{_ as h,a as k}from"./_plugin-vue_export-helper.563c4239.js";import{o as j,b}from"./uni-app.es.6e445678.js";import{m as C}from"./api.a8ee9fc2.js";import{i as I,f as L}from"./filterIdentity.a5bf590d.js";import{S as D}from"./search.40e4fcd5.js";import"./bottom.64dd5779.js";const w=h({__name:"recordDriver",setup(h){j((()=>{I()?(L(),F(),z()):t({url:"/pages/404/404?message=请在微信客户端打开链接"})})),b((()=>{F(),z(),setTimeout((function(){a()}),500)}));const w=e(0),E=e([{text:"全部",value:0},{text:"预约进行中",value:1},{text:"已截止",value:2},{text:"已分配",value:3},{text:"候补中",value:4}]),M=e("全部"),S=e([{text:"全部",value:0}]),q=e([]),z=async()=>{const t=await C({url:"/appcarCaptainManage.action",data:{result_state:w.value,car_number:M.value}});t.data.length&&t.data.forEach((t=>{t.percent=Math.ceil(parseInt(t.user_num)/parseInt(t.contain)*100)})),q.value=t.data},F=async()=>{const t=await C({url:"/appqueryCarInfos.action"});if(t.data.length){let a=[{text:"全部",value:0}];t.data.forEach(((t,e)=>{a.push({text:t.car_number,value:e+1})})),S.value=a}},H=t=>{w.value=t.typeIndex,M.value=S.value[t.timeIndex].text,z()};return(t,a)=>{const e=i,h=x;return s(),l(e,{class:"container"},{default:r((()=>[n(u(D),{typeList:E.value,timeList:S.value,onHandLeConveyData:H},null,8,["typeList","timeList"]),(s(!0),c(m,null,o(q.value,((t,a)=>(s(),l(e,{class:"list",key:a,onClick:a=>(t=>{const a=JSON.stringify(t);y({url:`/pages/detailDriver/detailDriver?info=${a}`})})(t)},{default:r((()=>[n(e,{class:"list-title"},{default:r((()=>[n(e,{class:"title-number"},{default:r((()=>[_("车牌："+f(0!=t.car_number?t.car_number:"无"),1)])),_:2},1024),n(e,{class:"title-icon"},{default:r((()=>[p("img",{src:g})])),_:1})])),_:2},1024),n(e,{class:"list-item"},{default:r((()=>[_(" 状态： "),p("span",{class:v("预约进行中"==t.state_str||"候补中"==t.state_str?"list-item-type":"")},f(t.state_str),3)])),_:2},1024),n(e,{class:"list-item"},{default:r((()=>[_(" 发车日期： "),p("span",null,f(t.yy_date),1)])),_:2},1024),"预约进行中"==t.state_str||"已截止"==t.state_str?(s(),l(e,{key:0,class:"list-item"},{default:r((()=>[_(" 发车时间： "),p("span",null,f(0!=t.ci_time?t.ci_time:""),1)])),_:2},1024)):d("",!0),n(e,{class:"list-item"},{default:r((()=>[_(" 扫码时间： "),p("span",null,f(t.sm_start+"-"+t.sm_end),1)])),_:2},1024),n(e,{class:"list-item"},{default:r((()=>[_(" 线路： "),p("span",null,f(t.route),1)])),_:2},1024),n(e,{class:"list-item"},{default:r((()=>[_(" 站点： "),p("span",null,f(t.route_end),1)])),_:2},1024),n(e,{class:"list-item"},{default:r((()=>[_(" 人数： "),"预约进行中"==t.state_str||"已截止"==t.state_str?(s(),l(e,{key:0,class:"list-item-progress"},{default:r((()=>[n(h,{activeColor:"#3C50E8","stroke-width":"9",percent:t.percent?t.percent:0},null,8,["percent"])])),_:2},1024)):d("",!0),"预约进行中"==t.state_str||"已截止"==t.state_str?(s(),c("span",{key:1},f(t.user_num+"/"+t.contain),1)):(s(),c("span",{key:2},f(t.contain),1))])),_:2},1024)])),_:2},1032,["onClick"])))),128)),0==q.value.length?(s(),l(e,{key:0,class:"list-nodata"},{default:r((()=>[p("img",{src:k}),n(e,null,{default:r((()=>[_("暂无数据")])),_:1})])),_:1})):d("",!0)])),_:1})}}},[["__scopeId","data-v-27a13543"]]);export{w as default};
