1 |
- import{s as e,z as s,c as t,Z as a,o as l,t as i,Q as o,f as n,g as c,w as r,x as f,ak as u,m as d,a6 as m,k as _,l as p,r as y,F as g,B as v,u as x,v as b,i as h,H as k,P as j,I as $,j as w,n as T,J as I,E as N}from"./index-a116b7fa.js";import{_ as C}from"./s-goods-item.e5b69bb0.js";import{_ as E}from"./s-empty.4d7f5239.js";import{a as P,_ as S}from"./s-layout.4ae51839.js";import{l as J,n as M,f as B,p as F}from"./useGoods.6b315a78.js";import{_ as O}from"./_plugin-vue_export-helper.1b428a4d.js";import"./points.c381a8e1.js";/* empty css *//* empty css */import"./phone-international-input.b9f6c8e6.js";const z=O({__name:"detail",setup(O){k((e=>({c18fce6a:f(A)}))),e.$store("user").userInfo;const z=2*e.$platform.device.statusBarHeight,A=e.$url.css("/static/img/shop/order/order_bg.png"),H=s({id:0,info:{},loading:!1,active:0,list:[{title:"提交申请"},{title:"处理中"},{title:"完成"}]});const D=()=>{e.$helper.copyText(H.info.no)};async function G(e){H.loading=!0;const{code:s,data:t}=await u.getAfterSale(e);0===s?(H.info=t,J(H.info),[10].includes(H.info.status)?H.active=0:[20,30,40].includes(H.info.status)?H.active=1:([50].includes(H.info.status)||[61,62,63].includes(H.info.status))&&(H.active=2)):H.info=null}const L=t((()=>e.$store("user").isLogin));return a((()=>L.value),(e=>{e&&window.location.reload()})),l((s=>L.value?s.username&&(console.log(JSON.parse(o("user-store")).userInfo.username),s.username!=JSON.parse(o("user-store")).userInfo.username)?(e.$helper.toast("您当前登录的账号是"+JSON.parse(o("user-store")).userInfo.username+",请切换到"+s.username+"后再试",3e3),!1):void(s.id?(H.id=s.id,G(s.id)):e.$helper.toast("缺少订单信息,请检查")):(i(),e.$helper.toast("您尚未登录,请登录:"+s.username+"后再试",3e3),!1))),(s,t)=>{const a=$,l=w,i=d(T("s-goods-item"),C),o=I,k=d(T("s-empty"),E),J=d(T("su-fixed"),P),O=d(T("s-layout"),S);return n(),c(O,{title:"售后详情",navbar:!f(m.isEmpty)(H.info)&&H.loading?"inner":"normal"},{default:r((()=>[!f(m.isEmpty)(H.info)&&H.loading?(n(),c(l,{key:0,class:"content_box"},{default:r((()=>[_(l,{class:"steps-box ss-flex",style:v([{marginTop:"-"+Number(z+88)+"rpx",paddingTop:Number(z+88)+"rpx"}])},{default:r((()=>[_(l,{class:"ss-flex"},{default:r((()=>[(n(!0),p(g,null,y(H.list,((e,s)=>(n(),c(l,{class:"steps-item",key:s},{default:r((()=>[_(l,{class:"ss-flex"},{default:r((()=>[H.list.length-1===s&&[61,62,63].includes(H.info.status)?(n(),c(a,{key:0,class:"sicon-circleclose"})):(n(),c(a,{key:1,class:N(["sicon-circlecheck",H.active>=s?"activity-color":"info-color"])},null,8,["class"])),H.list.length-1!==s?(n(),c(l,{key:2,class:N(["line",H.active>=s?"activity-bg":"info-bg"])},null,8,["class"])):h("",!0)])),_:2},1024),_(l,{class:N(["steps-item-title",H.active>=s?"activity-color":"info-color"])},{default:r((()=>[x(b(e.title),1)])),_:2},1032,["class"])])),_:2},1024)))),128))])),_:1})])),_:1},8,["style"]),_(l,{class:"status-box ss-flex ss-col-center ss-row-between ss-m-x-20",onClick:t[0]||(t[0]=s=>f(e).$router.go("/pages/order/aftersale/log",{id:H.id}))},{default:r((()=>[_(l,{class:""},{default:r((()=>[_(l,{class:"status-text"},{default:r((()=>[x(b(f(M)(H.info)),1)])),_:1}),_(l,{class:"status-time"},{default:r((()=>[x(b(f(e).$helper.timeFormat(H.info.updateTime,"yyyy-mm-dd hh:MM:ss")),1)])),_:1})])),_:1}),_(a,{class:"ss-iconfont _icon-forward",style:{color:"#666"}})])),_:1}),_(l,{class:"aftersale-content ss-m-y-20"},{default:r((()=>[_(l,{class:"aftersale-item ss-flex ss-col-center"},{default:r((()=>[_(l,{class:"item-title"},{default:r((()=>[x("退款总额:")])),_:1}),_(l,{class:"item-content"},{default:r((()=>[x(" ¥"+b(f(B)(H.info.refundPriceTotal)),1)])),_:1})])),_:1}),_(l,{class:"aftersale-item ss-flex ss-col-center"},{default:r((()=>[_(l,{class:"item-title"},{default:r((()=>[x("退款金额:")])),_:1}),_(l,{class:"item-content"},{default:r((()=>[x("¥"+b(f(B)(H.info.refundPrice)),1)])),_:1})])),_:1}),_(l,{class:"aftersale-item ss-flex ss-col-center"},{default:r((()=>[_(l,{class:"item-title"},{default:r((()=>[x("退款佣金:")])),_:1}),_(l,{class:"item-content"},{default:r((()=>[x("¥"+b(f(F)(H.info.refundIntegral)),1)])),_:1})])),_:1}),_(l,{class:"aftersale-item ss-flex ss-col-center"},{default:r((()=>[_(l,{class:"item-title"},{default:r((()=>[x("退款消费分:")])),_:1}),_(l,{class:"item-content"},{default:r((()=>[x("¥"+b(f(F)(H.info.refundConsumptionPoints)),1)])),_:1})])),_:1})])),_:1}),_(l,{class:"order-shop"},{default:r((()=>[_(i,{price:H.info.refundPriceTotal,img:H.info.picUrl,title:H.info.spuName,titleWidth:480,skuText:H.info.properties.map((e=>e.valueName)).join(" "),num:H.info.count},null,8,["price","img","title","skuText","num"])])),_:1}),_(l,{class:"aftersale-content"},{default:r((()=>[_(l,{class:"aftersale-item ss-flex ss-col-center"},{default:r((()=>[_(l,{class:"item-title"},{default:r((()=>[x("服务单号:")])),_:1}),_(l,{class:"item-content ss-m-r-16"},{default:r((()=>[x(b(H.info.no),1)])),_:1}),_(o,{class:"ss-reset-button copy-btn",onClick:D},{default:r((()=>[x("复制")])),_:1})])),_:1}),_(l,{class:"aftersale-item ss-flex ss-col-center"},{default:r((()=>[_(l,{class:"item-title"},{default:r((()=>[x("申请时间:")])),_:1}),_(l,{class:"item-content"},{default:r((()=>[x(b(f(e).$helper.timeFormat(H.info.createTime,"yyyy-mm-dd hh:MM:ss")),1)])),_:1})])),_:1}),_(l,{class:"aftersale-item ss-flex ss-col-center"},{default:r((()=>[_(l,{class:"item-title"},{default:r((()=>[x("售后类型:")])),_:1}),_(l,{class:"item-content"},{default:r((()=>[x(b(10===H.info.way?"仅退款":"退款退货"),1)])),_:1})])),_:1}),_(l,{class:"aftersale-item ss-flex ss-col-center"},{default:r((()=>[_(l,{class:"item-title"},{default:r((()=>[x("申请原因:")])),_:1}),_(l,{class:"item-content"},{default:r((()=>[x(b(H.info.applyReason),1)])),_:1})])),_:1}),_(l,{class:"aftersale-item ss-flex ss-col-center"},{default:r((()=>[_(l,{class:"item-title"},{default:r((()=>[x("相关描述:")])),_:1}),_(l,{class:"item-content"},{default:r((()=>[x(b(H.info.applyDescription),1)])),_:1})])),_:1})])),_:1})])),_:1})):h("",!0),f(m.isEmpty)(H.info)&&H.loading?(n(),c(k,{key:1,icon:"/static/order-empty.png",text:"暂无该订单售后详情"})):h("",!0),f(m.isEmpty)(H.info)?h("",!0):(n(),c(J,{key:2,bottom:"",placeholder:"",bg:"bg-white"},{default:r((()=>[_(l,{class:"foot_box"},{default:r((()=>{var s,a;return[(null==(s=H.info.buttons)?void 0:s.includes("cancel"))?(n(),c(o,{key:0,class:"ss-reset-button btn",onClick:t[1]||(t[1]=e=>{return s=H.info.id,void j({title:"提示",content:"确定要取消此申请吗?",success:async function(e){if(!e.confirm)return;const{code:t}=await u.cancelAfterSale(s);0===t&&await G(s)}});var s})},{default:r((()=>[x(" 取消申请 ")])),_:1})):h("",!0),(null==(a=H.info.buttons)?void 0:a.includes("delivery"))?(n(),c(o,{key:1,class:"ss-reset-button btn",onClick:t[2]||(t[2]=s=>f(e).$router.go("/pages/order/aftersale/return-delivery",{id:H.info.id}))},{default:r((()=>[x(" 填写退货 ")])),_:1})):h("",!0)]})),_:1})])),_:1}))])),_:1},8,["navbar"])}}},[["__scopeId","data-v-13566655"]]);export{z as default};
|