index.vue 7.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342
  1. <template>
  2. <view class="page" :style="{'min-height':(h-th)+'px','padding-top':mt+'px'}">
  3. <image class="bg_img" src="https://i.ringzle.com/file/20240129/3931d06eaa3346c9955aa7e5e535a95b.png"
  4. mode="widthFix"></image>
  5. <view class="account" :style="{'margin-top':(mt-44)+'px'}">
  6. <view class="a_left">
  7. <view class="al_avatar" @tap="toLogin">
  8. <image :src="avatar"></image>
  9. </view>
  10. <view class="al_name_edit">
  11. <text>{{name}}</text>
  12. <view class="ane_edit" @tap="toTurn('/pagesMy/handerUser/handerUser',true)">
  13. <text>编辑</text>
  14. <image src="https://i.ringzle.com/file/20240129/e824a765b6c24ac6aafbb49b12c23aa9.png"></image>
  15. </view>
  16. </view>
  17. </view>
  18. </view>
  19. <view class="orders box">
  20. <view class="o_title">
  21. <text>我的订单</text>
  22. <view class="ot_all" @tap="toTurn('/pagesHouse/Mine/ordersList/index?type=',true)">
  23. <!-- <view class="ot_all" @tap="toToast"> -->
  24. <text>全部订单</text>
  25. <!-- <image src="../../static/index/steamerTicket/icon_yjt.png"></image> -->
  26. </view>
  27. </view>
  28. <view class="o_menus">
  29. <view v-for="(item,index) in orderMenus" :key="index"
  30. @tap="toTurn('/pagesMy/order/index?type='+item.type,true)">
  31. <!-- <view v-for="(item,index) in orderMenus" :key="index" @tap="toToast"> -->
  32. <image :src="item.img"></image>
  33. <text>{{item.text}}</text>
  34. </view>
  35. </view>
  36. </view>
  37. <view class="wallet box">
  38. <view class="w_left">
  39. <view class="wl_top">
  40. <image src="https://i.ringzle.com/file/20240129/60f0d414e1494b8a9feeef2a8e627934.png"></image>
  41. <text>钱包余额</text>
  42. </view>
  43. <view class="wl_price"><span>¥</span><text>{{price.toFixed(2)}}</text></view>
  44. </view>
  45. <view class="w_right" @tap="toTurn('/pagesMy/wallet/index',true)">去结算</view>
  46. </view>
  47. <Tabbares :tabbarid="2"></Tabbares>
  48. </view>
  49. </template>
  50. <script>
  51. export default {
  52. data() {
  53. return {
  54. h: uni.getSystemInfoSync().windowHeight,
  55. w: uni.getSystemInfoSync().windowWidth,
  56. mt: uni.getSystemInfoSync().statusBarHeight + 44,
  57. avatar: 'https://i.ringzle.com/file/20240129/5b4a757190334fa7ae8616620c770bc4.png',
  58. name: '游客',
  59. orderMenus: [ //type:1 待付款、2 待使用、3 待评价、4 退款/售后
  60. {
  61. type: 1,
  62. img: 'https://i.ringzle.com/file/20240129/818fa751cf8d4772ac1cf818522a7f54.png',
  63. text: '待付款'
  64. },
  65. {
  66. type: 2,
  67. img: 'https://i.ringzle.com/file/20240129/c4ef5f92f5274dbe9e281ad509571fc3.png',
  68. text: '待使用'
  69. },
  70. {
  71. type: 3,
  72. img: 'https://i.ringzle.com/file/20240129/2a73e5e9afcf4d759b31e5332a21d012.png',
  73. text: '已完成'
  74. },
  75. {
  76. type: 4,
  77. img: 'https://i.ringzle.com/file/20240129/f3fd049aaffb4768aa115572851a2bb1.png',
  78. text: '退款/售后'
  79. }
  80. ],
  81. price: 0, //钱包余额
  82. }
  83. },
  84. methods: {
  85. toTurn(url, login) { //login 是否需要验证登录跳转
  86. if (!url) return this.$showToast('正在开发中...')
  87. uni.navigateTo({
  88. url
  89. });
  90. // if (login) {
  91. // this.$login().then(res => {
  92. // if (res === 0) {
  93. // uni.navigateTo({
  94. // url
  95. // });
  96. // } else this.$refs['phoneNumber'].show = true;
  97. // })
  98. // } else {
  99. // uni.navigateTo({
  100. // url
  101. // });
  102. // }
  103. },
  104. }
  105. }
  106. </script>
  107. <style scoped lang="less">
  108. .page {
  109. background: #F5F8FA;
  110. padding-bottom: 256rpx;
  111. box-sizing: border-box;
  112. .bg_img {
  113. width: 100%;
  114. position: absolute;
  115. top: 0;
  116. left: 0;
  117. z-index: 0;
  118. }
  119. .account {
  120. width: 100%;
  121. display: flex;
  122. justify-content: space-between;
  123. .a_left {
  124. padding: 10rpx 0 0 40rpx;
  125. display: flex;
  126. z-index: 1;
  127. .al_avatar {
  128. width: 120rpx;
  129. height: 120rpx;
  130. border-radius: 50%;
  131. background: #FFFFFF;
  132. padding: 4rpx;
  133. box-sizing: border-box;
  134. image {
  135. width: 100%;
  136. height: 100%;
  137. border-radius: 50%;
  138. }
  139. }
  140. .al_name_edit {
  141. margin-left: 30rpx;
  142. display: flex;
  143. flex-direction: column;
  144. &>text {
  145. font-size: 36rpx;
  146. font-family: PingFang-SC, PingFang-SC;
  147. font-weight: bold;
  148. color: #111111;
  149. line-height: 50rpx;
  150. padding-top: 4rpx;
  151. }
  152. .ane_edit {
  153. width: 120rpx;
  154. height: 54rpx;
  155. border-radius: 27rpx;
  156. border: 1rpx solid #D3D7DE;
  157. margin-top: 10rpx;
  158. display: flex;
  159. align-items: center;
  160. justify-content: center;
  161. &>text {
  162. font-size: 26rpx;
  163. font-family: PingFangSC, PingFang SC;
  164. font-weight: 400;
  165. color: #5A697C;
  166. line-height: 37rpx;
  167. }
  168. &>image {
  169. margin-left: 8rpx;
  170. width: 24rpx;
  171. height: 24rpx;
  172. }
  173. }
  174. }
  175. }
  176. }
  177. .box {
  178. width: calc(100% - 40rpx);
  179. margin: 0 20rpx;
  180. box-sizing: border-box;
  181. background: #FFFFFF;
  182. border-radius: 20rpx;
  183. position: relative;
  184. }
  185. .wallet {
  186. margin-top: 32rpx;
  187. padding: 34rpx 40rpx 30rpx 31rpx;
  188. // background: url(https://i.ringzle.com/file/20240129/062264cb5e224845b86e4567c2ec37a6.png) no-repeat;
  189. // background-size: 100% 100%;
  190. background-color: #fff;
  191. display: flex;
  192. justify-content: space-between;
  193. .w_left {
  194. .wl_top {
  195. display: flex;
  196. align-items: center;
  197. image {
  198. width: 30rpx;
  199. height: 30rpx;
  200. }
  201. text {
  202. margin-left: 12rpx;
  203. font-size: 26rpx;
  204. font-family: PingFangSC, PingFang SC;
  205. font-weight: 400;
  206. color: #111;
  207. line-height: 37rpx;
  208. }
  209. }
  210. .wl_price {
  211. margin-top: 17rpx;
  212. span {
  213. font-size: 36rpx;
  214. font-family: DINAlternate, DINAlternate;
  215. font-weight: bold;
  216. color: #111;
  217. line-height: 42rpx;
  218. }
  219. text {
  220. font-size: 48rpx;
  221. font-family: DINAlternate, DINAlternate;
  222. font-weight: bold;
  223. color: #111;
  224. line-height: 56rpx;
  225. margin-left: 10rpx;
  226. }
  227. }
  228. }
  229. .w_right {
  230. margin-top: 16rpx;
  231. width: 164rpx;
  232. height: 72rpx;
  233. background: linear-gradient(270deg, #D6F6ED 0%, #FFFFFF 100%);
  234. border-radius: 36rpx;
  235. line-height: 72rpx;
  236. text-align: center;
  237. font-size: 26rpx;
  238. font-family: PingFang-SC, PingFang-SC;
  239. font-weight: bold;
  240. color: #007750;
  241. }
  242. }
  243. .orders {
  244. margin-top: 20rpx;
  245. padding: 40rpx 0;
  246. .o_title {
  247. width: 100%;
  248. padding: 0 20rpx;
  249. box-sizing: border-box;
  250. display: flex;
  251. align-items: center;
  252. justify-content: space-between;
  253. &>text {
  254. font-size: 36rpx;
  255. font-family: PingFang-SC, PingFang-SC;
  256. font-weight: bold;
  257. color: #1C1E41;
  258. line-height: 36rpx;
  259. }
  260. .ot_all {
  261. display: flex;
  262. align-items: center;
  263. &>text {
  264. font-size: 28rpx;
  265. font-family: PingFangSC, PingFang SC;
  266. font-weight: 400;
  267. color: #808080;
  268. line-height: 28rpx;
  269. }
  270. &>image {
  271. margin-left: 8rpx;
  272. width: 24rpx;
  273. height: 24rpx;
  274. }
  275. }
  276. }
  277. .o_menus {
  278. margin-top: 44rpx;
  279. display: flex;
  280. align-items: center;
  281. justify-content: space-around;
  282. &>view {
  283. width: 25%;
  284. display: flex;
  285. flex-direction: column;
  286. align-items: center;
  287. image {
  288. width: 54rpx;
  289. height: 54rpx;
  290. }
  291. text {
  292. font-size: 26rpx;
  293. font-family: PingFangSC, PingFang SC;
  294. font-weight: 400;
  295. color: #111111;
  296. line-height: 26rpx;
  297. margin-top: 24rpx;
  298. }
  299. }
  300. }
  301. }
  302. }
  303. </style>