import{$ as e,o as s,c as a,w as l,n as d,e as t,i as u,a as o,f as i,t as f,b as r,d as n,F as c,k as _,g as x,l as m,ah as p,I as g,U as b,a4 as A}from"./index-4ddb689d.js";import{A as h,R as v,a as E}from"./RefundType.055df00b.js";import{d as w,a as y}from"./refund.57dda06a.js";import{_ as I}from"./_plugin-vue_export-helper.1b428a4d.js";const k="express/list";const R=I({data:()=>({AuditStatusEnum:h,RefundStatusEnum:v,RefundTypeEnum:E,isLoading:!0,orderRefundId:null,detail:{},expressList:[],formData:{expressId:null,expressNo:""},expressIndex:-1,disabled:!1}),onLoad({orderRefundId:e}){this.orderRefundId=e,this.getPageData()},methods:{getPageData(){const e=this;e.isLoading=!0,Promise.all([e.getRefundDetail(),e.getExpressList()]).then((s=>{e.isLoading=!1}))},getRefundDetail(){const e=this;return new Promise(((s,a)=>{w(e.orderRefundId).then((a=>{e.detail=a.data.detail,s()})).catch(a)}))},getExpressList(){const s=this;return new Promise(((a,l)=>{var d;e.get(k,d).then((e=>{s.expressList=e.data.list,a()})).catch(l)}))},onGoodsDetail(e){this.$navTo("pages/goods/detail",{goodsId:e})},handlePreviewImages(e){const{detail:{images:s}}=this,a=s.map((e=>e.image_url));uni.previewImage({current:a[e],urls:a})},onChangeExpress(e){const s=e.detail.value,{expressList:a}=this;this.expressIndex=s,this.formData.expressId=a[s].express_id},onSubmit(){const e=this;if(!0===e.disabled)return!1;e.disabled=!0,y(e.orderRefundId,e.formData).then((s=>{e.$toast(s.message),setTimeout((()=>{e.disabled=!1,uni.navigateBack()}),1500)})).catch((s=>e.disabled=!1))}}},[["render",function(e,h,v,E,w,y){const I=x,k=u,R=m,D=p,P=g,j=b,L=A;return w.isLoading?t("",!0):(s(),a(k,{key:0,class:"container p-bottom",style:d(e.appThemeStyle)},{default:l((()=>[o(k,{class:"detail-header dis-flex flex-y-center"},{default:l((()=>[o(k,{class:"header-backdrop"},{default:l((()=>[o(I,{class:"image",src:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUg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,{class:"header-state"},{default:l((()=>[o(R,{class:"f-32 col-f"},{default:l((()=>[i(f(w.detail.state_text),1)])),_:1})])),_:1})])),_:1}),o(k,{class:"detail-goods b-f m-top20 dis-flex flex-dir-row",onClick:h[0]||(h[0]=e=>y.onGoodsDetail(w.detail.orderGoods.goods_id))},{default:l((()=>[o(k,{class:"left"},{default:l((()=>[o(I,{class:"goods-image",src:w.detail.orderGoods.goods_image},null,8,["src"])])),_:1}),o(k,{class:"right dis-flex flex-box flex-dir-column flex-x-around"},{default:l((()=>[o(k,{class:"goods-name"},{default:l((()=>[o(R,{class:"twoline-hide"},{default:l((()=>[i(f(w.detail.orderGoods.goods_name),1)])),_:1})])),_:1}),o(k,{class:"dis-flex col-9 f-24"},{default:l((()=>[o(k,{class:"flex-box"},{default:l((()=>[o(k,{class:"goods-props clearfix"},{default:l((()=>[(s(!0),r(c,null,n(w.detail.orderGoods.goods_props,((e,d)=>(s(),a(k,{class:"goods-props-item",key:d},{default:l((()=>[o(R,null,{default:l((()=>[i(f(e.value.name),1)])),_:2},1024)])),_:2},1024)))),128))])),_:1})])),_:1}),o(R,{class:"t-r"},{default:l((()=>[i("×"+f(w.detail.orderGoods.total_num),1)])),_:1})])),_:1})])),_:1})])),_:1}),o(k,{class:"detail-order b-f row-block"},{default:l((()=>[o(k,{class:"item dis-flex flex-x-end flex-y-center"},{default:l((()=>[o(R,{class:""},{default:l((()=>[i("商品金额:")])),_:1}),o(R,{class:"col-m"},{default:l((()=>[i("¥"+f(w.detail.orderGoods.total_pay_price),1)])),_:1})])),_:1})])),_:1}),w.detail.status==w.RefundStatusEnum.COMPLETED.value&&10==w.detail.type?(s(),a(k,{key:0,class:"detail-order b-f row-block dis-flex flex-x-end flex-y-center"},{default:l((()=>[o(R,{class:""},{default:l((()=>[i("已退款金额:")])),_:1}),o(R,{class:"col-m"},{default:l((()=>[i("¥"+f(w.detail.refund_money),1)])),_:1})])),_:1})):t("",!0),w.detail.status==w.RefundStatusEnum.REJECTED.value?(s(),a(k,{key:1,class:"detail-refund b-f m-top20"},{default:l((()=>[o(k,{class:"detail-refund__row dis-flex"},{default:l((()=>[o(k,{class:"text"},{default:l((()=>[o(R,null,{default:l((()=>[i("售后类型:")])),_:1})])),_:1}),o(k,{class:"flex-box"},{default:l((()=>[o(R,null,{default:l((()=>[i(f(w.RefundTypeEnum[w.detail.type].name),1)])),_:1})])),_:1})])),_:1}),o(k,{class:"detail-refund__row dis-flex"},{default:l((()=>[o(k,{class:"text"},{default:l((()=>[o(R,null,{default:l((()=>[i("申请原因:")])),_:1})])),_:1}),o(k,{class:"flex-box"},{default:l((()=>[o(R,null,{default:l((()=>[i(f(w.detail.apply_desc),1)])),_:1})])),_:1})])),_:1}),w.detail.images.length>0?(s(),a(k,{key:0,class:"detail-refund__row dis-flex"},{default:l((()=>[o(k,{class:"text"},{default:l((()=>[o(R,null,{default:l((()=>[i("申请凭证:")])),_:1})])),_:1}),o(k,{class:"image-list flex-box"},{default:l((()=>[(s(!0),r(c,null,n(w.detail.images,((e,d)=>(s(),a(k,{class:"image-preview",key:d},{default:l((()=>[o(I,{class:"image",mode:"aspectFill",src:e.image_url,onClick:e=>y.handlePreviewImages(d)},null,8,["src","onClick"])])),_:2},1024)))),128))])),_:1})])),_:1})):t("",!0)])),_:1})):t("",!0),10==w.detail.status.value?(s(),a(k,{key:2,class:"detail-refund b-f m-top20"},{default:l((()=>[o(k,{class:"detail-refund__row dis-flex"},{default:l((()=>[o(k,{class:"text"},{default:l((()=>[o(R,{class:"col-m"},{default:l((()=>[i("拒绝原因:")])),_:1})])),_:1}),o(k,{class:"flex-box"},{default:l((()=>[o(R,null,{default:l((()=>[i(f(w.detail.refuse_desc),1)])),_:1})])),_:1})])),_:1})])),_:1})):t("",!0),w.detail.audit_status==w.AuditStatusEnum.REVIEWED.value&&w.detail.is_user_send?(s(),a(k,{key:3,class:"detail-address b-f m-top20"},{default:l((()=>[o(k,{class:"detail-address__row address-title"},{default:l((()=>[o(R,{class:"col-m"},{default:l((()=>[i("退货物流信息")])),_:1})])),_:1}),o(k,{class:"detail-address__row address-details"},{default:l((()=>[o(k,{class:"address-details__row"},{default:l((()=>[o(R,null,{default:l((()=>[i("物流公司:"+f(w.detail.express.express_name),1)])),_:1})])),_:1}),o(k,{class:"address-details__row"},{default:l((()=>[o(R,null,{default:l((()=>[i("物流单号:"+f(w.detail.express_no),1)])),_:1})])),_:1}),o(k,{class:"address-details__row"},{default:l((()=>[o(R,null,{default:l((()=>[i("发货时间:"+f(w.detail.send_time),1)])),_:1})])),_:1})])),_:1})])),_:1})):t("",!0),w.detail.audit_status==w.AuditStatusEnum.REVIEWED.value?(s(),a(k,{key:4,class:"detail-address b-f m-top20"},{default:l((()=>[o(k,{class:"detail-address__row address-title"},{default:l((()=>[o(R,{class:"col-m"},{default:l((()=>[i("商家退货地址")])),_:1})])),_:1}),o(k,{class:"detail-address__row address-details"},{default:l((()=>[o(k,{class:"address-details__row"},{default:l((()=>[o(R,null,{default:l((()=>[i("收货人:"+f(w.detail.address.name),1)])),_:1})])),_:1}),o(k,{class:"address-details__row"},{default:l((()=>[o(R,null,{default:l((()=>[i("联系电话:"+f(w.detail.address.phone),1)])),_:1})])),_:1}),o(k,{class:"address-details__row dis-flex"},{default:l((()=>[o(k,{class:"text"},{default:l((()=>[o(R,null,{default:l((()=>[i("详细地址:")])),_:1})])),_:1}),o(k,{class:"address flex-box"},{default:l((()=>[(s(!0),r(c,null,n(w.detail.address.region,((e,d)=>(s(),a(R,{class:"region",key:d},{default:l((()=>[i(f(e),1)])),_:2},1024)))),128)),o(R,{class:"detail"},{default:l((()=>[i(f(w.detail.address.detail),1)])),_:1})])),_:1})])),_:1})])),_:1}),o(k,{class:"detail-address__row address-tips"},{default:l((()=>[o(k,{class:"f-26 col-9"},{default:l((()=>[o(R,null,{default:l((()=>[i("· 未与卖家协商一致情况下,请勿寄到付或平邮")])),_:1})])),_:1}),o(k,{class:"f-26 col-9"},{default:l((()=>[o(R,null,{default:l((()=>[i("· 请填写真实有效物流信息")])),_:1})])),_:1})])),_:1})])),_:1})):t("",!0),w.detail.type!=w.RefundTypeEnum.RETURN.value||w.detail.audit_status!=w.AuditStatusEnum.REVIEWED.value||w.detail.is_user_send?t("",!0):(s(),a(L,{key:5,onSubmit:h[2]||(h[2]=e=>y.onSubmit())},{default:l((()=>[o(k,{class:"detail-express b-f m-top20"},{default:l((()=>[o(k,{class:"form-group dis-flex flex-y-center"},{default:l((()=>[o(k,{class:"field"},{default:l((()=>[i("物流公司:")])),_:1}),o(k,{class:"flex-box"},{default:l((()=>[o(D,{mode:"selector",range:w.expressList,"range-key":"express_name",value:w.expressIndex,onChange:y.onChangeExpress},{default:l((()=>[w.expressIndex>-1?(s(),a(R,{key:0},{default:l((()=>[i(f(w.expressList[w.expressIndex].express_name),1)])),_:1})):(s(),a(R,{key:1,class:"col-80"},{default:l((()=>[i("请选择物流公司")])),_:1}))])),_:1},8,["range","value","onChange"])])),_:1})])),_:1}),o(k,{class:"form-group dis-flex flex-y-center"},{default:l((()=>[o(k,{class:"field"},{default:l((()=>[i("物流单号:")])),_:1}),o(k,{class:"flex-box"},{default:l((()=>[o(P,{class:"input",modelValue:w.formData.expressNo,"onUpdate:modelValue":h[1]||(h[1]=e=>w.formData.expressNo=e),placeholder:"请填写物流单号"},null,8,["modelValue"])])),_:1})])),_:1})])),_:1}),o(k,{class:"footer"},{default:l((()=>[o(k,{class:"btn-wrapper"},{default:l((()=>[o(j,{class:_(["btn-item btn-item-main btn-normal",{disabled:w.disabled}]),formType:"submit"},{default:l((()=>[i("确认发货")])),_:1},8,["class"])])),_:1})])),_:1})])),_:1}))])),_:1},8,["style"]))}],["__scopeId","data-v-feb971c6"]]);export{R as default};