您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

order-details-logoff-etc.vue 8.3KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357
  1. <!-- ETC注销-订单详情 -->
  2. <template>
  3. <view>
  4. <image :src="`${$imgUrl}applyCard/bg-nav.png`" style='height: 300rpx;width: 100%;'></image>
  5. <view class="props-txt-wrap">
  6. <view class="pro-txt" :class="{'pro-txt-primary':state.step >= 1}">发起业务</view>
  7. <view class="pro-txt pro-center" :class="{'pro-txt-primary':state.step >= 2}">审核中</view>
  8. <view class="pro-txt" :class="{'pro-txt-primary':state.step >= 3}">完成</view>
  9. </view>
  10. <view class="pros-wrap">
  11. <view :class="state.step >= 1 ? 'item-circle' : 'item-circle-no'">1</view>
  12. <view :class="state.step >= 2 ? 'item-line-solid' : 'item-line'"></view>
  13. <view :class="state.step >= 2 ? 'item-circle' : 'item-circle-no'">2</view>
  14. <view :class="state.step >= 3 ? 'item-line-solid' : 'item-line'"></view>
  15. <view :class="state.step >= 3 ? 'item-circle' : 'item-circle-no'">3</view>
  16. </view>
  17. </view>
  18. <view class="content">
  19. <view class="title">基础信息</view>
  20. <view class="content-box" v-for="(item,index) in state.orderBaseInfo" :key="index">
  21. <order-info-item :label="item.label" :value="item.value"></order-info-item>
  22. </view>
  23. <view class="title">卡/OBU设备信息</view>
  24. <view class="card-box as-layout-horizontal as-gravity-center-start">
  25. <image :src="`${$imgUrl}card2.png`" mode="" class="left"></image>
  26. <view class="right">
  27. <view class="number">2023022700012</view>
  28. <view class="info as-layout-horizontal">
  29. <view class="card-type">储蓄卡</view>
  30. <view class="card-status">正常</view>
  31. </view>
  32. </view>
  33. </view>
  34. <view class="card-box as-layout-horizontal as-gravity-center-start">
  35. <image :src="`${$imgUrl}card1.png`" mode="" class="left"></image>
  36. <view class="right">
  37. <view class="number">2023022700012</view>
  38. <view class="info as-layout-horizontal">
  39. <view class="card-status">正常</view>
  40. </view>
  41. </view>
  42. </view>
  43. <view class="title">退货信息</view>
  44. <view class="content-box" v-for="(item,index) in state.orderReturnInfo" :key="index">
  45. <order-info-item :label="item.label" :value="item.value"></order-info-item>
  46. </view>
  47. <view class="title">退费信息</view>
  48. <view class="content-box" v-for="(item,index) in state.orderReturnMoneyInfo" :key="index">
  49. <order-info-item :label="item.label" :value="item.value"></order-info-item>
  50. </view>
  51. <view class="title">剪卡图片</view>
  52. <view class="imgs">
  53. <image v-for="(img,index) in state.imgList" :key="index" :src="img" @click="checkBigImg(index,state.imgList)" mode="aspectFill"></image>
  54. </view>
  55. </view>
  56. </template>
  57. <script setup lang="ts">
  58. import {reactive} from "vue";
  59. import orderInfoItem from "./components/order-info-item";
  60. import {checkBigImg, msg} from "@/utils/utils";
  61. import {onLoad,onUnload} from "@dcloudio/uni-app";
  62. import {request} from "@/utils/network/request";
  63. import {stringToJson} from "@/utils/network/encryption";
  64. import {orderDetail} from "@/utils/network/api";
  65. const state = reactive({
  66. //当前步骤
  67. step: 2,
  68. //订单信息
  69. orderInfo:{} as any,
  70. //基本信息
  71. orderBaseInfo: [{
  72. label: '审核进度:',
  73. value: '',
  74. field:'orderStep'
  75. },
  76. {
  77. label: '审核时间:',
  78. value: '',
  79. field:'insertTime'
  80. },
  81. {
  82. label: '审核不通过原因:',
  83. value: '',
  84. field:'cancelReason'
  85. },
  86. {
  87. label: '用户名称:',
  88. value: '',
  89. field:'customerName'
  90. },
  91. {
  92. label: '用户证件类型:',
  93. value: '',
  94. field:'customerIdtype'
  95. },
  96. {
  97. label: '用户证件号:',
  98. value: '',
  99. field:'customerIdnum'
  100. },
  101. {
  102. label: '收费类型:',
  103. value: '',
  104. field:'vehicleClass'
  105. },
  106. {
  107. label: '订单车牌号:',
  108. value: '',
  109. field:'vehiclePlate'
  110. },
  111. ],
  112. //退货信息
  113. orderReturnInfo: [{
  114. label: '退货物流公司:',
  115. value: 'courierCompany',
  116. field:''
  117. },
  118. {
  119. label: '退货单号:',
  120. value: '',
  121. field:'trackingNumber'
  122. },
  123. ],
  124. //退费信息
  125. orderReturnMoneyInfo: [{
  126. label: '联系人姓名:',
  127. value: '',
  128. field:'consignee'
  129. },
  130. {
  131. label: '手机号:',
  132. value: '',
  133. field:'consigneeTel'
  134. },
  135. {
  136. label: '开户行:',
  137. value: '',
  138. field:'region'
  139. },
  140. {
  141. label: '退费银行卡号:',
  142. value: '',
  143. field:'postalCode'
  144. },
  145. ],
  146. //图片信息
  147. imgList:[
  148. "https://img1.baidu.com/it/u=2677796618,1424998349&fm=253&app=138&size=w931&n=0&f=JPEG&fmt=auto?sec=1678294800&t=99803143786f4f6513c2b2aeae748a15",
  149. "https://img0.baidu.com/it/u=2754207011,3515217180&fm=253&app=120&size=w931&n=0&f=JPEG&fmt=auto?sec=1678294800&t=f021d6844b5a5635fdc8f126563f35a2",
  150. "https://img1.baidu.com/it/u=4151437824,901633886&fm=253&app=120&size=w931&n=0&f=JPEG&fmt=auto?sec=1678294800&t=33569726b5df7290d219739b72787fca",
  151. "https://img0.baidu.com/it/u=2504452063,280205584&fm=253&app=138&size=w931&n=0&f=JPEG&fmt=auto?sec=1678294800&t=607bc76442b793b4e5c23f4aee8d537a"
  152. ]
  153. });
  154. //获取订单详情
  155. const getOrderDetails = (id) => {
  156. if(!id) {
  157. msg('无效的订单id');
  158. return;
  159. }
  160. const options = {
  161. type: 2,
  162. data: {"id": id},
  163. method: 'POST',
  164. showLoading: true,
  165. }
  166. request(orderDetail, options).then((res) => {
  167. state.orderInfo = stringToJson(res.bizContent);
  168. setOrderData();
  169. })
  170. }
  171. //设置订单数据
  172. const setOrderData = () =>{
  173. state.orderBaseInfo.map((item) => {
  174. item.value = state.orderInfo[item.field];
  175. })
  176. state.orderReturnInfo.map((item)=>{
  177. item.value = state.orderInfo[item.field];
  178. })
  179. state.orderReturnMoneyInfo.map((item)=>{
  180. item.value = (state.orderInfo.orderInfoExt as {})[item.field];
  181. })
  182. }
  183. onLoad((options)=>{
  184. getOrderDetails(options.id);
  185. })
  186. onUnload(()=>{
  187. })
  188. </script>
  189. <style lang="scss" scoped>
  190. .props-txt-wrap {
  191. position: absolute;
  192. top: -50rpx;
  193. left: 30rpx;
  194. right: 30rpx;
  195. height: 200rpx;
  196. display: flex;
  197. justify-content: space-between;
  198. align-items: center;
  199. .pro-txt {
  200. font-size: 28rpx;
  201. color: #333333;
  202. }
  203. .pro-txt-primary {
  204. color: #ffffff;
  205. }
  206. .pro-center {
  207. margin-left: -50rpx;
  208. }
  209. }
  210. .pros-wrap {
  211. position: absolute;
  212. top: 20rpx;
  213. left: 30rpx;
  214. right: 30rpx;
  215. height: 180rpx;
  216. display: flex;
  217. justify-content: space-between;
  218. align-items: center;
  219. .item-circle-no {
  220. width: 52rpx;
  221. height: 52rpx;
  222. background: rgba(255, 255, 255, 0.5);
  223. border-radius: 50%;
  224. display: flex;
  225. justify-content: center;
  226. align-items: center;
  227. color: #25D8C9;
  228. font-size: 30rpx;
  229. font-weight: 700;
  230. }
  231. .item-circle {
  232. width: 52rpx;
  233. height: 52rpx;
  234. background: #FFFFFF;
  235. border-radius: 50%;
  236. display: flex;
  237. justify-content: center;
  238. align-items: center;
  239. color: #25D8C9;
  240. font-size: 30rpx;
  241. font-weight: 700;
  242. }
  243. .item-line-solid {
  244. width: calc(calc(100% - 270rpx) / 2);
  245. height: 2rpx;
  246. background-color: #FFFFFF;
  247. margin: 0 12rpx;
  248. }
  249. .item-line {
  250. border: 1px dashed rgba(255, 255, 255, 0.5);
  251. width: calc(calc(100% - 270rpx) / 2);
  252. margin: 0 12rpx;
  253. }
  254. }
  255. .content {
  256. padding: -40rpx 30rpx 0rpx;
  257. margin-top: -130rpx;
  258. background: #ffffff;
  259. border-radius: 30rpx 30rpx 0rpx 30rpx;
  260. position: relative;
  261. min-height: 100rpx;
  262. .title{
  263. font-size: 30rpx;
  264. color: #333333;
  265. font-weight: 600;
  266. padding: 30rpx 30rpx 0rpx;
  267. }
  268. .content-box{
  269. padding: 28rpx 30rpx 0rpx;
  270. }
  271. .imgs{
  272. display: flex;
  273. flex-direction: row;
  274. flex-wrap: wrap;
  275. padding: 0rpx 30rpx 30rpx;
  276. align-items: center;
  277. justify-content: space-between;
  278. image{
  279. width: calc(calc(100% - 30rpx) / 2);
  280. height: 200rpx;
  281. margin-top: 30rpx;
  282. }
  283. }
  284. .card-box{
  285. background: #FFFFFF;
  286. box-shadow: 0rpx 4rpx 13rpx 3rpx rgba(223,223,223,0.8);
  287. border-radius: 20rpx;
  288. margin: 30rpx 30rpx 0rpx;
  289. padding: 30rpx;
  290. .left{
  291. width: 100rpx;
  292. height: 90rpx;
  293. }
  294. .right{
  295. margin-left: 30rpx;
  296. .number{
  297. font-size: 32rpx;
  298. font-family: Noto Sans S Chinese;
  299. font-weight: 400;
  300. color: #333333;
  301. }
  302. .info{
  303. margin-top: 20rpx;
  304. .card-type{
  305. margin-right: 20rpx;
  306. font-size: 26rpx;
  307. font-weight: 400;
  308. color: #666666;
  309. }
  310. .card-status{
  311. height: 40rpx;
  312. line-height: 40rpx;
  313. background: #D3F2EF;
  314. border-radius: 6rpx;
  315. font-size: 20rpx;
  316. font-family: Noto Sans S Chinese;
  317. font-weight: 400;
  318. color: #0A8F8A;
  319. text-align: center;
  320. padding: 0rpx 30rpx
  321. }
  322. }
  323. }
  324. }
  325. }
  326. </style>