merchant.vue 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234
  1. <template>
  2. <view class="body">
  3. <view class="background"></view>
  4. <view class="content">
  5. <view class="userInfo">
  6. <view class="userInfo-box">
  7. <view class="userInfo-img"><image class="portrait" src="../../static/error/missing-face.png"></image></view>
  8. <view class="userInfo-xinxi">
  9. <view class="title"><text>满园春泰州店</text></view>
  10. <view class="phone"><text>19999999999</text></view>
  11. </view>
  12. <view class="balance">可用余额¥20000</view>
  13. </view>
  14. </view>
  15. <view class="userInfoList">
  16. <view class="userInfoList-top" @click="sao()">
  17. <view class="top"><image src="../../static/merchant/saoma.png" mode=""></image></view>
  18. 扫码核销
  19. </view>
  20. <view class="userInfoList-top" @click="navTo('/pages/merchant/storeQr')">
  21. <view class="top"><image src="../../static/merchant/erweima.png" mode=""></image></view>
  22. 店铺二维码
  23. </view>
  24. <view class="userInfoList-bottom" @click="navTo('/pages/merchant/finance')">
  25. <view class="bottom"><image src="../../static/merchant/money.png" mode=""></image></view>
  26. 店铺财务
  27. </view>
  28. <view class="userInfoList-bottom" @click="navTo('/pages/merchant/order')">
  29. <view class="bottom"><image src="../../static/merchant/order.png" mode=""></image></view>
  30. 订单管理
  31. </view>
  32. <view class="userInfoList-bottom" @click="navTo('/pages/merchant/commodity')">
  33. <view class="bottom"><image src="../../static/merchant/shop.png" mode=""></image></view>
  34. 商品管理
  35. </view>
  36. <<<<<<< HEAD
  37. <view class="userInfoList-bottom">
  38. <view class="bottom"><image src="../../static/merchant/xiadan.png" mode=""></image></view>
  39. =======
  40. <view class="userInfoList-bottom" @click="navTo('/pages/merchant/onlineOrder')">
  41. <view class="bottom">
  42. <image src="../../static/merchant/xiadan.png" mode=""></image>
  43. </view>
  44. >>>>>>> 5705ae03169c285084ea64fbe08c99a47a08f826
  45. 在线下单
  46. </view>
  47. <view class="userInfoList-bottom" @click="navTo('/pages/merchant/vipDetail')">
  48. <view class="bottom"><image src="../../static/merchant/vip.png" mode=""></image></view>
  49. 店铺会员
  50. </view>
  51. <view class="userInfoList-bottom" @click="navTo('/pages/merchant/storeData')">
  52. <view class="bottom"><image src="../../static/merchant/dianpu.png" mode=""></image></view>
  53. 店铺数据
  54. </view>
  55. </view>
  56. </view>
  57. </view>
  58. </template>
  59. <script>
  60. export default {
  61. data() {
  62. return {};
  63. },
  64. methods: {
  65. //跳转
  66. navTo(url) {
  67. uni.navigateTo({
  68. url
  69. });
  70. },
  71. //调取扫描二维码
  72. sao() {
  73. let obj = this;
  74. // #ifndef H5
  75. uni.scanCode({
  76. success(e) {
  77. obj.orderVerific(e.result);
  78. }
  79. });
  80. // #endif
  81. // #ifdef H5
  82. this.weichatObj.scanQRCode({
  83. needResult: 1, // 默认为0,扫描结果由微信处理,1则直接返回扫描结果,
  84. scanType: ['qrCode', 'barCode'], // 可以指定扫二维码还是一维码,默认二者都有
  85. success: function(res) {
  86. obj.orderVerific(res.resultStr); // 当needResult 为 1 时,扫码返回的结果
  87. }
  88. });
  89. // #endif
  90. }
  91. }
  92. };
  93. </script>
  94. <style lang="scss">
  95. page {
  96. height: 100%;
  97. background-color: #eeeded;
  98. padding: 0;
  99. margin: 0;
  100. }
  101. .content {
  102. background-color: #eeeded;
  103. margin: 0 30rpx;
  104. display: flex;
  105. flex-direction: column;
  106. }
  107. .background {
  108. width: 100%;
  109. height: 220rpx;
  110. background-color: #75e5b6;
  111. }
  112. .userInfo {
  113. margin-top: -110rpx;
  114. display: flex;
  115. flex-direction: column;
  116. justify-content: center;
  117. background-color: #f9f9f9;
  118. border-radius: 19rpx;
  119. width: 100%;
  120. height: 300rpx;
  121. .userInfo-box {
  122. display: flex;
  123. flex-direction: column;
  124. align-items: center;
  125. .userInfo-img {
  126. margin: -65rpx 0 0 0;
  127. width: 130rpx;
  128. height: 130rpx;
  129. border: 5rpx solid #fff;
  130. border-radius: 50%;
  131. image {
  132. width: 100%;
  133. height: 100%;
  134. }
  135. }
  136. .userInfo-xinxi {
  137. .title {
  138. margin: 20rpx 0;
  139. font-size: 32rpx;
  140. font-family: PingFang SC;
  141. font-weight: bold;
  142. color: #333333;
  143. line-height: 21rpx;
  144. }
  145. .phone {
  146. font-size: 28rpx;
  147. font-family: PingFang SC;
  148. font-weight: 500;
  149. color: #666666;
  150. line-height: 21rpx;
  151. margin-bottom: 40rpx;
  152. }
  153. }
  154. .balance {
  155. text-align: center;
  156. width: 500rpx;
  157. height: 60rpx;
  158. background: #52c696;
  159. border-radius: 30rpx;
  160. font-size: 28rpx;
  161. font-family: PingFang SC;
  162. font-weight: 500;
  163. color: #ffffff;
  164. line-height: 60rpx;
  165. }
  166. }
  167. }
  168. .userInfoList {
  169. display: flex;
  170. flex-wrap: wrap;
  171. justify-content: space-between;
  172. .userInfoList-top {
  173. position: relative;
  174. margin: 15rpx 0;
  175. display: flex;
  176. justify-content: center;
  177. align-items: center;
  178. width: 340rpx;
  179. height: 100rpx;
  180. background: #ffffff;
  181. border-radius: 20rpx;
  182. font-size: 30rpx;
  183. font-family: PingFang SC;
  184. font-weight: 500;
  185. color: #4d4d4d;
  186. line-height: 21rpx;
  187. .top {
  188. position: absolute;
  189. margin-left: -230rpx;
  190. width: 50rpx;
  191. height: 50rpx;
  192. image {
  193. width: 100%;
  194. height: 100%;
  195. }
  196. }
  197. }
  198. .userInfoList-bottom {
  199. margin-bottom: 15rpx;
  200. width: 340rpx;
  201. height: 250rpx;
  202. background: #f9f9f9;
  203. border-radius: 20rpx;
  204. display: flex;
  205. flex-direction: column;
  206. justify-content: center;
  207. align-items: center;
  208. .bottom {
  209. margin-bottom: 20rpx;
  210. width: 68rpx;
  211. height: 68rpx;
  212. image {
  213. width: 100%;
  214. height: 100%;
  215. }
  216. }
  217. }
  218. }
  219. </style>