refundMoneyDetail.vue 9.8 KB

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