index.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493
  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">
  8. <image :src="dto.storeFrontPic"></image>
  9. </view>
  10. <view class="al_name_edit">
  11. <text>{{dto.name==''?'临时商户':dto.name}}</text>
  12. <view class="ane_edit" @tap="toTurn('/pagesHouse/Mine/PersonalEditing/PersonalEditing',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=&index=-1',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('/pagesHouse/Mine/ordersList/index?type='+item.type+'&index='+index,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/20240225/337c4c20cbc94bdcb4f17b6058a9d39f.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. <view class="one" v-if="merchantType==10" @tap="toTurn('/pagesHouse/Mine/Businesses/Businesses',true)">
  48. <view class="">
  49. 商户信息
  50. </view>
  51. <view class="">
  52. <u-icon name="arrow-right"></u-icon>
  53. </view>
  54. </view>
  55. <view class="one" v-if="merchantType==4" @tap="toTurn('/pagesHouse/Mine/Businesses/Catering',true)">
  56. <view class="">
  57. 商户信息
  58. </view>
  59. <view class="">
  60. <u-icon name="arrow-right"></u-icon>
  61. </view>
  62. </view>
  63. <view class="" style="padding: 24rpx; background-color: #fff; margin: 0 20rpx ; border-radius: 16rpx;">
  64. <view class="one-input">
  65. <u-row customStyle="margin-bottom: 10px">
  66. <u-col span="7.8">
  67. <view class="demo-layout bg-purple-light">
  68. <view class="one2">
  69. <!-- {{myList.islandName}} -->
  70. {{dto.companyName}}
  71. </view>
  72. <view class="two2">
  73. {{dto.areaDetail}}
  74. </view>
  75. </view>
  76. </u-col>
  77. <u-col span="4" @click="navigation">
  78. <view class="demo-layout bg-purple">
  79. </view>
  80. </u-col>
  81. </u-row>
  82. </view>
  83. </view>
  84. <Tabbares :tabbarid="2"></Tabbares>
  85. </view>
  86. </template>
  87. <script>
  88. export default {
  89. data() {
  90. return {
  91. h: uni.getSystemInfoSync().windowHeight,
  92. w: uni.getSystemInfoSync().windowWidth,
  93. mt: uni.getSystemInfoSync().statusBarHeight + 44,
  94. avatar: 'https://i.ringzle.com/file/20240129/5b4a757190334fa7ae8616620c770bc4.png',
  95. name: '游客',
  96. orderMenus: [ //type:1 待付款、2 待使用、3 待评价、4 退款/售后
  97. {
  98. type: 0,
  99. img: 'https://i.ringzle.com/file/20240129/818fa751cf8d4772ac1cf818522a7f54.png',
  100. text: '待支付'
  101. },
  102. {
  103. type: 4,
  104. img: 'https://i.ringzle.com/file/20240129/c4ef5f92f5274dbe9e281ad509571fc3.png',
  105. text: '待使用'
  106. },
  107. {
  108. type: 3,
  109. img: 'https://i.ringzle.com/file/20240129/2a73e5e9afcf4d759b31e5332a21d012.png',
  110. text: '已完成'
  111. },
  112. {
  113. type: -3,
  114. img: 'https://i.ringzle.com/file/20240129/f3fd049aaffb4768aa115572851a2bb1.png',
  115. text: '退款/售后'
  116. }
  117. ],
  118. price: 0, //钱包余额
  119. merchantName: uni.getStorageSync('merchantName'),
  120. merchantType: uni.getStorageSync('merchantType'),
  121. dto: {}
  122. }
  123. },
  124. onLoad() {
  125. this.getInfo();
  126. },
  127. methods: {
  128. toTurn(url, login) { //login 是否需要验证登录跳转
  129. if (!url) return this.$showToast('正在开发中...')
  130. uni.navigateTo({
  131. url
  132. });
  133. },
  134. getInfo() {
  135. this.$api.get('/api/merchant/food/merchant/' + uni.getStorageSync('merchantId')).then(res => {
  136. if (res.data.code == 0) {
  137. this.dto = res.data.data;
  138. if (!res.data.data.shopSign) {
  139. this.dto.shopSign =
  140. 'https://i.ringzle.com/file/20240225/26feb8cc8f744123a980211ebdfb8d40.png';
  141. }
  142. //this.shopImgs = res.data.data.split(',');
  143. }
  144. })
  145. },
  146. }
  147. }
  148. </script>
  149. <style scoped lang="less">
  150. .page {
  151. background: #F5F8FA;
  152. padding-bottom: 256rpx;
  153. box-sizing: border-box;
  154. .bg_img {
  155. width: 100%;
  156. position: absolute;
  157. top: 0;
  158. left: 0;
  159. z-index: 0;
  160. }
  161. .account {
  162. width: 100%;
  163. display: flex;
  164. justify-content: space-between;
  165. .a_left {
  166. padding: 10rpx 0 0 40rpx;
  167. display: flex;
  168. z-index: 1;
  169. .al_avatar {
  170. width: 120rpx;
  171. height: 120rpx;
  172. border-radius: 50%;
  173. background: #FFFFFF;
  174. padding: 4rpx;
  175. box-sizing: border-box;
  176. image {
  177. width: 100%;
  178. height: 100%;
  179. border-radius: 50%;
  180. }
  181. }
  182. .al_name_edit {
  183. margin-left: 30rpx;
  184. display: flex;
  185. flex-direction: column;
  186. &>text {
  187. font-size: 36rpx;
  188. font-family: PingFang-SC, PingFang-SC;
  189. font-weight: bold;
  190. color: #111111;
  191. line-height: 50rpx;
  192. padding-top: 4rpx;
  193. }
  194. .ane_edit {
  195. width: 120rpx;
  196. height: 54rpx;
  197. border-radius: 27rpx;
  198. border: 1rpx solid #D3D7DE;
  199. margin-top: 10rpx;
  200. display: flex;
  201. align-items: center;
  202. justify-content: center;
  203. &>text {
  204. font-size: 26rpx;
  205. font-family: PingFangSC, PingFang SC;
  206. font-weight: 400;
  207. color: #5A697C;
  208. line-height: 37rpx;
  209. }
  210. &>image {
  211. margin-left: 8rpx;
  212. width: 24rpx;
  213. height: 24rpx;
  214. }
  215. }
  216. }
  217. }
  218. }
  219. .one {
  220. // padding: ;
  221. margin: 0 40rpx;
  222. height: 120rpx;
  223. line-height: 120rpx;
  224. display: flex;
  225. // border-bottom: 1rpx solid #EFEFEF;
  226. justify-content: space-between;
  227. align-items: center;
  228. font-size: 36rpx;
  229. color: #111111;
  230. font-weight: bold;
  231. }
  232. .box {
  233. width: calc(100% - 40rpx);
  234. margin: 0 20rpx;
  235. box-sizing: border-box;
  236. background: #FFFFFF;
  237. border-radius: 20rpx;
  238. position: relative;
  239. }
  240. .bg-img {
  241. background-color: #F0F8F6 !important;
  242. }
  243. .one-input {
  244. box-sizing: border-box;
  245. // width: 100%;
  246. height: 128rpx;
  247. background: #F0F8F6;
  248. // line-height: 128rpx;
  249. border-radius: 16rpx;
  250. padding: 0 20rpx;
  251. // margin: 0 20rpx;
  252. .bg-purple-light {
  253. // display: flex;
  254. .one2 {
  255. // height: 36rpx !important;
  256. font-size: 26rpx;
  257. color: #000000;
  258. margin: 12rpx 6rpx;
  259. font-weight: bold;
  260. }
  261. .two2 {
  262. font-size: 24rpx;
  263. color: #666666;
  264. // height: 36rpx !important;
  265. margin: 6rpx 6rpx;
  266. font-weight: Regular;
  267. }
  268. }
  269. .bg-purple {
  270. // align-items: center;
  271. // display: flex;
  272. text-align: center;
  273. // text-align: right;
  274. font-size: 24rpx;
  275. color: #808080;
  276. background-image: url('https://i.ringzle.com/file/20240129/dcf2338517e344c697ef7cd853ce2234.png');
  277. background-repeat: no-repeat;
  278. background-size: 100% 100%;
  279. width: 240rpx;
  280. height: 128rpx;
  281. .one1 {
  282. margin: auto 110rpx;
  283. padding-top: 30rpx;
  284. width: 46rpx;
  285. height: 46rpx;
  286. image {
  287. width: 100%;
  288. height: 100%;
  289. // width: 46rpx;
  290. // height: 46rpx;
  291. }
  292. }
  293. .two1 {
  294. margin: 4rpx 12rpx;
  295. font-size: 22rpx;
  296. color: #007A69;
  297. text {
  298. margin-left: 30rpx;
  299. }
  300. }
  301. }
  302. }
  303. .wallet {
  304. margin-top: 32rpx;
  305. padding: 34rpx 40rpx 30rpx 31rpx;
  306. // background: url(https://i.ringzle.com/file/20240129/062264cb5e224845b86e4567c2ec37a6.png) no-repeat;
  307. // background-size: 100% 100%;
  308. background-color: #fff;
  309. display: flex;
  310. justify-content: space-between;
  311. .w_left {
  312. .wl_top {
  313. display: flex;
  314. align-items: center;
  315. image {
  316. width: 30rpx;
  317. height: 30rpx;
  318. }
  319. text {
  320. margin-left: 12rpx;
  321. font-size: 26rpx;
  322. font-family: PingFangSC, PingFang SC;
  323. font-weight: 400;
  324. color: #111;
  325. line-height: 37rpx;
  326. }
  327. }
  328. .wl_price {
  329. margin-top: 17rpx;
  330. span {
  331. font-size: 36rpx;
  332. font-family: DINAlternate, DINAlternate;
  333. font-weight: bold;
  334. color: #111;
  335. line-height: 42rpx;
  336. }
  337. text {
  338. font-size: 48rpx;
  339. font-family: DINAlternate, DINAlternate;
  340. font-weight: bold;
  341. color: #111;
  342. line-height: 56rpx;
  343. margin-left: 10rpx;
  344. }
  345. }
  346. }
  347. .w_right {
  348. margin-top: 16rpx;
  349. width: 156rpx;
  350. height: 60rpx;
  351. // background: linear-gradient(270deg, #D6F6ED 0%, #FFFFFF 100%);
  352. background-color: #007A69;
  353. border-radius: 36rpx;
  354. line-height: 60rpx;
  355. text-align: center;
  356. font-size: 26rpx;
  357. font-family: PingFang-SC, PingFang-SC;
  358. font-weight: bold;
  359. color: #FFFFFF;
  360. }
  361. .w_right-image {
  362. margin-top: 16rpx;
  363. width: 156rpx;
  364. // height: 60rpx;
  365. // background: linear-gradient(270deg, #D6F6ED 0%, #FFFFFF 100%);
  366. background-color: #007A69;
  367. background-image: url('https://i.ringzle.com/file/20240225/b918fbd7e3424908a10497c4e4f71fda.png');
  368. background-repeat: no-repeat;
  369. background-size: 100% 100%;
  370. border-radius: 36rpx;
  371. // line-height: 60rpx;
  372. text-align: center;
  373. font-size: 26rpx;
  374. font-family: PingFang-SC, PingFang-SC;
  375. font-weight: bold;
  376. color: #FFFFFF;
  377. }
  378. }
  379. .orders {
  380. margin-top: 20rpx;
  381. padding: 40rpx 0;
  382. .o_title {
  383. width: 100%;
  384. padding: 0 20rpx;
  385. box-sizing: border-box;
  386. display: flex;
  387. align-items: center;
  388. justify-content: space-between;
  389. &>text {
  390. font-size: 36rpx;
  391. font-family: PingFang-SC, PingFang-SC;
  392. font-weight: bold;
  393. color: #1C1E41;
  394. line-height: 36rpx;
  395. }
  396. .ot_all {
  397. display: flex;
  398. align-items: center;
  399. &>text {
  400. font-size: 28rpx;
  401. font-family: PingFangSC, PingFang SC;
  402. font-weight: 400;
  403. color: #808080;
  404. line-height: 28rpx;
  405. }
  406. &>image {
  407. margin-left: 8rpx;
  408. width: 24rpx;
  409. height: 24rpx;
  410. }
  411. }
  412. }
  413. .o_menus {
  414. margin-top: 44rpx;
  415. display: flex;
  416. align-items: center;
  417. justify-content: space-around;
  418. &>view {
  419. width: 25%;
  420. display: flex;
  421. flex-direction: column;
  422. align-items: center;
  423. image {
  424. width: 54rpx;
  425. height: 54rpx;
  426. }
  427. text {
  428. font-size: 26rpx;
  429. font-family: PingFangSC, PingFang SC;
  430. font-weight: 400;
  431. color: #111111;
  432. line-height: 26rpx;
  433. margin-top: 24rpx;
  434. }
  435. }
  436. }
  437. }
  438. }
  439. </style>