1 |
- import{aa as p,d as A,r as g,b,c as u,e as s,k as c,i as a,h as o,u as n,f as v,j as V,m,t as h,F as B,E as L}from"./index.76214426.js";const U=()=>p.get("agent/agentset.DeliveryerRewardSetting/mySet"),R=y=>p.post("agent/agentset.DeliveryerRewardSetting/set",y),N=()=>p.post("agent/agentset.DeliveryerRewardSetting/getDeliveryerList"),j=m("\u63D0\u4EA4"),M=A({setup(y){g([]),g(1);let e=b({deliveryer_id:0,start_date:"",day:0,price:0,not_match_ids:[],id:0,record:[]}),i=b({list:[]});(()=>{N().then(d=>{i.list=d})})();const D=()=>{R(e).then(d=>{L.success("\u8BBE\u7F6E\u6210\u529F"),f()})},f=()=>{U().then(d=>{d.data&&(e.deliveryer_id=d.data.deliveryer_id,e.start_date=d.data.start_date,e.day=d.data.day,e.price=d.data.price,e.not_match_ids=d.data.not_match_ids,e.not_match_ids&&(e.not_match_ids=e.not_match_ids.map(l=>parseInt(l))))})};return f(),(d,l)=>{const F=u("el-option"),x=u("el-select"),r=u("el-form-item"),_=u("el-input"),k=u("el-checkbox"),E=u("el-checkbox-group"),S=u("el-button"),C=u("el-card");return s(),c(C,{shadow:"always",style:{"margin-top":"20px"}},{default:a(()=>[o(r,{label:"\u9A91\u624B\u56E2\u957F"},{default:a(()=>[o(x,{class:"agent-select",modelValue:n(e).deliveryer_id,"onUpdate:modelValue":l[0]||(l[0]=t=>n(e).deliveryer_id=t),placeholder:"\u8BF7\u9009\u62E9\u9A91\u624B",filterable:"",clearable:""},{default:a(()=>[(s(!0),v(B,null,V(n(i).list,(t,w)=>(s(),c(F,{value:t.id,label:t.title},{default:a(()=>[m(h(t.title),1)]),_:2},1032,["value","label"]))),256))]),_:1},8,["modelValue"])]),_:1}),o(r,{label:"\u5F00\u59CB\u65E5\u671F"},{default:a(()=>[o(_,{modelValue:n(e).start_date,"onUpdate:modelValue":l[1]||(l[1]=t=>n(e).start_date=t),placeholder:"\u683C\u5F0F:2024-02-26"},null,8,["modelValue"])]),_:1}),o(r,{label:"\u7ED3\u7B97\u5468\u671F"},{default:a(()=>[o(_,{modelValue:n(e).day,"onUpdate:modelValue":l[2]||(l[2]=t=>n(e).day=t)},null,8,["modelValue"])]),_:1}),o(r,{label:"\u6BCF\u5355\u5956\u52B1"},{default:a(()=>[o(_,{modelValue:n(e).price,"onUpdate:modelValue":l[3]||(l[3]=t=>n(e).price=t)},null,8,["modelValue"])]),_:1}),o(r,{label:"\u9664\u5916\u914D\u9001\u5458"},{default:a(()=>[o(E,{modelValue:n(e).not_match_ids,"onUpdate:modelValue":l[4]||(l[4]=t=>n(e).not_match_ids=t)},{default:a(()=>[(s(!0),v(B,null,V(n(i).list,(t,w)=>(s(),c(k,{key:t.id,label:t.id},{default:a(()=>[m(h(t.title),1)]),_:2},1032,["label"]))),128))]),_:1},8,["modelValue"])]),_:1}),o(r,{label:"",class:"continer-item"},{default:a(()=>[o(S,{type:"primary",onClick:D},{default:a(()=>[j]),_:1})]),_:1})]),_:1})}}});export{M as default};
|