index.vue 68 KB

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