import{a as I,g as w,A as L}from"./index.2e41469c.js";import{a as T,g as N,v as z}from"./index.9af1606c.js";import{a as D,w as P}from"./index.8af0c514.js";import{d as U,a6 as j,r,b as q,p as H,c as m,e as n,f as i,g as l,u as g,h as y,i as F,F as x,j as B,k as M,A as R,H as $,t as G,m as J,E as c,R as K,S as Q,_ as W}from"./index.0308b213.js";const b=d=>(K("data-v-91591694"),d=d(),Q(),d),X={class:"div"},Y={class:"container"},Z=b(()=>l("div",{style:{"font-size":"18px"}},"\u66F4\u65B0\u914D\u9001\u72B6\u6001",-1)),ee={key:0,class:"marginTop"},te={class:"container marginTop"},se={style:{display:"flex"}},ae=["onClick"],le={class:"marginTop",style:{position:"relative"}},oe=b(()=>l("text",{class:"tn-icon-scan",style:{"margin-right":"10px",position:"absolute",left:"220px",top:"8px"}},null,-1)),ue={class:"marginTop"},ne=J("\u786E\u8BA4"),re=U({setup(d){const{OpPlatform:a}=j(),o=r(""),t=q({sid:""}),h=r([]),_=r([]),p=r(0),f=r(0),S=()=>{a.value=="shangpu"?I(t).then(e=>{_.value=e.delivery_status}):a.value=="agent"?T(t).then(e=>{_.value=e.delivery_status}):D(t).then(e=>{_.value=e.delivery_status})};(()=>{a.value=="shangpu"?w({}).then(e=>{h.value=e.stores}):a.value&&N({}).then(e=>{h.value=e.stores})})(),S();const V=(e,u)=>{p.value=u,f.value=e},k=()=>{if(!o.value){c.error("\u8BF7\u8F93\u5165\u8BA2\u5355\u7F16\u53F7");return}if(a.value!="store"&&!t.sid){c.error("\u8BF7\u9009\u62E9\u95E8\u5E97");return}a.value=="shangpu"?L({delivery_status:p.value,ordersn:o.value,sid:t.sid}).then(e=>{c.success(e.msg)}):a.value=="agent"?z({delivery_status:p.value,ordersn:o.value,sid:t.sid}).then(e=>{c.success(e.msg)}):P({delivery_status:p.value,ordersn:o.value,sid:t.sid}).then(e=>{c.success(e.msg)})};return H(()=>t.sid,()=>{f.value=0,S()}),(e,u)=>{const E=m("el-option"),C=m("el-select"),A=m("el-input"),O=m("el-button");return n(),i("div",X,[l("div",Y,[Z,g(a)=="shangpu"||g(a)=="agent"?(n(),i("div",ee,[y(C,{modelValue:g(t).sid,"onUpdate:modelValue":u[0]||(u[0]=s=>g(t).sid=s),placeholder:"\u9009\u62E9\u95E8\u5E97",clearable:"",filterable:"",style:{"margin-left":"20rpx"}},{default:F(()=>[(n(!0),i(x,null,B(h.value,s=>(n(),M(E,{key:s.id,label:s.title,value:s.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])])):R("",!0)]),l("div",te,[l("div",se,[(n(!0),i(x,null,B(_.value,(s,v)=>(n(),i("div",{key:v,class:$(["status_item",[f.value==v?"item_active":"",v>0?"marginLeft":""]]),onClick:ce=>V(v,s.value)},G(s.title),11,ae))),128))]),l("div",le,[y(A,{modelValue:o.value,"onUpdate:modelValue":u[1]||(u[1]=s=>o.value=s),style:{width:"240px"},placeholder:"\u8BF7\u8F93\u5165\u8BA2\u5355\u7F16\u53F7"},null,8,["modelValue"]),oe]),l("div",ue,[y(O,{size:"large",type:"primary",onClick:k},{default:F(()=>[ne]),_:1})])])])}}});const me=W(re,[["__scopeId","data-v-91591694"]]);export{me as default};
