index.vue 58 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301
  1. <template>
  2. <!-- 个人中心模块 -->
  3. <view class="new-users copy-data" :style="{height:pageHeight}">
  4. <!-- 自定义顶部背景颜色 -->
  5. <view class="top" :style="colorStyle">
  6. <!-- #ifdef MP || APP-PLUS -->
  7. <view class="sys-head">
  8. <view class="sys-bar" :style="{height:sysHeight}"></view>
  9. <!-- #ifdef MP -->
  10. <view class="sys-title" :style="member_style==3?'color:#333':''">个人中心</view>
  11. <!-- #endif -->
  12. <view class="bg" :style="member_style==3?'background:#f5f5f5':''"></view>
  13. </view>
  14. <!-- #endif -->
  15. </view>
  16. <!-- 自定义顶部背景颜色 -->
  17. <view class="mid style-add" :style="colorStyle">
  18. <scroll-view scroll-y="true" class="height-add">
  19. <view class="head">
  20. <view class="user-card" :class="member_style==3?'unBg':''"
  21. :style="{backgroundImage:'url('+imgHost+'/statics/images/user01.png'+')'}">
  22. <view class="bg"></view>
  23. <!-- 个人资料展示 -->
  24. <view class="user-info">
  25. <view>
  26. <!-- 公众号未授权时显示 -->
  27. <!-- #ifdef H5 -->
  28. <button class="bntImg" v-if="userInfo.is_complete == 0 && isWeixin && !isLogin"
  29. @click="getWechatuserinfo">
  30. <image class="avatar" src='/static/images/f.png'></image>
  31. <view class="avatarName">获取头像</view>
  32. </button>
  33. <!-- #endif -->
  34. <!-- #ifdef MP -->
  35. <!-- <button class="bntImg" v-if="userInfo.is_complete == 0" @tap="getUserProfile">
  36. <image class="avatar" src='/static/images/f.png'></image>
  37. <view class="avatarName">获取头像</view>
  38. </button> -->
  39. <!-- #endif -->
  40. <!-- #ifndef APP-PLUS -->
  41. <view class="avatar-box" :class="{on:userInfo.is_money_level}">
  42. <image class="avatar" :src='userInfo.avatar' v-if="userInfo.avatar"
  43. @click="goEdit()">
  44. </image>
  45. <image v-else class="avatar" src="/static/images/f.png" mode="" @click="goEdit()">
  46. </image>
  47. <view class="headwear" v-if="userInfo.is_money_level && stu">
  48. <image src="/static/images/headwear.png"></image>
  49. </view>
  50. </view>
  51. <!-- #endif -->
  52. <!-- #ifdef APP-PLUS -->
  53. <view class="avatar-box" :class="{on:userInfo.is_money_level}">
  54. <image class="avatar" :src='userInfo.avatar' v-if="userInfo.avatar"
  55. @click="goEdit()">
  56. </image>
  57. <image v-else class="avatar" src="/static/images/f.png" mode="" @click="goEdit()">
  58. </image>
  59. <view class="headwear" v-if="userInfo.is_money_level && stu">
  60. <image src="/static/images/headwear.png"></image>
  61. </view>
  62. </view>
  63. <!-- #endif -->
  64. </view>
  65. <view class="info">
  66. <view class="name display-add" v-if="!userInfo.uid" @click="openAuto">
  67. 请点击授权
  68. </view>
  69. <view class="name" v-if="userInfo.uid">
  70. <view class="nickname line1">{{userInfo.nickname}}</view>
  71. <image class="live" :src="userInfo.vip_icon" v-if="parseInt(userInfo.vip_id)">
  72. </image>
  73. <view class="vip" v-if="userInfo.is_money_level> 0 && stu">
  74. <image src="/static/images/svip.png"></image>
  75. </view>
  76. </view>
  77. <view class="num" v-if="userInfo.phone">
  78. <view class="num-txt">{{userInfo.phone}}</view>
  79. <!-- <view class="icon">
  80. <image src="/static/images/edit.png" mode=""></image>
  81. </view> -->
  82. </view>
  83. <view class="phone" v-if="!userInfo.phone && isLogin && userInfo.uid" @tap="bindPhone">
  84. 绑定手机号</view>
  85. </view>
  86. <view v-if="isLogin" class="qrCode message iconfont icon-erweima-xingerenzhongxin"
  87. @click="tapQrCode">
  88. </view>
  89. <view class="message">
  90. <view @click="intoPage('/pages/users/user_set/index')">
  91. <view class="iconfont icon-shezhi"></view>
  92. </view>
  93. </view>
  94. <view class="message">
  95. <view @click="intoPage('/pages/users/message_center/index')">
  96. <!-- <view v-if="userInfo.service_num" class="num">
  97. {{userInfo.service_num >= 100 ? '99+' : userInfo.service_num}}
  98. </view> -->
  99. <uni-badge class="uni-badge-left-margin"
  100. :text="userInfo.service_num >= 100 ? '99+' : userInfo.service_num"
  101. absolute="rightTop">
  102. <view class="iconfont icon-s-kefu"></view>
  103. </uni-badge>
  104. </view>
  105. </view>
  106. <!-- #ifdef MP -->
  107. <!-- <view class="setting" @click="Setting"><text class="iconfont icon-shezhi"></text></view> -->
  108. <!-- #endif -->
  109. </view>
  110. <view class="achsac">
  111. </view>
  112. <!-- <view class="sign" @click="goSignIn">签到</view> -->
  113. <!-- 会员权益 -->
  114. <view class="cardVipA acea-row row-between-wrapper" v-if="member_style==1 && stu && vip_type==2"
  115. :style="{backgroundImage:'url('+imgHost+'/statics/images/member.png'+')'}">
  116. <view class="left-box">
  117. <view v-if="vipStatus == 1" class="small">永久</view>
  118. <view v-else-if="vipStatus == 3" class="small">会员到期
  119. {{ userInfo.overdue_time | dateFormat }}
  120. </view>
  121. <view v-else-if="vipStatus == -1" class="small">已过期</view>
  122. <view v-else-if="vipStatus == 2" class="small">未开通会员</view>
  123. </view>
  124. <view class="acea-row row-middle">
  125. <navigator v-if="vipStatus == 1" url="/pages/annex/vip_paid/index" hover-class="none"
  126. class="btn">查看会员权益
  127. </navigator>
  128. <navigator v-else url="/pages/annex/vip_paid/index" hover-class="none" class="btn">
  129. {{ userInfo.overdue_time ? '立即续费' : '立即激活' }}
  130. </navigator>
  131. <text class="iconfont icon-xiangyou"></text>
  132. </view>
  133. </view>
  134. <view class="cardVipB acea-row row-between" v-if="member_style==3 && stu && vip_type==2">
  135. <view class="left-box acea-row">
  136. <view class="pictrue">
  137. <image src="../../static/images/member01.png"></image>
  138. </view>
  139. <view v-if="vipStatus == 1" class="small">永久</view>
  140. <view v-else-if="vipStatus == 3" class="small">会员到期
  141. {{ userInfo.overdue_time | dateFormat }}
  142. </view>
  143. <view v-else-if="vipStatus == -1" class="small">已过期</view>
  144. <view v-else-if="vipStatus == 2" class="small">未开通会员</view>
  145. </view>
  146. <view class="acea-row">
  147. <navigator v-if="vipStatus == 1" url="/pages/annex/vip_paid/index" hover-class="none"
  148. class="btn">
  149. 会员可享多项权益</navigator>
  150. <navigator v-else url="/pages/annex/vip_paid/index" hover-class="none" class="btn">
  151. {{ userInfo.overdue_time ? '立即续费' : '立即激活' }}
  152. </navigator>
  153. <text class="iconfont icon-xiangyou btn"></text>
  154. </view>
  155. </view>
  156. <view class="cardVipA acea-row row-between-wrapper"
  157. :style="{backgroundImage:'url('+imgHost+'/statics/images/grade.png'+')'}"
  158. v-if="member_style==1 && memberStatus && vip_type==1">
  159. <view class="left-box on">
  160. <!-- <view class="small">{{userInfo.level_status==1?userInfo.vip_name:'激活会员卡 解锁更多权益'}}</view> -->
  161. <view class="small">{{userInfo.level_status==1?'':'激活会员卡 解锁更多权益'}}</view>
  162. </view>
  163. <view class="acea-row row-middle">
  164. <!-- 去激活 -->
  165. <navigator
  166. :url="userInfo.level_status==1?'/pages/annex/vip_grade/index':'/pages/annex/vip_grade_active/index'"
  167. hover-class="none" class="btn on">{{userInfo.level_status==1?'查看会员卡':'去激活'}}
  168. </navigator>
  169. <text class="iconfont icon-xiangyou on"></text>
  170. </view>
  171. </view>
  172. <view class="cardVipB acea-row row-between on"
  173. :style="{backgroundImage:'url('+imgHost+'/statics/images/grade01.png'+')'}"
  174. v-if="member_style==3 && memberStatus && vip_type==1">
  175. <!-- <view class="small">{{userInfo.level_status==1?userInfo.vip_name:'激活会员卡 解锁更多权益'}}</view> -->
  176. <view class="small">{{userInfo.level_status==1?'':'激活会员卡 解锁更多权益'}}</view>
  177. <view class="acea-row">
  178. <navigator
  179. :url="userInfo.level_status==1?'/pages/annex/vip_grade/index':'/pages/annex/vip_grade_active/index'"
  180. hover-class="none" class="btn on">{{userInfo.level_status==1?'查看会员卡':'去激活'}}
  181. </navigator>
  182. <text class="iconfont icon-xiangyou"></text>
  183. </view>
  184. </view>
  185. </view>
  186. <view class="card-vip" v-if="member_style==2 && stu && vip_type==2">
  187. <view class="left-box">
  188. <!-- <view class="big">会员可享多项权益</view> -->
  189. <view v-if="vipStatus == 1" class="small">永久</view>
  190. <view v-else-if="vipStatus == 3" class="small">会员到期
  191. {{ userInfo.overdue_time | dateFormat }}
  192. </view>
  193. <view v-else-if="vipStatus == -1" class="small">已过期</view>
  194. <view v-else-if="vipStatus == 2" class="small">未开通会员</view>
  195. </view>
  196. <view class="acea-row">
  197. <navigator v-if="vipStatus == 1" url="/pages/annex/vip_paid/index" hover-class="none"
  198. class="btn">查看会员权益
  199. </navigator>
  200. <navigator v-else url="/pages/annex/vip_paid/index" hover-class="none" class="btn">
  201. {{ userInfo.overdue_time ? '立即续费' : '立即激活' }}
  202. </navigator>
  203. <text class="iconfont icon-xiangyou"></text>
  204. </view>
  205. </view>
  206. <view class="card-vip on" v-if="member_style==2 && memberStatus && vip_type==1"
  207. :style="{backgroundImage:'url('+imgHost+'/statics/images/grade01.png'+')'}">
  208. <view class="left-box">
  209. <!-- <view class="small">{{userInfo.level_status==1?userInfo.vip_name:'激活会员卡 解锁更多权益'}}</view> -->
  210. <view class="small">{{userInfo.level_status==1?'':'激活会员卡 解锁更多权益'}}</view>
  211. </view>
  212. <view class="acea-row">
  213. <navigator
  214. :url="userInfo.level_status==1?'/pages/annex/vip_grade/index':'/pages/annex/vip_grade_active/index'"
  215. hover-class="none" class="btn">{{userInfo.level_status==1?'查看会员卡':'去激活'}}</navigator>
  216. <text class="iconfont icon-xiangyou"></text>
  217. </view>
  218. </view>
  219. <view class="flex-item-box">
  220. <view class="flex-item">
  221. <view class="txt">参考值</view>
  222. <text class="num">{{userInfo.integral_price || 0}}</text>
  223. </view>
  224. </view>
  225. <view class="num-wrapper"
  226. :class="[member_style==3?'unNum-wrapper':member_style==2?'Tnum-wrapper':'',((vip_type==2 && stu) || (vip_type==1 && memberStatus))?'':'height']"
  227. v-if="userInfo.hidden_integral=='1'">
  228. <view class="num-item">
  229. <text class="num">{{userInfo.sum_integral || 0}}</text>
  230. <view class="txt">总积分</view>
  231. </view>
  232. <view class="num-item">
  233. <text class="num">{{userInfo.award_lack || 0}}</text>
  234. <view class="txt">总资金</view>
  235. </view>
  236. </view>
  237. <view class="num-wrapper"
  238. :class="[member_style==3?'unNum-wrapper':member_style==2?'Tnum-wrapper':'',((vip_type==2 && stu) || (vip_type==1 && memberStatus))?'':'height']"
  239. v-if="userInfo.uid">
  240. <view class="num-item" v-show="userInfo.balance_func_status"
  241. @click="goMenuPage('/pages/users/user_money/index')">
  242. <text class="num">{{userInfo.now_money || 0}}</text>
  243. <view class="txt">余额</view>
  244. </view>
  245. <view class="num-item" @click="goMenuPage('/pages/users/user_payment/energy')">
  246. <text class="num">{{userInfo.energy || 0}}</text>
  247. <view class="txt">能量值</view>
  248. </view>
  249. <view class="num-item" @click="goMenuPage('/pages/users/user_integral/integral')">
  250. <text class="num">{{userInfo.action_integral || 0}}</text>
  251. <view class="txt">贡献分</view>
  252. </view>
  253. <view class="num-item" @click="goMenuPage('/pages/users/user_integral/integral')">
  254. <text class="num">{{userInfo.static_integral || 0}}</text>
  255. <view class="txt">消费分</view>
  256. </view>
  257. </view>
  258. <!-- 新人礼物 -->
  259. <view class="num-wrapper on" v-if="!userInfo.uid">
  260. <image :src="giftPic" mode="" class="img"></image>
  261. <view class="text">
  262. 登录即获得<text class="gift">新人大礼包</text>
  263. </view>
  264. <view class="btn-login" @click="openAuto">去登录</view>
  265. </view>
  266. <!-- 新人专享 -->
  267. <view class="newcomersCon" :class="newcomer_style==1?'':'on'"
  268. v-if="newList.length && newcomer_status==1">
  269. <view class="newcomers"
  270. :style="{backgroundImage:'url('+ (newcomer_style==1?imgHost+'/statics/images/new-bg.png':newBg) +')'}">
  271. <view class="title">
  272. <view class="tl">
  273. 新人专享
  274. </view>
  275. <view class="tr acea-row row-center-wrapper" @click="goNewcomers">
  276. 更多 <text class="iconfont icon-xiangyou"></text>
  277. </view>
  278. </view>
  279. <scroll-view scroll-x="true" class="scroll">
  280. <view class="scroll-item" v-for="(item,index) in newList" :key="index"
  281. @click="goDetail(item)">
  282. <view class="pictrue">
  283. <image :src='item.image'></image>
  284. <view class="label">新人价</view>
  285. </view>
  286. <view class="money">¥{{item.price}}</view>
  287. </view>
  288. </scroll-view>
  289. </view>
  290. </view>
  291. <!-- 订单中心 -->
  292. <view class="order-wrapper">
  293. <view class="order-hd flex">
  294. <view class="left">订单中心</view>
  295. <view class="right flex" @click="intoPage('/pages/goods/order_list/index')">
  296. 查看全部
  297. <text class="iconfont icon-xiangyou"></text>
  298. </view>
  299. </view>
  300. <view class="order-bd">
  301. <block v-for="(item,index) in orderMenu" :key="index">
  302. <view class="order-item" @click="intoPage(item.url)">
  303. <view class="pic">
  304. <!-- <image :src="item.img" mode=""></image> -->
  305. <text class="iconfont" :class="item.img"></text>
  306. <uni-badge class="uni-badge-left-margin" v-if="item.num>0" :text="item.num"
  307. absolute="rightTop"></uni-badge>
  308. <!-- <text class="order-status-num" v-if="item.num > 0">{{ item.num }}</text> -->
  309. </view>
  310. <view class="txt">{{item.title}}</view>
  311. </view>
  312. </block>
  313. </view>
  314. </view>
  315. </view>
  316. <!-- 轮播 -->
  317. <view class="slider-wrapper" v-if="imgUrls.length>0 && my_banner_status">
  318. <swiper indicator-dots="true" :autoplay="autoplay" :circular="circular" :interval="interval"
  319. :duration="duration" indicator-color="rgba(255,255,255,0.6)" indicator-active-color="#fff">
  320. <block v-for="(item,index) in imgUrls" :key="index">
  321. <swiper-item>
  322. <navigator @click="goMenuPage(item.url)"
  323. class='slide-navigator acea-row row-between-wrapper' hover-class='none'>
  324. <image :src="item.pic" class="slide-image"></image>
  325. </navigator>
  326. </swiper-item>
  327. </block>
  328. </swiper>
  329. </view>
  330. <!-- 会员菜单二 -->
  331. <view class="menus-list" v-if="menu_status == 2 && MyMenus.length">
  332. <view class="title">我的服务</view>
  333. <!-- #ifdef APP-PLUS || H5 -->
  334. <block v-for="(item,index) in MyMenus" :key="index">
  335. <view class="item acea-row row-between-wrapper"
  336. v-if="item.url!='#' && item.url!='/pages/service/index'"
  337. @click="goMenuPage(item.url, item.name)">
  338. <image :src="item.pic"></image>
  339. <view class="text acea-row row-between-wrapper">
  340. <view>{{item.name}}</view>
  341. <view class="iconfont icon-xiangyou"></view>
  342. </view>
  343. </view>
  344. </block>
  345. <!-- #endif -->
  346. <!-- #ifdef MP -->
  347. <block v-for="(item,index) in MyMenus" :key="index">
  348. <view class="item acea-row row-between-wrapper" v-if="item.url!='#'
  349. && item.url!='/pages/service/index'
  350. && item.url!='/pages/extension/customer_list/chat'
  351. || (item.url=='/pages/extension/customer_list/chat' && routineContact == 0)"
  352. @click="goMenuPage(item.url, item.name)">
  353. <image :src="item.pic"></image>
  354. <view class="text acea-row row-between-wrapper">
  355. <view>{{item.name}}</view>
  356. <view class="iconfont icon-xiangyou"></view>
  357. </view>
  358. </view>
  359. </block>
  360. <button class="item acea-row row-between-wrapper" open-type='contact' v-if="routineContact == 1">
  361. <image src="/static/images/contact.png"></image>
  362. <view class="text acea-row row-between-wrapper">
  363. <view>联系客服</view>
  364. <view class="iconfont icon-xiangyou"></view>
  365. </view>
  366. </button>
  367. <!-- #endif -->
  368. <!-- #ifdef APP-PLUS -->
  369. <view class="item acea-row row-between-wrapper" hover-class="none"
  370. @click="goMenuPage('/pages/users/privacy/index?type=privacy')">
  371. <image src="/static/images/menu.png"></image>
  372. <view class="text acea-row row-between-wrapper">
  373. <view>隐私协议</view>
  374. <view class="iconfont icon-xiangyou"></view>
  375. </view>
  376. </view>
  377. <!-- #endif -->
  378. </view>
  379. <!-- 会员菜单一 -->
  380. <view class="user-menus" style="margin-top: 25rpx;" v-if="menu_status == 1 && MyMenus.length">
  381. <view class="menu-title">我的服务</view>
  382. <view class="list-box">
  383. <!-- #ifdef APP-PLUS || H5 -->
  384. <block v-for="(item,index) in MyMenus" :key="index">
  385. <view class="item" v-if="item.url!='#' && item.url!='/pages/service/index'"
  386. @click="goMenuPage(item.url, item.name)">
  387. <image :src="item.pic"></image>
  388. <text>{{item.name}}</text>
  389. </view>
  390. </block>
  391. <!-- #endif -->
  392. <!-- #ifdef MP -->
  393. <block v-for="(item,index) in MyMenus" :key="index">
  394. <view class="item" v-if="item.url!='#'
  395. && item.url!='/pages/service/index'
  396. && item.url!='/pages/extension/customer_list/chat'
  397. || (item.url=='/pages/extension/customer_list/chat' && routineContact == 0)"
  398. @click="goMenuPage(item.url, item.name)">
  399. <image :src="item.pic"></image>
  400. <text>{{item.name}}</text>
  401. </view>
  402. </block>
  403. <button class="item" open-type='contact' v-if="routineContact == 1">
  404. <image src="/static/images/contact.png"></image>
  405. <text>联系客服</text>
  406. </button>
  407. <!-- #endif -->
  408. <!-- #ifdef APP-PLUS -->
  409. <view class="item" hover-class="none"
  410. @click="goMenuPage('/pages/users/privacy/index?type=privacy')">
  411. <image src="/static/images/menu.png"></image>
  412. <text>隐私协议</text>
  413. </view>
  414. <!-- #endif -->
  415. </view>
  416. </view>
  417. <view class="user-menus" style="margin-top: 25rpx;" v-if="service_status == 1 && storeMenu.length">
  418. <view class="menu-title">商家管理</view>
  419. <view class="list-box">
  420. <block v-for="(item,index) in storeMenu" :key="index">
  421. <view class="item" :url="item.url" v-if="item.url!='#' && item.url!='/pages/service/index'"
  422. @click="goMenuPage(item.url, item.name)">
  423. <image :src="item.pic"></image>
  424. <text>{{item.name}}</text>
  425. </view>
  426. </block>
  427. </view>
  428. </view>
  429. <view class="menus-list" v-if="service_status == 2 && storeMenu.length">
  430. <view class="title">商家管理</view>
  431. <block v-for="(item,index) in storeMenu" :key="index">
  432. <view class="item acea-row row-between-wrapper" :url="item.url" hover-class="none"
  433. v-if="item.url!='#' && item.url!='/pages/service/index'"
  434. @click="goMenuPage(item.url, item.name)">
  435. <image :src="item.pic"></image>
  436. <view class="text acea-row row-between-wrapper">
  437. <view>{{item.name}}</view>
  438. <view class="iconfont icon-xiangyou"></view>
  439. </view>
  440. </view>
  441. </block>
  442. </view>
  443. <view class="copy_right">
  444. <template v-if='copyRightText'>
  445. <image :src="copyRightImg" mode="aspectFill" class="copyRightImg"></image>
  446. <view class="copyRightText">
  447. {{copyRightText}}
  448. </view>
  449. </template>
  450. <image v-else :src="copyRightImg" mode="aspectFill" class='support'></image>
  451. </view>
  452. <view class="uni-p-b-98"></view>
  453. </scroll-view>
  454. </view>
  455. <view class="codePopup" :style="colorStyle" v-show="isCode">
  456. <view class="header acea-row row-between-wrapper">
  457. <view class="title" :class="{'on': codeIndex == index,'onLeft':codeIndex == 1}"
  458. v-for="(item, index) in codeList" :key="index" @click="tapCode(index)">{{item.name}}</view>
  459. </view>
  460. <view>
  461. <view class="acea-row row-center-wrapper">
  462. <w-barcode :options="config.bar"></w-barcode>
  463. </view>
  464. <view class="acea-row row-center-wrapper" style="margin-top: 35rpx;">
  465. <w-qrcode :options="config.qrc" @generate="hello"></w-qrcode>
  466. </view>
  467. <view class="codeNum">{{config.bar.code}}</view>
  468. <view class="tip">如遇到扫码失败请将屏幕调至最亮重新扫码</view>
  469. </view>
  470. <view class="iconfont icon-guanbi2" @click="closeCode"></view>
  471. </view>
  472. <view class="mark" v-if="isCode"></view>
  473. <pageFooter :style="colorStyle"></pageFooter>
  474. <!-- 店员推广码 extension-->
  475. <view class="codePopup heg" :style="colorStyle" v-show="isextension">
  476. <view class="header">
  477. <view class="title on" style="width: 100%;">店员推广码</view>
  478. </view>
  479. <view>
  480. <view class="acea-row row-center-wrapper" style="margin-top: 25rpx;" @click="hah">
  481. <w-qrcode id="hah" :options="extension"></w-qrcode>
  482. </view>
  483. <view class="tip">如遇到扫码失败请将屏幕调至最亮重新扫码</view>
  484. </view>
  485. <view class="iconfont icon-guanbi2" @click="closeCode"></view>
  486. </view>
  487. <view class="mark" v-show="isextension"></view>
  488. <ewcomerPop v-if="isComerGift" :comerGift="comerGift" @comerPop="comerPop"></ewcomerPop>
  489. <!-- #ifdef MP -->
  490. <!-- <authorize v-if="isShowAuth" @authColse="authColse" @onLoadFun="onLoadFun"></authorize> -->
  491. <editUserModal :isShow="editModal" @closeEdit="closeEdit" @editSuccess="editSuccess"></editUserModal>
  492. <!-- #endif -->
  493. <view class="bottomTips">浙江神英优选电子商务科技有限公司</view>
  494. <view class="bottomTips">浙ICP备2022013004号-1</view>
  495. </view>
  496. </template>
  497. <script>
  498. let sysHeight = uni.getSystemInfoSync().statusBarHeight + 'px';
  499. import {
  500. storeCardApi
  501. } from '@/api/store.js';
  502. import {
  503. newcomerGift
  504. } from '@/api/new_store.js';
  505. import {
  506. newcomerList,
  507. copyRight
  508. } from '@/api/api.js';
  509. import {
  510. getMenuList,
  511. getUserInfo,
  512. setVisit,
  513. updateUserInfo,
  514. getRandCode,
  515. updateWechatInfo
  516. } from '@/api/user.js';
  517. import {
  518. wechatAuthV2,
  519. silenceAuth
  520. } from '@/api/public.js'
  521. import {
  522. toLogin
  523. } from '@/libs/login.js';
  524. import {
  525. mapState,
  526. mapGetters
  527. } from "vuex";
  528. // #ifdef H5
  529. import Auth from '@/libs/wechat';
  530. // #endif
  531. import {
  532. HTTP_REQUEST_URL
  533. } from '@/config/app';
  534. const app = getApp();
  535. import ewcomerPop from '@/components/ewcomerPop/index.vue'
  536. import pageFooter from '@/components/pageFooter/index.vue'
  537. import dayjs from '@/plugin/dayjs/dayjs.min.js';
  538. import Routine from '@/libs/routine';
  539. import colors from '@/mixins/color';
  540. // #ifdef MP
  541. import editUserModal from '@/components/eidtUserModal/index.vue';
  542. // #endif
  543. export default {
  544. components: {
  545. pageFooter,
  546. ewcomerPop,
  547. // #ifdef MP
  548. editUserModal
  549. // #endif
  550. },
  551. computed: {
  552. ...mapGetters({
  553. cartNum: 'cartNum',
  554. isLogin: 'isLogin'
  555. })
  556. },
  557. filters: {
  558. coundTime(val) {
  559. var setTime = val * 1000
  560. var nowTime = new Date()
  561. var rest = setTime - nowTime.getTime()
  562. var day = parseInt(rest / (60 * 60 * 24 * 1000))
  563. // var hour = parseInt(rest/(60*60*1000)%24) //小时
  564. return day + '天'
  565. },
  566. dateFormat: function(value) {
  567. return dayjs(value * 1000).format('YYYY-MM-DD');
  568. }
  569. },
  570. mixins: [colors],
  571. data() {
  572. return {
  573. vipStatus: 0,
  574. stu: false,
  575. storeMenu: [], // 商家管理
  576. orderMenu: [{
  577. img: 'icon-daifukuan',
  578. title: '待付款',
  579. url: '/pages/goods/order_list/index?status=0'
  580. },
  581. {
  582. img: 'icon-daifahuo',
  583. title: '待发货',
  584. url: '/pages/goods/order_list/index?status=1'
  585. },
  586. {
  587. img: 'icon-daishouhuo',
  588. title: '待收货',
  589. url: '/pages/goods/order_list/index?status=2'
  590. },
  591. {
  592. img: 'icon-daipingjia',
  593. title: '待评价',
  594. url: '/pages/goods/order_list/index?status=3'
  595. },
  596. {
  597. img: 'icon-a-shouhoutuikuan',
  598. title: '售后/退款',
  599. url: '/pages/users/user_return_list/index'
  600. },
  601. ],
  602. imgUrls: [],
  603. autoplay: true,
  604. circular: true,
  605. interval: 3000,
  606. duration: 500,
  607. isAuto: false, //没有授权的不会自动授权
  608. //isShowAuth: false, //是否隐藏授权
  609. orderStatusNum: {},
  610. userInfo: {},
  611. MyMenus: [],
  612. sysHeight: sysHeight,
  613. mpHeight: 0,
  614. showStatus: 1,
  615. // #ifdef H5 || MP
  616. pageHeight: '100%',
  617. routineContact: 0,
  618. // #endif
  619. // #ifdef APP-PLUS
  620. pageHeight: app.globalData.windowHeight,
  621. // #endif
  622. // #ifdef H5
  623. isWeixin: Auth.isWeixin(),
  624. //#endif
  625. footerSee: false,
  626. member_style: 1,
  627. my_banner_status: 1,
  628. menu_status: 1,
  629. service_status: 1,
  630. newcomer_status: 1,
  631. codeList: [{
  632. name: '会员码'
  633. }, {
  634. name: '付款码'
  635. }],
  636. codeIndex: 0,
  637. config: {
  638. bar: {
  639. code: '',
  640. color: ['#000'],
  641. bgColor: '#FFFFFF', // 背景色
  642. width: 480, // 宽度
  643. height: 110 // 高度
  644. },
  645. qrc: {
  646. code: '',
  647. size: 380, // 二维码大小
  648. level: 3, //等级 0~4
  649. bgColor: '#FFFFFF', //二维码背景色 默认白色
  650. border: {
  651. color: ['#eee', '#eee'], //边框颜色支持渐变色
  652. lineWidth: 3, //边框宽度
  653. },
  654. // img: '/static/logo.png', //图片
  655. // iconSize: 40, //二维码图标的大小
  656. color: ['#333', '#333'], //边框颜色支持渐变色
  657. }
  658. },
  659. isCode: false,
  660. isextension: false,
  661. extension: {
  662. code: "",
  663. size: 380, // 二维码大小
  664. level: 3, //等级 0~4
  665. bgColor: '#FFFFFF', //二维码背景色 默认白色
  666. border: {
  667. color: ['#eee', '#eee'], //边框颜色支持渐变色
  668. lineWidth: 3, //边框宽度
  669. },
  670. // img: '/static/logo.png', //图片
  671. // iconSize: 40, //二维码图标的大小
  672. color: ['#333', '#333'], //边框颜色支持渐变色
  673. },
  674. imgHost: HTTP_REQUEST_URL,
  675. copyRightText: "",
  676. copyRightImg: '',
  677. giftPic: '',
  678. vip_type: 1,
  679. newcomer_style: 1,
  680. newList: [],
  681. newBg: '',
  682. comerGift: {},
  683. isComerGift: false,
  684. memberStatus: 0,
  685. editModal: false, // 编辑头像信息
  686. }
  687. },
  688. created() {
  689. let that = this;
  690. // #ifdef MP
  691. // 小程序静默授权
  692. if (!this.$store.getters.isLogin) {
  693. // Routine.getCode()
  694. // .then(code => {
  695. // Routine.silenceAuth(code).then(res => {
  696. // this.onLoadFun();
  697. // })
  698. // })
  699. // .catch(res => {
  700. // uni.hideLoading();
  701. // });
  702. }
  703. // #endif
  704. if (that.isLogin == false) {
  705. // #ifdef H5 || APP-PLUS
  706. toLogin()
  707. // #endif
  708. // #ifdef MP
  709. //this.isShowAuth = true;
  710. // #endif
  711. }
  712. // #ifdef APP-PLUS
  713. that.$set(that, 'pageHeight', app.globalData.windowHeight);
  714. // #endif
  715. },
  716. async onLoad(option) {
  717. if (this.isLogin) {
  718. this.getNewcomerGift();
  719. }
  720. // #ifdef H5
  721. if (this.isLogin && Auth.isWeixin() && option.code) {
  722. try {
  723. let res = await updateWechatInfo({
  724. code: option.code
  725. });
  726. this.userInfo.nickname = res.data.nickname;
  727. this.userInfo.avatar = res.data.avatar;
  728. this.userInfo.is_complete = 1;
  729. } catch (e) {}
  730. }
  731. // #endif
  732. this.colorData();
  733. let giftList = [
  734. this.imgHost + '/statics/images/gift01.png',
  735. this.imgHost + '/statics/images/gift02.png',
  736. this.imgHost + '/statics/images/gift03.png',
  737. this.imgHost + '/statics/images/gift04.png',
  738. this.imgHost + '/statics/images/gift05.png',
  739. this.imgHost + '/statics/images/gift06.png'
  740. ];
  741. let newBg = [
  742. this.imgHost + '/statics/images/blue-bg.png',
  743. this.imgHost + '/statics/images/green-bg.png',
  744. this.imgHost + '/statics/images/red-bg.png',
  745. this.imgHost + '/statics/images/pink-bg.png',
  746. this.imgHost + '/statics/images/orange-bg.png',
  747. this.imgHost + '/statics/images/gold-bg.png'
  748. ]
  749. setTimeout(() => {
  750. switch (this.colorNum) {
  751. case 1:
  752. this.giftPic = giftList[2];
  753. this.newBg = newBg[0];
  754. break;
  755. case 2:
  756. this.giftPic = giftList[1];
  757. this.newBg = newBg[1];
  758. break;
  759. case 3:
  760. this.giftPic = giftList[4];
  761. this.newBg = newBg[2];
  762. break;
  763. case 4:
  764. this.giftPic = giftList[0];
  765. this.newBg = newBg[3];
  766. break;
  767. case 5:
  768. this.giftPic = giftList[3];
  769. this.newBg = newBg[4];
  770. break;
  771. case 6:
  772. this.giftPic = giftList[5];
  773. this.newBg = newBg[5];
  774. break;
  775. default:
  776. this.giftPic = giftList[4];
  777. this.newBg = newBg[2];
  778. break
  779. }
  780. }, 1)
  781. },
  782. onReady() {
  783. let self = this
  784. // #ifdef MP
  785. let info = uni.createSelectorQuery().select(".sys-head");
  786. info.boundingClientRect(function(data) { //data - 各种参数
  787. self.mpHeight = data.height
  788. }).exec()
  789. // #endif
  790. },
  791. onShow: function() {
  792. this.getNewList();
  793. if (this.cartNum > 0) {
  794. uni.setTabBarBadge({
  795. index: 3,
  796. text: this.cartNum > 99 ? '99+' : this.cartNum + ''
  797. })
  798. } else {
  799. uni.hideTabBarRedDot({
  800. index: 3
  801. })
  802. }
  803. this.copyRightText = uni.getStorageSync('copyNameInfo');
  804. this.copyRightImg = uni.getStorageSync('copyImageInfo');
  805. uni.removeStorageSync('form_type_cart');
  806. if (!this.copyRightText) {
  807. this.getCopyRight();
  808. }
  809. let that = this;
  810. // #ifdef APP-PLUS
  811. uni.getSystemInfo({
  812. success: function(res) {
  813. that.pageHeight = res.windowHeight + 'px'
  814. }
  815. });
  816. // #endif
  817. if (that.isLogin) {
  818. // #ifdef MP
  819. // this.isShowAuth = false;
  820. // #endif
  821. this.getUserInfo();
  822. this.getMyMenus();
  823. this.setVisit();
  824. };
  825. },
  826. methods: {
  827. // #ifdef MP
  828. editSuccess() {
  829. this.editModal = false;
  830. this.getUserInfo();
  831. },
  832. closeEdit() {
  833. this.editModal = false;
  834. },
  835. // #endif
  836. getCopyRight() {
  837. copyRight().then(res => {
  838. let data = res.data;
  839. if (!data.copyrightContext && !data.copyrightImage) {
  840. data.copyrightImage = '/static/images/support.png'
  841. }
  842. uni.setStorageSync('copyNameInfo', data.copyrightContext);
  843. uni.setStorageSync('copyImageInfo', data.copyrightImage);
  844. this.copyRightText = data.copyrightContext;
  845. this.copyRightImg = data.copyrightImage;
  846. }).catch(err => {
  847. return this.$util.Tips({
  848. title: err.msg
  849. });
  850. });
  851. },
  852. // 查看订单
  853. intoPage(url) {
  854. if (this.isLogin) {
  855. uni.navigateTo({
  856. url: url
  857. })
  858. } else {
  859. toLogin()
  860. }
  861. },
  862. goDetail(item) {
  863. uni.navigateTo({
  864. url: `/pages/goods_details/index?id=${item.id}&fromPage='newVip'`
  865. });
  866. },
  867. comerPop() {
  868. this.isComerGift = false;
  869. },
  870. getNewcomerGift() {
  871. if (uni.getStorageSync('newcomerGift')) {
  872. return this.isComerGift = false;
  873. }
  874. newcomerGift().then(res => {
  875. this.comerGift = res.data;
  876. if (Object.prototype.toString.call(this.comerGift) == '[object Object]') {
  877. if (res.data.coupon_count || res.data.product_count || res.data.register_give_money || res
  878. .data.first_order_discount || res.data.register_give_integral) {
  879. uni.setStorageSync('newcomerGift', true);
  880. this.isComerGift = true;
  881. }
  882. }
  883. }).catch(err => {
  884. return this.$util.Tips({
  885. title: err
  886. });
  887. })
  888. },
  889. getNewList() {
  890. newcomerList({
  891. page: 1,
  892. limit: 6,
  893. priceOrder: '',
  894. salesOrder: ''
  895. }).then(res => {
  896. this.newList = res.data;
  897. }).catch(err => {
  898. return this.$util.Tips({
  899. title: err
  900. });
  901. })
  902. },
  903. hah() {
  904. let that = this
  905. // #ifdef H5
  906. var canvas = document.getElementById("hah").getElementsByTagName("canvas")
  907. var imgURL = canvas[0].toDataURL("image/png")
  908. var dlLink = document.createElement('a');
  909. dlLink.download = "店员推广码";
  910. dlLink.href = imgURL;
  911. dlLink.dataset.downloadurl = ["image/png", dlLink.download, dlLink.href].join(':');
  912. document.body.appendChild(dlLink);
  913. dlLink.click();
  914. document.body.removeChild(dlLink);
  915. // #endif
  916. // #ifdef MP
  917. // let ctx = uni.createCanvasContext("WQrcode")
  918. // let ctx = uni.createSelectorQuery().in(this).select("canvas")
  919. // uni.canvasToTempFilePath({
  920. // canvasId: "WQrcode",
  921. // fileType: 'image/png',
  922. // success: (res) => {
  923. // // 保存当前绘制推广码
  924. // that.savePic(res.tempFilePath)
  925. // },
  926. // fail: function(err) {
  927. // console.log(err, '推广码生成失败')
  928. // }
  929. // },that)
  930. // ctx.draw(false, uni.canvasToTempFilePath({
  931. // canvasId: 'WQrcode',
  932. // success: function (res) {
  933. // that.savePic(res.tempFilePath)
  934. // },
  935. // fail: function (err) {
  936. // console.log(err, '推广码生成失败')
  937. // }
  938. // },that))
  939. // console.log("222222",ctx)
  940. // #endif
  941. // #ifdef APP-PLUS
  942. uni.canvasToTempFilePath({
  943. canvasId: 'WQrcode',
  944. success: (res) => {
  945. uni.hideLoading()
  946. // 保存当前绘制推广码
  947. that.savePic(res.tempFilePath)
  948. },
  949. fail: function(err) {
  950. console.log(err, '推广码生成失败')
  951. }
  952. })
  953. // #endif
  954. },
  955. //保存推广码到本地
  956. savePic(filePath) {
  957. // #ifdef APP-PLUS
  958. uni.showLoading({
  959. title: '正在保存'
  960. });
  961. uni.saveImageToPhotosAlbum({
  962. filePath: filePath,
  963. success: function() {
  964. uni.showToast({
  965. title: '推广码保存成功~'
  966. });
  967. },
  968. fail: function(e) {
  969. console.log(e, '推广码保存失败')
  970. },
  971. complete: function() {
  972. uni.hideLoading()
  973. }
  974. });
  975. // #endif
  976. },
  977. hello(res) {
  978. // console.log(321,res)
  979. },
  980. // 前往新人专享
  981. goNewcomers() {
  982. uni.navigateTo({
  983. url: '/pages/store/newcomers/index'
  984. })
  985. },
  986. getCode() {
  987. getRandCode().then(res => {
  988. let code = res.data.code;
  989. this.config.bar.code = code;
  990. this.config.qrc.code = code;
  991. }).catch(err => {
  992. return this.$util.Tips(err);
  993. })
  994. },
  995. tapQrCode() {
  996. this.isCode = true;
  997. this.codeIndex = 0;
  998. this.$nextTick(function() {
  999. let code = this.userInfo.bar_code;
  1000. this.config.bar.code = code;
  1001. this.config.qrc.code = code;
  1002. })
  1003. },
  1004. closeCode() {
  1005. this.isCode = false
  1006. this.isextension = false
  1007. },
  1008. tapCode(index) {
  1009. this.codeIndex = index;
  1010. if (index == 1) {
  1011. this.getCode();
  1012. } else {
  1013. let code = this.userInfo.bar_code;
  1014. this.config.bar.code = code;
  1015. this.config.qrc.code = code;
  1016. }
  1017. },
  1018. getWechatuserinfo() {
  1019. //#ifdef H5
  1020. Auth.isWeixin() && Auth.toAuth('snsapi_userinfo', '/pages/user/index');
  1021. //#endif
  1022. },
  1023. getRoutineUserInfo(e) {
  1024. updateUserInfo({
  1025. userInfo: e.detail.userInfo
  1026. }).then(res => {
  1027. this.getUserInfo();
  1028. return this.$util.Tips('更新用户信息成功');
  1029. }).catch(err => {
  1030. return this.$util.Tips(err);
  1031. })
  1032. },
  1033. // 记录会员访问
  1034. setVisit() {
  1035. setVisit({
  1036. url: '/pages/user/index'
  1037. }).then(res => {})
  1038. },
  1039. // 打开授权
  1040. openAuto() {
  1041. toLogin();
  1042. },
  1043. // 授权回调
  1044. onLoadFun(e) {
  1045. this.getUserInfo(e);
  1046. this.getMyMenus();
  1047. this.setVisit();
  1048. this.isShowAuth = false;
  1049. },
  1050. Setting: function() {
  1051. uni.openSetting({
  1052. success: function(res) {}
  1053. });
  1054. },
  1055. // 授权关闭
  1056. authColse: function(e) {
  1057. this.isShowAuth = e
  1058. },
  1059. // 绑定手机
  1060. bindPhone() {
  1061. uni.navigateTo({
  1062. url: '/pages/users/user_phone/index'
  1063. })
  1064. },
  1065. /**
  1066. * 获取个人用户信息
  1067. */
  1068. getUserInfo: function() {
  1069. let that = this;
  1070. getUserInfo().then(res => {
  1071. that.userInfo = res.data;
  1072. that.userInfo.integral_price = (+res.data.integral_price).toFixed(2);
  1073. that.userInfo.static_integral = (+res.data.static_integral).toFixed(2);
  1074. that.userInfo.action_integral = (+res.data.action_integral).toFixed(2);
  1075. that.stu = res.data.svip_open
  1076. that.memberStatus = parseInt(res.data.member_func_status)
  1077. that.vipStatus = res.data.vip_status
  1078. that.$store.commit("SETUID", res.data.uid);
  1079. that.$store.commit("UPDATE_USERINFO", res.data);
  1080. that.orderMenu.forEach((item, index) => {
  1081. switch (item.title) {
  1082. case '待付款':
  1083. item.num = res.data.orderStatusNum.unpaid_count
  1084. break
  1085. case '待发货':
  1086. item.num = res.data.orderStatusNum.unshipped_count
  1087. break
  1088. case '待收货':
  1089. item.num = res.data.orderStatusNum.received_count
  1090. break
  1091. case '待评价':
  1092. item.num = res.data.orderStatusNum.evaluated_count
  1093. break
  1094. case '售后/退款':
  1095. item.num = res.data.orderStatusNum.refunding_count
  1096. break
  1097. }
  1098. })
  1099. });
  1100. },
  1101. //小程序授权api替换 getUserInfo
  1102. getUserProfile() {
  1103. uni.showLoading({
  1104. title: '获取中'
  1105. });
  1106. let self = this;
  1107. Routine.getUserProfile()
  1108. .then(res => {
  1109. Routine.getCode()
  1110. .then(code => {
  1111. let userInfo = res.userInfo;
  1112. userInfo.code = code;
  1113. userInfo.spread_spid = app.globalData.spid; //获取推广人ID
  1114. userInfo.spread_code = app.globalData.code; //获取推广人分享二维码ID
  1115. Routine.authUserInfo(userInfo)
  1116. .then(res => {
  1117. if (res.data.key !== undefined && res.data.key) {
  1118. uni.hideLoading();
  1119. self.authKey = res.data.key;
  1120. self.isPhoneBox = true;
  1121. } else {
  1122. uni.hideLoading();
  1123. let time = res.data.expires_time - self.$Cache.time();
  1124. self.$store.commit('LOGIN', {
  1125. token: res.data.token,
  1126. time: time
  1127. });
  1128. this.getUserInfo()
  1129. }
  1130. })
  1131. .catch(res => {
  1132. uni.hideLoading();
  1133. uni.showToast({
  1134. title: res.msg,
  1135. icon: 'none',
  1136. duration: 2000
  1137. });
  1138. });
  1139. })
  1140. .catch(res => {
  1141. uni.hideLoading();
  1142. });
  1143. })
  1144. .catch(res => {
  1145. uni.hideLoading();
  1146. });
  1147. },
  1148. /**
  1149. *
  1150. * 获取个人中心图标
  1151. */
  1152. switchTab(order) {
  1153. this.orderMenu.forEach((item, index) => {
  1154. switch (item.title) {
  1155. case '待付款':
  1156. item.img = order.dfk
  1157. break
  1158. case '待发货':
  1159. item.img = order.dfh
  1160. break
  1161. case '待收货':
  1162. item.img = order.dsh
  1163. break
  1164. case '待评价':
  1165. item.img = order.dpj
  1166. break
  1167. case '售后/退款':
  1168. item.img = order.sh
  1169. break
  1170. }
  1171. })
  1172. },
  1173. getMyMenus: function() {
  1174. let that = this;
  1175. // if (this.MyMenus.length) return;
  1176. getMenuList().then(res => {
  1177. let storeMenu = []
  1178. let myMenu = []
  1179. res.data.routine_my_menus.forEach((el, index, arr) => {
  1180. if (el.type == '2') {
  1181. storeMenu.push(el)
  1182. } else {
  1183. myMenu.push(el)
  1184. }
  1185. })
  1186. this.member_style = Number(res.data.diy_data.status)
  1187. this.my_banner_status = res.data.diy_data.my_banner_status
  1188. this.menu_status = res.data.diy_data.menu_status
  1189. this.service_status = res.data.diy_data.service_status
  1190. this.vip_type = res.data.diy_data.vip_type;
  1191. this.newcomer_style = res.data.diy_data.newcomer_style;
  1192. this.newcomer_status = res.data.diy_data.newcomer_status;
  1193. let order01 = {
  1194. dfk: 'icon-daifukuan',
  1195. dfh: 'icon-daifahuo',
  1196. dsh: 'icon-daishouhuo',
  1197. dpj: 'icon-daipingjia',
  1198. sh: 'icon-a-shouhoutuikuan'
  1199. }
  1200. let order02 = {
  1201. dfk: 'icon-daifukuan-lan',
  1202. dfh: 'icon-daifahuo-lan',
  1203. dsh: 'icon-daishouhuo-lan',
  1204. dpj: 'icon-daipingjia-lan',
  1205. sh: 'icon-shouhou-tuikuan-lan'
  1206. }
  1207. let order03 = {
  1208. dfk: 'icon-daifukuan-ju',
  1209. dfh: 'icon-daifahuo-ju',
  1210. dsh: 'icon-daishouhuo-ju',
  1211. dpj: 'icon-daipingjia-ju',
  1212. sh: 'icon-shouhou-tuikuan-ju'
  1213. }
  1214. let order04 = {
  1215. dfk: 'icon-daifukuan-fen',
  1216. dfh: 'icon-daifahuo-fen',
  1217. dsh: 'icon-daishouhuo-fen',
  1218. dpj: 'icon-daipingjia-fen',
  1219. sh: 'icon-a-shouhoutuikuan-fen'
  1220. }
  1221. let order05 = {
  1222. dfk: 'icon-daifukuan-lv',
  1223. dfh: 'icon-daifahuo-lv',
  1224. dsh: 'icon-daishouhuo-lv',
  1225. dpj: 'icon-daipingjia-lv',
  1226. sh: 'icon-shouhou-tuikuan-lv'
  1227. }
  1228. switch (res.data.diy_data.order_status) {
  1229. case 1:
  1230. this.switchTab(order01)
  1231. break
  1232. case 2:
  1233. this.switchTab(order02)
  1234. break
  1235. case 3:
  1236. this.switchTab(order03)
  1237. break
  1238. case 4:
  1239. this.switchTab(order04)
  1240. break
  1241. case 5:
  1242. this.switchTab(order05)
  1243. break
  1244. }
  1245. that.$set(that, 'MyMenus', myMenu);
  1246. that.$set(that, 'storeMenu', storeMenu);
  1247. this.imgUrls = res.data.routine_my_banner
  1248. this.routineContact = Number(res.data.routine_contact_type)
  1249. });
  1250. },
  1251. // 编辑页面
  1252. goEdit() {
  1253. if (this.isLogin == false || !this.userInfo.uid) {
  1254. toLogin();
  1255. } else {
  1256. // #ifdef MP
  1257. if (this.userInfo.is_default_avatar) {
  1258. this.editModal = true;
  1259. return;
  1260. }
  1261. // #endif
  1262. uni.navigateTo({
  1263. url: '/pages/users/user_set/index'
  1264. })
  1265. }
  1266. },
  1267. // 签到
  1268. goSignIn() {
  1269. uni.navigateTo({
  1270. url: '/pages/users/user_sgin/index'
  1271. })
  1272. },
  1273. goMenuPage(url, name) {
  1274. if (this.isLogin) {
  1275. let arr = url.split('@APPID=');
  1276. if (arr.length > 1) {
  1277. //#ifdef MP
  1278. uni.navigateToMiniProgram({
  1279. appId: arr[arr.length - 1], // 此为生活缴费appid
  1280. path: arr[0], // 此为生活缴费首页路径
  1281. envVersion: "release",
  1282. success: res => {
  1283. console.log("打开成功", res);
  1284. },
  1285. fail: err => {
  1286. console.log('sgdhgf', err);
  1287. }
  1288. })
  1289. //#endif
  1290. //#ifndef MP
  1291. this.Tips({
  1292. title: 'h5与app端不支持跳转外部小程序'
  1293. });
  1294. //#endif
  1295. } else {
  1296. if (url == '/pages/extension/customer_list/chat' || url == 'https://chat.crmeb.net/chat/mobile') {
  1297. this.$util.getCustomer(this.userInfo)
  1298. } else {
  1299. if (url.indexOf('http') === -1) {
  1300. // #ifdef H5
  1301. if (name && name === '订单核销') {
  1302. return window.location.href = `${location.origin}${url}`
  1303. }
  1304. // #endif
  1305. // #ifdef MP
  1306. if (url != '#' && url == '/pages/users/user_set/index') {
  1307. uni.openSetting({
  1308. success: function(res) {}
  1309. });
  1310. }
  1311. // #endif
  1312. if (url == '/pages/store_spread/index') {
  1313. storeCardApi().then(res => {
  1314. this.isextension = true
  1315. this.$nextTick(function() {
  1316. this.extension.code = res.data.url
  1317. })
  1318. }).catch(err => {
  1319. uni.hideLoading()
  1320. this.$util.Tips({
  1321. title: err
  1322. })
  1323. })
  1324. }
  1325. if (['/pages/goods_cate/goods_cate', '/pages/order_addcart/order_addcart',
  1326. '/pages/user/index', '/pages/store_cate/store_cate', '/pages/index/index'
  1327. ]
  1328. .indexOf(url.split('?')[0]) == -1) {
  1329. uni.navigateTo({
  1330. url: url
  1331. })
  1332. } else {
  1333. uni.reLaunch({
  1334. url: url
  1335. })
  1336. }
  1337. } else {
  1338. uni.navigateTo({
  1339. url: `/pages/annex/web_view/index?url=${url}`
  1340. });
  1341. }
  1342. }
  1343. }
  1344. } else {
  1345. this.openAuto();
  1346. }
  1347. }
  1348. }
  1349. }
  1350. </script>
  1351. <style lang="scss">
  1352. .style-add {
  1353. flex: 1;
  1354. overflow: hidden;
  1355. }
  1356. .height-add {
  1357. height: 100%;
  1358. }
  1359. .display-add {
  1360. height: 100%;
  1361. display: flex;
  1362. align-items: center;
  1363. }
  1364. page,
  1365. body {
  1366. height: 100%;
  1367. }
  1368. .heg {
  1369. height: 670rpx !important;
  1370. }
  1371. .mark {
  1372. position: fixed;
  1373. top: 0;
  1374. left: 0;
  1375. bottom: 0;
  1376. right: 0;
  1377. background: rgba(0, 0, 0, 0.5);
  1378. z-index: 30;
  1379. }
  1380. .height {
  1381. margin-top: -84rpx !important;
  1382. }
  1383. .menus-list {
  1384. width: 690rpx;
  1385. background-color: #fff;
  1386. border-radius: 14rpx;
  1387. margin: 25rpx auto 0 auto;
  1388. .title {
  1389. font-weight: 600;
  1390. font-size: 30rpx;
  1391. color: #333;
  1392. padding: 30rpx 30rpx 10rpx 30rpx;
  1393. }
  1394. .item {
  1395. margin-left: 30rpx;
  1396. font-size: 30rpx;
  1397. color: #333;
  1398. image {
  1399. width: 42rpx;
  1400. height: 42rpx;
  1401. display: block;
  1402. }
  1403. .text {
  1404. width: 590rpx;
  1405. border-bottom: 1rpx solid #EEEEEE;
  1406. padding: 28rpx 30rpx 28rpx 0;
  1407. .iconfont {
  1408. font-size: 20rpx;
  1409. color: #8A8A8A;
  1410. }
  1411. }
  1412. }
  1413. }
  1414. .flex-item-box {
  1415. background-color: #fff;
  1416. border-radius: 16rpx;
  1417. padding:20rpx 30rpx;
  1418. margin: 30rpx 30rpx 25rpx 30rpx;
  1419. .flex-item {
  1420. line-height: 40rpx;
  1421. width: 100%;
  1422. display: flex;
  1423. font-size: 28rpx;
  1424. font-weight: bold;
  1425. justify-content: space-between;
  1426. .num{
  1427. font-size: 40rpx;
  1428. }
  1429. }
  1430. }
  1431. .num-wrapper {
  1432. background-color: #fff;
  1433. z-index: 29;
  1434. position: relative;
  1435. display: flex;
  1436. align-items: center;
  1437. justify-content: space-between;
  1438. margin-top: 22rpx;
  1439. color: #333;
  1440. margin: 30rpx 30rpx 25rpx 30rpx;
  1441. border-radius: 16rpx;
  1442. height: 160rpx;
  1443. &.on {
  1444. height: 128rpx;
  1445. margin-top: -68rpx;
  1446. .gift {
  1447. color: var(--view-theme);
  1448. margin-left: 10rpx;
  1449. font-weight: bold;
  1450. }
  1451. }
  1452. .img {
  1453. margin-left: 38rpx;
  1454. width: 76rpx;
  1455. height: 68rpx;
  1456. }
  1457. .text {
  1458. font-size: 28rpx;
  1459. font-weight: 400;
  1460. color: #333333;
  1461. margin-left: -60rpx;
  1462. }
  1463. .btn-login {
  1464. width: 144rpx;
  1465. height: 56rpx;
  1466. // background: linear-gradient(270deg, #FF7931 0%, #E93323 100%);
  1467. background-color: var(--view-theme);
  1468. border-radius: 28rpx;
  1469. text-align: center;
  1470. line-height: 56rpx;
  1471. margin-right: 32rpx;
  1472. font-size: 28rpx;
  1473. font-weight: 500;
  1474. color: #FFFFFF;
  1475. }
  1476. .num-item {
  1477. width: 33.33%;
  1478. text-align: center;
  1479. flex-grow: 1;
  1480. &~.num-item {
  1481. position: relative;
  1482. &:before {
  1483. content: '';
  1484. position: absolute;
  1485. width: 1rpx;
  1486. height: 28rpx;
  1487. top: 50%;
  1488. margin-top: -14rpx;
  1489. background-color: rgba(255, 255, 255, 0.4);
  1490. left: 0;
  1491. }
  1492. }
  1493. .num {
  1494. font-size: 36rpx;
  1495. font-weight: bold;
  1496. }
  1497. .txt {
  1498. margin-top: 8rpx;
  1499. font-size: 26rpx;
  1500. color: #555;
  1501. }
  1502. }
  1503. }
  1504. // 新人专享
  1505. .newcomersCon {
  1506. background-color: var(--view-theme);
  1507. width: 690rpx;
  1508. height: 296rpx;
  1509. margin: 0 30rpx;
  1510. border-radius: 16rpx;
  1511. &.on {
  1512. background-color: #fff;
  1513. .newcomers {
  1514. .title {
  1515. .tl {
  1516. color: #333;
  1517. }
  1518. .tr {
  1519. width: unset;
  1520. color: #666666;
  1521. background: unset;
  1522. }
  1523. }
  1524. .scroll {
  1525. .scroll-item {
  1526. background-color: var(--view-minorColorT);
  1527. }
  1528. }
  1529. }
  1530. }
  1531. .newcomers {
  1532. padding: 24rpx 30rpx;
  1533. width: 100%;
  1534. height: 100%;
  1535. background-repeat: no-repeat;
  1536. background-size: 100% 100%;
  1537. .title {
  1538. display: flex;
  1539. justify-content: space-between;
  1540. .tl {
  1541. font-size: 30rpx;
  1542. font-weight: 600;
  1543. color: #FFFFFF;
  1544. }
  1545. .tr {
  1546. width: 90rpx;
  1547. height: 36rpx;
  1548. background: linear-gradient(135deg, #FFCA52 0%, #FE960F 100%);
  1549. border-radius: 18rpx;
  1550. font-size: 24rpx;
  1551. text-align: center;
  1552. line-height: 36rpx;
  1553. font-weight: 400;
  1554. color: #FFFFFF;
  1555. .icon-xiangyou {
  1556. font-size: 20rpx;
  1557. }
  1558. }
  1559. }
  1560. .scroll {
  1561. // width: 690rpx;
  1562. margin-top: 20rpx;
  1563. white-space: nowrap;
  1564. // padding-right: 60rpx;
  1565. .scroll-item {
  1566. display: inline-block;
  1567. width: 162rpx;
  1568. height: 194rpx;
  1569. background-color: #fff;
  1570. border-radius: 12rpx;
  1571. margin-right: 10rpx;
  1572. padding: 12rpx;
  1573. .pictrue {
  1574. width: 138rpx;
  1575. height: 138rpx;
  1576. position: relative;
  1577. image {
  1578. width: 100%;
  1579. height: 100%;
  1580. }
  1581. .label {
  1582. width: 98rpx;
  1583. height: 32rpx;
  1584. background: var(--view-theme);
  1585. border-radius: 16rpx;
  1586. color: #FFFFFF;
  1587. font-size: 24rpx;
  1588. text-align: center;
  1589. line-height: 32rpx;
  1590. position: absolute;
  1591. bottom: 2rpx;
  1592. left: 50%;
  1593. margin-left: -49rpx;
  1594. }
  1595. }
  1596. .money {
  1597. font-size: 24rpx;
  1598. color: var(--view-priceColor);
  1599. margin-top: 6rpx;
  1600. }
  1601. }
  1602. }
  1603. }
  1604. }
  1605. .Tnum-wrapper {
  1606. margin: -34rpx 30rpx 25rpx 30rpx;
  1607. }
  1608. .unNum-wrapper {
  1609. margin: 0 auto 25rpx auto;
  1610. width: 690rpx;
  1611. }
  1612. .unBg {
  1613. background-color: unset !important;
  1614. .user-info {
  1615. .info {
  1616. .name {
  1617. color: #333333 !important;
  1618. font-weight: 600;
  1619. }
  1620. .num {
  1621. color: #333 !important;
  1622. .num-txt {
  1623. height: 38rpx;
  1624. background-color: rgba(51, 51, 51, 0.13);
  1625. padding: 0 12rpx;
  1626. border-radius: 16rpx;
  1627. }
  1628. }
  1629. }
  1630. }
  1631. .qrCode {
  1632. color: #333 !important;
  1633. }
  1634. .message {
  1635. .iconfont {
  1636. color: #333 !important;
  1637. }
  1638. .num {
  1639. color: #fff !important;
  1640. background-color: var(--view-theme) !important;
  1641. }
  1642. }
  1643. .setting {
  1644. .iconfont {
  1645. color: #333 !important;
  1646. }
  1647. }
  1648. }
  1649. .cardVipB {
  1650. background-color: #343A48;
  1651. width: 100%;
  1652. height: 124rpx;
  1653. border-radius: 16rpx 16rpx 0 0;
  1654. padding: 22rpx 30rpx 0 30rpx;
  1655. margin-top: 16px;
  1656. &.on {
  1657. width: 690rpx;
  1658. height: 130rpx;
  1659. background-repeat: no-repeat;
  1660. background-size: 100% 100%;
  1661. color: #fff;
  1662. margin-left: auto;
  1663. margin-right: auto;
  1664. padding: 26rpx 30rpx 0 90rpx;
  1665. .iconfont {
  1666. font-size: 24rpx;
  1667. margin-left: 6rpx;
  1668. }
  1669. }
  1670. .left-box {
  1671. .small {
  1672. color: #F8D5A8;
  1673. font-size: 28rpx;
  1674. margin-left: 18rpx;
  1675. }
  1676. .pictrue {
  1677. width: 40rpx;
  1678. height: 45rpx;
  1679. image {
  1680. width: 100%;
  1681. height: 100%;
  1682. }
  1683. }
  1684. }
  1685. .btn {
  1686. color: #BBBBBB;
  1687. font-size: 26rpx;
  1688. &.on {
  1689. color: #fff;
  1690. }
  1691. }
  1692. .icon-xiangyou {
  1693. margin-top: 6rpx;
  1694. }
  1695. }
  1696. .cardVipA {
  1697. position: absolute;
  1698. background-repeat: no-repeat;
  1699. background-size: 100% 100%;
  1700. width: 750rpx;
  1701. height: 84rpx;
  1702. bottom: -2rpx;
  1703. left: 0;
  1704. padding: 0 56rpx 0 135rpx;
  1705. .left-box {
  1706. font-size: 26rpx;
  1707. color: #905100;
  1708. font-weight: 400;
  1709. &.on {
  1710. color: #fff;
  1711. }
  1712. }
  1713. .btn {
  1714. color: #905100;
  1715. font-weight: 400;
  1716. font-size: 24rpx;
  1717. &.on {
  1718. color: #fff;
  1719. }
  1720. }
  1721. .iconfont {
  1722. font-size: 20rpx;
  1723. margin: 4rpx 0 0 4rpx;
  1724. &.on {
  1725. color: #fff;
  1726. margin-top: 0;
  1727. }
  1728. }
  1729. }
  1730. .new-users {
  1731. display: flex;
  1732. flex-direction: column;
  1733. height: 100%;
  1734. .sys-head {
  1735. position: relative;
  1736. width: 100%;
  1737. // background: linear-gradient(90deg, $bg-star1 0%, $bg-end1 100%);
  1738. .bg {
  1739. position: absolute;
  1740. left: 0;
  1741. top: 0;
  1742. width: 100%;
  1743. height: 100%;
  1744. // background: url("~@/static/images/user-sys.png") no-repeat;
  1745. background: var(--view-theme);
  1746. background-size: 100% auto;
  1747. background-position: left bottom;
  1748. }
  1749. .sys-title {
  1750. z-index: 10;
  1751. position: relative;
  1752. height: 43px;
  1753. text-align: center;
  1754. line-height: 43px;
  1755. font-size: 34rpx;
  1756. color: #FFFFFF;
  1757. }
  1758. }
  1759. .head {
  1760. // background: #fff;
  1761. .user-card {
  1762. position: relative;
  1763. width: 100%;
  1764. height: 270rpx;
  1765. margin: 0 auto;
  1766. padding: 35rpx 28rpx;
  1767. background-size: 100% auto;
  1768. background-color: var(--view-theme);
  1769. .user-info {
  1770. z-index: 20;
  1771. position: relative;
  1772. display: flex;
  1773. .headwear {
  1774. position: absolute;
  1775. right: -4rpx;
  1776. top: -14rpx;
  1777. width: 44rpx;
  1778. height: 44rpx;
  1779. image {
  1780. width: 100%;
  1781. height: 100%;
  1782. }
  1783. }
  1784. .live {
  1785. width: 28rpx;
  1786. height: 28rpx;
  1787. margin-left: 14rpx;
  1788. display: block;
  1789. }
  1790. .bntImg {
  1791. width: 120rpx;
  1792. height: 120rpx;
  1793. border-radius: 50%;
  1794. text-align: center;
  1795. line-height: 120rpx;
  1796. background-color: unset;
  1797. position: relative;
  1798. .avatarName {
  1799. font-size: 16rpx;
  1800. color: #fff;
  1801. text-align: center;
  1802. background-color: rgba(0, 0, 0, 0.6);
  1803. height: 37rpx;
  1804. line-height: 37rpx;
  1805. position: absolute;
  1806. bottom: 0;
  1807. left: 0;
  1808. width: 100%;
  1809. }
  1810. }
  1811. .avatar-box {
  1812. position: relative;
  1813. display: flex;
  1814. align-items: center;
  1815. justify-content: center;
  1816. width: 120rpx;
  1817. height: 120rpx;
  1818. border-radius: 50%;
  1819. &.on {
  1820. .avatar {
  1821. border: 2px solid #FFAC65;
  1822. border-radius: 50%;
  1823. box-sizing: border-box;
  1824. }
  1825. }
  1826. }
  1827. .avatar {
  1828. position: relative;
  1829. width: 120rpx;
  1830. height: 120rpx;
  1831. border-radius: 50%;
  1832. }
  1833. .info {
  1834. width: 346rpx;
  1835. flex: 1;
  1836. display: flex;
  1837. flex-direction: column;
  1838. justify-content: space-between;
  1839. margin-left: 20rpx;
  1840. padding: 20rpx 0;
  1841. .name {
  1842. display: flex;
  1843. align-items: center;
  1844. color: #fff;
  1845. font-size: 31rpx;
  1846. width: 346rpx;
  1847. .nickname {
  1848. max-width: 196rpx;
  1849. display: block;
  1850. }
  1851. .vip {
  1852. margin-left: 10rpx;
  1853. width: 78rpx;
  1854. height: 30rpx;
  1855. image {
  1856. width: 100%;
  1857. height: 100%;
  1858. display: block;
  1859. }
  1860. }
  1861. }
  1862. .num {
  1863. display: flex;
  1864. align-items: center;
  1865. font-size: 24rpx;
  1866. color: rgba(255, 255, 255, 0.6);
  1867. image {
  1868. width: 22rpx;
  1869. height: 23rpx;
  1870. margin-left: 20rpx;
  1871. }
  1872. }
  1873. }
  1874. }
  1875. .qrCode {
  1876. color: #fff;
  1877. margin-top: 18rpx !important;
  1878. font-size: 38rpx;
  1879. margin-right: 34rpx !important;
  1880. }
  1881. .message {
  1882. align-self: flex-start;
  1883. position: relative;
  1884. margin-top: 16rpx;
  1885. margin-right: 30rpx;
  1886. .uni-badge-left-margin {
  1887. /deep/.uni-badge--error {
  1888. background-color: #fff !important;
  1889. color: var(--view-theme);
  1890. }
  1891. }
  1892. .num {
  1893. position: absolute;
  1894. top: -8rpx;
  1895. left: 18rpx;
  1896. padding: 0 6rpx;
  1897. height: 28rpx;
  1898. border-radius: 12rpx;
  1899. background-color: #fff;
  1900. font-size: 18rpx;
  1901. line-height: 28rpx;
  1902. text-align: center;
  1903. color: var(--view-theme);
  1904. }
  1905. .iconfont {
  1906. font-size: 40rpx;
  1907. color: #fff;
  1908. }
  1909. }
  1910. .sign {
  1911. z-index: 200;
  1912. position: absolute;
  1913. right: -12rpx;
  1914. top: 80rpx;
  1915. display: flex;
  1916. align-items: center;
  1917. justify-content: center;
  1918. width: 120rpx;
  1919. height: 60rpx;
  1920. background: linear-gradient(90deg, rgba(255, 225, 87, 1) 0%, rgba(238, 193, 15, 1) 100%);
  1921. border-radius: 29rpx 4rpx 4rpx 29rpx;
  1922. color: #282828;
  1923. font-size: 28rpx;
  1924. font-weight: bold;
  1925. }
  1926. }
  1927. .order-wrapper {
  1928. background: #fff;
  1929. margin: 0 30rpx;
  1930. border-radius: 16rpx;
  1931. position: relative;
  1932. .order-hd {
  1933. justify-content: space-between;
  1934. padding: 30rpx 20rpx 10rpx;
  1935. margin-top: 25rpx;
  1936. font-size: 30rpx;
  1937. color: #282828;
  1938. .left {
  1939. font-weight: bold;
  1940. }
  1941. .right {
  1942. align-items: center;
  1943. color: #666666;
  1944. font-size: 26rpx;
  1945. .icon-xiangyou {
  1946. margin-left: 5rpx;
  1947. margin-top: 6rpx;
  1948. font-size: 26rpx;
  1949. }
  1950. }
  1951. }
  1952. .order-bd {
  1953. display: flex;
  1954. padding: 0 0;
  1955. .order-item {
  1956. display: flex;
  1957. flex-direction: column;
  1958. justify-content: center;
  1959. align-items: center;
  1960. width: 20%;
  1961. height: 140rpx;
  1962. .pic {
  1963. position: relative;
  1964. text-align: center;
  1965. .iconfont {
  1966. font-size: 48rpx;
  1967. color: var(--view-theme);
  1968. }
  1969. image {
  1970. width: 58rpx;
  1971. height: 48rpx;
  1972. }
  1973. .uni-badge-left-margin {
  1974. position: absolute;
  1975. // #ifdef MP
  1976. top: -22rpx;
  1977. // #endif
  1978. /deep/.uni-badge--error {
  1979. background-color: #fff !important;
  1980. }
  1981. /deep/.uni-badge {
  1982. color: var(--view-theme);
  1983. border: 1px solid var(--view-theme);
  1984. z-index: 29;
  1985. }
  1986. }
  1987. }
  1988. .txt {
  1989. margin-top: 6rpx;
  1990. font-size: 26rpx;
  1991. color: #454545;
  1992. }
  1993. }
  1994. }
  1995. }
  1996. }
  1997. .slider-wrapper {
  1998. margin: 20rpx 30rpx;
  1999. height: 130rpx;
  2000. swiper,
  2001. swiper-item {
  2002. height: 100%;
  2003. }
  2004. image {
  2005. width: 100%;
  2006. height: 130rpx;
  2007. border-radius: 16rpx;
  2008. }
  2009. }
  2010. .user-menus {
  2011. background-color: #fff;
  2012. margin: 0 30rpx;
  2013. border-radius: 16rpx;
  2014. .menu-title {
  2015. padding: 30rpx 30rpx 40rpx;
  2016. font-size: 30rpx;
  2017. color: #282828;
  2018. font-weight: bold;
  2019. }
  2020. .list-box {
  2021. display: flex;
  2022. flex-wrap: wrap;
  2023. padding: 0;
  2024. }
  2025. .item {
  2026. position: relative;
  2027. display: flex;
  2028. align-items: center;
  2029. justify-content: space-between;
  2030. flex-direction: column;
  2031. width: 25%;
  2032. margin-bottom: 47rpx;
  2033. font-size: 26rpx;
  2034. color: #333333;
  2035. image {
  2036. width: 52rpx;
  2037. height: 52rpx;
  2038. margin-bottom: 18rpx;
  2039. }
  2040. &:last-child::before {
  2041. display: none;
  2042. }
  2043. }
  2044. button {
  2045. font-size: 28rpx;
  2046. }
  2047. }
  2048. .phone {
  2049. color: #fff;
  2050. background-color: #CCC;
  2051. border-radius: 15px;
  2052. width: max-content;
  2053. padding: 2px 10px;
  2054. font-size: 20rpx;
  2055. margin-top: 4px;
  2056. }
  2057. .order-status-num {
  2058. min-width: 12rpx;
  2059. background-color: #fff;
  2060. color: var(--view-theme);
  2061. border-radius: 15px;
  2062. position: absolute;
  2063. right: -14rpx;
  2064. top: -15rpx;
  2065. font-size: 20rpx;
  2066. padding: 0 8rpx;
  2067. border: 1px solid var(--view-theme);
  2068. }
  2069. .support {
  2070. width: 219rpx;
  2071. height: 74rpx;
  2072. margin: 54rpx auto;
  2073. display: block;
  2074. }
  2075. .copyRightImg {
  2076. width: 219rpx;
  2077. height: 74rpx;
  2078. margin: 16rpx auto;
  2079. display: block;
  2080. }
  2081. .copy_right {
  2082. text-align: center;
  2083. color: #ccc;
  2084. font-size: 22rpx;
  2085. margin-top: 40rpx;
  2086. .copyRightText {
  2087. margin-top: 0rpx;
  2088. color: #ccc;
  2089. font-size: 20rpx;
  2090. margin-bottom: 20rpx;
  2091. }
  2092. }
  2093. }
  2094. .card-vip {
  2095. display: flex;
  2096. justify-content: space-between;
  2097. position: relative;
  2098. width: 690rpx;
  2099. height: 125rpx;
  2100. margin: -72rpx auto 0;
  2101. background: url('~@/static/images/user_vip.png');
  2102. background-size: cover;
  2103. padding: 28rpx 30rpx 0 92rpx;
  2104. &.on {
  2105. .left-box {
  2106. color: #fff;
  2107. }
  2108. .btn {
  2109. color: #fff;
  2110. }
  2111. .iconfont {
  2112. color: #fff;
  2113. }
  2114. }
  2115. .left-box {
  2116. font-size: 28rpx;
  2117. color: #AE5A2A;
  2118. .big {
  2119. font-size: 28rpx;
  2120. }
  2121. .small {
  2122. opacity: 0.8;
  2123. }
  2124. }
  2125. .btn {
  2126. color: #AE5A2A;
  2127. font-weight: 400;
  2128. font-size: 26rpx;
  2129. }
  2130. .iconfont {
  2131. font-size: 20rpx;
  2132. margin: 4rpx 0 0 4rpx;
  2133. color: #AE5A2A;
  2134. }
  2135. }
  2136. .setting {
  2137. margin-top: 15rpx;
  2138. margin-left: 15rpx;
  2139. color: #fff;
  2140. .iconfont {
  2141. font-size: 40rpx;
  2142. }
  2143. }
  2144. .new-users {
  2145. padding-bottom: 0;
  2146. padding-bottom: constant(safe-area-inset-bottom);
  2147. padding-bottom: env(safe-area-inset-bottom);
  2148. }
  2149. .bottomTips{
  2150. }
  2151. </style>