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,v as f,t as v,y,z as g}from"./index-d0748378.js";import{_ as x,a as h}from"./right2.a72c0f79.js";import{_ as k,a as b}from"./_plugin-vue_export-helper.85faaf7d.js";import{o as j,b as C}from"./uni-app.es.74adb8e7.js";import{m as I}from"./api.9a3ad04e.js";import{i as L,f as D}from"./filterIdentity.cbbb7619.js";import{S as w}from"./search.bf783dee.js";import"./bottom.64dd5779.js";const E=k({__name:"recordDriver",setup(k){j((()=>{L()?(D(),H(),F()):t({url:"/pages/404/404?message=请在微信客户端打开链接"})})),C((()=>{H(),F(),setTimeout((function(){a()}),500)}));const E=e(0),M=e([{text:"全部",value:0},{text:"预约进行中",value:1},{text:"已截止",value:2},{text:"已分配",value:3},{text:"候补中",value:4}]),S=e("全部"),q=e([{text:"全部",value:0}]),z=e([]),F=async()=>{const t=await I({url:"/appcarCaptainManage.action",data:{result_state:E.value,car_number:S.value}});t.data.length&&t.data.forEach((t=>{t.percent=Math.ceil(parseInt(t.user_num)/parseInt(t.contain)*100)})),z.value=t.data},H=async()=>{const t=await I({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})})),q.value=a}},J=t=>{E.value=t.typeIndex,S.value=q.value[t.timeIndex].text,F()};return(t,a)=>{const e=i,k=g;return s(),l(e,{class:"container"},{default:r((()=>[n(u(w),{typeList:M.value,timeList:q.value,onHandLeConveyData:J},null,8,["typeList","timeList"]),(s(!0),c(m,null,o(z.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:f(["list-title","南昌-靖安"===t.route?"type":"type2"])},{default:r((()=>[n(e,{class:"title-number"},{default:r((()=>[_(v(t.route)+"   车牌："+v(0!=t.car_number?t.car_number:"无"),1)])),_:2},1024),n(e,{class:"title-icon"},{default:r((()=>["南昌-靖安"===t.route?(s(),c("img",{key:0,src:x})):d("",!0),"靖安-南昌"===t.route?(s(),c("img",{key:1,src:h})):d("",!0)])),_:2},1024)])),_:2},1032,["class"]),n(e,{class:"list-item"},{default:r((()=>[_(" 状态： "),p("span",{class:f("预约进行中"==t.state_str||"候补中"==t.state_str?"list-item-type":"")},v(t.state_str),3)])),_:2},1024),n(e,{class:"list-item"},{default:r((()=>[_(" 发车日期： "),p("span",null,v(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,v(0!=t.ci_time?t.ci_time:""),1)])),_:2},1024)):d("",!0),n(e,{class:"list-item"},{default:r((()=>[_(" 扫码时间： "),p("span",null,v(t.sm_start+"-"+t.sm_end),1)])),_:2},1024),n(e,{class:"list-item"},{default:r((()=>[_(" 站点： "),p("span",null,v(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(k,{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},v(t.user_num+"/"+t.contain),1)):(s(),c("span",{key:2},v(t.contain),1))])),_:2},1024)])),_:2},1032,["onClick"])))),128)),0==z.value.length?(s(),l(e,{key:0,class:"list-nodata"},{default:r((()=>[p("img",{src:b}),n(e,null,{default:r((()=>[_("暂无数据")])),_:1})])),_:1})):d("",!0)])),_:1})}}},[["__scopeId","data-v-b50ea2cf"]]);export{E as default};
