import{o as M,d as N}from"./store.79aaf4bd.js";import{d as R,a6 as I,r as E,b as y,p as q,V as T,c as l,e as v,f as P,g as _,h as t,i as a,u as c,k as U,q as j,A as L,F as O,m as n,a as F,R as z,S as G,aN as H,_ as J}from"./index.0308b213.js";const K=p=>(z("data-v-a3f5578d"),p=p(),G(),p),Q={class:"filter-form"},W=n("\u4ECA\u5929"),X=n("\u6700\u8FD17\u5929"),Z=n("\u6700\u8FD130\u5929"),$=n("\u81EA\u5B9A\u4E49"),ee=n("\u67E5\u8BE2"),te=n("\u5BFC\u51FA"),ae=K(()=>_("div",{class:"header"},[_("div",{class:"tn-title--vertical-line title"}," \u8868\u683C\u6570\u636E ")],-1)),oe={class:"body"},le={class:"table"},ue=n("\u70B9\u51FB\u67E5\u770B"),ne=R({setup(p){I(),E(!0);const B=[{text:"\u4E00\u5468\u5185",value:()=>{const e=F();return[e.subtract(1,"week").toDate(),e.toDate()]}},{text:"\u4E24\u5468\u5185",value:()=>{const e=F();return[e.subtract(2,"week").toDate(),e.toDate()]}},{text:"\u4E00\u4E2A\u6708\u5185",value:()=>{const e=F();return[e.subtract(1,"month").toDate(),e.toDate()]}}],o=y({sid:"",agentid:"",orderby:"total_fee",days:0,stat_day:"",end_day:"",areaid:""}),D=y({list:[]}),C=()=>{M(o).then(e=>{console.log("res",e),window.open(e.data)})};y({sid:[],value:[]});let i=E([]);const k=()=>{const e=H(i.value,"YYYY-MM-DD");o.stat_day=e[0]||"",o.end_day=e[1]||""},m=()=>{k(),N(o).then(e=>{console.log("res",e),D.list=e})};m();const A=()=>{m()};q(()=>[o.days,o.sid,o.orderby],()=>{m()});const{router:Y,route:se}=T(),V=e=>{let s=e.uid,r=e.start_date,f=e.end_date,b=e.sid,h="/agent/order/takeway/all",g={uid:s,start_date:r,end_date:f,sid:b};Y.push({path:h,query:g})};return(e,s)=>{const r=l("el-radio"),f=l("el-radio-group"),b=l("el-date-picker"),h=l("el-form-item"),g=l("el-form"),x=l("el-button"),u=l("el-table-column"),w=l("el-table"),S=l("el-card");return v(),P(O,null,[_("div",Q,[t(g,{model:c(o),"label-width":"90px"},{default:a(()=>[t(h,{class:"tn-el-form-item",label:"\u7B5B\u9009\u65F6\u95F4"},{default:a(()=>[t(f,{modelValue:c(o).days,"onUpdate:modelValue":s[0]||(s[0]=d=>c(o).days=d)},{default:a(()=>[t(r,{border:!0,label:0},{default:a(()=>[W]),_:1}),t(r,{border:!0,label:7},{default:a(()=>[X]),_:1}),t(r,{border:!0,label:30},{default:a(()=>[Z]),_:1}),t(r,{border:!0,label:-1},{default:a(()=>[$]),_:1})]),_:1},8,["modelValue"]),c(o).days===-1?(v(),U(b,{key:0,modelValue:c(i),"onUpdate:modelValue":s[1]||(s[1]=d=>j(i)?i.value=d:i=d),type:"daterange","range-separator":"\u81F3","start-placeholder":"\u5F00\u59CB\u65F6\u95F4","end-placeholder":"\u7ED3\u675F\u65F6\u95F4",format:"YYYY-MM-DD","value-format":"YYYY-MM-DD",style:{"margin-left":"8px"},shortcuts:B},null,8,["modelValue"])):L("",!0)]),_:1})]),_:1},8,["model"]),t(x,{class:"tn-el-form-item--item tn-button tn-button--green",onClick:A},{default:a(()=>[ee]),_:1}),t(x,{class:"tn-el-form-item--item tn-button tn-button--blue",onClick:C},{default:a(()=>[te]),_:1})]),t(S,{class:"trend"},{header:a(()=>[ae]),default:a(()=>[_("div",oe,[_("div",le,[t(w,{data:c(D).list,border:!0,style:{width:"100%","margin-top":"10px"}},{default:a(()=>[t(u,{label:"\u5E8F\u53F7",fixed:"",type:"index",width:"55px",align:"center"}),t(u,{label:"\u5E97\u94FA",fixed:"",prop:"store_title",align:"center"}),t(u,{label:"\u5B66\u6821",fixed:"",prop:"area_text",align:"center"}),t(u,{label:"\u697C\u680B",fixed:"",prop:"area_parent_text",align:"center"}),t(u,{label:"\u697C\u957F\u540D\u79F0",fixed:"",prop:"username",align:"center"}),t(u,{label:"\u697C\u957F\u624B\u673A\u53F7",fixed:"",prop:"mobile",align:"center"}),t(u,{label:"\u8BA2\u5355\u660E\u7EC6",fixed:"",prop:"",align:"center"},{default:a(({row:d})=>[t(x,{type:"text",onClick:re=>V(d)},{default:a(()=>[ue]),_:2},1032,["onClick"])]),_:1}),t(u,{label:"\u4E0A\u8D27\u91D1\u989D",fixed:"",prop:"fee",align:"center"})]),_:1},8,["data"])])])]),_:1})],64)}}});const ie=J(ne,[["__scopeId","data-v-a3f5578d"]]);export{ie as default};
