charge.vue 47 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112
  1. <template>
  2. <view>
  3. <ujp-navbar title="开始充电" :is-back="isback">
  4. <view class="exchange " slot="right" @click="showmodal2=true">充电说明</view>
  5. </ujp-navbar>
  6. <view class="carImg" v-if="personInfo&&personInfo.userType!=2">
  7. <img @click="gotoLogin" src="@/assets/img/gologin/img.png">
  8. </view>
  9. <view v-else>
  10. <!-- 优惠 -->
  11. <view class="discounts" style="padding:0 36rpx;" v-if="bannerList.length">
  12. <u-swiper bg-color="#fff" mode="none" :img-mode="'scaleToFill'" height="160" :list="bannerList"
  13. @click="clickBanner" :name="'picUrl'">
  14. </u-swiper>
  15. </view>
  16. </view>
  17. <view class="recharge">
  18. <view class="title">
  19. <view class="left lefttitle">
  20. 请选择支付方式和充电金额
  21. </view>
  22. <!-- <view class="to-recharge" @click="show=true,recordId='',otherNum_f='',fee=0">
  23. 去充值
  24. </view> -->
  25. </view>
  26. <view class="card" @click="payValue=0" :class="{
  27. cardselect:payValue==0,
  28. cardno:payValue!=0
  29. }">
  30. <view class="cardgo">
  31. <view class="cardinfo">
  32. <img src="@/assets/img/riFill-check-fill.svg" alt="">
  33. </view>
  34. </view>
  35. <view class="title">先付后退</view>
  36. <p>充电结束后,余额自动退还;不享受<span style="color:#ff3d00;">会员充电折扣、平台各类优惠券</span>等福利</p>
  37. <view class="rechargeMain" v-show="payValue==0">
  38. <view class="recharge-item" @click="moneyActiveClass_n=(item.id)"
  39. :class="moneyActiveClass_n == item.id ? 'active' : ''" v-for="(item,index) in moneyListN"
  40. :key="item.id">
  41. {{item.name}}
  42. </view>
  43. </view>
  44. </view>
  45. <view class="card" @click="paySelectMethod(paySelectMethodValue)" :class="{
  46. cardselect:payValue==1||payValue==4,
  47. cardno:!(payValue==1||payValue==4)
  48. }">
  49. <view class="cardgo">
  50. <view class="cardinfo">
  51. <img src="@/assets/img/riFill-check-fill.svg" alt="">
  52. </view>
  53. </view>
  54. <view class="title">会员账户余额充电</view>
  55. <p v-show="!chargingFundsBl&&!(payValue==1||payValue==4)">当前余额{{user.balance>0?user.balance.toFixed(2):'0.00'}}元
  56. <span @click="paySelectShow()" style="color:#00B962;margin-left: 20px; ">去充值></span>
  57. </p>
  58. <p v-show="(payValue==1||payValue==4)">优先使用付款方式
  59. <span @click="paySelectShow()" style="color:#00B962;margin-left: 20px; ">去充值></span>
  60. </p>
  61. <view class="rechargeBalance" v-if="chargingFundsBl" >
  62. <view class="rechargeBalanceItem">账户余额{{user.balance>0?user.balance.toFixed(2):'0.00'}}元</view>
  63. <view class="rechargeBalanceItem" v-if="chargingFundsBl">|</view>
  64. <view class="rechargeBalanceItem" v-if="chargingFundsBl" >充电金{{user.chargingFunds>0?user.chargingFunds.toFixed(2):'0.00'}}元</view>
  65. </view>
  66. <view class="rechargeMain" v-if="chargingFundsBl" v-show="payValue==1||payValue==4">
  67. <view
  68. class=" recharge-item " @click="paySelectMethodValue=1" :class="payValue == 1? 'active' : ''" >
  69. 账户余额
  70. </view>
  71. <view
  72. class=" recharge-item " @click="paySelectMethodValue=4" :class="payValue == 4? 'active' : ''">
  73. 充电金
  74. </view>
  75. </view>
  76. <p v-if="chargingFundsBl" v-show="(payValue==1||payValue==4)" >充电时长</p>
  77. <view class="rechargeMain" v-show="payValue==1||payValue==4">
  78. <view @click="moneyClick(-1)" :class="!otherNum&&moneyActiveClass == -1? 'active' : ''"
  79. class=" recharge-item ">
  80. 充满自停
  81. </view>
  82. <view class="recharge-item" @click="moneyClick(item.id)"
  83. :class="!otherNum&&moneyActiveClass == item.id ? 'active' : ''"
  84. v-for="(item,index) in moneyList" :key="item.id">
  85. {{item.name}}元
  86. </view>
  87. <view class="recharge-item recharge-item2" :class="otherNum ? 'active' : ''" style="
  88. padding: 1px 0px;">
  89. <ujp-input v-model="otherNum" @input="ckInput" @focus="focus" type="digit" placeholder="其他金额" />
  90. </view>
  91. </view>
  92. </view>
  93. <view class="card" v-for="(companyItem,i) in companyList" :key="i" @click="paySelectMethod(2,companyItem)"
  94. :class="{
  95. cardselect:(payValue==2&&companyItem.enterpriseAccount.id==companyPaySelect.enterpriseAccount.id),
  96. cardno:!(payValue==2&&companyItem.enterpriseAccount.id==companyPaySelect.enterpriseAccount.id)
  97. }">
  98. <view class="cardgo">
  99. <view class="cardinfo">
  100. <img src="@/assets/img/riFill-check-fill.svg" alt="">
  101. </view>
  102. </view>
  103. <view class="title">{{companyItem.enterpriseAccount.entName}}账户余额充电</view>
  104. <p>余额{{companyItem.enterpriseAccount.totalAmount>0?companyItem.enterpriseAccount.totalAmount.toFixed(2):'0.00'}}元
  105. <span
  106. v-show="(payValue==2&&companyItem.enterpriseAccount.id==companyPaySelect.enterpriseAccount.id)"
  107. @click="companyCarSelectBl=true"
  108. style="color:#00B962;margin-left: 40rpx; ">{{companyPaySelect.car?companyPaySelect.car+'(更换)':'选择充电车辆>'}}</span>
  109. <span style="margin-left: 40rpx; "
  110. v-show="(payValue==2&&companyItem.enterpriseAccount.id==companyPaySelect.enterpriseAccount.id)"></span>
  111. </p>
  112. <view class="rechargeMain"
  113. v-show="(payValue==2&&companyItem.enterpriseAccount.id==companyPaySelect.enterpriseAccount.id)">
  114. <view @click="moneyClick(-1)" :class="!otherNum&&moneyActiveClass == -1? 'active' : ''"
  115. class=" recharge-item ">
  116. 充满自停
  117. </view>
  118. <view class="recharge-item recharge-item2" :class="otherNum ? 'active' : ''" style="
  119. padding: 1px 0px;">
  120. <ujp-input v-model="otherNum" @input="ckInput" @focus="focus" type="digit" placeholder="其他金额" />
  121. </view>
  122. </view>
  123. </view>
  124. <!-- 优惠券2 -->
  125. <view v-if="personInfo.userType == '1'&&0" class="greyTips" >
  126. 车主注册会员可享受至少5%优惠,并可快速进入会员注册页面
  127. </view>
  128. <!-- 入场车辆 -->
  129. <view class="member" :class="{
  130. 'cost-explain2':!submitForm.carNumber
  131. }">
  132. <view class="actively ">
  133. 入场车辆
  134. </view>
  135. <view class="type" @click="carDet()" >
  136. {{submitForm.carNumber?submitForm.carNumber:'填车牌号可减免部分停车费用'}}
  137. <img v-if="!submitForm.carNumber" src="@/assets/static/img/riLine-edit-box-line2.svg" alt="">
  138. </view>
  139. </view>
  140. <view class="member">
  141. <view class="actively">
  142. 优惠券
  143. </view>
  144. <view class="right" v-if="payValue=='0'">
  145. 先付后退不享受会员优惠活动
  146. </view>
  147. <view class="right" v-else-if="payValue=='2'">
  148. 企业单位用户不可使用优惠券
  149. </view>
  150. <view class="right" @click="chooseCoupons" v-else-if="selectObj.id">
  151. {{selectObj.threshold == 0 ? '无门槛' : '满'+selectObj.threshold.toFixed(2)+'元可用'}},
  152. <span class="price"
  153. v-if="selectObj.classify == '1'||selectObj.classify == '3'">抵扣{{selectObj.value.toFixed(2)}}元</span>
  154. <span class="price" v-if="selectObj.classify == '2'">
  155. <template v-if="selectObj.value==0">
  156. 服务费全免
  157. </template>
  158. <template v-else>
  159. 服务费{{selectObj.value}}折
  160. </template>
  161. </span>
  162. <view class="iconfont">&#xe600;</view>
  163. </view>
  164. <view class="right" @click="chooseCoupons" v-else-if="listlength">
  165. 未选择,剩余{{listlength}}张优惠券
  166. <view class="iconfont">&#xe600;</view>
  167. </view>
  168. <view class="right" @click="chooseCoupons" v-else>
  169. 无优惠券
  170. <view class="iconfont">&#xe600;</view>
  171. </view>
  172. </view>
  173. <!-- 会员活动 -->
  174. <view class="member">
  175. <view class="actively ">
  176. 会员活动
  177. </view>
  178. <view class="type" v-if="payValue=='0'">
  179. 先付后退不享受会员优惠活动
  180. </view>
  181. <view class="type" v-else-if="payValue=='2'">
  182. 企业单位用户不享受会员优惠活动
  183. </view>
  184. <template v-else-if="userCardBool">
  185. <view class="type" v-if="!vin" style="color: red;">
  186. vin码不一致
  187. </view>
  188. <view class="type" v-else-if="canUse">
  189. <template v-if="userCard.cardType==4">
  190. {{userCard.cardName}}
  191. {{userCard.monthlyRentName}}
  192. </template>
  193. <template v-else>
  194. {{userCard.classify==1?'折扣卡':''}}
  195. {{userCard.classify==2?'服务费'+(userCard.serviceFeeDiscountRate/10)+'折卡':''}}
  196. </template>
  197. </view>
  198. <view class="type" style="color: red;" v-else>
  199. 此充电站不支持折扣卡
  200. </view>
  201. </template>
  202. <template v-else>
  203. <view class="type" style="color:#999999" @click="gotoUrl('pages/discountCard/productDetails')">
  204. 未使用服务费6折卡<view class="iconfont">&#xe600;</view>
  205. </view>
  206. </template>
  207. </view>
  208. <view v-if="(cardList.length||userCard)&&(payValue=='1'||payValue=='4')" class="cardListView">
  209. <view class="cardListItemTitle" v-if="cardList.length>1" >点击切换其他卡</view>
  210. <view class="cardListItem card" v-for="(item,i) in cardList"
  211. :key="i" :class="{
  212. cardselect:userCard&&userCard.id==item.id,
  213. cardno:(!userCard||userCard.id!=item.id)
  214. }" @click="userCardBtn(item)" >
  215. <view class="cardgo">
  216. <view class="cardinfo">
  217. <img src="@/assets/img/riFill-check-fill.svg" alt="">
  218. </view>
  219. </view>
  220. <view class="cardListName" >
  221. {{item.cardName}}
  222. </view>
  223. <view class="cardListText" v-if="item.classify==1" >
  224. <view>充电服务费全免</view>
  225. <view>
  226. {{thisendTime(item.endTime)}}到期
  227. </view>
  228. </view>
  229. <view class="cardListText" v-if="item.classify==2" >
  230. <view>
  231. 已用{{item.chargedDegree?item.chargedDegree.toFixed(0):0.00}}度 / 共{{item.chargeDegreeLimit}}度
  232. </view>
  233. <view>
  234. {{thisendTime(item.endTime)}}到期
  235. </view>
  236. </view>
  237. </view>
  238. <p>点击可<span style="color:red">取消</span>使用<span style="color:#00b962">“服务费折扣卡”</span></p>
  239. </view>
  240. </view>
  241. <view class="botton">
  242. <view style=" display: flex;
  243. justify-content: center;">
  244. <u-checkbox-group >
  245. <u-checkbox
  246. active-color="green" shape="circle"
  247. v-model="contractSignTime"
  248. >我已阅读并同意</u-checkbox><span style="color: rgba(0, 185, 98, 1);" @click="gotoUrl('pages/article/details?code=YHXY')">《优电联盟用户使用协议》</span>
  249. </u-checkbox-group>
  250. </view>
  251. <button class="bottonBtn" @click="submit">开始充电</button>
  252. </view>
  253. <u-modal v-model="showmodal2" confirm-text="知道了" title="充电说明">
  254. <view style="padding: 10px;font-size: 32rpx;">
  255. 1.最终结算金额将以实际充入电量为准;<br />
  256. 2.充满自停模式需要您的余额不低于10元才可充电;<br />
  257. 3.充电金额请输入1元~500元的整数。实际充电金额与所选金额会略有出入(一般误差约几分钱);<br />
  258. 4.完成充电后,在满足条件的情况下,优惠券自动抵扣;提前结束充电则不使用优惠券并返还至您的卡包。<br />
  259. 5.先付后退模式,无法享受平台会员的服务费折扣、优惠券等优惠活动。<br />
  260. </view>
  261. </u-modal>
  262. <!-- <view class="but-box" style="margin-bottom: 20px;">
  263. <u-button
  264. style=" background-color: rgba(0, 185, 98, 100);
  265. color: rgba(255, 255, 255, 100);
  266. font-size: 16px;
  267. text-align: center;"
  268. @click="submit" shape="circle">开始充电</u-button>
  269. </view> -->
  270. <u-modal v-model="showmodal" :show-cancel-button="true" title="余额不足" confirm-text="前往充值"
  271. content="账户余额不足,充值成功后开始充电" @confirm="show=true"></u-modal>
  272. <u-popup v-model="companyCarSelectBl" :closeable="true" mode="bottom" border-radius="30">
  273. <view class="indexData5content">
  274. <view class="contentTitle">
  275. 选择充电车辆
  276. </view>
  277. <view
  278. v-if="companyPaySelect&&(companyPaySelect.carList&&companyPaySelect.carList.length==0||companyPaySelect.carList==null)"
  279. style=" text-align: center;">
  280. <img src="@/assets/static/img/暂无数据-缺省页.png" alt="">
  281. <p class="oldTextjp2">未分配车辆,请联系管理员</p>
  282. </view>
  283. <scroll-view v-else scroll-y="true" style="height: 520rpx;">
  284. <view style="padding-bottom: 30rpx;">
  285. <u-radio-group v-model="companyPaySelect.car" size="42">
  286. <view class="contentbody">
  287. <view v-for="(item,index) in companyPaySelect.carList"
  288. @click="companyPaySelect.car=(item.carNum),companyCarSelectBl = false;"
  289. class="contentItem" :key="index">
  290. <view class="span1">{{item.carNum}}</view>
  291. <view class="span2">
  292. <span v-show="!item.vin" style="color:#fff">aaa</span>
  293. <img v-show="item.vin" style="vertical-align: bottom;" width="20"
  294. src="@/assets/img/riLine-link-m.png" />
  295. <span v-show="item.vin" style="color:#999999 ">已关联Vin码</span>
  296. </view>
  297. <view class="span3">
  298. <u-radio style=" overflow: inherit;"
  299. @change="companyPaySelect.car=(item.carNum),companyCarSelectBl = false;"
  300. :name="item.carNum">
  301. <span style="color:#fff">.</span>
  302. </u-radio>
  303. </view>
  304. </view>
  305. </view>
  306. </u-radio-group>
  307. </view>
  308. </scroll-view>
  309. </view>
  310. </u-popup>
  311. <!-- 弹窗2 -->
  312. <!-- 弹窗 -->
  313. <template>
  314. <view>
  315. <u-popup v-model="show" mode="bottom">
  316. <view class="recharge" style="padding-bottom: 0;">
  317. <view class="title lefttitle ">选择充值金额
  318. <span class=" rightspan">当前余额
  319. <span style="color: red;">{{user.balance>0?user.balance.toFixed(2):'0.00'}}元</span>
  320. </span>
  321. </view>
  322. <p style="color: red; font-size: 28rpx;" v-show="selectItem.amountRemark">
  323. {{selectItem.amountRemark}}代金券,退余额时将扣除已使用的优惠券金额
  324. </p>
  325. <view class="rechargeMain">
  326. <view class="recharge-item"
  327. :class="!otherNum_f&&moneyActiveClass_f == item.id ? 'active' : ''"
  328. v-for="(item,index) in moneyList_f" :key="item.id" @click="moneyClick_f(item.id,item)">
  329. {{item.amountDesc?item.amountDesc:item.rechargeAmount+'元'}}
  330. <view class="amount" v-if="item.amountRemark">{{item.amountRemark}}</view>
  331. </view>
  332. </view>
  333. <p class="oldTextjp2" oldstyle="font-size:16px">其他充值金额</p>
  334. <view style="margin-bottom: 32px;">
  335. <view :class="otherNum_f? 'active' : ''" class="recharge-input self-stop"
  336. style="height: 100%;width: 100%;margin-bottom: 8px;">
  337. <ujp-input v-model="otherNum_f" @input="ckInput_f" @focus="focus" type="digit"
  338. :border="true" />
  339. </view>
  340. <view style="color: rgba(153, 153, 153, 100);
  341. font-size: 12px;
  342. text-align: left;
  343. font-family: AlibabaPuHui-regular;"><span style="color:red">*</span>金额范围为1元-500元</view>
  344. </view>
  345. <view class="recharge-btn transactionClass" style="margin-top: 60px;">
  346. <view>
  347. <u-checkbox-group>
  348. <u-checkbox
  349. active-color="green" v-model="checked" shape="circle"></u-checkbox>
  350. </u-checkbox-group>
  351. 我已阅读并同意<span @click="gotoUrl('pages/article/details?code=CZXY')"
  352. style="color:#00B962">《充值协议》</span>
  353. </view>
  354. <u-button class="success-btn" shape="circle" type="success" @click="rechargeNow"
  355. style="margin-top: 12px;margin-bottom: 16px;">
  356. <span>微信充值</span>
  357. </u-button>
  358. </view>
  359. </view>
  360. </u-popup>
  361. </view>
  362. </template>
  363. <u-modal v-model="contractSignTimeBl"
  364. :show-confirm-button="true" :show-title="false" :show-cancel-button="true" confirm-color="rgba(0, 185, 98, 1)"
  365. cancel-text="放弃充电" confirm-text="同意并充电" @confirm="contractSignTimeSubmit()"
  366. >
  367. <view class="slot-content" style="padding:40rpx; text-align: center;margin-top: 10rpx;">
  368. 我已阅读并同意<br/>
  369. <span style="color: rgba(0, 185, 98, 1);" @click="gotoUrl('pages/article/details?code=YHXY')">《优电联盟用户使用协议》</span>
  370. </view>
  371. </u-modal>
  372. <quickRegistration v-if="personInfo.userType == '1'" @login="loginMethod" :carNum="carNumber" ></quickRegistration>
  373. </view>
  374. </template>
  375. <script>
  376. import * as API from '@/apis/chargeProcess.js'
  377. import * as API_index from '@/apis/index.js'
  378. import * as userApi from '@/apis/user.js'
  379. import * as newsApi from '@/apis/news.js'
  380. import * as API_finance from '@/apis/finance.js'
  381. import {
  382. wxPayJs
  383. } from '@/utils/wxpay'
  384. import {
  385. newDate,daysDistance
  386. } from '@/utils'
  387. import * as Pay from '@/apis/weixin.js'
  388. // import { contentStore } from 'core/core.model'
  389. import quickRegistration from '@/components/QuickRegistration.vue'
  390. export default {
  391. components: {
  392. quickRegistration
  393. },
  394. data() {
  395. return {
  396. fee: 0,
  397. recordId: "",
  398. show2: false,
  399. stationId: "",
  400. elderMode: false,
  401. isback: true,
  402. show: false,
  403. moneyActiveClass_n: "50",
  404. moneyActiveClass: "-1",
  405. moneyActiveClass_f: "-1",
  406. contractSignTime:"",
  407. contractSignTimeBl:false,
  408. detail: {},
  409. couponsuse: '',
  410. showmodal: false,
  411. showmodal2: false,
  412. //提交信息
  413. //提交信息
  414. submitForm_f: {
  415. //paytype:'YE',
  416. },
  417. submitForm: {
  418. deviceNo: '',
  419. channelNo: '',
  420. carNumber: '',
  421. chargeStrategy: 2,
  422. amount: 0
  423. //paytype:'YE',
  424. },
  425. uuid: 0,
  426. user: {},
  427. companyCarSelectBl: false,
  428. companyList: [
  429. ],
  430. companyPaySelect: {
  431. id: "",
  432. car: "aaa"
  433. },
  434. otherNum_f: '',
  435. otherNum: '',
  436. moneyList_f: [],
  437. paySelect: true,
  438. payName: "",
  439. payValueTemp: 0,
  440. payValue: 0,
  441. payList: [{
  442. name: "先付后退",
  443. tips: "游客不享受平台优惠活动",
  444. value: "1",
  445. select: false,
  446. }, {
  447. name: "个人账户支付",
  448. tips: "可使用折扣卡、优惠券、折扣卷等",
  449. value: "2",
  450. select: false,
  451. }, {
  452. name: "单位账户支付",
  453. tips: "账户余额:99999元",
  454. value: "3",
  455. select: false,
  456. }, {
  457. name: "充电金",
  458. tips: "账户余额:99999元",
  459. value: "4",
  460. select: false,
  461. }, {
  462. name: "充电金",
  463. tips: "账户余额:99999元",
  464. value: "4",
  465. select: false,
  466. }],
  467. moneyList: [
  468. {
  469. id: '10',
  470. name: '10'
  471. },
  472. {
  473. id: '20',
  474. name: '20'
  475. },
  476. {
  477. id: '50',
  478. name: '50'
  479. },
  480. {
  481. id: '100',
  482. name: '100'
  483. },
  484. ],
  485. moneyListN: [{
  486. id: '10',
  487. name: '10元'
  488. },
  489. {
  490. id: '20',
  491. name: '20元'
  492. },
  493. {
  494. id: '50',
  495. name: '50元'
  496. }
  497. ],
  498. userCard: null,
  499. canUse: false,
  500. selectObj: {},
  501. value: "",
  502. // 优惠券
  503. listlength: 0,
  504. vin: true,
  505. bannerList: [],
  506. checked: true,
  507. selectItem: {},
  508. personInfo: {},
  509. carNumber: "",
  510. show3: false,
  511. cardList:[],
  512. startMode:"",
  513. paySelectMethodValue:1,
  514. chargingFundsBl:false,
  515. id:""
  516. }
  517. },
  518. computed: {
  519. userCardBool() {
  520. if (this.userCard) {
  521. var date = new Date().getTime()
  522. var reg = new RegExp('-', 'gi')
  523. var str = this.userCard.endTime;
  524. //console.log(str.replace(reg,'/'))
  525. var date2 = new Date(str.replace(reg, '/')).getTime();
  526. if (date < date2) {
  527. return true;
  528. }
  529. }
  530. return false
  531. }
  532. },
  533. onLoad(op) {
  534. if(op.startMode){
  535. this.startMode=op.startMode
  536. }
  537. if(op.id){
  538. this.id=op.id
  539. }
  540. this.uuid = new Date().getTime();
  541. this.stationId = op.stationId;
  542. if (op.deviceNo) {
  543. this.submitForm.deviceNo = op.deviceNo;
  544. this.submitForm.channelNo = op.gun;
  545. this.carNumber = op.carNumber;
  546. this.submitForm.carNumber = op.carNumber;
  547. this.carhelp.setGunIdCharge(this.submitForm);
  548. }
  549. if (op.vin == 'no') {
  550. this.vin = false;
  551. }
  552. if (op.isback) {
  553. this.isback = false;
  554. }
  555. this.useCoupon()
  556. var couponsuse = "充电结束后满足金额即可生效,提前结束充电则优惠券不生效并返回"
  557. // img="https://yktwechat.xiaoxinda.com/config/xxd2021.jpg"
  558. if (couponsuse) {
  559. this.couponsuse = couponsuse
  560. }
  561. this.init()
  562. },
  563. onReady() {
  564. this.getBannerInfo("charge-start")
  565. this.elderMode = this.carhelp.get('getElderModeClass') == '长辈模式';
  566. if (this.elderMode)
  567. this.theme('elder')
  568. else
  569. this.theme('standard')
  570. this.loginMethod()
  571. },
  572. onShow() {
  573. this.personInfo = this.carhelp.getPersonInfo()
  574. var obj = this.carhelp.get("chooseCoupons");
  575. if (obj) {
  576. if (obj.uuid == this.uuid) {
  577. this.selectObj = obj.selectObj;
  578. }
  579. }
  580. this.getHomePage()
  581. },
  582. methods: {
  583. userCardBtn(item){
  584. if(this.userCard&&this.userCard.id==item.id){
  585. this.userCard=null
  586. uni.showToast({
  587. title: "已经取消选中"
  588. })
  589. }else{
  590. this.userCard=item
  591. }
  592. },
  593. carDet(t) {
  594. if(this.submitForm.carNumber){
  595. return
  596. }
  597. this.onShowRole = true
  598. var url="/pages/user/car/carDet?jpcode=jp_team51_charge_id:A_" + this.id
  599. uni.navigateTo({
  600. url: url
  601. })
  602. },
  603. loginMethod(form){
  604. this.personInfo = this.carhelp.getPersonInfo()
  605. // if(plus){
  606. // this.userCard=plus.userCard;
  607. // }
  608. if (this.personInfo && this.personInfo.userType == "1") {
  609. this.show3 = true
  610. }
  611. this.personInfo = this.carhelp.getPersonInfo()
  612. if (this.personInfo.userType == "1") {
  613. this.payValueTemp = 0;
  614. this.payValue = 0;
  615. } else {
  616. this.payValueTemp = 1;
  617. var payValueDefault = this.carhelp.get("payValueDefault");
  618. if(this.user&&this.user.chargingFunds>0){
  619. payValueDefault="4"
  620. }
  621. this.payValue = 1;
  622. if (payValueDefault == "1" || payValueDefault == "0") {
  623. this.payValue = payValueDefault;
  624. }
  625. if (payValueDefault == "1" || payValueDefault == "4") {
  626. this.paySelectMethodValue = payValueDefault;
  627. this.payValue = payValueDefault;
  628. }
  629. if(payValueDefault==4){
  630. this.chargingFundsBl=true;
  631. }
  632. }
  633. this.payName = this.payList[this.payValue].name;
  634. this.useCoupon()
  635. if(form){
  636. this.submitForm.carNumber=form.carNumber
  637. }
  638. },
  639. thisdaysDistance(endTime){
  640. var date=new Date()
  641. var date2=newDate(endTime);
  642. return daysDistance(date,date2)
  643. },
  644. getChargeList() {
  645. uni.showLoading({
  646. title: "加载中",
  647. mask: true,
  648. })
  649. API_index.personCardList({
  650. }).then((res) => {
  651. uni.hideLoading();
  652. this.cardList=res.data.cardList
  653. }).catch(error => {
  654. uni.showToast({
  655. title: error,
  656. icon: "none"
  657. })
  658. })
  659. },
  660. gotoLogin() {
  661. this.onShowRole = true
  662. if (false) {
  663. } else {
  664. uni.navigateTo({
  665. url: "/pages/login/login?jpcode=jp_team51_charge_id:A_" + this.submitForm.deviceNo
  666. })
  667. }
  668. },
  669. paySelectShow() {
  670. if (this.personInfo.userType == "1") {
  671. } else {
  672. this.show = true;
  673. this.recordId = '';
  674. this.otherNum_f = '';
  675. this.fee = 0
  676. }
  677. },
  678. //companyPaySelect
  679. paySelectCompany() {
  680. },
  681. paySelectMethod(value, company) {
  682. console.log(value)
  683. if (this.personInfo.userType == "1") {
  684. uni.showToast({
  685. title: "游客模式只支持“先付后退”"
  686. })
  687. } else {
  688. this.payValue = value
  689. if (value == 2) {
  690. this.companyPaySelect = company
  691. if (company.carList && company.carList.length == 1) {
  692. //this.companyPaySelect=entRegList[0]
  693. this.companyPaySelect.car = company.carList[0].carNum;
  694. }
  695. }
  696. this.$forceUpdate()
  697. }
  698. },
  699. moneyClick_f(index, item) {
  700. this.otherNum_f = '';
  701. this.moneyActiveClass_f = index;
  702. if (item) {
  703. this.selectItem = item;
  704. // if(item.imgUrl){
  705. // this.selectImg=item
  706. // }
  707. }
  708. },
  709. rechargeNow2() {
  710. //先付后退
  711. this.submitForm_f = {};
  712. var fee = 0;
  713. this.submitForm_f.amount = this.fee;
  714. uni.showLoading({
  715. title: "加载中",
  716. mask: true,
  717. })
  718. if (this.recordId) {
  719. this.submitForm_f.recordId = this.recordId
  720. }
  721. //(this.submitForm)
  722. this.wxpy()
  723. },
  724. rechargeNow() {
  725. if (!this.checked) {
  726. uni.showToast({
  727. title: "请同意《充值协议》后进行充值"
  728. })
  729. return
  730. }
  731. this.submitForm_f = {};
  732. var fee = 0;
  733. if (!this.otherNum_f) {
  734. this.submitForm_f.chargingMarketingId = this.selectItem.id;
  735. fee = this.selectItem.rechargeAmount
  736. } else {
  737. this.submitForm_f.amount = this.otherNum_f
  738. fee = this.otherNum_f
  739. }
  740. if (this.fee) {
  741. var thisfee = this.fee
  742. if (this.fee > parseFloat(fee)) {
  743. uni.showToast({
  744. title: `最少充值${thisfee}元才能启动充电`
  745. })
  746. return
  747. }
  748. }
  749. uni.showLoading({
  750. title: "加载中",
  751. mask: true,
  752. })
  753. if (this.recordId) {
  754. this.submitForm_f.recordId = this.recordId
  755. }
  756. //(this.submitForm)
  757. this.wxpy()
  758. },
  759. wxpy() {
  760. var obj = {
  761. ...this.submitForm_f
  762. }
  763. if (obj.amount) {
  764. for (var i in this.moneyList_f) {
  765. var item = this.moneyList_f[i]
  766. if (item.rechargeAmount == obj.amount) {
  767. delete obj.amount;
  768. obj.chargingMarketingId = item.id
  769. break
  770. }
  771. }
  772. }
  773. Pay.wxpay(obj).then((response) => {
  774. if (!response.result) {
  775. uni.showToast({
  776. title: response.message
  777. })
  778. return
  779. }
  780. var data = response.data
  781. uni.hideLoading()
  782. //("Pay+"+new Date().getTime())
  783. wxPayJs(data);
  784. }).catch(error => {
  785. uni.showToast({
  786. title: error
  787. })
  788. })
  789. },
  790. focus() {
  791. console.log(0)
  792. uni.pageScrollTo({
  793. scrollTop: 999999,
  794. duration: 0
  795. })
  796. },
  797. init() {
  798. var data = {
  799. type: 2,
  800. };
  801. API_finance.marketingData(data).then((res) => {
  802. this.moneyList_f = res.data.chargingMarketingList
  803. if (this.moneyList_f.length > 0) {
  804. this.selectItem = this.moneyList_f[0];
  805. this.moneyActiveClass_f = this.moneyList_f[0].id
  806. //(this.moneyActiveClass)
  807. }
  808. var list = res.data.priceList
  809. if (list.length) {
  810. this.moneyListN = [];
  811. for (var i in list) {
  812. this.moneyListN.push({
  813. id: list[i],
  814. name: list[i] + "元"
  815. })
  816. }
  817. this.moneyActiveClass_n = list[0]
  818. }
  819. }).catch(error => {
  820. uni.showToast({
  821. title: error
  822. })
  823. })
  824. },
  825. clickBanner(index) {
  826. var mod = this.bannerList[index]
  827. if (mod.linkUrl.indexOf('http') == 0) {
  828. window.location = mod.linkUrl;
  829. } else if (mod.linkUrl.indexOf('#/') == 0) {
  830. if (mod.linkUrl.indexOf("?") == -1) {
  831. mod.linkUrl += '?';
  832. }
  833. //window.location=mod.linkUrl;
  834. var url = mod.linkUrl.split("#")[1]
  835. //window.location = mod.clickUrl;
  836. uni.navigateTo({
  837. url: url
  838. })
  839. } else if (mod.linkUrl == '#' || mod.linkUrl == '') {
  840. } else {
  841. uni.navigateTo({
  842. url: mod.linkUrl
  843. })
  844. }
  845. },
  846. getBannerInfo(code) {
  847. newsApi.getBannerInfo(code).then((res) => {
  848. this.bannerList = res.data;
  849. // document.getElementsByClassName("uni-swiper-wrapper")[0].parentNode.style="background-color: rgb(255, 255, 255); height: 300px;"
  850. }).catch(error => {
  851. uni.showToast({
  852. title: error,
  853. icon: "none"
  854. })
  855. })
  856. },
  857. getPile() {
  858. },
  859. theme(type) {
  860. if (type == 'elder') {
  861. document.getElementsByTagName('body')[0].setAttribute('data-theme', type);
  862. } else {
  863. document.getElementsByTagName('body')[0].setAttribute('data-theme', type);
  864. }
  865. },
  866. chooseCoupons() {
  867. this.submitInit()
  868. this.gotoUrl('pages/user/coupon/chooseCoupons?uuid=' + this.uuid + "&amount=" + this.submitForm.amount +
  869. "&stationId=" + this.stationId)
  870. },
  871. ckInput_f(text) {
  872. if (text.indexOf('.') > 0) {
  873. var k = text.split(".")[1]
  874. if (k.length >= 3) {
  875. this.$nextTick(() => {
  876. text = parseFloat(text).toFixed(2);
  877. this.otherNum_f = text
  878. })
  879. }
  880. }
  881. var t = Number(text);
  882. if (t < 1) {
  883. this.$nextTick(() => {
  884. this.otherNum_f = '';
  885. })
  886. }
  887. if (t > 500) {
  888. this.$nextTick(() => {
  889. this.otherNum_f = 500;
  890. })
  891. }
  892. },
  893. ckInput(text) {
  894. if (text.indexOf('.') > 0) {
  895. this.$nextTick(() => {
  896. this.otherNum = text.substring(0, text.indexOf('.'))
  897. uni.showToast({
  898. title: "请输入正整数"
  899. })
  900. })
  901. }
  902. var t = Number(text);
  903. if (t < 1) {
  904. this.$nextTick(() => {
  905. this.otherNum = '';
  906. })
  907. }
  908. if (t > 500) {
  909. this.$nextTick(() => {
  910. this.otherNum = 500;
  911. })
  912. }
  913. this.selectJudge();
  914. },
  915. moneyClick(index) {
  916. this.otherNum = ''
  917. this.moneyActiveClass = index;
  918. this.selectJudge();
  919. },
  920. selectJudge() {
  921. this.submitInit()
  922. if (this.submitForm.amount == 0) {
  923. return
  924. }
  925. if (this.selectObj.id && this.selectObj.threshold > this.submitForm.amount) {
  926. uni.showToast({
  927. title: "请重新选择优惠券"
  928. })
  929. this.selectObj = {}
  930. }
  931. },
  932. radioChange(e) {},
  933. confirm() {
  934. ////(JSON.stringify(this.submitForm))
  935. if (this.payValue == 1||this.payValue == 4) {
  936. if (this.selectObj.id) {
  937. this.submitForm.userCouponId = this.selectObj.id
  938. }
  939. if (this.userCardBool && this.canUse && this.vin) {
  940. this.submitForm.userCardId = this.userCard.id
  941. }
  942. } else {
  943. this.submitForm.userCouponId = ""
  944. this.submitForm.userCardId = ""
  945. }
  946. if (this.payValue == 2) {
  947. if (!this.companyPaySelect.car) {
  948. uni.showToast({
  949. title: '请选择充车辆'
  950. })
  951. return
  952. }
  953. this.submitForm.vipUserId = this.companyPaySelect.vipUser.id;
  954. this.submitForm.carNumber = this.companyPaySelect.car;
  955. } else {
  956. this.submitForm.carNumber = this.carNumber;
  957. this.submitForm.vipUserId = ""
  958. }
  959. uni.showLoading({
  960. title: "加载中",
  961. mask: true,
  962. })
  963. this.carhelp.set("payValueDefault", this.payValue);
  964. if (this.payValue == 2) {
  965. this.carhelp.set("payValueDefault3", {
  966. carNumber: this.companyPaySelect.car,
  967. companyId: this.companyPaySelect.enterpriseAccount.id,
  968. });
  969. }
  970. if(this.startMode){
  971. this.submitForm.startMode=this.startMode; //判断充电入口
  972. }
  973. //this.submitForm.deviceNo = this.detail.deviceNo;
  974. API.startCarCharging(this.submitForm).then((res) => {
  975. //(JSON.stringify(this.res))
  976. if (res.data.status == "5") {
  977. uni.hideLoading()
  978. if (this.submitForm.payType == "1") {
  979. this.recordId = res.data.recordId;
  980. this.fee = res.data.fee;
  981. this.rechargeNow2() //先付后退
  982. } else {
  983. if (this.payValue == 2) {
  984. uni.showToast({
  985. title: "余额不足,请联系企业单位人员"
  986. })
  987. } else {
  988. this.showmodal = true;
  989. this.recordId = res.data.recordId;
  990. var fee = res.data.fee;
  991. this.fee = (fee - this.user.balance).toFixed(2);
  992. this.otherNum_f = this.fee;
  993. }
  994. }
  995. } else {
  996. this.gotoUrl("pages/searchPile/chargeProcess/dcCharging?id=" + res.data.recordId);
  997. }
  998. }).catch((error)=> {
  999. uni.hideLoading()
  1000. if (error == '用户账户余额不足!') {
  1001. } else {
  1002. // uni.showToast({
  1003. // title: error
  1004. // })
  1005. uni.showModal({
  1006. title: "提示",
  1007. content: error,
  1008. //showCancel: false,
  1009. confirmText: "首页>找桩",
  1010. success: res1 => {
  1011. if (res1.confirm) {
  1012. //this.alerttipsCk()
  1013. uni.navigateTo({
  1014. url: '/pages/searchPile/searchPile'
  1015. })
  1016. } else if (res1.cancel) {
  1017. //('用户点击取消');
  1018. }
  1019. }
  1020. })
  1021. }
  1022. })
  1023. },
  1024. thisendTime(endTime){
  1025. if(endTime){
  1026. var reg=new RegExp('-','gi')
  1027. var str=endTime.substring(0,10).replace(reg,'.')
  1028. return str
  1029. }
  1030. return ''
  1031. },
  1032. getHomePage() {
  1033. uni.showLoading({
  1034. title: "加载中",
  1035. mask: true,
  1036. })
  1037. API.userCard({
  1038. stationId: this.stationId
  1039. }).then((res) => {
  1040. this.userCard = res.data.regUserCard
  1041. this.canUse = res.data.canUse
  1042. //this.user = res.data
  1043. API.personalCenter({
  1044. stationId: this.stationId
  1045. }).then((res2) => {
  1046. this.user = res2.data
  1047. this.contractSignTime=res2.data.regUser.contractSignTime
  1048. if(this.user.chargingFunds){
  1049. this.chargingFundsBl=true;
  1050. }
  1051. var entRegList = res2.data.entRegList;
  1052. this.companyList = []
  1053. for (var i in entRegList) {
  1054. var item = entRegList[i]
  1055. if (item.enterpriseAccount) {
  1056. this.companyList.push(item)
  1057. }
  1058. }
  1059. this.isReady = true;
  1060. uni.hideLoading()
  1061. var payValueDefault = this.carhelp.get("payValueDefault");
  1062. if (payValueDefault == "2") {
  1063. var payValueDefault3 = this.carhelp.get("payValueDefault3");
  1064. for (var i in this.companyList) {
  1065. var item = this.companyList[i]
  1066. if (item.enterpriseAccount.id == payValueDefault3.companyId) {
  1067. this.companyPaySelect = item;
  1068. for (var j in item.carList) {
  1069. var car = item.carList[j]
  1070. if (car.carNum == payValueDefault3.carNumber) {
  1071. this.companyPaySelect.car = payValueDefault3.carNumber;
  1072. this.payValue = payValueDefault;
  1073. }
  1074. }
  1075. }
  1076. }
  1077. }
  1078. this.getChargeList()
  1079. this.loginMethod()
  1080. }).catch(error => {
  1081. uni.showToast({
  1082. title: error
  1083. })
  1084. })
  1085. }).catch(error => {
  1086. uni.showToast({
  1087. title: error
  1088. })
  1089. })
  1090. },
  1091. useCoupon() {
  1092. var obj = {
  1093. status: 0,
  1094. stationId: this.stationId,
  1095. hideCardCoupon: 1
  1096. }
  1097. if (this.userCardBool) {
  1098. obj.userCardId = this.userCard.id
  1099. }
  1100. userApi.couponList(obj).then((res) => {
  1101. this.listlength = res.data.recordsTotal;
  1102. }).catch(error => {
  1103. uni.showToast({
  1104. title: error
  1105. })
  1106. })
  1107. },
  1108. submitInit() {
  1109. if (this.moneyActiveClass == -1 && !this.otherNum) {
  1110. this.submitForm.chargeStrategy = 0;
  1111. this.submitForm.amount = 0
  1112. } else {
  1113. this.submitForm.chargeStrategy = 2;
  1114. if (this.otherNum) {
  1115. this.submitForm.amount = this.otherNum
  1116. } else {
  1117. this.submitForm.amount = this.moneyActiveClass
  1118. }
  1119. }
  1120. },
  1121. contractSignTimeSubmit(){
  1122. this.contractSignTime=true;
  1123. this.submit()
  1124. },
  1125. updateContractSignTime(){
  1126. if(this.user&&this.user.regUser&&!this.user.regUser.contractSignTime){
  1127. API.updateContractSignTime({
  1128. openId:this.carhelp.getOpenId()
  1129. }).then((res) => {
  1130. }).catch(error => {
  1131. uni.showToast({
  1132. title: error
  1133. })
  1134. })
  1135. }
  1136. },
  1137. submit() {
  1138. if(!this.contractSignTime){
  1139. this.contractSignTimeBl=true;
  1140. return
  1141. }
  1142. if (!this.submitForm.channelNo) {
  1143. uni.showToast({
  1144. title: '请先选择充电通道'
  1145. })
  1146. return
  1147. }
  1148. this.submitForm.payType = this.payList[this.payValue].value;
  1149. if (this.submitForm.payType == "1") {
  1150. this.submitForm.amount = this.moneyActiveClass_n
  1151. this.submitForm.chargeStrategy = 2;
  1152. } else {
  1153. this.submitInit()
  1154. }
  1155. this.updateContractSignTime()
  1156. this.confirm()
  1157. },
  1158. }
  1159. }
  1160. </script>
  1161. <style>
  1162. page {
  1163. background-color: #fff;
  1164. }
  1165. </style>
  1166. <style lang="scss" scoped>
  1167. .exchange {
  1168. margin-right: 32rpx;
  1169. color: rgba(119, 119, 119, 100);
  1170. //font-size: 24rpx;
  1171. font-size: 32rpx;
  1172. //margin-right: 6rpx;
  1173. }
  1174. .rightspan {
  1175. float: right;
  1176. }
  1177. .indexData5content {
  1178. padding: 40rpx 40rpx;
  1179. .contentTitle {
  1180. color: #333333;
  1181. font-size: 40rpx;
  1182. font-weight: bold;
  1183. margin-bottom: 16rpx;
  1184. }
  1185. .contentbody {
  1186. width: 100%;
  1187. display: block;
  1188. .contentItem {
  1189. border-bottom: 1px solid #ededed;
  1190. padding: 12rpx 0;
  1191. font-size: 32rpx;
  1192. display: flex;
  1193. width: 100%;
  1194. .span1 {
  1195. padding-top: 8rpx;
  1196. width: 50%;
  1197. }
  1198. .span2 {
  1199. padding-top: 8rpx;
  1200. width: 35%;
  1201. }
  1202. .span3 {
  1203. padding-top: 8rpx;
  1204. padding-left: 8rpx;
  1205. width: 10%;
  1206. }
  1207. }
  1208. }
  1209. }
  1210. .textinfo {
  1211. padding: 40rpx;
  1212. font-size: 24rpx !important;
  1213. color: #999999;
  1214. p {
  1215. font-size: 32rpx !important;
  1216. color: #101010;
  1217. font-weight: bold;
  1218. }
  1219. }
  1220. .lefttitle {
  1221. font-weight: bold;
  1222. font-size: 32rpx
  1223. }
  1224. @import "@/_theme.scss";
  1225. .listlength {
  1226. float: right;
  1227. padding-right: 20rpx;
  1228. }
  1229. /deep/.u-drawer-content {
  1230. border-radius: 10px 10px 0 0
  1231. }
  1232. /deep/.u-radio-group {
  1233. width: 100%;
  1234. }
  1235. /deep/.u-radio {
  1236. position: relative;
  1237. }
  1238. /deep/.u-radio__icon-wrap {
  1239. position: absolute;
  1240. right: 0;
  1241. }
  1242. .recharge-item2 {
  1243. @include themeify {
  1244. font-size: themed('font-size2') !important;
  1245. }
  1246. /* font-size: 14px !important;*/
  1247. color: #999999;
  1248. }
  1249. .paySelect {
  1250. padding: 32rpx;
  1251. .title {
  1252. font-size: 40rpx
  1253. }
  1254. p {
  1255. width: 100%;
  1256. span {
  1257. color: #666;
  1258. }
  1259. .u-radio__label {
  1260. color: #333333;
  1261. }
  1262. .u-radio {
  1263. width: 100% !important;
  1264. ;
  1265. }
  1266. color: #333333;
  1267. margin-top: 16rpx;
  1268. font-size:32rpx;
  1269. }
  1270. }
  1271. .recharge {
  1272. padding: 32rpx;
  1273. padding-bottom: 250rpx;
  1274. .title {
  1275. @include themeify {
  1276. font-size: themed('font-size3');
  1277. }
  1278. /* font-size: 16px;*/
  1279. position: relative;
  1280. }
  1281. p {
  1282. color: #666;
  1283. margin-top: 4px;
  1284. }
  1285. .self-stop.active {
  1286. background-color: #EFFFF7;
  1287. border-color: #00B962;
  1288. color: #00B962;
  1289. }
  1290. .rechargeMain {
  1291. display: flex;
  1292. flex-wrap: wrap;
  1293. // justify-content: space-between;
  1294. margin-top: 24rpx;
  1295. margin-bottom: 10rpx;
  1296. .recharge-item {
  1297. .u-input {
  1298. text-align: center !important;
  1299. }
  1300. width: 31%;
  1301. border: 1px solid #e3e3e3;
  1302. padding: 20rpx 0;
  1303. border-radius: 4px;
  1304. text-align: center;
  1305. margin-bottom: 20rpx;
  1306. position: relative;
  1307. margin-left: 10rpx;
  1308. @include themeify {
  1309. font-size: themed('font-size3');
  1310. }
  1311. /* font-size: 16px;*/
  1312. }
  1313. .active {
  1314. background-color: #EFFFF7;
  1315. border-color: #00B962;
  1316. color: #00B962;
  1317. }
  1318. }
  1319. .self-stop {
  1320. width: 105px;
  1321. /* height: 48px;
  1322. line-height: 48px;*/
  1323. border-radius: 4px;
  1324. color: #101010;
  1325. @include themeify {
  1326. font-size: themed('font-size3');
  1327. height: themed('font-size19');
  1328. line-height: themed('font-size19')
  1329. }
  1330. /* font-size: 16px;*/
  1331. text-align: center;
  1332. font-family: Arial;
  1333. border: 1px solid rgba(227, 227, 227, 100);
  1334. margin-top: 12px;
  1335. }
  1336. }
  1337. .recharge-input {
  1338. margin-top: 8px;
  1339. margin-bottom: 32px;
  1340. }
  1341. .recharge-radio {
  1342. margin-top: 10px;
  1343. .recharge-radio-item {
  1344. display: flex;
  1345. align-items: center;
  1346. }
  1347. .recharge-radio-name {
  1348. margin-left: 8px;
  1349. }
  1350. }
  1351. .but-box {
  1352. width: 89.3%;
  1353. height: 44px;
  1354. margin: 0 auto;
  1355. position: fixed;
  1356. bottom: 0;
  1357. right: 0;
  1358. left: 0;
  1359. }
  1360. //优惠券
  1361. .discounts {
  1362. margin-top: 10px;
  1363. width: 100%;
  1364. .title {
  1365. width: 100%;
  1366. .title-1 {
  1367. /* height: 22px;*/
  1368. color: rgba(16, 16, 16, 100);
  1369. @include themeify {
  1370. font-size: themed('font-size3');
  1371. height: themed('font-size6');
  1372. }
  1373. /* font-size: 16px;*/
  1374. }
  1375. .title-2 {
  1376. margin-left: 4px;
  1377. @include themeify {
  1378. font-size: themed('font-size2');
  1379. line-height: themed('font-size5');
  1380. }
  1381. /* font-size: 14px;
  1382. line-height: 20px;*/
  1383. }
  1384. .title-3 {
  1385. float: right;
  1386. @include themeify {
  1387. font-size: themed('font-size3');
  1388. line-height: themed('font-size5');
  1389. }
  1390. /* height: 19px;
  1391. font-size: 16px;*/
  1392. }
  1393. }
  1394. .select {
  1395. position: relative;
  1396. /deep/.u-radio {
  1397. padding: 36rpx 32rpx;
  1398. margin-top: 12px;
  1399. width: 100%;
  1400. height: 48px;
  1401. border-radius: 4px;
  1402. background-color: rgba(255, 255, 255, 100);
  1403. text-align: center;
  1404. border: 1px solid rgba(227, 227, 227, 100);
  1405. position: relative;
  1406. }
  1407. // /deep/.u-radio:nth-child(3) {
  1408. //
  1409. // }
  1410. /deep/.u-radio__icon-wrap {
  1411. left: 32rpx;
  1412. background-color: #fff;
  1413. }
  1414. /deep/.u-radio__label {
  1415. margin-left: 40px;
  1416. }
  1417. }
  1418. .explain {
  1419. width: 64px;
  1420. /* height: 24px;
  1421. line-height: 24px;*/
  1422. position: absolute;
  1423. top: 10px;
  1424. right: 12px;
  1425. border-radius: 4px;
  1426. background-color: rgba(255, 255, 255, 100);
  1427. text-align: center;
  1428. border: 1px solid rgba(227, 227, 227, 100);
  1429. color: rgba(0, 185, 98, 100);
  1430. /* font-size: 12px;*/
  1431. @include themeify {
  1432. font-size: themed('font-size1');
  1433. line-height: themed('font-size7');
  1434. height: themed('font-size7');
  1435. }
  1436. }
  1437. }
  1438. // 优惠券2
  1439. .discounts2 {
  1440. margin-top: 10px;
  1441. width: 100%;
  1442. display: flex;
  1443. justify-content: space-between;
  1444. .left {
  1445. /* width: 70px;*/
  1446. // height: 20px;
  1447. color: rgba(16, 16, 16, 100);
  1448. /* font-size: 20px;*/
  1449. @include themeify {
  1450. width: 160rpx;
  1451. font-size: 40rpx;
  1452. }
  1453. }
  1454. .right {
  1455. /*
  1456. height: 16px;
  1457. line-height: 28px;*/
  1458. color: rgba(255, 61, 0, 100);
  1459. @include themeify {
  1460. font-size: themed('font-size3');
  1461. height: themed('font-size3');
  1462. line-height: themed('font-size9');
  1463. }
  1464. /* font-size: 16px;*/
  1465. text-align: right;
  1466. display: flex;
  1467. }
  1468. .iconfont {
  1469. @include themeify {
  1470. font-size: themed('font-size7');
  1471. line-height: themed('font-size10');
  1472. }
  1473. /* line-height: 29px;*/
  1474. text-align: center;
  1475. color: #b3b3b3;
  1476. /* font-size: 24px;*/
  1477. }
  1478. }
  1479. // 会员活动
  1480. .member {
  1481. margin-top: 24rpx;
  1482. display: flex;
  1483. justify-content: space-between;
  1484. flex-wrap: wrap;
  1485. align-items: center;
  1486. .actively {
  1487. color: rgba(119, 119, 119, 1);
  1488. font-size: 36rpx;
  1489. }
  1490. .type,
  1491. .right {
  1492. color: rgba(16, 18, 18, 100);
  1493. font-size: 36rpx;
  1494. //line-height: 28px;
  1495. padding-right: 10px;
  1496. display: flex;
  1497. align-items: center;
  1498. }
  1499. .iconfont {
  1500. @include themeify {
  1501. font-size: themed('font-size7');
  1502. line-height: themed('font-size10');
  1503. }
  1504. /* line-height: 29px;*/
  1505. text-align: center;
  1506. color: #b3b3b3;
  1507. /* font-size: 24px;*/
  1508. }
  1509. }
  1510. // 尾部
  1511. .botton {
  1512. border: 1px solid rgba(242, 242, 242, 1);
  1513. background: linear-gradient(180deg, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 1) 100%);
  1514. position: fixed;
  1515. //background: #fff;
  1516. width: 100%;
  1517. padding: 24rpx 40rpx;
  1518. line-height: 88rpx;
  1519. bottom: 0;
  1520. left: 0;
  1521. z-index: 999;
  1522. //padding: 0px 32rpx 32rpx;
  1523. padding-bottom: 12px;
  1524. button {
  1525. display: flex;
  1526. align-items: center;
  1527. justify-content: center;
  1528. //width: 45.8%;
  1529. // background-color: black;
  1530. // color: #fff;
  1531. // background-color: rgba(255, 255, 255, 1);
  1532. // color: rgba(0, 185, 98, 1);
  1533. background-color: rgba(0, 185, 98, 100);
  1534. color: rgba(255, 255, 255, 100);
  1535. height: 88rpx;
  1536. border-radius: 50px;
  1537. font-size: 32rpx;
  1538. }
  1539. }
  1540. .couponsuse {
  1541. color: rgba(153, 153, 153, 100);
  1542. margin-top: 10px;
  1543. font-size: 14px;
  1544. text-align: left;
  1545. font-family: AlibabaPuHui-regular;
  1546. }
  1547. .to-recharge {
  1548. padding: 0 16px;
  1549. line-height: 36px;
  1550. border-radius: 50px 0px 0px 50px;
  1551. background: linear-gradient(#FF9000, #FFB700);
  1552. color: rgba(255, 255, 255, 100);
  1553. font-size: 16px;
  1554. text-align: center;
  1555. position: absolute;
  1556. right: -16px;
  1557. top: 0;
  1558. }
  1559. // /deep/.u-checkbox__icon-wrap--checked {
  1560. // background-color: #2979ff !important;
  1561. // border-color: #2979ff !important;
  1562. // }
  1563. .amount {
  1564. // width: 41.9%;
  1565. height: 16px;
  1566. line-height: 15px;
  1567. border-radius: 0px 4px 0px 4px;
  1568. background-color: #ec4530; //rgba(0, 185, 98, 100)
  1569. color: rgba(255, 255, 255, 100);
  1570. font-size: 10px;
  1571. text-align: center;
  1572. position: absolute;
  1573. top: 0;
  1574. right: 0;
  1575. }
  1576. .card {
  1577. overflow: hidden;
  1578. padding: 10px;
  1579. margin-top: 10px;
  1580. .title {
  1581. font-weight: bold;
  1582. }
  1583. }
  1584. .cardselect {
  1585. border-radius: 8px;
  1586. border: 2px solid rgba(0, 185, 98, 1);
  1587. .title {
  1588. color: #00B962;
  1589. font-weight: bold;
  1590. }
  1591. .cardgo {
  1592. position: relative;
  1593. .cardinfo {
  1594. background-color: #00b962;
  1595. width: 64rpx;
  1596. height: 64rpx;
  1597. position: absolute;
  1598. top: -12px;
  1599. right: -12px;
  1600. border-radius: 0 0 0 8px;
  1601. img {
  1602. width: 64rpx;
  1603. }
  1604. }
  1605. }
  1606. }
  1607. .cardno {
  1608. border: 2px solid rgba(204, 204, 204, 1);
  1609. border-radius: 8px;
  1610. .title {
  1611. font-weight: bold;
  1612. }
  1613. .cardgo {
  1614. position: relative;
  1615. .cardinfo {
  1616. background-color: rgba(204, 204, 204, 1);
  1617. width: 64rpx;
  1618. height: 64rpx;
  1619. position: absolute;
  1620. top: -12px;
  1621. right: -12px;
  1622. border-radius: 0 0 0 8px;
  1623. img {
  1624. width: 64rpx;
  1625. }
  1626. }
  1627. }
  1628. }
  1629. .classtable {
  1630. margin: 40rpx 40rpx;
  1631. .td1 {
  1632. width: 50rpx;
  1633. padding: 12rpx 0;
  1634. text-align: center;
  1635. img {
  1636. width: 48rpx;
  1637. height: 48rpx;
  1638. }
  1639. font-size: 10px;
  1640. }
  1641. .td2 {
  1642. padding-left: 16rpx;
  1643. font-size: 12px;
  1644. line-height: 24px;
  1645. .dian {
  1646. padding: 0 10rpx
  1647. }
  1648. }
  1649. }
  1650. .carImg {
  1651. margin: 0 40rpx;
  1652. img {
  1653. width: 100%;
  1654. }
  1655. }
  1656. .cardListView{
  1657. .cardListItemTitle{
  1658. color: #777777;
  1659. font-size: 36rpx;
  1660. }
  1661. .cardListItem{
  1662. // margin:5px 4px;
  1663. //border: 1px solid ;
  1664. border: 2px solid #cccccc;
  1665. // border: 2px solid #cccccc;
  1666. // border-radius: 8px;
  1667. // padding: 3px;
  1668. border-radius: 6px;
  1669. .cardListName{
  1670. font-size: 34rpx;
  1671. }
  1672. .cardListText{
  1673. font-size: 24rpx;
  1674. display:flex;
  1675. justify-content: space-between;
  1676. }
  1677. }
  1678. .cardselect{
  1679. border: 2px solid #00b962;
  1680. background-color: #fff ;
  1681. color: #00b962;
  1682. }
  1683. }
  1684. .rechargeBalance{
  1685. display: flex;
  1686. .rechargeBalanceItem{
  1687. margin-right: 6px;
  1688. color: #666;
  1689. }
  1690. }
  1691. .greyTips{
  1692. background-color: #cccccc;
  1693. // color: #00b962;
  1694. font-weight: bold;
  1695. padding: 30rpx;
  1696. margin-top: 20rpx;
  1697. border-radius: 8px;
  1698. }
  1699. .cost-explain2{
  1700. .type{
  1701. color: #FF3D00;
  1702. }
  1703. }
  1704. </style>