apply-status.vue 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380
  1. <template>
  2. <view class="content" v-if="applyInfo.id">
  3. <view class="statusDesc">
  4. <view class="status">
  5. {{applyInfo.refund_type==1?'仅退款':applyInfo.refund_type==2?'退货退款':''}}
  6. </view>
  7. <view class="applyDesc">
  8. <template v-if="applyInfo.status == 10">
  9. <view class="title">审核中</view>
  10. </template>
  11. <template v-if="applyInfo.status == 21">
  12. <view class="title">审核通过,正在退款中</view>
  13. </template>
  14. <template v-if="applyInfo.status == 22">
  15. <view class="title">申请未通过</view>
  16. <view class="">
  17. 如有疑问,可联系客服
  18. </view>
  19. </template>
  20. <template v-if="applyInfo.status == 211">
  21. <view class="title">退款成功</view>
  22. </template>
  23. <template v-if="applyInfo.status == 31">
  24. <view class="title">审核通过,请填写退货快递单号</view>
  25. </template>
  26. <template v-if="applyInfo.status == 32">
  27. <view class="title">审核未通过</view>
  28. <view class="">
  29. 如有疑问,可联系客服
  30. </view>
  31. </template>
  32. <template v-if="applyInfo.status == 33">
  33. <view class="title">等待卖家收货确认</view>
  34. </template>
  35. <template v-if="applyInfo.status == 34">
  36. <view class="title">卖家已确认收货,正在退款中</view>
  37. </template>
  38. <template v-if="applyInfo.status == 344">
  39. <view class="title">退款成功</view>
  40. </template>
  41. </view>
  42. </view>
  43. <view class="refuseReason" v-if="applyInfo.refuse_reason">
  44. 拒绝原因:{{applyInfo.refuse_reason}}
  45. </view>
  46. <!-- 退货退款,输入运单号 -->
  47. <setExpress :refundId="applyInfo.id" v-if="applyInfo.status == 31" @done="setExpressSuccess"></setExpress>
  48. <!-- <view class="tExpress" v-if="applyInfo.status == 33">
  49. <view class="con">
  50. 退货物流单号:{{applyInfo.express_no}}
  51. </view>
  52. <view class="operate">
  53. <text class="copy" @click="$copyByUniappApi(applyInfo.refund_no)">复制</text>
  54. </view>
  55. </view> -->
  56. <view class="tExpress cell" v-if="applyInfo.express_no">
  57. <view class="label">退货物流单号</view>
  58. <view class="value">{{ applyInfo.express_no}}</view>
  59. <view class="operate">
  60. <text class="copy" @click="$copyByUniappApi(applyInfo.express_no)">复制</text>
  61. </view>
  62. </view>
  63. <view class="conD">
  64. <!-- <u-button class="returnBtn" :custom-style="returnBtnStyle" @click="goBack()">返回</u-button> -->
  65. <!--
  66. 10=待审核,21=卖家同意等待退款中,211=退款成功,
  67. 22=卖家驳回,31=卖家同意(用户填写退货单号),32=卖家驳回,33=等待卖家收货确认中,
  68. 34=卖家确认收货,验货没问题同意退款,344=退款成功
  69. -->
  70. <!-- <TitleOperate title="申请类型" padding="10rpx 30rpx 24rpx 30rpx"></TitleOperate> -->
  71. <!-- <view class="baseP">
  72. 申请类型:{{applyInfo.refund_type==1?'仅退款':applyInfo.refund_type==2?'退货退款':''}}
  73. </view> -->
  74. <view class="conbox">
  75. <TitleOperate title="售后商品" padding="30rpx 0 0"></TitleOperate>
  76. <template>
  77. <orderDetailGoodsCard v-for="(goods, index) in applyInfo.order_detail" :data="goods" :key="index"></orderDetailGoodsCard>
  78. </template>
  79. </view>
  80. <view class="conbox">
  81. <TitleOperate title="售后信息" padding="30rpx 0 30rpx"></TitleOperate>
  82. <view class="binfo">
  83. <view class="cell">
  84. <view class="label">服务编号</view>
  85. <view class="value">{{ applyInfo.refund_no}}</view>
  86. <view class="operate">
  87. <text class="copy" @click="$copyByUniappApi(applyInfo.refund_no)">复制</text>
  88. </view>
  89. </view>
  90. <view class="cell">
  91. <view class="label">退款原因</view>
  92. <view class="value">{{ applyInfo.reason}}</view>
  93. </view>
  94. <view class="cell">
  95. <view class="label">退款金额</view>
  96. <view class="value money">&yen;{{ applyInfo.refundFee}}</view>
  97. </view>
  98. <view class="cell">
  99. <view class="label">申请时间</view>
  100. <view class="value">{{ formatDateF(applyInfo.createtime*1000)}}</view>
  101. </view>
  102. <view class="cell" v-if="applyInfo.check_time">
  103. <view class="label">审核时间</view>
  104. <view class="value">{{ formatDateF(applyInfo.check_time*1000)}}</view>
  105. </view>
  106. <view class="cell" v-if="applyInfo.status == 33" >
  107. <view class="label">买家发货时间</view>
  108. <view class="value">{{ formatDateF(applyInfo.updatetime*1000)}}</view>
  109. </view>
  110. <view class="cell" v-if="applyInfo.status == 34" >
  111. <view class="label">卖家确认收货时间</view>
  112. <view class="value">{{ formatDateF(applyInfo.updatetime*1000)}}</view>
  113. </view>
  114. <view class="cell" v-if="applyInfo.refund_success_time">
  115. <view class="label">退款到账时间</view>
  116. <view class="value">{{ formatDateF(applyInfo.refund_success_time*1000)}}</view>
  117. </view>
  118. <!-- <view class="contact">
  119. <button class="item serviceBtn" open-type="contact" >
  120. 联系客服
  121. </button>
  122. </view> -->
  123. </view>
  124. </view>
  125. <!-- <u-steps direction="column" :list="statusList[status]" :current="current" :active-color="activeColor"></u-steps> -->
  126. </view>
  127. <view class="">
  128. <view class="foot_opar">
  129. <view class="oparbtn">
  130. <u-button plain size="small" open-type="contact">联系客服</u-button>
  131. </view>
  132. <view class="oparbtn" v-if="applyInfo.status == 22 || applyInfo.status == 32">
  133. <u-button type="primary" size="small" @click="applyAfterSales(applyInfo.order_id)">重新申请</u-button>
  134. </view>
  135. </view>
  136. <view class="siteBar">
  137. </view>
  138. </view>
  139. </view>
  140. </template>
  141. <script>
  142. import { orderOperate } from '@/pages-mall/mixins/order-operate.js';
  143. import orderDetailGoodsCard from '@/pages-mall/components/order/orderdetail-goods-card.vue';
  144. import setExpress from './components/setExpress.vue'
  145. import { formatDate } from '@/utils/tools.js'
  146. // 组件
  147. export default {
  148. mixins: [orderOperate],
  149. components: {
  150. orderDetailGoodsCard,
  151. setExpress
  152. },
  153. data() {
  154. return {
  155. status: '1',
  156. current: 1,
  157. expressCode:null,
  158. activeColor:'#22ac38',
  159. applyInfo:{
  160. refund_type:null,
  161. status:null,
  162. order_detail:[],
  163. },
  164. returnBtnStyle: {
  165. marginTop: '30rpx',
  166. },
  167. statusList: {
  168. '1': [{
  169. name: '提交申请'
  170. }, {
  171. name: '审核中'
  172. },{
  173. name: '退款中'
  174. }, {
  175. name: '退款成功'
  176. }, ],
  177. '2': [{
  178. name: '提交申请'
  179. }, {
  180. name: '审核中'
  181. }, {
  182. name: '买家寄件'
  183. }, {
  184. name: '卖家处理'
  185. }, {
  186. name: '退款中'
  187. }, {
  188. name: '完成'
  189. }, ],
  190. },
  191. };
  192. },
  193. onLoad(opt) {
  194. console.log(opt);
  195. if(opt.id){
  196. this.getRefundOrderDetailFun(opt.id);
  197. }else{
  198. uni.navigateBack();
  199. }
  200. },
  201. onBackPress() {
  202. uni.navigateBack({
  203. delta:-2
  204. })
  205. },
  206. methods: {
  207. // 退货物流查询
  208. tuiExpress(express_no){
  209. console.log('查看退货物流',express_no);
  210. },
  211. getRefundOrderDetailFun(id){
  212. this.$u.api.getRefundOrderDetailAjax(id).then(({code,data})=>{
  213. if(code==1){
  214. this.applyInfo = data;
  215. }
  216. }).catch(()=>{})
  217. },
  218. formatDateF(v){
  219. return formatDate(v,'all');
  220. },
  221. goBack() {
  222. uni.navigateBack({
  223. delta: 1
  224. });
  225. },
  226. setExpressSuccess(){
  227. this.applyInfo.status = 33;
  228. this.current = 3;
  229. },
  230. }
  231. };
  232. </script>
  233. <style lang="scss" scoped>
  234. .siteBar{
  235. height: 120rpx;
  236. // padding-bottom: constant(safe-area-inset-bottom);
  237. // padding-bottom: env(safe-area-inset-bottom);
  238. // box-sizing: content-box;
  239. @extend .safeAreaPad;
  240. }
  241. .foot_opar{
  242. border-top: solid 2rpx #f2f2f2;
  243. padding: 0 20rpx;
  244. box-sizing: border-box;
  245. position: fixed;
  246. bottom: 0;
  247. left: 0;
  248. width: 100%;
  249. height: 120rpx;
  250. display: flex;
  251. justify-content: flex-end;
  252. align-items: center;
  253. background-color: $app-theme-bg-color;
  254. z-index: $app-zIndex-fixed;
  255. @extend .safeAreaPad;
  256. .oparbtn{
  257. padding: 0 10rpx;
  258. }
  259. }
  260. .refuseReason{
  261. padding: 20rpx 30rpx;
  262. background-color: #fff;
  263. margin: 20rpx 0;
  264. }
  265. .content {
  266. // padding: 30rpx;
  267. }
  268. .conbox {
  269. background-color: #fff;
  270. margin-bottom: 30rpx;
  271. padding: 0 30rpx;
  272. }
  273. .selgoodsb {
  274. text-align: center;
  275. .t {
  276. margin-bottom: 20rpx;
  277. color: #666;
  278. }
  279. }
  280. // .baseP{
  281. // font-size: 32rpx;
  282. // padding: 30rpx 50rpx;
  283. // color: $app-theme-color;
  284. // }
  285. .returnBtn{
  286. margin-top: 30rpx;
  287. }
  288. .statusDesc{
  289. position: relative;
  290. padding: 30rpx;
  291. background-color: $app-theme-color;
  292. color: $app-theme-text-white-color;
  293. margin-bottom: 24rpx;
  294. .title{
  295. font-size: 36rpx;
  296. margin-bottom: 50rpx;
  297. }
  298. .status {
  299. margin-bottom: 20rpx;
  300. font-size: 30rpx;
  301. }
  302. .desc {
  303. font-size: 26rpx;
  304. }
  305. }
  306. .binfo{
  307. // padding: 30rpx;
  308. }
  309. .cell {
  310. display: flex;
  311. justify-content: space-between;
  312. align-items: center;
  313. padding: 20rpx 0;
  314. flex-shrink: 0;
  315. .label {
  316. // width: 204rpx;
  317. font-size: 28rpx;
  318. color: $app-theme-text-color;
  319. }
  320. .value {
  321. // width: 320rpx;
  322. flex: 1;
  323. text-align: right;
  324. font-size: 28rpx;
  325. color: $app-theme-text-color;
  326. padding: 0 30rpx;
  327. }
  328. .price{
  329. color: $app-theme-text-money-color;
  330. }
  331. .operate {
  332. // width: 80rpx;
  333. text-align: right;
  334. .copy {
  335. font-size: 28rpx;
  336. color: $app-theme-color;
  337. }
  338. }
  339. }
  340. .contact{
  341. border-top: 1rpx solid #eee;
  342. padding: 20rpx;
  343. color: $app-theme-color;
  344. }
  345. .serviceBtn{
  346. background-color: transparent;
  347. padding: 0;
  348. border: none;
  349. line-height: 1.2;
  350. font-size: 30rpx;
  351. &::after{
  352. content: '';
  353. border: none;
  354. display: none;
  355. }
  356. }
  357. .tExpress{
  358. padding: 20rpx 30rpx;
  359. background-color: #fff;
  360. margin-bottom: 30rpx;
  361. font-size: 30rpx;
  362. .label{font-size: inherit;}
  363. }
  364. </style>