refundMoneyDetail.vue 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462
  1. <template>
  2. <view class="content">
  3. <view class="topView">
  4. <!-- 待处理 -->
  5. <view class="waitBg" v-if="state>0">
  6. <view class="title">请等待平台处理</view>
  7. <!-- 进度条 -->
  8. <view class="progress">
  9. <image :src="(state>0 ? tongguoUrl : waitUrl)" class="waitImg" :class="{tongguoImg:state>0}">
  10. </image>
  11. <view class="line" :class="{lightLine:state>0}"></view>
  12. <image :src="(state>1 ? tongguoUrl : waitUrl)" class="waitImg" :class="{tongguoImg:state>1}">
  13. </image>
  14. <view class="line" :class="{lightLine:state>1}"></view>
  15. <image :src="(state>2 ? tongguoUrl : waitUrl)" class="waitImg" :class="{tongguoImg:state>2}">
  16. </image>
  17. </view>
  18. <!-- 进度条 文字提示 -->
  19. <view class="progressT">
  20. <view class="progressTitle">提交申请</view>
  21. <view style="width: 9%;"></view>
  22. <view class="progressTitle">平台审核</view>
  23. <view style="width: 9%;"></view>
  24. <view class="progressTitle">平台同意退款</view>
  25. </view>
  26. <view class="progressT">
  27. <view class="time" v-if="state>0">{{detailData.createTime.slice(0,detailData.createTime.length-3)}}</view>
  28. <view style="width: 7%;"></view>
  29. <view class="time" v-if="state>1">{{detailData.handlerTime.slice(0,detailData.handlerTime.length-3)}}</view>
  30. <view style="width: 8%;"></view>
  31. <view class="time" v-if="state>2">{{detailData.handlerTime.slice(0,detailData.handlerTime.length-3)}}</view>
  32. </view>
  33. </view>
  34. <!-- 退款关闭 -->
  35. <view class="waitBg" v-if="state==0" style="height: 100rpx;">
  36. <view class="title">退款关闭</view>
  37. <view class="title3">{{detailData.handlerTime}}</view>
  38. </view>
  39. <!-- 平台拒绝 -->
  40. <view class="waitBg" v-if="state==-1" style="height: 100rpx;">
  41. <view class="title">平台已拒绝</view>
  42. <view class="title3">{{detailData.handlerTime}}</view>
  43. </view>
  44. </view>
  45. <!-- 退款提交 -->
  46. <view class="whiteView" v-if="state==1">
  47. <view class="title1">您已成功发起退款申请,请耐心等待平台处理</view>
  48. <view class="title2">平台同意后,系统将退款给您</view>
  49. <view class="title3">如果平台拒绝,您可以修改退款申请后再次发起,平台会重新处理</view>
  50. </view>
  51. <!-- 退款关闭 -->
  52. <view class="whiteView" v-if="state==0">
  53. <view class="title1">您已撤销本次退款申请,如有问题仍未解决,您可以重新发起申请</view>
  54. </view>
  55. <!-- 平台拒绝 -->
  56. <view class="whiteView" v-if="state==-1">
  57. <view class="title1">平台拒绝原因:这是选择的原因</view>
  58. <view class="title2">您可以修改退款申请后再次发起,平台会重新处理</view>
  59. </view>
  60. <!-- 同意申请 -->
  61. <view class="tongyiView" v-if="state!=1" @click="goSchedule()">
  62. <view class="title1">进度详情</view>
  63. <image src="../../static/img/rightArrow.png" mode="" style="width: 14rpx; height: 23rpx;"></image>
  64. </view>
  65. <!-- 退款信息 -->
  66. <view class="whiteView">
  67. <view class="informationLine">
  68. <view class="informationTxt">退款原因:</view>
  69. <view class="informationNum">{{detailData.applyReason}}</view>
  70. </view>
  71. <view class="informationLine">
  72. <view class="informationTxt">申请退款金额:</view>
  73. <view class="informationNum">¥{{detailData.money}}</view>
  74. </view>
  75. <view class="informationLine">
  76. <view class="informationTxt">申请时间:</view>
  77. <view class="informationNum">{{detailData.createTime}}</view>
  78. </view>
  79. <view class="informationLine">
  80. <view class="informationTxt">补充描述:</view>
  81. <view class="informationNum" style="width: 80%;" v-if="detailData.applyReasonComment!=null">
  82. {{detailData.applyReasonComment}}</view>
  83. </view>
  84. <view class="informationLine">
  85. <view class="informationTxt">售后单号:</view>
  86. <view class="informationNum">{{detailData.serviceCode}}</view>
  87. <view class="copyBtn" @click="copy(detailData.serviceCode)">复制</view>
  88. </view>
  89. <view class="informationLine">
  90. <view class="informationTxt">订单单号:</view>
  91. <view class="informationNum">{{detailData.sheetCode}}</view>
  92. <view class="copyBtn" @click="copy(detailData.sheetCode)">复制</view>
  93. <view style="color: #3F90F7; font-size: 26rpx; margin-left: 50rpx;" @click="goOrderDetail()">详情</view>
  94. </view>
  95. </view>
  96. <!-- 底部按钮 操作 -->
  97. <view style="height: 150rpx;"></view>
  98. <view class="orderBottom" v-if="state==1">
  99. <view class="cancelBtn" @click="cancelBtn">撤销申请</view>
  100. <view class="cancelBtn" @click="editBtn">修改申请</view>
  101. </view>
  102. </view>
  103. </template>
  104. <script>
  105. export default {
  106. data() {
  107. return {
  108. state: -1, // -1 拒绝 0自己撤销关闭 1 提交申请 3 同意申请
  109. tongguoUrl: '../../static/img/icon_tongguo.png',
  110. waitUrl: '../../static/img/icon_yuan.png',
  111. id: '',
  112. detailData: '',
  113. }
  114. },
  115. onLoad(opt) {
  116. this.id = opt.id
  117. this.getData();
  118. },
  119. onShow() {
  120. this.getData();
  121. },
  122. methods: {
  123. goSchedule(){
  124. uni.navigateTo({
  125. url: 'refundSchedule?id=' + this.detailData.ID
  126. })
  127. },
  128. goOrderDetail() {
  129. uni.navigateTo({
  130. url: '../order/orderDetail?id=' + this.detailData.sheetID
  131. })
  132. },
  133. getData() {
  134. uni.showLoading({
  135. title: '加载中'
  136. })
  137. let url = '/worldKeepCar/orderRefund/refundDetail',
  138. params = {
  139. id: this.id,
  140. }
  141. this.$http(url, params, 'GET').then(res => {
  142. uni.hideLoading();
  143. this.detailData = res.data
  144. // 退款状态
  145. // "serviceState": 备注:处理状态1待处理2退款成功3退款关闭
  146. if (this.detailData.serviceState == 1) {
  147. // 平台处理
  148. this.state = 1;
  149. } else if (this.detailData.serviceState == 2) {
  150. // 平台同意
  151. this.state = 3;
  152. }
  153. if (this.detailData.handlerReasonID != null) {
  154. // 拒绝
  155. this.state = -1;
  156. }
  157. if (this.detailData.cancelType == 1) {
  158. // 关闭
  159. this.state = 0;
  160. }
  161. })
  162. },
  163. copy(txt) {
  164. uni.setClipboardData({
  165. data: txt,
  166. success: function() {
  167. uni.showToast({
  168. title: '复制成功',
  169. icon: 'none',
  170. duration: 2000
  171. });
  172. }
  173. });
  174. },
  175. cancelBtn(){
  176. var that = this
  177. uni.showLoading({
  178. title: '加载中'
  179. })
  180. let url = 'worldKeepCar/orderRefund/cancelApply',
  181. params = {
  182. id: this.detailData.ID,
  183. }
  184. this.$http(url, params, 'POST').then(res => {
  185. uni.hideLoading();
  186. if(res.code==0){
  187. uni.showToast({
  188. title: '撤销成功',
  189. icon: 'none',
  190. duration: 2000,
  191. });
  192. setTimeout(function() {
  193. that.getData()
  194. }, 2000);
  195. }
  196. })
  197. },
  198. editBtn(){
  199. uni.navigateTo({
  200. url:'refundMoney?edit=true'+'&editId='+this.detailData.ID+'&money='+this.detailData.money+'&reasonId='+this.detailData.applyReasonID+'&reason='+this.detailData.applyReason+'&exeContent='+this.detailData.applyReasonComment
  201. })
  202. }
  203. },
  204. onPullDownRefresh() {
  205. this.getData()
  206. setTimeout(function() {
  207. uni.stopPullDownRefresh();
  208. }, 1000);
  209. },
  210. }
  211. </script>
  212. <style>
  213. .content {
  214. background-color: #F4F5F7;
  215. min-height: 100vh;
  216. }
  217. .topView {
  218. background: linear-gradient(315deg, #FD5002 0%, #FE8F00 100%);
  219. padding: 20rpx 24rpx;
  220. }
  221. .waitBg {
  222. background-color: #FFFFFF;
  223. border-radius: 20rpx;
  224. height: 209rpx;
  225. padding: 30rpx;
  226. }
  227. .title {
  228. color: #333333;
  229. font-size: 32rpx;
  230. font-weight: bold;
  231. margin-bottom: 30rpx;
  232. }
  233. .progress {
  234. display: flex;
  235. align-items: center;
  236. padding: 10rpx 70rpx;
  237. }
  238. .waitImg {
  239. width: 20rpx;
  240. height: 20rpx;
  241. }
  242. .tongguoImg {
  243. width: 38rpx;
  244. height: 38rpx;
  245. }
  246. .line {
  247. width: 40%;
  248. margin: 0rpx 5rpx;
  249. height: 2px;
  250. background: #FF2400;
  251. opacity: 0.4;
  252. }
  253. .lightLine {
  254. width: 40%;
  255. margin: 0rpx 5rpx;
  256. height: 2px;
  257. background: #FF2400;
  258. opacity: 1.0;
  259. }
  260. .progressT {
  261. display: flex;
  262. align-items: center;
  263. }
  264. .progressTitle {
  265. color: #333333;
  266. font-size: 22rpx;
  267. text-align: center;
  268. width: 30%;
  269. }
  270. .time {
  271. color: #999999;
  272. font-size: 22rpx;
  273. text-align: center;
  274. }
  275. .whiteView {
  276. background-color: #FFFFFF;
  277. padding: 30rpx 24rpx;
  278. margin: 20rpx 0;
  279. }
  280. .title1 {
  281. color: #3C3C3C;
  282. font-size: 30rpx;
  283. font-weight: bold;
  284. }
  285. .title2 {
  286. color: #999999;
  287. font-size: 24rpx;
  288. padding-top: 16rpx;
  289. padding-bottom: 8rpx;
  290. }
  291. .title3 {
  292. color: #999999;
  293. font-size: 24rpx;
  294. }
  295. .storeTitle {
  296. color: #3C3C3C;
  297. font-size: 30rpx;
  298. font-weight: bold;
  299. border-bottom: 1rpx #EEEEEE solid;
  300. padding-bottom: 22rpx;
  301. }
  302. .store {
  303. display: flex;
  304. padding-top: 20rpx;
  305. align-items: center;
  306. }
  307. .leftIcon {
  308. width: 30rpx;
  309. height: 30rpx;
  310. margin-right: 10rpx;
  311. }
  312. .name {
  313. color: #3C3C3C;
  314. font-size: 26rpx;
  315. }
  316. .address {
  317. color: #999999;
  318. font-size: 26rpx;
  319. }
  320. .informationLine {
  321. display: flex;
  322. font-size: 26rpx;
  323. padding: 20rpx 0;
  324. }
  325. .informationTxt {
  326. color: #666666;
  327. }
  328. .informationNum {
  329. color: #333333;
  330. }
  331. .copyBtn {
  332. width: 86rpx;
  333. height: 40rpx;
  334. background: #F4F5F7;
  335. border-radius: 20rpx;
  336. font-size: 24rpx;
  337. color: #333333;
  338. text-align: center;
  339. line-height: 40rpx;
  340. margin-left: 20rpx;
  341. }
  342. .orderBottom {
  343. width: 750rpx;
  344. height: 98rpx;
  345. background: #FFFFFF;
  346. position: fixed;
  347. left: 0;
  348. bottom: 0;
  349. display: flex;
  350. justify-content: flex-end;
  351. }
  352. .cancelBtn {
  353. width: 150rpx;
  354. height: 56rpx;
  355. border-radius: 36rpx;
  356. border: 2rpx solid #DDDDDD;
  357. text-align: center;
  358. line-height: 56rpx;
  359. font-size: 28rpx;
  360. color: #3C3C3C;
  361. margin-top: 21rpx;
  362. margin-right: 16rpx;
  363. margin-left: 20rpx;
  364. }
  365. .tongyiView {
  366. display: flex;
  367. justify-content: space-between;
  368. align-items: center;
  369. background-color: #FFFFFF;
  370. padding: 30rpx 24rpx;
  371. margin: 20rpx 0;
  372. }
  373. </style>