建材商城系统20241014
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

395 lines
8.9 KiB

8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
  1. <template>
  2. <view class="page">
  3. <!-- <navbar title="个人中心" /> -->
  4. <view class="head">
  5. <view class="headImage">
  6. <image :src="userInfo.headImage || '/static/image/center/headImage.png'" mode="aspectFill"></image>
  7. </view>
  8. <view class="info">
  9. <view v-if="isLogin">
  10. <view style="display: flex;gap: 20rpx;">
  11. <view class="name">
  12. {{userInfo.nickName || '未登录'}}
  13. </view>
  14. <view class="headBtn" @click="$utils.navigateTo('/pages_order/auth/wxUserInfo')">
  15. 修改资料
  16. <uv-icon name="edit-pen-fill" size="26rpx" color="#fff"></uv-icon>
  17. </view>
  18. </view>
  19. <view class="tips">
  20. 手机号<text>{{userInfo.phone || '未绑定'}}</text>
  21. </view>
  22. </view>
  23. <view v-else>
  24. <view class="login-btn" @tap.stop="$utils.toLogin()">
  25. <text>立即登录</text>
  26. </view>
  27. </view>
  28. </view>
  29. </view>
  30. <!-- 酒店 -->
  31. <view class="user">
  32. <view class="line" @click="$utils.navigateTo('/pages_order/mine/purse')">
  33. <view class="item">
  34. <view class="image">
  35. <image src="/static/image/center/1.png" mode=""></image>
  36. </view>
  37. <view class="">
  38. 累计提现
  39. <p style="color:#DC2828; font-weight: 700;">{{ userInfo.price || 0 }}</p>
  40. </view>
  41. </view>
  42. <view class="item" @click="$utils.navigateTo('/pages_order/mine/purse')">
  43. <view class="image">
  44. <image src="/static/image/center/4.png" mode=""></image>
  45. </view>
  46. <view class="">
  47. 我的积分
  48. <p style="color:#DC2828;font-weight: 700">{{ userInfo.money || 0 }}</p>
  49. </view>
  50. </view>
  51. </view>
  52. <view class="line">
  53. <view class="image-home"
  54. @click="$utils.navigateTo('/pages_order/order/fastCreateOrder')">
  55. <uv-swiper
  56. class="uv-swaip"
  57. height="240rpx"
  58. :list="[configList.banner_icon]"
  59. circular
  60. indicator="true"
  61. bgColor="#ffffff">
  62. </uv-swiper>
  63. </view>
  64. </view>
  65. <view class="line grid">
  66. <view class="title">
  67. 我的服务
  68. </view>
  69. <uv-grid :col="4" :border="false">
  70. <uv-grid-item @click="$utils.navigateTo('/index/order')">
  71. <image class="image" src="/static/image/center/12.png" mode=""></image>
  72. <text class="grid-text">我的订单</text>
  73. </uv-grid-item>
  74. <uv-grid-item @click="$utils.navigateTo('/pages_order/mine/address')">
  75. <image class="image" src="/static/image/center/12.png" mode=""></image>
  76. <text class="grid-text">我的地址</text>
  77. </uv-grid-item>
  78. <uv-grid-item @click="$utils.navigateTo('/pages_order/mine/individualTeam')">
  79. <image class="image" src="/static/image/center/8.png" mode=""></image>
  80. <text class="grid-text">我的分享</text>
  81. </uv-grid-item>
  82. <uv-grid-item @click="$utils.navigateTo('/pages_order/order/fastOrderList')">
  83. <image class="image" src="/static/image/center/12.png" mode=""></image>
  84. <text class="grid-text">快捷订单</text>
  85. </uv-grid-item>
  86. <uv-grid-item @click="$utils.navigateTo('/pages_order/mine/promotion')">
  87. <image class="image" src="/static/image/center/9.png" mode=""></image>
  88. <text class="grid-text">邀请好友</text>
  89. </uv-grid-item>
  90. <!-- <uv-grid-item @click="$utils.navigateTo('/pages_order/center/systemSet')">
  91. <image class="image" src="/static/image/center/6.png" mode=""></image>
  92. <text class="grid-text">系统设置</text>
  93. </uv-grid-item> -->
  94. <uv-grid-item @click="$utils.navigateTo('/pages_order/mine/help')">
  95. <image class="image" src="/static/image/center/7.png" mode=""></image>
  96. <text class="grid-text">帮助与反馈</text>
  97. </uv-grid-item>
  98. <uv-grid-item
  99. @click="$utils.navigateTo('/pages_order/mine/about')">
  100. <image class="image" src="/static/image/center/7.png" mode=""></image>
  101. <text class="grid-text">关于本程序</text>
  102. </uv-grid-item>
  103. <uv-grid-item @click="$store.commit('logout')">
  104. <image class="image" src="/static/image/center/logout.png" mode=""></image>
  105. <text class="grid-text">退出登录</text>
  106. </uv-grid-item>
  107. <!-- <uv-grid-item>
  108. <button open-type="contact" class="share">
  109. <image class="image" src="/static/image/center/5.png" mode=""></image>
  110. <text class="grid-text">联系客服</text>
  111. </button>
  112. </uv-grid-item> -->
  113. </uv-grid>
  114. </view>
  115. </view>
  116. <quick-order-entry
  117. ref="quickOrderEntry"
  118. bottom="50vh"
  119. />
  120. <kefu/>
  121. <tabber select="center" />
  122. </view>
  123. </template>
  124. <script>
  125. import tabber from '@/components/base/tabbar.vue'
  126. import QuickOrderEntry from '@/components/QuickOrderEntry.vue'
  127. export default {
  128. components: {
  129. tabber,
  130. QuickOrderEntry,
  131. },
  132. computed: {
  133. isLogin(){
  134. return this.userInfo && this.userInfo.id
  135. }
  136. },
  137. data() {
  138. return {
  139. list: [],
  140. }
  141. },
  142. onShow() {
  143. if(uni.getStorageSync('token')){
  144. // 刷新快捷下单信息
  145. this.$store.commit('getUserInfo')
  146. this.$refs.quickOrderEntry.refresh()
  147. }
  148. },
  149. methods: {
  150. // 显示快捷订单菜单
  151. showQuickOrderMenu() {
  152. uni.showActionSheet({
  153. itemList: ['快捷下单', '我的快捷订单'],
  154. success: (res) => {
  155. if (res.tapIndex === 0) {
  156. // 跳转到快捷下单页面
  157. this.$utils.navigateTo('/pages_order/order/fastCreateOrder');
  158. } else if (res.tapIndex === 1) {
  159. // 跳转到快捷订单列表
  160. this.$utils.navigateTo('/pages_order/order/fastOrderList');
  161. }
  162. }
  163. });
  164. }
  165. }
  166. }
  167. </script>
  168. <style scoped lang="scss">
  169. .page {
  170. .warp {
  171. display: flex;
  172. align-items: center;
  173. justify-content: center;
  174. height: 100%;
  175. }
  176. .rect {
  177. width: 600rpx;
  178. height: 300rpx;
  179. background-color: #fff;
  180. border-radius: 20rpx;
  181. overflow: hidden;
  182. .title {
  183. padding: 10rpx 0 0 15rpx;
  184. background-color: #fd5100;
  185. color: #FFF;
  186. text-align: left;
  187. width: 100%;
  188. height: 18%;
  189. font-size: 36rpx;
  190. }
  191. .center {
  192. height: 40%;
  193. display: flex;
  194. justify-content: center;
  195. align-items: center;
  196. font-size: 36rpx;
  197. }
  198. .bottom {
  199. display: flex;
  200. justify-content: center;
  201. gap: 50rpx;
  202. }
  203. }
  204. }
  205. image {
  206. width: 100%;
  207. height: 100%;
  208. }
  209. .head {
  210. display: flex;
  211. background-color: #DC2828;
  212. padding: 0rpx 20rpx;
  213. align-items: center;
  214. position: relative;
  215. height: 300rpx;
  216. padding-top: 60rpx;
  217. .headImage {
  218. width: 120rpx;
  219. height: 120rpx;
  220. background-image: url(/static/image/center/3.png);
  221. background-size: 100% 100%;
  222. overflow: hidden;
  223. border-radius: 50%;
  224. margin-right: 40rpx;
  225. }
  226. .info {
  227. font-size: 28rpx;
  228. .vip {
  229. background-color: #FCCC92;
  230. color: #FA6239;
  231. width: 100rpx;
  232. display: flex;
  233. justify-content: center;
  234. align-items: center;
  235. height: 40rpx;
  236. border-radius: 20rpx;
  237. margin-top: 20rpx;
  238. }
  239. .name {
  240. font-size: 36rpx;
  241. color: #fff;
  242. margin-right: 20rpx;
  243. width: 240rpx;
  244. white-space: nowrap;
  245. overflow: hidden;
  246. text-overflow: ellipsis;
  247. }
  248. .tips {
  249. font-size: 26rpx;
  250. color: #fff;
  251. margin-top: 10rpx;
  252. }
  253. .login-btn {
  254. margin-top: 20rpx;
  255. background-color: #fff;
  256. color: #DC2828;
  257. padding: 10rpx 30rpx;
  258. border-radius: 30rpx;
  259. font-size: 28rpx;
  260. display: inline-block;
  261. width: 160rpx;
  262. text-align: center;
  263. }
  264. }
  265. .headBtn {
  266. color: #FFF;
  267. font-size: 26rpx;
  268. display: flex;
  269. align-items: center;
  270. }
  271. }
  272. .user {
  273. position: relative;
  274. z-index: 9;
  275. margin: 0 30rpx;
  276. margin-top: -60rpx;
  277. .line {
  278. display: flex;
  279. background-color: #fff;
  280. padding: 20rpx 0;
  281. align-content: center;
  282. margin-top: 20rpx;
  283. border-radius: 15rpx;
  284. .item {
  285. flex: 1;
  286. display: flex;
  287. justify-content: center;
  288. align-items: center;
  289. padding: 20rpx 0;
  290. &:nth-child(1) {
  291. border-right: 1px dotted #00000013;
  292. }
  293. .image {
  294. width: 150rpx;
  295. height: 135rpx;
  296. margin-right: 20rpx;
  297. }
  298. }
  299. .image-home{
  300. z-index: 1;
  301. width: 100%;
  302. }
  303. }
  304. .grid {
  305. flex-direction: column;
  306. font-size: 26rpx;
  307. padding: 20rpx;
  308. .title {
  309. margin-bottom: 30rpx;
  310. font-size: 28rpx;
  311. font-weight: 600;
  312. }
  313. .image {
  314. width: 50rpx;
  315. height: 50rpx;
  316. margin: 20rpx 0;
  317. }
  318. text {
  319. text-align: center;
  320. width: 120rpx;
  321. font-size: 24rpx;
  322. }
  323. .share {
  324. background: none;
  325. padding: 0;
  326. margin: 0;
  327. line-height: normal;
  328. border: none;
  329. display: flex;
  330. flex-direction: column;
  331. align-items: center;
  332. justify-content: center;
  333. &::after {
  334. border: none;
  335. }
  336. .image {
  337. width: 50rpx;
  338. height: 50rpx;
  339. margin: 20rpx 0;
  340. }
  341. .grid-text {
  342. text-align: center;
  343. width: 120rpx;
  344. font-size: 24rpx;
  345. }
  346. }
  347. }
  348. }
  349. </style>