index.vue 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011
  1. <template>
  2. <view>
  3. <view class="header">
  4. <!-- 用户信息 -->
  5. <view class="userinfo">
  6. <view class="infos" @click="toData" >
  7. <view class="head-portrait" >
  8. <u-avatar :src="userId ? headImg : '../../assets/img/head.png'" size="96"></u-avatar>
  9. </view>
  10. <view class="username" v-if="personInfo&&personInfo.userType==1" >
  11. <view class="name" style="font-size: 56rpx; width: 360rpx;line-height: 100rpx;">
  12. 游客模式
  13. </view>
  14. </view>
  15. <view class="" v-if="personInfo&&personInfo.userType==1" >
  16. <view class="btnuserType1" @click="gotoUrl('pages/login/login')">
  17. 点击注册
  18. </view>
  19. </view>
  20. <view class="username" v-else >
  21. <view class="name" :style="elderStatus ? 'font-size: 28px;' : ''">
  22. {{userId ? nickName : '登录 / 注册'}}
  23. </view>
  24. <view class="change" :style="elderStatus ? 'font-size: 16px;' : ''">
  25. {{userId ? '点击修改个人信息' : '登录后享受更多优惠及服务'}}
  26. </view>
  27. </view>
  28. </view>
  29. <view class="right" v-if="false">
  30. <!-- <i class="ri-notification-2-line">
  31. <text class="unread">20</text>
  32. </i> -->
  33. <i class="ri-settings-line" @click="setUp"></i>
  34. </view>
  35. </view>
  36. <!-- 卡片 -->
  37. <view v-for="(item,i) in businessVipList" :key="i" v-if="!(personInfo&&personInfo.userType==1)"
  38. @click="gotoUrl('pages/user/company-vip?id='+item.platform)"
  39. class="card" >
  40. <view class="card2">
  41. <view class="title">
  42. <text class="img">
  43. <img src="../../assets/img/riFill-building-fill@4x.png" alt="">
  44. </text>
  45. {{item.platformN}}
  46. </view>
  47. <view class="view" >
  48. 查看<text class="iconfont">&#xe600;</text>
  49. </view>
  50. </view>
  51. <view class="cardspan" v-if="item.entAccountEnabled&&item.enterpriseAccount!=null">
  52. 企业余额:{{item.enterpriseAccount.balance?item.enterpriseAccount.balance.toFixed(2):'0.00'}}元
  53. </view>
  54. </view>
  55. <view class="openlogin" v-if="personInfo&&personInfo.userType==1" >
  56. <view class="title">
  57. <text class="img">
  58. <img src="../../assets/img/riFill-user-2-fill.svg" alt="">
  59. </text>51充电联盟会员
  60. <view>
  61. 注册享<span style="color: red;">51充电联盟会员的优惠活动</span>
  62. </view>
  63. </view>
  64. <view class="open-btn" @click="gotoUrl('pages/login/login')">
  65. 立即注册
  66. <text class="iconfont">&#xe632;</text>
  67. </view>
  68. </view>
  69. <!-- 立即开通 -->
  70. <view class="open" v-else-if="userId&&!userCardBool">
  71. <view class="title">
  72. <text class="img">
  73. <img src="../../assets/img/antFill-crown@3x.png" alt="">
  74. </text>充电月卡
  75. </view>
  76. <view class="open-btn" @click="gotoUrl('pages/monthlyCardActivity/monthlyCardBuy')">
  77. 立即开通
  78. <text class="iconfont">&#xe632;</text>
  79. </view>
  80. </view>
  81. <!-- 开通后 -->
  82. <view class="opened" v-if="userId&&userCardBool" @click="gotoUrl('pages/monthlyCardActivity/monthlyCardBuy')">
  83. <view class="title">
  84. <text class="img">
  85. <img src="../../assets/img/antFill-crown@3x.png" alt="">
  86. </text>充电月卡
  87. </view>
  88. <view class="date">
  89. {{userCard.endTime?userCard.endTime.slice(0,10):''}}到期
  90. <text class="iconfont">&#xe600;</text>
  91. </view>
  92. </view>
  93. <!-- 可用余额 -->
  94. <view class="balance" v-if="!(personInfo&&personInfo.userType==1)" >
  95. <view class="item" @click="toBalance">
  96. <view class="num oldTextjp" oldstyle="font-size: 28px;">
  97. {{personAccount.availableAmount != null ? personAccount.availableAmount.toFixed(2) : '0.00'}}<span style="font-size: 16px;">元</span>
  98. </view>
  99. <view class="name" :style="elderStatus ? 'font-size: 16px;' : ''">
  100. 可用余额{{" "}}
  101. <span class="userData-foot-look">查看</span>
  102. </view>
  103. </view>
  104. <view class="item" @click="toMyCoupon">
  105. <view class="num oldTextjp" oldstyle="font-size: 28px;">
  106. {{recordsTotal}}<span style="font-size: 16px;">张</span>
  107. <!-- <text class="new">新券</text> -->
  108. </view>
  109. <view class="name" :style="elderStatus ? 'font-size: 16px;' : ''">
  110. 优惠券{{" "}}
  111. <span class="userData-foot-look">查看</span>
  112. </view>
  113. </view>
  114. <!-- <view class="item">
  115. <view class="num oldTextjp" oldstyle="font-size: 28px;">
  116. 0
  117. </view>
  118. <view class="name" :style="elderStatus ? 'font-size: 16px;' : ''">
  119. 积分{{" "}}
  120. <span class="userData-foot-look">查看</span>
  121. </view>
  122. </view> -->
  123. </view>
  124. </view>
  125. <!-- 优惠 -->
  126. <view class="discounts">
  127. <u-swiper bg-color="#fff" :img-mode="'scaleToFill'" height="160" :list="bannerList" @click="clickBanner"
  128. :name="'picUrl'">
  129. </u-swiper>
  130. </view>
  131. <!-- 菜单 -->
  132. <view class="menu">
  133. <view class="item" @click="chargingRecord">
  134. <view class="item-icon">
  135. <i class="ri-todo-line"></i>
  136. </view>
  137. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  138. 充电记录
  139. </view>
  140. </view>
  141. <view class="item" @click="myAppointment">
  142. <view class="item-icon">
  143. <i class="ri-map-pin-time-line"></i>
  144. </view>
  145. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  146. 我的预约
  147. </view>
  148. </view>
  149. <view class="item" @click="toInvoice">
  150. <view class="item-icon">
  151. <i class="ri-ticket-line"></i>
  152. </view>
  153. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  154. 我的发票
  155. </view>
  156. </view>
  157. <view class="item" @click="gotoUrl('pages/user/contactService')">
  158. <view class="item-icon">
  159. <i class="ri-customer-service-2-line"></i>
  160. </view>
  161. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  162. 联系客服
  163. </view>
  164. </view>
  165. <view class="item" @click="feedback">
  166. <view class="item-icon">
  167. <i class="ri-feedback-line"></i>
  168. </view>
  169. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  170. 意见反馈
  171. </view>
  172. </view>
  173. <view class="item" @click="gotoUrl('pages/user/help')">
  174. <view class="item-icon">
  175. <i class="ri-compass-3-line"></i>
  176. </view>
  177. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  178. 操作指南
  179. </view>
  180. </view>
  181. <view class="item" @click="gotoUrl('pages/user/about')">
  182. <view class="item-icon">
  183. <i class="ri-account-pin-box-line"></i>
  184. </view>
  185. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  186. 关于我们
  187. </view>
  188. </view>
  189. <!-- <view class="item">
  190. <view class="item-icon">
  191. <i class="ri-tools-line"></i>
  192. </view>
  193. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  194. 我要报修
  195. </view>
  196. </view> -->
  197. <view class="item" @click="toFreeInstallation">
  198. <view class="item-icon">
  199. <i class="ri-file-add-line"></i>
  200. </view>
  201. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  202. 免费安桩
  203. </view>
  204. </view>
  205. <view class="item" @click="toJoin">
  206. <view class="item-icon">
  207. <i class="ri-service-line"></i>
  208. </view>
  209. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  210. 我要加盟
  211. </view>
  212. </view>
  213. <view class="item" @click="setUp">
  214. <view class="item-icon">
  215. <u-icon name="setting" size="48" ></u-icon>
  216. </view>
  217. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  218. 设置
  219. </view>
  220. </view>
  221. <!-- <view class="item">
  222. <view class="item-icon">
  223. <i class="ri-shield-user-line"></i>
  224. </view>
  225. <view class="item-name oldTextjp" oldstyle="font-size: 16px;">
  226. 实名认证
  227. </view>
  228. </view> -->
  229. </view>
  230. <Tabbar :current="2" ref="tabbarMain" :elderStatus="elderStatus"></Tabbar>
  231. </view>
  232. </template>
  233. <script>
  234. import * as API from '@/apis/index.js'
  235. import * as userApi from '@/apis/user.js'
  236. import * as loginApi from '@/apis/login.js'
  237. import * as WxJsApi from '@/utils/wxJsApi.js'
  238. import Tabbar from '@/components/Tabbar.vue'
  239. import * as newsApi from '@/apis/news.js'
  240. import {
  241. newDate
  242. } from '@/utils'
  243. export default {
  244. components: {
  245. Tabbar
  246. },
  247. data() {
  248. return {
  249. userCard:null,
  250. recordsTotal: 0,
  251. myCouponList: [],
  252. elderStatus: false,
  253. personAccount: {},
  254. userId: '',
  255. headImg: '',
  256. nickName: '',
  257. userPhone: '',
  258. personInfo:{},
  259. show: false,
  260. title: '联系客服',
  261. content: '400-8899-619',
  262. confirmText: '拨打电话',
  263. bannerList:[],
  264. businessVipList:[],
  265. background:{
  266. background: 'none'
  267. },
  268. }
  269. },
  270. onShow() {
  271. this.personInfo=this.carhelp.getPersonInfo()
  272. if(this.carhelp.getPersonInfo()) {
  273. this.userId = this.carhelp.getPersonInfo().id;
  274. this.getCarPersonAccount();
  275. this.getUserInfo();
  276. this.getCouponList();
  277. }
  278. if(this.$refs.tabbarMain){
  279. this.$refs.tabbarMain.setcount(2);
  280. }
  281. if(this.carhelp.get("getElderModeClass") == "长辈模式") {
  282. this.elderStatus = true;
  283. } else {
  284. this.elderStatus = false;
  285. }
  286. },
  287. computed:{
  288. userCardBool(){
  289. if(this.userCard){
  290. var date=new Date().getTime()
  291. var reg=new RegExp('-','gi')
  292. var str=this.userCard.endTime;
  293. //console.log(str.replace(reg,'/'))
  294. var date2=newDate(str).getTime();
  295. if(date<date2){
  296. return true;
  297. }
  298. }
  299. return false
  300. }
  301. },
  302. onReady() {
  303. WxJsApi.getWxConfig(['getLocation', 'addEventListener', 'scanQRCode']).then((res) => {
  304. // //(res)
  305. }).catch(error => {
  306. //(error)
  307. })
  308. var consumerPhone=this.carhelp.getConfig().consumerPhone
  309. // img="https://yktwechat.xiaoxinda.com/config/xxd2021.jpg"
  310. if(consumerPhone){
  311. this.content=consumerPhone
  312. }
  313. this.getBannerInfo("userinfo")
  314. },
  315. methods: {
  316. personalCenter(){
  317. API.personalCenter().then((res2) => {
  318. var entRegList=res2.data.entRegList;
  319. for(var i in this.businessVipList){
  320. var item1=this.businessVipList[i]
  321. for(var j in entRegList){
  322. var item2=entRegList[j].vipUser;
  323. if(item1.id==item2.id){
  324. item1.enterpriseAccount=entRegList[j].enterpriseAccount
  325. }
  326. }
  327. }
  328. this.$forceUpdate()
  329. }).catch(error => {
  330. uni.showToast({
  331. title: error
  332. })
  333. })
  334. },
  335. clickBanner(index){
  336. var mod= this.bannerList[index]
  337. if(mod.linkUrl.indexOf('http')==0){
  338. window.location=mod.linkUrl;
  339. }
  340. else if(mod.linkUrl.indexOf('#/')==0){
  341. if(mod.linkUrl.indexOf("?")==-1){
  342. mod.linkUrl+='?';
  343. }
  344. //window.location=mod.linkUrl;
  345. var url=mod.linkUrl.split("#")[1]
  346. //window.location = mod.clickUrl;
  347. uni.navigateTo({
  348. url: url
  349. })
  350. }
  351. else if(mod.linkUrl=='#'||mod.linkUrl==''){
  352. }
  353. else{
  354. uni.navigateTo({
  355. url:mod.linkUrl
  356. })
  357. }
  358. },
  359. getBannerInfo(code){
  360. uni.showLoading({
  361. title: "加载中",
  362. mask: true,
  363. })
  364. newsApi.getBannerInfo(code).then((res) => {
  365. uni.hideLoading();
  366. this.bannerList =res.data;
  367. // document.getElementsByClassName("uni-swiper-wrapper")[0].parentNode.style="background-color: rgb(255, 255, 255); height: 300px;"
  368. }).catch(error => {
  369. uni.showToast({
  370. title: error,icon: "none"
  371. })
  372. })
  373. },
  374. getCouponList() {
  375. uni.showLoading({
  376. title: "加载中",
  377. mask: true,
  378. })
  379. userApi.couponList({
  380. status: '0'
  381. }).then((res) => {
  382. uni.hideLoading();
  383. this.myCouponList = res.data.data;
  384. this.recordsTotal = res.data.recordsTotal;
  385. }).catch(error => {
  386. uni.showToast({
  387. title: error,
  388. icon: "none"
  389. })
  390. })
  391. },
  392. //微信扫二维码
  393. getScanCode() {
  394. if (this.userId) {
  395. WxJsApi.scanQRCode(1).then(res => {
  396. if(res) {
  397. API.scanCode(res).then((response) => {
  398. }).catch(error => {
  399. uni.showToast({
  400. title: error,
  401. icon: "none"
  402. })
  403. })
  404. }
  405. }).catch(error => {
  406. })
  407. } else {
  408. uni.navigateTo({
  409. url: '/pages/login/login'
  410. })
  411. }
  412. },
  413. fastRecharge() {
  414. if (this.userId) {
  415. uni.navigateTo({
  416. url: '/pages/user/finance/recharge'
  417. })
  418. } else {
  419. uni.navigateTo({
  420. url: '/pages/login/login'
  421. })
  422. }
  423. },
  424. toInvoice(){
  425. if (this.userId) {
  426. uni.navigateTo({
  427. url: '/pages/MyInvoice/invoiceManagement'
  428. })
  429. } else {
  430. uni.navigateTo({
  431. url: '/pages/login/login'
  432. })
  433. }
  434. },
  435. chargingRecord() {
  436. if (this.userId) {
  437. uni.navigateTo({
  438. url: '/pages/record/index'
  439. })
  440. } else {
  441. uni.navigateTo({
  442. url: '/pages/login/login'
  443. })
  444. }
  445. },
  446. toSearchPile() {
  447. uni.navigateTo({
  448. url: '/pages/searchPile/searchPile'
  449. })
  450. },
  451. getUserInfo() {
  452. uni.showLoading({
  453. title: "加载中",
  454. mask: true,
  455. })
  456. loginApi.findByOpenId({
  457. openId: this.carhelp.getOpenId()
  458. }).then((res) => {
  459. uni.hideLoading();
  460. this.businessVipList=res.data.businessVipList;
  461. if(this.businessVipList.length){
  462. var b=false;
  463. for(var i in this.businessVipList){
  464. var item=this.businessVipList[i];
  465. if(item.entAccountEnabled){
  466. b=true
  467. }
  468. }
  469. if(b){
  470. this.personalCenter()
  471. }
  472. }
  473. this.headImg = res.data.regUser.headImg;
  474. this.nickName = res.data.regUser.nickName;
  475. this.userCard=res.data.userCard;
  476. var phone = res.data.regUser.phone;
  477. var phone1 = phone.slice(0,3);
  478. var phone2 = phone.slice(-4);
  479. this.userPhone = phone1 + '****' + phone2;
  480. if (res.code == 200&&res.result) {
  481. var token = res ? res.data.token : '';
  482. this.personInfo=res.data.regUser
  483. this.carhelp.setPersonInfo(res.data.regUser );
  484. this.carhelp.setToken(token);
  485. this.carhelp.setPersonInfoPlus(res.data);
  486. console.log("setPersonInfoPlus")
  487. }
  488. }).catch(error => {
  489. uni.showToast({
  490. title: error,
  491. icon: "none"
  492. })
  493. })
  494. },
  495. toData() {
  496. if(this.personInfo&&this.personInfo.userType==1){
  497. uni.navigateTo({
  498. url: '/pages/login/login'
  499. })
  500. }else if(this.userId) {
  501. uni.navigateTo({
  502. url: '/pages/user/dataSet'
  503. })
  504. } else {
  505. uni.navigateTo({
  506. url: '/pages/login/login'
  507. })
  508. }
  509. },
  510. toBalance() {
  511. if(this.userId) {
  512. uni.navigateTo({
  513. url: '/pages/user/finance/balance'
  514. })
  515. } else {
  516. uni.navigateTo({
  517. url: '/pages/login/login'
  518. })
  519. }
  520. },
  521. toMyCoupon() {
  522. if(this.userId) {
  523. uni.navigateTo({
  524. url: '/pages/user/coupon/myCoupon'
  525. })
  526. } else {
  527. uni.navigateTo({
  528. url: '/pages/login/login'
  529. })
  530. }
  531. },
  532. toRecharge() {
  533. if(this.userId) {
  534. uni.navigateTo({
  535. url: '/pages/user/finance/recharge'
  536. })
  537. } else {
  538. uni.navigateTo({
  539. url: '/pages/login/login'
  540. })
  541. }
  542. },
  543. carManage() {
  544. if(this.userId) {
  545. } else {
  546. uni.navigateTo({
  547. url: '/pages/login/login'
  548. })
  549. }
  550. },
  551. myAppointment() {
  552. if(this.userId) {
  553. uni.navigateTo({
  554. url: '/pages/user/myReservation/myReservation'
  555. })
  556. } else {
  557. uni.navigateTo({
  558. url: '/pages/login/login'
  559. })
  560. }
  561. },
  562. toFreeInstallation() {
  563. if(this.userId) {
  564. uni.navigateTo({
  565. url: '/pages/user/freeInstallment?isback=1'
  566. })
  567. } else {
  568. uni.navigateTo({
  569. url: '/pages/login/login'
  570. })
  571. }
  572. },
  573. toJoin() {
  574. if(this.userId) {
  575. uni.navigateTo({
  576. url: '/pages/user/toJoin?isback=1'
  577. })
  578. } else {
  579. uni.navigateTo({
  580. url: '/pages/login/login'
  581. })
  582. }
  583. },
  584. feedback() {
  585. if(this.userId) {
  586. uni.navigateTo({
  587. url: '/pages/user/message'
  588. })
  589. } else {
  590. uni.navigateTo({
  591. url: '/pages/login/login'
  592. })
  593. }
  594. },
  595. setUp() {
  596. if(this.userId) {
  597. uni.navigateTo({
  598. url: '/pages/user/setting'
  599. })
  600. } else {
  601. uni.navigateTo({
  602. url: '/pages/login/login'
  603. })
  604. }
  605. },
  606. openModal() {
  607. this.show = true;
  608. },
  609. confirmPhone(){
  610. this.show = false;
  611. uni.makePhoneCall({
  612. phoneNumber:this.content //仅为示例
  613. });
  614. },
  615. getCarPersonAccount() {
  616. uni.showLoading({
  617. title: "加载中",
  618. mask: true,
  619. })
  620. userApi.carPersonAccount().then((res) => {
  621. uni.hideLoading();
  622. this.personAccount = res.data;
  623. }).catch(error => {
  624. uni.showToast({
  625. title: error,
  626. icon: "none"
  627. })
  628. })
  629. }
  630. }
  631. }
  632. </script>
  633. <style>
  634. page{
  635. background-size: 100%;
  636. }
  637. </style>
  638. <style lang="scss" scoped>
  639. .btnuserType1{
  640. width: 160rpx;
  641. height: 64rpx;
  642. line-height: 60rpx;
  643. border-radius: 50px;
  644. background-color: rgba(0, 185, 98, 1);
  645. color: #fff;
  646. font-size: 28rpx;
  647. text-align: center;
  648. font-family: -apple-system;
  649. margin-top: 20rpx;
  650. }
  651. .header {
  652. background: linear-gradient(#D6EEDC, #F6F8F8);
  653. .userinfo {
  654. display: flex;
  655. justify-content: space-between;
  656. padding: 40rpx 32rpx 32rpx 32rpx;
  657. .infos {
  658. display: flex;
  659. }
  660. .head-portrait {
  661. width: 48px;
  662. height: 48px;
  663. img {
  664. width: 100%;
  665. height: 100%;
  666. }
  667. }
  668. .username {
  669. margin-left: 8px;
  670. .name {
  671. color: rgba(51, 51, 51, 100);
  672. font-size: 20px;
  673. line-height: 24px;
  674. }
  675. .change {
  676. color: rgba(166, 180, 173, 100);
  677. line-height: 14px;
  678. margin-top: 8px;
  679. }
  680. }
  681. .right {
  682. font-size: 24px;
  683. .ri-notification-2-line {
  684. position: relative;
  685. .unread {
  686. width: 20px;
  687. line-height: 14px;
  688. border-radius: 24px;
  689. background-color: rgba(255, 94, 0, 100);
  690. color: rgba(255, 255, 255, 100);
  691. font-size: 9px;
  692. text-align: center;
  693. position: absolute;
  694. bottom: 14px;
  695. left: 14px;
  696. }
  697. }
  698. .ri-settings-line {
  699. margin-left: 16px;
  700. }
  701. }
  702. }
  703. // 卡片
  704. .card {
  705. background: linear-gradient(#405473, #536D96);
  706. border-radius: 8px;
  707. width: 91.4%;
  708. margin: 8rpx auto 0;
  709. padding: 24rpx 24rpx;
  710. .cardspan{
  711. margin-left: 48rpx;
  712. font-size: 24rpx;
  713. line-height:40rpx;
  714. color: rgba(255, 255, 255, 100);
  715. }
  716. .card2 {
  717. display: flex;
  718. justify-content: space-between;
  719. .title {
  720. line-height: 72rpx;
  721. color: rgba(255, 255, 255, 100);
  722. font-size: 36rpx;
  723. .img {
  724. display: inline-block;
  725. // width: 48rpx;
  726. // height: 48rpx;
  727. vertical-align: middle;
  728. margin-right: 8rpx;
  729. img {
  730. width: 40rpx;
  731. height: 40rpx;
  732. }
  733. }
  734. }
  735. .view {
  736. line-height: 72rpx;
  737. color: rgba(208, 214, 226, 100);
  738. font-size: 36rpx;
  739. }
  740. .view2 {
  741. line-height: 144rpx !important;
  742. }
  743. }
  744. }
  745. // 立即开通
  746. .openlogin {
  747. border: 1px solid rgba(187, 226, 189, 1);
  748. background: #F4FFF3 ;
  749. width: 91.4%;
  750. padding: 30rpx 24rpx 24rpx 24rpx;
  751. margin: 8rpx auto 0;
  752. margin-bottom: 10px;
  753. display: flex;
  754. justify-content: space-between;
  755. border-radius: 8px;
  756. .title {
  757. line-height: 72rpx;
  758. color: #101010;
  759. font-size: 36rpx;
  760. .img {
  761. display: inline-block;
  762. // width: 48rpx;
  763. // height: 48rpx;
  764. vertical-align: middle;
  765. margin-right: 8rpx;
  766. img {
  767. width: 40rpx;
  768. height: 40rpx;
  769. }
  770. }
  771. }
  772. .open-btn {
  773. margin: auto;
  774. padding-left: 12px;
  775. padding-right: 4px;
  776. line-height: 28px;
  777. height: 32px;
  778. // text-align: center;
  779. color: #ffffff;
  780. border-radius: 10px;
  781. background: linear-gradient(to right,#34BC58 , #00A39A );
  782. .iconfont {
  783. margin-left: 0px;
  784. }
  785. }
  786. }
  787. // 立即开通
  788. .open,.opened {
  789. background: linear-gradient(#4A4C62, #2C3145);
  790. width: 91.4%;
  791. padding: 30rpx 24rpx 24rpx 24rpx;
  792. margin: 8rpx auto 0;
  793. display: flex;
  794. justify-content: space-between;
  795. border-radius: 8px;
  796. .title {
  797. line-height: 72rpx;
  798. color: #E1C082;
  799. font-size: 36rpx;
  800. .img {
  801. display: inline-block;
  802. vertical-align: middle;
  803. margin-right: 8rpx;
  804. img {
  805. width: 40rpx;
  806. height: 40rpx;
  807. }
  808. }
  809. }
  810. .open-btn {
  811. padding-left: 28rpx;
  812. padding-right: 8rpx;
  813. line-height: 76rpx;
  814. // text-align: center;
  815. font-size: 32rpx;
  816. border-radius: 100rpx;
  817. background: linear-gradient(to right,#F0E1C6, #ECC194);
  818. .iconfont {
  819. margin-left: 0px;
  820. }
  821. }
  822. .date{
  823. color: #d1b37a;
  824. line-height: 24px;
  825. font-size: 32rpx;
  826. .iconfont{
  827. color: #867668
  828. }
  829. }
  830. }
  831. // 余额
  832. .balance {
  833. background-color: #fff;
  834. width: 91.4%;
  835. margin: 12px auto;
  836. padding: 16px 29px;
  837. display: flex;
  838. // justify-content: space-between;
  839. justify-content: space-around;
  840. border-radius: 8px;
  841. .item {
  842. text-align: center;
  843. .num {
  844. line-height: 28px;
  845. color: rgba(51, 51, 51, 100);
  846. font-size: 24px;
  847. position: relative;
  848. .new {
  849. width: 40px;
  850. line-height: 20px;
  851. border-radius: 24px 24px 24px 0px;
  852. background-color: rgba(255, 94, 0, 100);
  853. color: rgba(255, 255, 255, 100);
  854. font-size: 12px;
  855. text-align: center;
  856. position: absolute;
  857. bottom: 20px;
  858. left: 36px;
  859. }
  860. }
  861. .name {
  862. height: 16px;
  863. color: rgba(134, 134, 134, 100);
  864. font-size: 14px;
  865. margin-top: 4px;
  866. .userData-foot-look {
  867. color: #00B962;
  868. }
  869. }
  870. }
  871. }
  872. }
  873. // 优惠
  874. .discounts {
  875. width: 91.4%;
  876. height: 80px;
  877. margin: 0 auto;
  878. border-radius: 8px;
  879. overflow: hidden;
  880. img {
  881. width: 100%;
  882. height: 80px;
  883. }
  884. }
  885. // 菜单
  886. .menu {
  887. background-color: #fff;
  888. width: 91.4%;
  889. margin: 12px auto 0;
  890. padding: 0 12px 9px 12px;
  891. border-radius: 8px;
  892. display: flex;
  893. flex-wrap: wrap;
  894. @media screen and (max-width: 375px) {
  895. .item {
  896. width: 33% !important;
  897. }
  898. }
  899. .item {
  900. width: 25%;
  901. margin-top: 20px;
  902. margin-bottom: 11px;
  903. display: flex;
  904. flex-direction: column;
  905. align-items: center;
  906. color: rgba(119, 119, 119, 100);
  907. i {
  908. font-size: 24px
  909. }
  910. .item-name {
  911. font-size: 14px;
  912. margin-top: 8px;
  913. }
  914. }
  915. }
  916. </style>