user.vue 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927
  1. <template>
  2. <view class="container">
  3. <view class="vheigh"></view>
  4. <view class="user">
  5. <!-- 背景图片 -->
  6. <view class="top-bg"></view>
  7. <!-- 用户头像和信息 -->
  8. <view class="infor">
  9. <!-- 用户信息 -->
  10. <view class="infor-left" @click="navTo('/pages/set/userinfo')">
  11. <image :src=" userInfo.avatar || '../../static/error/missing-face.png' "></image>
  12. <view class="info-box">
  13. <view class="username clamp2">{{ userInfo.nickname || '游客' }}</view>
  14. <view class="phone" v-if="userInfo.phone">{{userInfo.phone | phone}}</view>
  15. <view class="phone" v-if="userInfo.uid">邀请码:{{userInfo.uid}}</view>
  16. <view class="phone" v-if="userInfo.level >= 1">
  17. <text v-if="userInfo.valid_time != 0">会员到期: {{userInfo.valid_time}}</text>
  18. <text v-if="userInfo.valid_time == 0">会员已到期</text>
  19. <text v-if="userInfo.commission_time != 0" style="display: inline-block;padding-left: 20rpx;">分红到期: {{userInfo.commission_time}}</text>
  20. <text v-if="userInfo.commission_time == 0" style="display: inline-block;padding-left: 20rpx;">分红已到期</text>
  21. <text class="show-btn" @click.stop="longTime" style="display: inline-block;padding-left: 20rpx;text-decoration:underline;font-weight: bold;">续期</text>
  22. </view>
  23. </view>
  24. </view>
  25. </view>
  26. <!-- 我的订单 -->
  27. <view class="order-box">
  28. <view class="my-order" @click="navTo('/pages/order/order')">
  29. <view class="order">我的订单</view>
  30. <image src="../../static/img/xiangxia.png" mode="scaleToFill"></image>
  31. </view>
  32. <!-- 订单栏 -->
  33. <view class="order-section">
  34. <view class="order-item" @click="navTo('/pages/order/order?state=0')">
  35. <image src="../../static/img/img19.png" mode="scaleToFill"></image>
  36. <view class="text">待付款</view>
  37. </view>
  38. <view class="order-item" @click="navTo('/pages/order/order?state=1')">
  39. <image src="../../static/img/img20.png" mode="scaleToFill"></image>
  40. <view class="text">待发货</view>
  41. </view>
  42. <view class="order-item" @click="navTo('/pages/order/order?state=2')">
  43. <image src="../../static/img/img21.png" mode="scaleToFill"></image>
  44. <view class="text">待收货</view>
  45. </view>
  46. <view class="order-item" @click="navTo('/pages/order/order?state=4')">
  47. <image src="../../static/img/img22.png" mode="scaleToFill"></image>
  48. <view class="text">已完成</view>
  49. </view>
  50. </view>
  51. </view>
  52. </view>
  53. <view class="open-m" @click="navTo('/pages/user/vip')" v-if="userInfo.uid && userInfo.level <= 2">
  54. <image src="../../static/img/open-m.png" mode=""></image>
  55. </view>
  56. <!-- <scroll-view class="content-box" scroll-y="true"> -->
  57. <!-- <template v-if="userInfo.level >= 1">
  58. <view class="show-time" >
  59. <view v-if="userInfo.valid_time != 0">会员到期: {{userInfo.valid_time}}</view>
  60. <view v-if="userInfo.valid_time == 0">会员已到期</view>
  61. </view>
  62. <view class="show-time flex">
  63. <view v-if="userInfo.commission_time != 0">分红到期: {{userInfo.commission_time}}</view>
  64. <view v-if="userInfo.commission_time == 0">分红已到期</view>
  65. <view class="show-btn" @click="longTime">续期</view>
  66. </view>
  67. </template> -->
  68. <view class="cover-container">
  69. <view class="item-box">
  70. <!-- <view class="order-section">
  71. <view class="order-item" @click="navTo('/pages/order/order?state=0')" hover-class="common-hover"
  72. :hover-stay-time="50">
  73. <view class=" icon position-relative">
  74. <image class="icon-img" src="/static/icon/i1.png" mode="aspectFit"></image>
  75. <view class="corner" v-if="orderInfo.unpaid_count > 0">
  76. <text>{{ orderInfo.unpaid_count }}</text>
  77. </view>
  78. </view>
  79. <text>待付款</text>
  80. </view>
  81. <view class="order-item" @click="navTo('/pages/order/order?state=1')" hover-class="common-hover"
  82. :hover-stay-time="50">
  83. <view class=" icon position-relative">
  84. <image class="icon-img" src="/static/icon/i2.png" mode="aspectFit"></image>
  85. <view class="corner" v-if="orderInfo.unshipped_count > 0">
  86. <text>{{ orderInfo.unshipped_count }}</text>
  87. </view>
  88. </view>
  89. <text>待发货</text>
  90. </view>
  91. <view class="order-item" @click="navTo('/pages/order/order?state=2')" hover-class="common-hover"
  92. :hover-stay-time="50">
  93. <view class="icon position-relative">
  94. <image class="icon-img" src="/static/icon/i3.png" mode="aspectFit"></image>
  95. <view class="corner" v-if="orderInfo.received_count > 0">
  96. <text>{{ orderInfo.received_count }}</text>
  97. </view>
  98. </view>
  99. <text>待收货</text>
  100. </view>
  101. <view class="order-item" @click="navTo('/pages/order/order?state=3')" hover-class="common-hover"
  102. :hover-stay-time="50">
  103. <view class="icon position-relative">
  104. <image class="icon-img" src="/static/icon/i4.png" mode="aspectFit"></image>
  105. </view>
  106. <text>已完成</text>
  107. </view>
  108. </view> -->
  109. </view>
  110. <view class="item-box">
  111. <view class="order-section">
  112. <view class="order-item" @click="navTo('/pages/money/wallet')" hover-class="common-hover"
  113. :hover-stay-time="50">
  114. <view class="icon">
  115. <image class="icon-img" src="/static/icon/u1.png" mode="aspectFit"></image>
  116. </view>
  117. <text>购物卡</text>
  118. </view>
  119. <view class="order-item" @click="navTo('/pages/user/award')" hover-class="common-hover"
  120. :hover-stay-time="50">
  121. <view class="icon">
  122. <image class="icon-img" src="/static/icon/u2.png" mode="aspectFit"></image>
  123. </view>
  124. <text>我的收益</text>
  125. </view>
  126. <view class="order-item" @click="navTo('/pages/user/scoreAccumulate')" hover-class="common-hover"
  127. :hover-stay-time="50">
  128. <view class="icon">
  129. <image class="icon-img" src="/static/icon/u3.png" mode="aspectFit"></image>
  130. </view>
  131. <text>我的积分</text>
  132. </view>
  133. <view class="order-item" @click="navTo('/pages/user/extension')" hover-class="common-hover"
  134. :hover-stay-time="50">
  135. <view class="icon">
  136. <image class="icon-img" src="/static/icon/u4.png" mode="aspectFit"></image>
  137. </view>
  138. <text>我的团队</text>
  139. </view>
  140. <!-- <view class="order-item" @click="navTo('/pages/user/zjc')" hover-class="common-hover"
  141. :hover-stay-time="50">
  142. <view class="icon">
  143. <image class="icon-img" src="/static/icon/u5.png" mode="aspectFit"></image>
  144. </view>
  145. <text>资金池</text>
  146. </view> -->
  147. </view>
  148. </view>
  149. <!-- 续期 -->
  150. <view class="history-section icon">
  151. <uni-list>
  152. <uni-list-item title="推广海报" @click="navTo('/pages/user/shareQrCode')" thumb="/static/icon/tuiguang.png">
  153. </uni-list-item>
  154. <!-- <uni-list-item title="资金池" @click="navTo('/pages/user/zjc')" thumb="/static/icon/zjc-u.png">
  155. </uni-list-item> -->
  156. <uni-list-item title="交易密码" @click="navTo('/pages/money/moneyPwd')" thumb="/static/icon/img06.png"></uni-list-item>
  157. <uni-list-item title="收货地址" @click="navTo('/pages/set/address')" thumb="/static/icon/dizhi.png">
  158. </uni-list-item>
  159. <!-- <uni-list-item title="商户入驻" @click="navTo('/pages/set/address')" thumb="/static/icon/img05.png"></uni-list-item> -->
  160. <uni-list-item title="联系客服" @click="openPopup"
  161. thumb="/static/icon/kefu.png">
  162. </uni-list-item>
  163. <!-- <uni-list-item title="关于我们" @click="navTo('/pages/shareQrCode/index')" thumb="/static/icon/img09.png"></uni-list-item> -->
  164. </uni-list>
  165. </view>
  166. </view>
  167. <!-- </scroll-view> -->
  168. <uni-popup ref="popup" type="center">
  169. <view class="popup-box">
  170. <view class="img"><image src="../../static/img/img009.png" mode=""></image></view>
  171. <view class="mian">
  172. <view class="delivery">
  173. <view class="title">已经为您定制专属客服</view>
  174. <image src="../../static/img/img010.png" mode=""></image>
  175. </view>
  176. <view class="nocancel">客服VX:{{ text }}</view>
  177. <view class="comfirm-box">
  178. <view class="cancel" @click="cancel">取消</view>
  179. <view class="comfirm" @click="comfirm(text)">复制微信</view>
  180. </view>
  181. </view>
  182. </view>
  183. </uni-popup>
  184. </view>
  185. </template>
  186. <script>
  187. import uniCopy from '@/utils/uni-copy.js';
  188. import {
  189. mapState,
  190. mapMutations
  191. } from 'vuex';
  192. import uniList from '@/components/uni-list/uni-list.vue';
  193. import uniListItem from '@/components/uni-list-item/uni-list-item.vue';
  194. import {
  195. orderData,
  196. getUserInfo,
  197. repurchase
  198. } from '@/api/user.js';
  199. import {
  200. saveUrl,
  201. interceptor
  202. } from '@/utils/loginUtils.js';
  203. let startY = 0,
  204. moveY = 0,
  205. pageAtTop = true;
  206. export default {
  207. components: {
  208. uniList,
  209. uniListItem
  210. },
  211. filters: {
  212. phone(val) {
  213. let str = ''
  214. if(val) {
  215. val = "" + val;
  216. str = val.substr(0,3) + "****" + val.substr(7)
  217. }
  218. return str
  219. }
  220. },
  221. data() {
  222. return {
  223. coverTransform: 'translateY(0px)',
  224. coverTransition: '0s',
  225. moving: false,
  226. userDowm: 0, //卡片升级专属高度
  227. userMaxDowm: 0 ,//卡片最高高度
  228. text: '123456',
  229. };
  230. },
  231. onShow() {
  232. // 判断是否已经登录
  233. if (this.hasLogin) {
  234. this.loadBaseData();
  235. }
  236. },
  237. onReady() {
  238. // 初始化获取页面宽度
  239. uni.createSelectorQuery()
  240. .select('.container')
  241. .fields({
  242. size: true
  243. },
  244. data => {
  245. // 计算最多下拉的高度
  246. this.userDowm = Math.floor((data.width / 750) * 185);
  247. // 计算最大触发修改高度事件
  248. this.userMaxDowm = Math.floor((data.width / 750) * 250);
  249. }
  250. )
  251. .exec();
  252. },
  253. // #ifndef MP
  254. // onNavigationBarButtonTap(e) {
  255. // const index = e.index;
  256. // if (index === 0) {
  257. // this.navTo('/pages/set/set');
  258. // } else if (index === 1) {
  259. // // #ifdef APP-PLUS
  260. // const pages = getCurrentPages();
  261. // const page = pages[pages.length - 1];
  262. // const currentWebview = page.$getAppWebview();
  263. // currentWebview.hideTitleNViewButtonRedDot({
  264. // index
  265. // });
  266. // // #endif
  267. // uni.navigateTo({
  268. // url: '/pages/user/notice'
  269. // });
  270. // }
  271. // },
  272. // #endif
  273. computed: {
  274. ...mapState('user', ['userInfo', 'orderInfo', 'hasLogin'])
  275. },
  276. methods: {
  277. ...mapMutations('user', ['setUserInfo', 'setOrderInfo']),
  278. // 加载初始数据
  279. loadBaseData() {
  280. getUserInfo({})
  281. .then(({
  282. data
  283. }) => {
  284. this.setUserInfo(data);
  285. // 获取用户数据完毕后在获取订单数据防止多次跳转到登录页
  286. orderData({})
  287. .then(({
  288. data
  289. }) => {
  290. this.setOrderInfo(data);
  291. })
  292. .catch(e => {
  293. this.setOrderInfo({
  294. complete_count: 0, //完成
  295. received_count: 0, //待收货
  296. unshipped_count: 0, //待发货
  297. order_count: 0, //订单总数
  298. unpaid_count: 0 //待付款
  299. });
  300. });
  301. })
  302. .catch(e => {
  303. console.log(e);
  304. });
  305. },
  306. /**
  307. * 统一跳转接口,拦截未登录路由
  308. * navigator标签现在默认没有转场动画,所以用view
  309. */
  310. navTo(url) {
  311. if (!this.hasLogin) {
  312. // 保存地址
  313. saveUrl();
  314. // 登录拦截
  315. interceptor();
  316. } else {
  317. uni.navigateTo({
  318. url
  319. });
  320. }
  321. },
  322. /**
  323. * 会员卡下拉和回弹
  324. * 1.关闭bounce避免ios端下拉冲突
  325. * 2.由于touchmove事件的缺陷(以前做小程序就遇到,比如20跳到40,h5反而好很多),下拉的时候会有掉帧的感觉
  326. * transition设置0.1秒延迟,让css来过渡这段空窗期
  327. * 3.回弹效果可修改曲线值来调整效果,推荐一个好用的bezier生成工具 http://cubic-bezier.com/
  328. */
  329. coverTouchstart(e) {
  330. // console.log(e);
  331. if (pageAtTop === false) {
  332. return;
  333. }
  334. this.coverTransition = 'transform .1s linear';
  335. startY = e.touches[0].clientY;
  336. },
  337. coverTouchmove(e) {
  338. // console.log(e);
  339. moveY = e.touches[0].clientY;
  340. let moveDistance = moveY - startY;
  341. let maxDowm = this.userMaxDowm;
  342. let Dowm = this.userDowm;
  343. if (moveDistance < 0) {
  344. this.moving = false;
  345. return;
  346. }
  347. this.moving = true;
  348. if (moveDistance >= Dowm && moveDistance < maxDowm) {
  349. moveDistance = Dowm;
  350. }
  351. if (moveDistance > 0 && moveDistance <= Dowm) {
  352. this.coverTransform = `translateY(${moveDistance}px)`;
  353. }
  354. },
  355. coverTouchend() {
  356. if (this.moving === false) {
  357. return;
  358. }
  359. this.moving = false;
  360. this.coverTransition = 'transform 0.3s cubic-bezier(.21,1.93,.53,.64)';
  361. this.coverTransform = 'translateY(0px)';
  362. },
  363. longTime() {
  364. uni.showModal({
  365. title: '续期',
  366. content: '系统将自动扣除本次分红收益的20%用于续期费用',
  367. success(res) {
  368. if (res.confirm) {
  369. repurchase().then(res => {
  370. this.loadBaseData()
  371. uni.showToast({
  372. title: '续期成功',
  373. duration: 2000
  374. });
  375. })
  376. } else {
  377. console.log('else', res)
  378. }
  379. }
  380. })
  381. },
  382. openPopup() {
  383. this.$refs.popup.open()
  384. },
  385. // 客服弹窗 - 复制微信
  386. comfirm(value) {
  387. let content = value; //需要复制的内容
  388. console.log('复制的内容:', content);
  389. // content = typeof content === 'string' ? content : content.toString(); // 复制内容,必须字符串,数字需要转换为字符串
  390. const result = uniCopy({content});
  391. if (result === false) {
  392. uni.showToast({
  393. title: '不支持'
  394. });
  395. } else {
  396. uni.showToast({
  397. title: '复制成功',
  398. icon: 'none'
  399. });
  400. }
  401. this.$refs.popup.close();
  402. },
  403. // 客服弹窗 - 取消
  404. cancel() {
  405. this.$refs.popup.close();
  406. }
  407. }
  408. };
  409. </script>
  410. <style lang="scss">
  411. page {
  412. height: 100%;
  413. }
  414. %flex-center {
  415. display: flex;
  416. flex-direction: column;
  417. justify-content: center;
  418. align-items: center;
  419. }
  420. %section {
  421. display: flex;
  422. justify-content: space-around;
  423. align-content: center;
  424. background: #fff;
  425. border-radius: 10rpx;
  426. }
  427. .container {
  428. height: 100%;
  429. background-color: $page-color-base;
  430. }
  431. .content-box {
  432. height: 100%;
  433. }
  434. .vheigh {
  435. height: var(--status-bar-height);
  436. background-color: $base-color;
  437. }
  438. .user-section {
  439. height: 250rpx;
  440. padding: 15rpx 30rpx 0;
  441. position: relative;
  442. .bg {
  443. position: absolute;
  444. left: 0;
  445. top: 0;
  446. width: 100%;
  447. height: 100%;
  448. background-color: $base-color;
  449. }
  450. }
  451. .vip-card-box {
  452. display: flex;
  453. flex-direction: column;
  454. color: #f7d680;
  455. height: 240rpx;
  456. background: linear-gradient(left, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.8));
  457. border-radius: 16rpx 16rpx 0 0;
  458. overflow: hidden;
  459. position: relative;
  460. padding: 20rpx 24rpx;
  461. .card-bg {
  462. position: absolute;
  463. top: 20rpx;
  464. right: 0;
  465. width: 380rpx;
  466. height: 260rpx;
  467. }
  468. .b-btn {
  469. position: absolute;
  470. right: 20rpx;
  471. top: 16rpx;
  472. width: 132rpx;
  473. height: 40rpx;
  474. text-align: center;
  475. line-height: 40rpx;
  476. font-size: 22rpx;
  477. color: #36343c;
  478. border-radius: 20px;
  479. background: linear-gradient(left, #f9e6af, #ffd465);
  480. z-index: 1;
  481. }
  482. .tit {
  483. font-size: $font-base + 2rpx;
  484. color: #f7d680;
  485. margin-bottom: 28rpx;
  486. .iconfont {
  487. color: #f6e5a3;
  488. margin-right: 16rpx;
  489. }
  490. }
  491. .e-b {
  492. font-size: $font-sm;
  493. color: #d8cba9;
  494. margin-top: 10rpx;
  495. }
  496. }
  497. .cover-container {
  498. background: $page-color-base;
  499. // margin-top: 165rpx;
  500. padding: 0 30rpx;
  501. position: relative;
  502. background: #f5f5f5;
  503. padding-bottom: 20rpx;
  504. .arc {
  505. position: absolute;
  506. left: 0;
  507. top: -34rpx;
  508. width: 100%;
  509. height: 36rpx;
  510. }
  511. }
  512. .tj-sction {
  513. @extend %section;
  514. .tj-item {
  515. @extend %flex-center;
  516. flex-direction: column;
  517. height: 140rpx;
  518. font-size: $font-sm;
  519. color: #75787d;
  520. }
  521. .num {
  522. font-size: $font-lg;
  523. color: $font-color-dark;
  524. margin-bottom: 8rpx;
  525. }
  526. }
  527. .item-box {
  528. border-radius: 10rpx;
  529. background-color: white;
  530. margin-top: 20rpx;
  531. .box-title {
  532. line-height: 1;
  533. padding: 30rpx;
  534. .title {
  535. font-size: $font-lg;
  536. font-weight: bold;
  537. }
  538. .link {
  539. font-size: $font-base - 2rpx;
  540. color: $font-color-light;
  541. }
  542. }
  543. .order-section {
  544. @extend %section;
  545. padding: 28rpx 0;
  546. .order-item {
  547. @extend %flex-center;
  548. width: 120rpx;
  549. height: 120rpx;
  550. border-radius: 10rpx;
  551. font-size: $font-sm;
  552. color: $font-color-dark;
  553. }
  554. .iconfont {
  555. font-size: 48rpx;
  556. margin-bottom: 18rpx;
  557. color: #fa436a;
  558. }
  559. .icon-shouhoutuikuan {
  560. font-size: 44rpx;
  561. }
  562. .icon {
  563. height: 90rpx;
  564. width: 88rpx;
  565. margin-bottom: 18rpx;
  566. background-size: 100%;
  567. background-repeat: no-repeat;
  568. background-position: center;
  569. .icon-img {
  570. width: 100%;
  571. height: 100%;
  572. }
  573. }
  574. }
  575. }
  576. .history-section {
  577. // padding: 30rpx 0 0;
  578. margin-top: 20rpx;
  579. background: #fff;
  580. border-radius: 10rpx;
  581. .sec-header {
  582. display: flex;
  583. align-items: center;
  584. font-size: $font-base;
  585. color: $font-color-dark;
  586. line-height: 40rpx;
  587. margin-left: 30rpx;
  588. padding-top: 30rpx;
  589. .iconfont {
  590. font-size: 44rpx;
  591. color: $color-red;
  592. margin-right: 16rpx;
  593. line-height: 40rpx;
  594. }
  595. }
  596. .h-list {
  597. white-space: nowrap;
  598. padding: 30rpx 30rpx 0;
  599. .h-list-image {
  600. display: inline-block;
  601. width: 160rpx;
  602. height: 160rpx;
  603. margin-right: 20rpx;
  604. border-radius: 10rpx;
  605. }
  606. }
  607. }
  608. .show-time {
  609. width: 690rpx;
  610. margin: 20rpx auto;
  611. border-radius: 20rpx;
  612. padding-left: 20rpx;
  613. background-color: #fff;
  614. line-height: 50rpx;
  615. // padding-right: 20rpx;
  616. font-size: 26rpx;
  617. color: #36343c;
  618. .show-btn {
  619. text-align: center;
  620. border-radius: 20rpx;
  621. width: 100rpx;
  622. color: #fff;
  623. background-color: $base-color;
  624. }
  625. }
  626. .user {
  627. position: relative;
  628. .top-bg {
  629. width: 750rpx;
  630. height: 480rpx;
  631. position: relative;
  632. background: #ecd0a9;
  633. border-radius: 0 0 25rpx 25rpx;
  634. }
  635. .infor {
  636. // height: 126.5rpx;
  637. width: 100%;
  638. // height: 100%;
  639. // background-color: pink;
  640. position: absolute;
  641. top: 15%;
  642. display: flex;
  643. justify-content: space-around; // 水平平均分布
  644. align-items: center; // 垂直居中
  645. // margin-top: 60rpx;
  646. text-align: center;
  647. .infor-left {
  648. width: 100%;
  649. height: 126rpx;
  650. display: flex;
  651. align-items: center;
  652. // padding-left: 23rpx;
  653. flex-direction: column;
  654. image {
  655. width: 126rpx;
  656. height: 126rpx;
  657. border-radius: 50%;
  658. flex-shrink: 0;
  659. background-color: #fff;
  660. }
  661. .info-box {
  662. // margin-left: 21rpx;
  663. // width: 750rpx;
  664. .username {
  665. padding-top: 10rpx;
  666. width: 300rpx;
  667. margin: auto;
  668. text-align: center;
  669. font-size: 34rpx;
  670. font-family: PingFang SC;
  671. font-weight: bold;
  672. color: #54320B;
  673. }
  674. .phone {
  675. padding-top: 10rpx;
  676. font-size: 26rpx;
  677. font-family: PingFang SC;
  678. font-weight: 500;
  679. color: #fff;
  680. font-size: 20rpx;
  681. font-family: PingFang SC;
  682. font-weight: 500;
  683. color: #54320B;
  684. }
  685. }
  686. }
  687. .infor-right {
  688. width: 165rpx;
  689. height: 64rpx;
  690. background: #FFFFFF;
  691. border-radius: 32px 0px 0px 32px;
  692. display: flex;
  693. align-items: center; // 垂直居中
  694. padding-left: 20rpx;
  695. image {
  696. width: 32rpx;
  697. height: 31rpx;
  698. }
  699. .setting {
  700. font-size: 28rpx;
  701. font-family: PingFang SC;
  702. font-weight: 500;
  703. color: #3F7C1F;
  704. padding-left: 10rpx;
  705. }
  706. }
  707. }
  708. // 我的订单
  709. .order-box {
  710. width: 710rpx;
  711. height: 221rpx;
  712. background: #FFFFFF;
  713. box-shadow: 0rpx 0rpx 20rpx 0rpx rgba(50, 50, 52, 0.06);
  714. border-radius: 20rpx;
  715. position: absolute;
  716. top: 400rpx;
  717. // display: flex;
  718. // justify-content: center; // 水平居中
  719. margin-left: 20rpx;
  720. // margin: auto;
  721. .my-order {
  722. height: 73rpx;
  723. width: 100%;
  724. border-bottom: 2rpx solid #F5F5F5;
  725. display: flex;
  726. align-items: center;
  727. justify-content: flex-start;
  728. .order {
  729. font-size: 30rpx;
  730. font-family: PingFang SC;
  731. font-weight: bold;
  732. color: #333333;
  733. margin-left: 36rpx;
  734. margin-right: 520rpx;
  735. }
  736. image {
  737. width: 12rpx;
  738. height: 22rpx;
  739. }
  740. }
  741. .order-section {
  742. display: flex;
  743. align-items: center;
  744. justify-content: space-between;
  745. .order-item {
  746. flex: 1;
  747. display: flex;
  748. flex-direction: column;
  749. align-items: center;
  750. justify-content: center;
  751. margin-top: 30rpx;
  752. image {
  753. width: 42rpx;
  754. height: 42rpx;
  755. }
  756. .text {
  757. margin-top: 20rpx;
  758. font-size: 24rpx;
  759. color: #333333;
  760. }
  761. }
  762. }
  763. }
  764. }
  765. .popup-box {
  766. width: 522rpx;
  767. height: 605rpx;
  768. background-color: #ffffff;
  769. border-radius: 20rpx;
  770. position: relative;
  771. .img {
  772. position: relative;
  773. top: -56rpx;
  774. left: 0;
  775. width: 522rpx;
  776. height: 132rpx;
  777. display: flex;
  778. justify-content: center;
  779. image {
  780. border-radius: 20rpx 20rpx 0 0;
  781. width: 450rpx;
  782. height: 132rpx;
  783. }
  784. }
  785. .mian {
  786. margin-top: -44rpx;
  787. display: flex;
  788. flex-direction: column;
  789. align-items: center;
  790. // padding: 32rpx 32rpx;
  791. background-color: #ffffff;
  792. border-radius: 0 0 20rpx 20rpx;
  793. text-align: center;
  794. .delivery {
  795. font-size: 40rpx;
  796. color: #333333;
  797. display: flex;
  798. align-items: center;
  799. flex-direction: column;
  800. .title {
  801. }
  802. image {
  803. margin-top: 48rpx;
  804. width: 172rpx;
  805. height: 160rpx;
  806. }
  807. }
  808. .nocancel {
  809. font-size: 32rpx;
  810. color: #333333;
  811. margin-top: 14rpx;
  812. }
  813. .comfirm-box {
  814. margin-top: 52rpx;
  815. display: flex;
  816. // margin-bottom: 32rpx;
  817. // justify-content: space-around;
  818. .cancel {
  819. display: flex;
  820. align-items: center;
  821. justify-content: center;
  822. width: 197rpx;
  823. height: 74rpx;
  824. border: 1px solid #dcc786;
  825. border-radius: 38rpx;
  826. font-size: 32rpx;
  827. color: #605128;
  828. }
  829. .comfirm {
  830. margin-left: 32rpx;
  831. display: flex;
  832. align-items: center;
  833. justify-content: center;
  834. width: 197rpx;
  835. height: 74rpx;
  836. background: linear-gradient(-90deg, #d1ba77 0%, #f7e8ad 100%);
  837. border-radius: 38px;
  838. font-size: 32rpx;
  839. color: #605128;
  840. }
  841. }
  842. }
  843. }
  844. .open-m {
  845. width: 710rpx;
  846. height: 90rpx;
  847. margin: auto;
  848. margin-top: 165rpx;
  849. // background: linear-gradient(73deg, #FFFFFF 0%, #FFFBEB 0%, #FFF1DA 0%, #FED591 100%);
  850. border-radius: 20rpx;
  851. image {
  852. width: 710rpx;
  853. height: 90rpx;
  854. }
  855. }
  856. </style>