bargainingAssistance.vue 46 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695
  1. <template>
  2. <div class="bargaining-assistance">
  3. <!-- 邀请人提示 -->
  4. <div class="inviter-tips" v-if="+type">
  5. <img src="@/assets/image/claimCloudPhone/inviter-tips.png" alt="" />
  6. <div>好友注册获得助力 好友下单加速助力</div>
  7. </div>
  8. <!-- 被邀请人提示 -->
  9. <div v-else class="invitee-tips">
  10. <div class="invitee-tips-text">
  11. <div>亲,我在用<span>双子星云手机</span>,它可以帮我:</div>
  12. <div>
  13. <div style="animation-delay: 0.5s">
  14. <van-icon name="success" /> <span>24小时</span>运行游戏 / 聊天 /
  15. 看视频
  16. </div>
  17. <div style="animation-delay: 1s">
  18. <van-icon name="success" /> 双子星云手机已经帮我节省<span>
  19. 10086 </span
  20. >小时
  21. </div>
  22. <div style="animation-delay: 1.5s">
  23. <van-icon name="success" />
  24. 我得任务全做完了,游戏升级哇哇快,现在官方活动领云机,麻烦帮我助力!
  25. </div>
  26. </div>
  27. </div>
  28. </div>
  29. <!-- 砍价进度 -->
  30. <div
  31. class="bargaining-assistance-main"
  32. :class="{ 'bargaining-assistance-main-animation': !+type }"
  33. >
  34. <!-- 被邀请人助力、邀请人砍价 -->
  35. <template>
  36. <div class="package-name">
  37. <span> {{ info.phoneType }}{{ info.validityPeriod }}天</span>
  38. </div>
  39. <div class="package-price"><span>¥</span>{{ info.totalAmount }}</div>
  40. <div class="package-progress">
  41. <customProgress v-model="info.schedule" />
  42. </div>
  43. <div class="package-tips">
  44. <div>
  45. 仅差<span>{{ info.remainingPrice }}元</span>
  46. </div>
  47. <div>
  48. 必得价值<span>{{ info.totalAmount }}元</span>的免费云机
  49. </div>
  50. </div>
  51. <div
  52. :class="['package-btn', { end: +type === 7, 'mb-24': !+type }]"
  53. @click="btnFun"
  54. >
  55. {{ btnName }}
  56. </div>
  57. <div class="package-expire" v-if="+type">
  58. 免单失效时间:<van-count-down :time="time" />
  59. </div>
  60. </template>
  61. <van-dialog v-model="assistanceVisible" :showConfirmButton="false">
  62. <div class="invitee-to-claim">
  63. <div class="invitee-to-claim_btn" @click="loginVisible = true">
  64. 免费领取
  65. </div>
  66. </div>
  67. </van-dialog>
  68. </div>
  69. <!-- 邀请人显示 -->
  70. <template v-if="+type">
  71. <!-- 砍价记录 -->
  72. <div class="bargaining-record">
  73. <div class="title">砍价记录</div>
  74. <div class="container">
  75. <loadList
  76. ref="assistRecodeList"
  77. url="activity/v5/assist/operation/assistRecodeList"
  78. description="暂无砍价记录"
  79. >
  80. <template #default="{ list }">
  81. <div
  82. v-for="item in list"
  83. :key="item.id"
  84. class="bargaining-record-item"
  85. >
  86. <div class="bargaining-record-item_info">
  87. <div>{{ item.surfaceName }}</div>
  88. <div v-if="item.assistType === 1">
  89. 道具砍掉<span>{{ item.assistPrice }}元</span>
  90. </div>
  91. <div
  92. v-else-if="item.assistType === 2 || item.assistType === 3"
  93. >
  94. 为您砍价<span>{{ item.assistPrice }}元</span>
  95. </div>
  96. <div v-else>为您加油打气</div>
  97. </div>
  98. </div>
  99. </template>
  100. </loadList>
  101. </div>
  102. </div>
  103. <!-- 云机发放记录 -->
  104. <div class="distribution-records">
  105. <div class="title">云机发放记录</div>
  106. <div class="container">
  107. <div>
  108. <div>序号</div>
  109. <div>云机名称</div>
  110. <div>套餐类型</div>
  111. <div>云机时长</div>
  112. <div>购买类型</div>
  113. </div>
  114. <div>
  115. <loadList
  116. ref="assistGetPhoneRecode"
  117. url="activity/v5/assist/operation/assistGetPhoneRecode"
  118. description="当前您还没有白嫖到云手机"
  119. >
  120. <template #default="{ list }">
  121. <div
  122. v-for="(item, index) in list"
  123. :key="item.id"
  124. class="distribution-records-item"
  125. >
  126. <div>{{ index + 1 }}</div>
  127. <div>{{ item.diskName }}</div>
  128. <div>{{ item.phoneTypeStr }}</div>
  129. <div>{{ item.validTime }}天</div>
  130. <div>{{ ['', '购买', '续费'][item.dataType] }}</div>
  131. </div>
  132. </template>
  133. </loadList>
  134. </div>
  135. </div>
  136. </div>
  137. </template>
  138. <!-- 参加活动的所有信息 -->
  139. <template v-if="barrageList.length">
  140. <div class="barrage"></div>
  141. </template>
  142. <div class="rule" @click="ruleVisible = true" v-if="+type">规则</div>
  143. <!-- 规则弹窗 -->
  144. <van-dialog v-model="ruleVisible" :showConfirmButton="false">
  145. <div class="rule-title">活动规则</div>
  146. <div class="rule-content">
  147. <div v-html="ruleHtml"></div>
  148. </div>
  149. <div class="rule-close">
  150. <van-icon name="cross" @click="ruleVisible = false" />
  151. </div>
  152. </van-dialog>
  153. <!-- 邀请人首次到砍价的页面的弹窗 -->
  154. <van-dialog
  155. v-model="bargainingVisible"
  156. :showConfirmButton="false"
  157. class="dialog-bargaining"
  158. >
  159. <template v-if="!bargainingTipsBool">
  160. <div class="bargaining-img">
  161. <img
  162. src="@/assets/image/claimCloudPhone/red-packet-title.png"
  163. alt=""
  164. class="red-packet-title"
  165. />
  166. <lottie class="glory" :data="glory" :key="'glory'" />
  167. <lottie
  168. :key="'red-packet'"
  169. class="red-packet"
  170. :data="redPacket"
  171. @click.native="bargainingFun(true)"
  172. />
  173. </div>
  174. </template>
  175. <template v-if="bargainingTipsBool">
  176. <div class="bargaining-amount">
  177. <div class="bargaining-amount-text">
  178. 恭喜您,砍价成功<span>{{ bargainingAmount }}元</span>
  179. </div>
  180. <lottie
  181. class="species"
  182. :data="species"
  183. v-if="species"
  184. :key="'species'"
  185. />
  186. </div>
  187. </template>
  188. </van-dialog>
  189. <!-- 退出活动页的弹窗 -->
  190. <van-dialog v-model="exitVisible" :showConfirmButton="false">
  191. <div class="exit">
  192. <div class="exit-content">
  193. <div>确定要退出吗?</div>
  194. <div>
  195. 仅差<span>{{ info.remainingPrice }}元</span>免费带走云机
  196. </div>
  197. <div class="exit-content-progress">
  198. <customProgress v-model="info.schedule" />
  199. </div>
  200. <div class="exit-content-btn">
  201. <img
  202. @click="exitVisible = false"
  203. src="@/assets/image/claimCloudPhone/Inviting-others-img.png"
  204. alt=""
  205. />
  206. <div class="exit-content-btn_leave" @click="leaveFun">狠心离开</div>
  207. </div>
  208. </div>
  209. <img src="@/assets/image/claimCloudPhone/inviter-exit.png" alt="" />
  210. <lottie class="exit-glory" :data="glory" :key="'exit-glory'" />
  211. </div>
  212. </van-dialog>
  213. <!-- 砍价成功的弹窗-->
  214. <van-dialog
  215. v-model="successfulBargainingVisible"
  216. :showConfirmButton="false"
  217. >
  218. <div class="bargaining-success">
  219. <div class="bargaining-success-title">恭喜您,砍价成功</div>
  220. <div class="bargaining-success-tips">
  221. 您的云手机【{{ info.diskName }}】发放成功/续费成功
  222. </div>
  223. <div class="bargaining-success-btn">
  224. <div @click="claimTheNextOne">免费领下一台云机</div>
  225. <div @click="leaveFun">返回云手机首页</div>
  226. </div>
  227. </div>
  228. </van-dialog>
  229. <!-- 免单时间过期弹窗 -->
  230. <van-dialog v-model="expireVisible" :showConfirmButton="false">
  231. <div class="expire">
  232. <div class="expire-btn" @click="claimTheNextOne">免费领下一台云机</div>
  233. </div>
  234. </van-dialog>
  235. <!-- 被邀请人登录 -->
  236. <van-dialog v-model="loginVisible" :showConfirmButton="false">
  237. <div class="login">
  238. <div class="login-title">双子星快捷登录</div>
  239. <van-field
  240. placeholder="手机号"
  241. type="digit"
  242. v-model="laoginData.phone"
  243. clearable
  244. maxLength="11"
  245. />
  246. <van-field
  247. placeholder="验证码"
  248. v-model="laoginData.code"
  249. clearable
  250. type="digit"
  251. maxLength="6"
  252. >
  253. <template #button>
  254. <div
  255. :class="[
  256. 'login-code',
  257. {
  258. disabled:
  259. codeNumber !== '获取验证码' || laoginData.phone.length < 11,
  260. },
  261. ]"
  262. @click="getCode"
  263. >
  264. {{ codeNumber }}
  265. </div>
  266. </template>
  267. </van-field>
  268. <van-button
  269. color="#3666F2"
  270. :disabled="
  271. !agreementBool ||
  272. !laoginData.code ||
  273. laoginData.phone.length < 11 ||
  274. loginLoading
  275. "
  276. @click="login"
  277. >
  278. <template v-if="loginLoading"> 正在登录中... </template>
  279. <template v-else> 登录 </template>
  280. </van-button>
  281. <div class="login-agreement">
  282. <van-checkbox icon-size="16px" v-model="agreementBool">
  283. 通过登录即可完成注册,成为我们的新用户登录后表示同意
  284. <span @click.stop="toAgreement">用户协议</span>
  285. </van-checkbox>
  286. </div>
  287. </div>
  288. </van-dialog>
  289. <van-dialog
  290. v-model="endVisible"
  291. :showConfirmButton="false"
  292. :before-close="beforeClose"
  293. style="background: #fff"
  294. >
  295. <img
  296. src="@/assets/image/claimCloudPhone/end-visible-img.png"
  297. @click="endConfirm"
  298. class="end-visible-img"
  299. />
  300. <!-- <div style="text-align: center; padding: 10px; color: #999">
  301. 感谢您对我们应用的支持和参与。<br />
  302. 我们的活动已经结束了,<br />
  303. 但是我们会不断努力,<br />
  304. 为您带来更多精彩的活动和内容。<br />
  305. </div> -->
  306. </van-dialog>
  307. <Verify
  308. @success="success"
  309. mode="pop"
  310. captchaType="blockPuzzle"
  311. :imgSize="{ width: '300px', height: '155px' }"
  312. ref="verify"
  313. ></Verify>
  314. </div>
  315. </template>
  316. <script>
  317. import * as species from '@/assets/lottie/species/data.json';
  318. import * as redPacket from '@/assets/lottie/redPacket/data.json';
  319. import * as glory from '@/assets/lottie/glory/data.json';
  320. import { sha256 } from 'js-sha256';
  321. import customProgress from './customProgress.vue';
  322. import loadList from '@/components/loadList';
  323. import { fileKeyToUrl } from '@/plugins/file-center.js';
  324. import Verify from '@/components/verifition/Verify';
  325. import { writeToClipboard } from '@/plugins/plugins.js';
  326. import lottie from '@/components/lottie';
  327. export default {
  328. props: {
  329. operateActivityId: {
  330. type: [String, Number],
  331. default: '',
  332. },
  333. type: {
  334. type: [Number, String],
  335. default: '',
  336. },
  337. getSystemTime: {
  338. type: Function,
  339. default: () => {
  340. return () => {};
  341. },
  342. },
  343. leaveFun: {
  344. type: Function,
  345. default: () => {
  346. return () => {};
  347. },
  348. },
  349. wxIntercept: {
  350. type: Function,
  351. default: () => {
  352. return () => {};
  353. },
  354. },
  355. inviteeData: {
  356. type: Object,
  357. default: () => {
  358. return {};
  359. },
  360. },
  361. },
  362. data() {
  363. return {
  364. total: 50, // 砍价百分比
  365. barrageList: [], // 滚动轮播数据
  366. ruleVisible: false, // 规则弹窗
  367. bargainingVisible: false, // 首次砍价弹窗
  368. bargainingTipsBool: false, // 是否切换成砍价金额的页面
  369. exitVisible: false, // 退出弹窗
  370. successfulBargainingVisible: false, // 砍价成功弹窗
  371. expireVisible: false, // 免单时间过期弹窗
  372. loginVisible: false, // 被邀请人登录框
  373. agreementBool: false, // 是否勾选协议
  374. ruleHtml: '', // 规则内容
  375. info: {}, // 砍价相关信息
  376. bargainingAmount: '', // 砍价金额
  377. systemTime: '', // 系统时间
  378. assistanceVisible: false, // 是否触发助力
  379. laoginData: {
  380. // 被邀请人登录信息
  381. phone: '',
  382. code: '',
  383. },
  384. codeNumber: '获取验证码',
  385. loginLoading: false,
  386. endVisible: false, // 被邀请人活动结束弹窗
  387. species,
  388. redPacket,
  389. glory,
  390. };
  391. },
  392. components: {
  393. customProgress,
  394. loadList,
  395. Verify,
  396. lottie,
  397. },
  398. mounted() {
  399. document.addEventListener(
  400. 'touchmove',
  401. function (event) {
  402. event.preventDefault();
  403. },
  404. { passive: false },
  405. );
  406. if (sessionStorage.getItem('isAgreementBool')) {
  407. this.loginVisible = true;
  408. this.laoginData.phone = sessionStorage.getItem('invitedPhone');
  409. this.laoginData.code = sessionStorage.getItem('invitedCode');
  410. sessionStorage.removeItem('isAgreementBool');
  411. sessionStorage.removeItem('invitedPhone');
  412. sessionStorage.removeItem('invitedCode');
  413. }
  414. if (+this.type === 1 || +this.type === 2 || +this.type === 7) {
  415. this.getRule();
  416. this.getAssistAwardRecode();
  417. }
  418. setTimeout(() => {
  419. this.bargainingStatus(true);
  420. });
  421. },
  422. computed: {
  423. time() {
  424. const { validityPeriodTimeStamp = 0 } = this.info;
  425. let time = null;
  426. time = validityPeriodTimeStamp
  427. ? validityPeriodTimeStamp - this.systemTime * 1000
  428. : 0;
  429. time = +this.type === 7 ? 0 : time;
  430. return time;
  431. },
  432. btnName() {
  433. let name = null;
  434. if (+this.type === 7) {
  435. name = '活动已到期';
  436. } else {
  437. name = +this.type
  438. ? this.info.bargainingStatus === 1
  439. ? `继续砍价${this.info.remainingQuantity || 0}次`
  440. : '邀请好友助力免单'
  441. : '帮他助力';
  442. }
  443. return name;
  444. },
  445. },
  446. methods: {
  447. // 轮播活动参加的人的信息
  448. startBarrage() {
  449. const barrage = document.querySelector('.barrage');
  450. if (!barrage.childNodes.length) {
  451. const data = this.barrageList[0];
  452. this.barrageList.shift();
  453. this.barrageList.push(data);
  454. barrage.appendChild(writeIn(data));
  455. }
  456. const first = barrage.childNodes[0];
  457. setTimeout(() => {
  458. first.className = 'start';
  459. first.addEventListener('animationstart', () => {
  460. const data = this.barrageList[0];
  461. this.barrageList.shift();
  462. this.barrageList.push(data);
  463. const div = writeIn(data);
  464. barrage.appendChild(div);
  465. setTimeout(() => {
  466. div.style = 'opacity: 1';
  467. }, 100);
  468. });
  469. first.addEventListener('animationend', () => {
  470. barrage.removeChild(first);
  471. this.startBarrage();
  472. });
  473. }, 1000);
  474. function writeIn({ price, phoneNumber, phoneType, duration }) {
  475. const div = document.createElement('div');
  476. div.style = 'opacity: 0';
  477. div.innerHTML = `<div>
  478. <div>${phoneNumber}</div>
  479. <div class="free">免单</div>
  480. </div>
  481. <div>${phoneType}${duration}天,价值<span>${price}元</span></div>`;
  482. return div;
  483. }
  484. },
  485. bargainingFun(bool = false) {
  486. // 首次砍价的时候进此判断
  487. if (bool) {
  488. this.$toast.loading({
  489. message: '加载中...',
  490. forbidClick: true,
  491. duration: 0,
  492. });
  493. const { menuRuleId, userCardId } = this.$route.query;
  494. const obj = {
  495. operateActivityId: this.operateActivityId,
  496. menuRuleId,
  497. };
  498. // 如果是续费,选择了对应云机,需要传云机id
  499. if (userCardId) obj.userCardId = userCardId;
  500. this.$axios
  501. .$post('activity/v5/assist/bargaining/userSelectedPackage', obj)
  502. .then((res) => {
  503. if (res.success) {
  504. // 砍价金额
  505. this.bargainingAmount = res.data.fristKnifeAmount;
  506. setTimeout(() => {
  507. this.bargainingTipsBool = true;
  508. });
  509. // 重新获取用户最新的数据
  510. setTimeout(this.bargainingStatus, 1000);
  511. }
  512. })
  513. .catch((error) => {
  514. setTimeout(() => {
  515. this.$toast(error.message);
  516. });
  517. })
  518. .finally(() => {
  519. this.$toast.clear();
  520. });
  521. return;
  522. }
  523. this.chopAKnife();
  524. },
  525. // 获取规则
  526. getRule() {
  527. this.$axios
  528. .$get('public/v4/agreement/content', {
  529. params: { agreementCoding: 'YDQLBHD10000' },
  530. })
  531. .then((res) => {
  532. if (res.success) {
  533. const html = res.data.content;
  534. const rx = /<body[^>]*>([\s\S]+?)<\/body>/i;
  535. let m = rx.exec(html);
  536. if (m) {
  537. m = m[1];
  538. }
  539. this.ruleHtml = m;
  540. }
  541. });
  542. },
  543. // 获取用户数据接口
  544. bargainingStatus(bool = false) {
  545. if (bool) {
  546. this.$toast.loading({
  547. message: '加载中...',
  548. forbidClick: true,
  549. duration: 0,
  550. });
  551. }
  552. const params = {
  553. operateActivityId: localStorage.getItem('auth.operateActivityId'),
  554. };
  555. if (Object.keys(this.inviteeData).length) {
  556. params.userLaunchId = this.inviteeData.userLaunchId;
  557. }
  558. this.$axios
  559. .$get('activity/v5/assist/bargaining/current/bargainingStatus', {
  560. params,
  561. })
  562. .then(async (res) => {
  563. if (res.success) {
  564. this.info = res.data;
  565. // 砍价记录、云机发放记录
  566. if (
  567. [1, 2, 7].includes(this.info.bargainingStatus) &&
  568. this.$refs.assistRecodeList &&
  569. this.$refs.assistGetPhoneRecode
  570. ) {
  571. this.$refs.assistRecodeList.data = [];
  572. this.$refs.assistGetPhoneRecode.data = [];
  573. this.$refs.assistRecodeList.list();
  574. this.$refs.assistGetPhoneRecode.list();
  575. }
  576. localStorage.setItem(
  577. 'bargainingStatusInfo',
  578. JSON.stringify(this.info),
  579. );
  580. // 如果是被邀请人就不需要走下面流程
  581. if (Object.keys(this.inviteeData).length) {
  582. // 被邀请人活动结束
  583. if (res.data.bargainingStatus === 5) this.endVisible = true;
  584. return;
  585. }
  586. switch (+this.type) {
  587. case 3: // 成功,领取下一台云机界面
  588. this.successfulBargainingVisible = true;
  589. break;
  590. case 4: // 失败,领取下一台云机界面
  591. this.expireVisible = true;
  592. return;
  593. case 7: // 活动已结束
  594. return;
  595. }
  596. const data = await this.getSystemTime();
  597. this.systemTime = data.data;
  598. if (this.info.bargainingStatus === 0) {
  599. this.bargainingVisible = true;
  600. return;
  601. }
  602. // 如果是安卓客户端登录的情况且bargainingStatus为 1 2 ,
  603. if (
  604. this.info.bargainingStatus === 1 ||
  605. this.info.bargainingStatus === 2
  606. ) {
  607. // 对安卓返回键做拦截
  608. if (
  609. (this.$userAgent.isSzx || this.$userAgent.isSzxBrowser) &&
  610. this.$userAgent.isAndroid
  611. ) {
  612. // 旧版本做兼容,如果有的情况下的话就显示
  613. if (window.native.webBackStatus) {
  614. window.native.webBackStatus(true);
  615. window.appGoBackCallback = () => {
  616. this.exitVisible = true;
  617. };
  618. }
  619. }
  620. // 对微信做拦截
  621. if (this.$userAgent.isWx) {
  622. this.wxIntercept(() => {
  623. history.pushState(null, null, document.URL);
  624. this.exitVisible = true;
  625. });
  626. }
  627. }
  628. }
  629. })
  630. .catch((error) => {
  631. this.$toast(error.message);
  632. })
  633. .finally(() => {
  634. if (this.info.bargainingStatus !== 0) this.bargainingVisible = false;
  635. this.$toast.clear();
  636. });
  637. },
  638. // 滚动的相关数据
  639. getAssistAwardRecode() {
  640. this.$axios
  641. .$get('activity/v5/assist/operation/getAssistAwardRecode', {})
  642. .then((res) => {
  643. if (res.success) {
  644. this.barrageList = res.data;
  645. setTimeout(() => {
  646. this.barrageList.length && this.startBarrage();
  647. });
  648. }
  649. });
  650. },
  651. // 领取下一台手机
  652. claimTheNextOne() {
  653. this.$toast.loading({
  654. message: '加载中...',
  655. forbidClick: true,
  656. duration: 0,
  657. });
  658. this.$axios
  659. .$get('activity/v5/assist/operation/reportCutStatus', {
  660. params: {
  661. userLaunchId: this.info.userLaunchId,
  662. },
  663. })
  664. .then((res) => {
  665. if (res.success) {
  666. // 解除安卓返回按键
  667. if (
  668. (this.$userAgent.isSzx || this.$userAgent.isSzxBrowser) &&
  669. this.$userAgent.isAndroid
  670. ) {
  671. window.native.webBackStatus && window.native.webBackStatus(false);
  672. }
  673. this.$router.replace('/claimCloudPhone?exit=1&bool=1');
  674. }
  675. })
  676. .catch((error) => {
  677. setTimeout(() => {
  678. this.$toast(error.message);
  679. });
  680. })
  681. .finally(() => {
  682. this.$toast.clear();
  683. });
  684. },
  685. // 砍一刀
  686. chopAKnife() {
  687. this.$toast.loading({
  688. message: '加载中...',
  689. forbidClick: true,
  690. duration: 0,
  691. });
  692. this.$axios
  693. .$post('activity/v5/assist/operation/chopAKnife')
  694. .then((res) => {
  695. if (res.success) {
  696. this.bargainingTipsBool = true;
  697. this.bargainingAmount = res.data;
  698. setTimeout(() => {
  699. this.bargainingVisible = true;
  700. });
  701. // 重新获取用户最新的数据
  702. setTimeout(this.bargainingStatus, 1000);
  703. }
  704. })
  705. .catch((error) => {
  706. setTimeout(() => {
  707. this.$toast(error.message);
  708. });
  709. setTimeout(() => {
  710. this.$toast.clear();
  711. }, 500);
  712. })
  713. .finally(() => {
  714. this.$toast.clear();
  715. });
  716. },
  717. btnFun() {
  718. if (+this.type === 7) return;
  719. if (!+this.type) this.assistanceVisible = true;
  720. if (+this.type) {
  721. switch (this.info.bargainingStatus) {
  722. case 1:
  723. this.chopAKnife();
  724. break;
  725. case 2:
  726. this.$toast.loading({
  727. message: '加载中...',
  728. forbidClick: true,
  729. duration: 0,
  730. });
  731. this.$axios
  732. .$post('activity/v5/assist/bargaining/getGenerateInvitationLink')
  733. .then(async (res) => {
  734. if (res.success) {
  735. res.data.desc = res.data.content;
  736. res.data.link = res.data.url;
  737. res.data.imgUrl = fileKeyToUrl(res.data.imgUrl);
  738. const shareInfo = { ...res.data };
  739. if (this.$userAgent.isSzx || this.$userAgent.isSzxBrowser) {
  740. this.$native.share(shareInfo);
  741. } else {
  742. writeToClipboard(res.data.link)
  743. .then(() => {
  744. setTimeout(() => {
  745. this.$toast('链接复制成功');
  746. });
  747. })
  748. .catch((err) => {
  749. setTimeout(() => {
  750. this.$toast('链接复制失败');
  751. });
  752. });
  753. }
  754. }
  755. })
  756. .finally(() => {
  757. this.$toast.clear();
  758. });
  759. break;
  760. }
  761. }
  762. },
  763. // 获取验证码
  764. getCode() {
  765. if (
  766. this.laoginData.phone.length < 11 ||
  767. this.codeNumber !== '获取验证码'
  768. ) {
  769. return;
  770. }
  771. if (!/^1[3456789]\d{9}$/.test(this.laoginData.phone)) {
  772. this.$toast('手机号码有误,请重填');
  773. return;
  774. }
  775. this.$refs.verify.show();
  776. },
  777. // 登录
  778. async login() {
  779. this.loginLoading = true;
  780. let uuid = localStorage.getItem('uuid');
  781. if (!uuid) {
  782. const url = URL.createObjectURL(new Blob());
  783. uuid = url.toString();
  784. URL.revokeObjectURL(url);
  785. uuid = uuid.substring(uuid.lastIndexOf('/') + 1);
  786. // 去除 UUID 字符串中的连字符
  787. const uuidHex = uuid.replace(/-/g, '');
  788. // 将十六进制字符串解析为大整数
  789. const uuidNumber = BigInt('0x' + uuidHex);
  790. uuid = uuidNumber.toString().substring(0, 20); // 将大整数转换为字符串格式
  791. localStorage.setItem('uuid', uuid);
  792. }
  793. const data = await this.getSystemTime();
  794. const registerTime = this.timestampToTime(data.data);
  795. const params = {
  796. invitationType: 6,
  797. registerSource: 102,
  798. uuid,
  799. registerTime,
  800. };
  801. const headers = {
  802. devicesId: uuid,
  803. registerSign: this.jm(registerTime),
  804. };
  805. Object.assign(params, this.laoginData);
  806. Object.assign(params, this.inviteeData);
  807. params.activityId = params.operateActivityId;
  808. delete params.operateActivityId;
  809. this.$axios
  810. .$post('user/v5/client/register/forH5', params, { headers })
  811. .then((res) => {
  812. if (res.success) {
  813. localStorage.setItem('phone', params.phone);
  814. localStorage.setItem('auth._token.password', res.data.token);
  815. localStorage.setItem('token', res.data.token);
  816. localStorage.setItem(
  817. 'dataInfo',
  818. JSON.stringify({ type: Object, data: res.data }),
  819. );
  820. this.$toast('登录成功');
  821. const url = res.data.jumpToPage
  822. ? '/claimCloudPhone?bool=1'
  823. : '/claimCloudPhone/firstReward';
  824. this.$router[res.data.jumpToPage ? 'replace' : 'push'](url);
  825. }
  826. })
  827. .catch((error) => {
  828. setTimeout(() => {
  829. this.$toast(error.message);
  830. });
  831. })
  832. .finally(() => {
  833. this.loginLoading = false;
  834. });
  835. },
  836. timestampToTime(timestamp) {
  837. var date = new Date(timestamp * 1000);
  838. var Y = date.getFullYear() + '-';
  839. var M =
  840. (date.getMonth() + 1 < 10
  841. ? '0' + (date.getMonth() + 1)
  842. : date.getMonth() + 1) + '-';
  843. var D =
  844. (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()) + ' ';
  845. var h =
  846. (date.getHours() < 10 ? '0' + date.getHours() : date.getHours()) + ':';
  847. var m =
  848. (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()) +
  849. ':';
  850. var s =
  851. date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds();
  852. return Y + M + D + h + m + s;
  853. },
  854. jm(systemTime) {
  855. const registerSign = sha256('Register_SZX_2023:' + systemTime);
  856. return registerSign;
  857. },
  858. // 跳转对应协议
  859. toAgreement() {
  860. sessionStorage.setItem('invitedPhone', this.laoginData.phone);
  861. sessionStorage.setItem('invitedCode', this.laoginData.code);
  862. this.$router.push(
  863. '/claimCloudPhone/agreement?agreementCoding=XYPZYHXY2002',
  864. );
  865. },
  866. success(data) {
  867. this.$toast.loading({
  868. message: '加载中...',
  869. forbidClick: true,
  870. duration: 0,
  871. });
  872. const params = {
  873. type: 'common',
  874. authorizationType: 4,
  875. phone: this.laoginData.phone,
  876. captchaVerification: data.captchaVerification,
  877. };
  878. this.$axios
  879. .$post('activity/v5/assist/bargaining/phone/send/activity', params)
  880. .then((res) => {
  881. if (res.success) {
  882. this.codeNumber = 60;
  883. const timer = setInterval(() => {
  884. this.codeNumber--;
  885. if (this.codeNumber === 0) {
  886. this.codeNumber = '获取验证码';
  887. clearInterval(timer);
  888. }
  889. }, 1000);
  890. setTimeout(() => {
  891. this.$toast('获取成功');
  892. });
  893. }
  894. })
  895. .catch((error) => {
  896. setTimeout(() => {
  897. this.$toast(error.message);
  898. });
  899. })
  900. .finally(() => {
  901. this.$toast.clear();
  902. });
  903. },
  904. endConfirm() {
  905. location.href = 'https://www.androidscloud.com';
  906. },
  907. beforeClose(action, done) {
  908. done(false);
  909. },
  910. },
  911. };
  912. </script>
  913. <style lang="less" scoped>
  914. .bargaining-assistance {
  915. @keyframes invitee-tips-text {
  916. 0% {
  917. opacity: 0;
  918. }
  919. 100% {
  920. opacity: 1;
  921. }
  922. }
  923. height: 100%;
  924. position: relative;
  925. .inviter-tips,
  926. .invitee-tips {
  927. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  928. }
  929. .inviter-tips {
  930. & > img {
  931. height: 60px;
  932. display: block;
  933. margin: 0 auto;
  934. }
  935. & > div {
  936. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  937. font-weight: 400;
  938. font-size: 12px;
  939. color: #ffffff;
  940. line-height: 17px;
  941. text-align: center;
  942. font-style: normal;
  943. margin-top: 6px;
  944. margin-bottom: 14px;
  945. }
  946. }
  947. .invitee-tips {
  948. .invitee-tips-user {
  949. font-weight: bold;
  950. font-size: 18px;
  951. color: #ffffff;
  952. line-height: 22px;
  953. text-align: left;
  954. font-style: normal;
  955. margin-bottom: 8px;
  956. }
  957. .invitee-tips-text {
  958. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  959. font-weight: 500;
  960. font-size: 18px;
  961. color: #ffffff;
  962. line-height: 22px;
  963. font-style: normal;
  964. & > div:first-of-type {
  965. opacity: 0;
  966. animation: invitee-tips-text 0.5s linear forwards;
  967. }
  968. & > div:last-of-type {
  969. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  970. font-weight: 400;
  971. font-size: 14px;
  972. color: #fff;
  973. line-height: 22px;
  974. text-align: left;
  975. font-style: normal;
  976. margin-top: 15px;
  977. margin-bottom: 14px;
  978. & > div {
  979. opacity: 0;
  980. animation: invitee-tips-text 0.5s linear forwards;
  981. margin-bottom: 14px;
  982. .van-icon-success {
  983. margin-right: 13px;
  984. }
  985. }
  986. }
  987. span {
  988. color: #ffe7a1;
  989. }
  990. }
  991. }
  992. .bargaining-assistance-main {
  993. background: #ffffff;
  994. border-radius: 20px;
  995. margin-bottom: 24px;
  996. overflow: hidden;
  997. &.bargaining-assistance-main-animation {
  998. opacity: 0;
  999. animation: invitee-tips-text 0.5s linear forwards;
  1000. animation-delay: 2s;
  1001. }
  1002. .package-name {
  1003. display: flex;
  1004. justify-content: center;
  1005. span {
  1006. display: inline-block;
  1007. padding: 5px 61px;
  1008. background: #ffe8e8;
  1009. border-radius: 0 0 15px 15px;
  1010. margin: 0 auto;
  1011. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1012. font-weight: bold;
  1013. font-size: 16px;
  1014. color: #c00202;
  1015. line-height: 20px;
  1016. text-align: center;
  1017. font-style: normal;
  1018. }
  1019. }
  1020. .package-price {
  1021. font-family: Alibaba-PuHuiTi, Alibaba-PuHuiTi;
  1022. font-weight: bold;
  1023. color: #c70b0b;
  1024. height: 120px;
  1025. font-weight: normal;
  1026. box-sizing: border-box;
  1027. padding-top: 30px;
  1028. font-size: 60px;
  1029. line-height: 62px;
  1030. text-align: center;
  1031. font-style: normal;
  1032. font-weight: bold;
  1033. width: calc(100% - 24px);
  1034. margin: 0 auto;
  1035. background: #fff3f5;
  1036. box-shadow: 0px 0px 8px 2px #f4f7f8, 0px 2px 4px 0px #ecedf8;
  1037. border-radius: 20px;
  1038. margin-top: -20px;
  1039. border: 1px solid #eaeaea;
  1040. span {
  1041. font-size: 30px;
  1042. }
  1043. }
  1044. .package-progress {
  1045. margin: 24px 42px 35px;
  1046. }
  1047. .package-tips {
  1048. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1049. text-align: center;
  1050. font-size: 16px;
  1051. color: #000000;
  1052. font-style: normal;
  1053. margin-bottom: 24px;
  1054. font-weight: 500;
  1055. line-height: 22px;
  1056. font-style: normal;
  1057. span {
  1058. color: #f04646;
  1059. }
  1060. & > div:first-of-type {
  1061. font-size: 21px;
  1062. line-height: 29px;
  1063. }
  1064. }
  1065. .package-btn {
  1066. height: 54px;
  1067. background: linear-gradient(178deg, #fd8c50 0%, #fc3307 100%);
  1068. border-radius: 28px;
  1069. margin: 0 27px;
  1070. font-family: AlimamaShuHeiTi, AlimamaShuHeiTi;
  1071. font-weight: bold;
  1072. font-size: 20px;
  1073. color: #ffffff;
  1074. line-height: 54px;
  1075. text-align: center;
  1076. font-style: normal;
  1077. // margin-bottom: 24px;
  1078. &.end {
  1079. opacity: 0.5;
  1080. }
  1081. }
  1082. .package-expire {
  1083. margin-top: 12px;
  1084. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1085. text-align: center;
  1086. font-style: normal;
  1087. margin-bottom: 24px;
  1088. &,
  1089. .van-count-down {
  1090. font-weight: 400;
  1091. font-size: 12px;
  1092. color: #7d6156;
  1093. line-height: 16px;
  1094. }
  1095. .van-count-down {
  1096. display: inline-block;
  1097. }
  1098. }
  1099. .invitee-to-claim {
  1100. width: 330px;
  1101. height: 406px;
  1102. border-radius: 20px;
  1103. background: url('~/assets/image/claimCloudPhone/Invitee-to-claim.png')
  1104. no-repeat 0 0;
  1105. background-size: 100% 100%;
  1106. position: relative;
  1107. .invitee-to-claim_btn {
  1108. height: 54px;
  1109. background: linear-gradient(90deg, #ff6d2b 0%, #ff1500 100%);
  1110. box-shadow: inset 9px -7px 19px 0px #ffba57,
  1111. inset -1px 2px 6px 0px #ffbd63;
  1112. border-radius: 27px;
  1113. text-align: center;
  1114. position: absolute;
  1115. bottom: 14px;
  1116. width: 200px;
  1117. font-family: YouSheBiaoTiYuan;
  1118. font-size: 28px;
  1119. color: #ffffff;
  1120. line-height: 23px;
  1121. left: 50%;
  1122. transform: translateX(-50%);
  1123. font-style: normal;
  1124. font-weight: bold;
  1125. line-height: 54px;
  1126. }
  1127. }
  1128. }
  1129. .bargaining-record {
  1130. margin-bottom: 24px;
  1131. }
  1132. .bargaining-record,
  1133. .distribution-records {
  1134. background: #ffffff;
  1135. border-radius: 12px;
  1136. .title {
  1137. height: 44px;
  1138. background: #ffe8e8;
  1139. border-radius: 12px 12px 0px 0px;
  1140. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1141. font-weight: bold;
  1142. font-size: 16px;
  1143. color: #c00202;
  1144. line-height: 44px;
  1145. text-align: center;
  1146. font-style: normal;
  1147. }
  1148. .container {
  1149. height: 250px;
  1150. overflow-y: auto;
  1151. padding: 0 20px;
  1152. scrollbar-width: none !important; /* 对于 Firefox 隐藏滚动条 */
  1153. &::-webkit-scrollbar {
  1154. display: none !important; /* 对于 Chrome, Safari 和 Opera 隐藏滚动条 */
  1155. }
  1156. ::v-deep .van-empty {
  1157. padding: 0 !important;
  1158. }
  1159. }
  1160. .bargaining-record-item {
  1161. height: 53px;
  1162. border-bottom: 2px #f1f1f1 solid;
  1163. display: flex;
  1164. align-items: center;
  1165. .bargaining-record-item_info {
  1166. font-family: PingFangSC, PingFang SC;
  1167. font-weight: 400;
  1168. font-size: 14px;
  1169. color: #7d6156;
  1170. line-height: 18px;
  1171. font-style: normal;
  1172. & > div:first-of-type,
  1173. span {
  1174. font-weight: bold;
  1175. }
  1176. span {
  1177. color: #c00202;
  1178. }
  1179. }
  1180. }
  1181. }
  1182. .distribution-records {
  1183. .container {
  1184. padding: 0px;
  1185. position: relative;
  1186. & > div:first-of-type {
  1187. position: absolute;
  1188. width: 100%;
  1189. left: 0;
  1190. height: 20px;
  1191. background: #ffffff;
  1192. box-shadow: 0px 2px 4px 0px #ecedf8;
  1193. top: 0;
  1194. font-family: PingFangSC, PingFang SC;
  1195. font-weight: 400;
  1196. font-size: 12px;
  1197. color: #7d6156;
  1198. line-height: 20px;
  1199. text-align: center;
  1200. display: flex;
  1201. font-style: normal;
  1202. & > div {
  1203. width: 25%;
  1204. }
  1205. }
  1206. & > div:last-of-type {
  1207. height: 100%;
  1208. box-sizing: border-box;
  1209. padding-top: 20px;
  1210. overflow-y: auto;
  1211. scrollbar-width: none !important; /* 对于 Firefox 隐藏滚动条 */
  1212. &::-webkit-scrollbar {
  1213. display: none !important; /* 对于 Chrome, Safari 和 Opera 隐藏滚动条 */
  1214. }
  1215. ::v-deep .van-empty {
  1216. padding: 0px;
  1217. .van-empty__image {
  1218. img {
  1219. display: none;
  1220. }
  1221. background: url('~/assets/image/claimCloudPhone/distribution-records-empty.png')
  1222. no-repeat center bottom;
  1223. background-size: 90px 90px;
  1224. }
  1225. }
  1226. .distribution-records-item {
  1227. height: 46px;
  1228. line-height: 46px;
  1229. box-sizing: border-box;
  1230. display: flex;
  1231. border-bottom: 2px #f1f1f1 solid;
  1232. & > div {
  1233. width: 25%;
  1234. text-align: center;
  1235. font-family: PingFangSC, PingFang SC;
  1236. font-weight: 400;
  1237. font-size: 14px;
  1238. color: #6d2b12;
  1239. text-align: center;
  1240. font-style: normal;
  1241. }
  1242. }
  1243. }
  1244. }
  1245. }
  1246. .barrage {
  1247. position: fixed;
  1248. bottom: 11%;
  1249. transform: translateY(-11%);
  1250. right: 11px;
  1251. & > ::v-deep div {
  1252. transition: all 0.7s;
  1253. &.start {
  1254. opacity: 1;
  1255. animation: barrage 0.5s linear;
  1256. @keyframes barrage {
  1257. 0% {
  1258. opacity: 1;
  1259. transform: translateY(0px);
  1260. }
  1261. 100% {
  1262. transform: translateY(-30px);
  1263. opacity: 0;
  1264. }
  1265. }
  1266. }
  1267. opacity: 1;
  1268. width: 143px;
  1269. height: 40px;
  1270. position: absolute;
  1271. bottom: 11%;
  1272. right: 11px;
  1273. background: linear-gradient(
  1274. 90deg,
  1275. #992bff 0%,
  1276. rgba(255, 21, 0, 0.4) 100%
  1277. );
  1278. border-radius: 23px;
  1279. border-image: linear-gradient(
  1280. 94deg,
  1281. rgba(255, 255, 255, 1),
  1282. rgba(255, 255, 255, 0.35)
  1283. )
  1284. 1 1;
  1285. padding-left: 20px;
  1286. font-size: 10px;
  1287. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1288. font-weight: 400;
  1289. color: #ffffff;
  1290. display: flex;
  1291. flex-direction: column;
  1292. justify-content: center;
  1293. & > div {
  1294. height: 16px;
  1295. line-height: 16px;
  1296. &:first-of-type {
  1297. display: flex;
  1298. justify-content: space-between;
  1299. align-items: center;
  1300. & > div:first-of-type {
  1301. width: 60px;
  1302. overflow: hidden;
  1303. text-overflow: ellipsis;
  1304. white-space: nowrap;
  1305. }
  1306. & > div:last-of-type {
  1307. height: 16px;
  1308. line-height: 16px;
  1309. margin-right: 15px;
  1310. padding: 0 8px;
  1311. background: linear-gradient(to top, #fec37a 0%, #ff1500 100%);
  1312. border-radius: 21px;
  1313. }
  1314. }
  1315. &:last-of-type span {
  1316. color: #fddb2b;
  1317. }
  1318. }
  1319. }
  1320. }
  1321. .rule {
  1322. position: absolute;
  1323. z-index: 0;
  1324. right: -16px;
  1325. top: 5.5%;
  1326. width: 40px;
  1327. height: 20px;
  1328. line-height: 20px;
  1329. background: #f04646;
  1330. border-radius: 17px 0px 0px 17px;
  1331. font-family: PingFangSC, PingFang SC;
  1332. font-weight: 400;
  1333. font-size: 12px;
  1334. color: #ffffff;
  1335. text-align: center;
  1336. font-style: normal;
  1337. }
  1338. .rule-title {
  1339. height: 53px;
  1340. border-radius: 16px 16px 0 0;
  1341. background: linear-gradient(90deg, #f6cdb9 0%, #fbdbde 100%);
  1342. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1343. font-weight: bold;
  1344. font-size: 18px;
  1345. color: #751d13;
  1346. line-height: 53px;
  1347. text-align: center;
  1348. font-style: normal;
  1349. }
  1350. .rule-content {
  1351. height: 325px;
  1352. padding: 16px;
  1353. box-sizing: border-box;
  1354. background: #fff;
  1355. border-radius: 0 0 16px 16px;
  1356. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1357. font-weight: 400;
  1358. font-size: 14px;
  1359. color: #751d13;
  1360. line-height: 16px;
  1361. font-style: normal;
  1362. overflow-y: auto;
  1363. }
  1364. .rule-close {
  1365. height: 32px;
  1366. width: 32px;
  1367. background: #c1c1c1;
  1368. z-index: 5;
  1369. margin: 20px auto 0;
  1370. border-radius: 50%;
  1371. display: flex;
  1372. justify-content: center;
  1373. align-items: center;
  1374. font-size: 24px;
  1375. color: #666666;
  1376. }
  1377. ::v-deep .van-dialog {
  1378. background: transparent !important;
  1379. // overflow: visible;
  1380. }
  1381. .bargaining-img {
  1382. position: relative;
  1383. width: 336px;
  1384. height: 468px;
  1385. }
  1386. .bargaining-amount {
  1387. box-sizing: border-box;
  1388. background-size: 100% auto;
  1389. .bargaining-amount-text {
  1390. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1391. font-weight: bold;
  1392. font-size: 24px;
  1393. color: #ffffff;
  1394. line-height: 20px;
  1395. text-align: center;
  1396. font-style: normal;
  1397. span {
  1398. color: #ff0000;
  1399. font-size: 35px;
  1400. color: #fad539;
  1401. }
  1402. }
  1403. }
  1404. .exit {
  1405. height: 520px;
  1406. position: relative;
  1407. & > img {
  1408. position: absolute;
  1409. top: 50%;
  1410. left: 50%;
  1411. transform: translate(-50%, -50%);
  1412. height: 321px;
  1413. width: 284px;
  1414. z-index: -1;
  1415. }
  1416. .exit-glory {
  1417. position: absolute;
  1418. top: 50%;
  1419. left: 50%;
  1420. transform: translate(-50%, -50%) scale(1.5);
  1421. z-index: -2;
  1422. }
  1423. .exit-content {
  1424. position: absolute;
  1425. top: 25%;
  1426. left: 50%;
  1427. width: 200px;
  1428. transform: translateX(-50%);
  1429. font-family: AlimamaShuHeiTi, AlimamaShuHeiTi;
  1430. color: #171815;
  1431. line-height: 24px;
  1432. text-align: center;
  1433. font-style: normal;
  1434. font-weight: bold;
  1435. font-size: 16px;
  1436. z-index: 0;
  1437. & > div span {
  1438. color: #f04646;
  1439. }
  1440. .exit-content-progress {
  1441. margin: 30px 10px 100px;
  1442. }
  1443. .exit-content-btn {
  1444. & > img {
  1445. height: 42px;
  1446. width: 100%;
  1447. }
  1448. .exit-content-btn_leave {
  1449. font-weight: 400;
  1450. font-size: 12px;
  1451. color: #faf3d8;
  1452. }
  1453. }
  1454. }
  1455. }
  1456. .bargaining-success {
  1457. height: 378px;
  1458. width: 289px;
  1459. margin: 0 auto;
  1460. background: url('~/assets/image/claimCloudPhone/successful-bargaining-img.png')
  1461. no-repeat 0 0;
  1462. background-size: 100% 100%;
  1463. overflow: hidden;
  1464. position: relative;
  1465. .bargaining-success-title {
  1466. margin-top: 24px;
  1467. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1468. text-align: center;
  1469. font-style: normal;
  1470. font-weight: bold;
  1471. font-size: 28px;
  1472. color: #fdf9c8;
  1473. line-height: 38px;
  1474. }
  1475. .bargaining-success-tips {
  1476. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1477. font-weight: 500;
  1478. font-size: 12px;
  1479. color: #ffffff;
  1480. line-height: 17px;
  1481. text-align: center;
  1482. font-style: normal;
  1483. width: 160px;
  1484. margin: 0 auto;
  1485. }
  1486. .bargaining-success-btn {
  1487. position: absolute;
  1488. bottom: 20px;
  1489. left: 50%;
  1490. transform: translateX(-50%);
  1491. display: flex;
  1492. flex-direction: column;
  1493. justify-content: center;
  1494. & > div {
  1495. width: 180px;
  1496. height: 48px;
  1497. line-height: 48px;
  1498. text-align: center;
  1499. border-radius: 24px;
  1500. color: #fff;
  1501. font-weight: bold;
  1502. &:first-of-type {
  1503. margin-bottom: 8px;
  1504. background: linear-gradient(178deg, #fd8c50 0%, #fc3307 100%);
  1505. }
  1506. &:last-of-type {
  1507. color: #e63b47;
  1508. border: 1px solid #e63b47;
  1509. }
  1510. }
  1511. }
  1512. }
  1513. .expire {
  1514. height: 378px;
  1515. width: 289px;
  1516. margin: 0 auto;
  1517. background: url('~/assets/image/claimCloudPhone/expire-img.png') no-repeat 0
  1518. 0;
  1519. background-size: 100% 100%;
  1520. position: relative;
  1521. .expire-btn {
  1522. position: absolute;
  1523. bottom: 20px;
  1524. font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
  1525. font-weight: 500;
  1526. font-size: 16px;
  1527. color: #ffffff;
  1528. line-height: 48px;
  1529. left: 50%;
  1530. transform: translateX(-50%);
  1531. text-align: center;
  1532. font-style: normal;
  1533. width: 180px;
  1534. height: 48px;
  1535. background: linear-gradient(178deg, #fd8c50 0%, #fc3307 100%);
  1536. border-radius: 24px;
  1537. }
  1538. }
  1539. .login {
  1540. height: 312px;
  1541. background: #ffffff;
  1542. border-radius: 24px;
  1543. padding: 16px 28px;
  1544. box-sizing: border-box;
  1545. .login-title {
  1546. font-family: DingTalk, DingTalk;
  1547. font-weight: normal;
  1548. font-weight: bold;
  1549. font-size: 24px;
  1550. color: #0a132b;
  1551. line-height: 28px;
  1552. text-align: left;
  1553. font-style: normal;
  1554. margin-bottom: 14px;
  1555. }
  1556. .van-field {
  1557. margin-bottom: 14px;
  1558. border-radius: 8px;
  1559. border: 1px solid #e6e6e6;
  1560. }
  1561. .van-button {
  1562. width: 100%;
  1563. border-radius: 8px;
  1564. }
  1565. .login-code {
  1566. font-family: PingFangSC, PingFang SC;
  1567. font-weight: 500;
  1568. font-size: 14px;
  1569. color: #3666f2;
  1570. line-height: 16px;
  1571. text-align: left;
  1572. font-style: normal;
  1573. &.disabled {
  1574. color: #999;
  1575. }
  1576. }
  1577. .login-agreement {
  1578. font-family: PingFangSC, PingFang SC;
  1579. font-weight: 400;
  1580. font-size: 12px;
  1581. font-style: normal;
  1582. margin-top: 12px;
  1583. display: flex;
  1584. span {
  1585. color: #3666f2;
  1586. }
  1587. .van-checkbox {
  1588. align-items: start;
  1589. ::v-deep .van-checkbox__label {
  1590. color: #999999;
  1591. }
  1592. ::v-deep .van-checkbox__icon {
  1593. margin-top: 3px;
  1594. }
  1595. }
  1596. }
  1597. }
  1598. ::v-deep .phone-container {
  1599. background: transparent;
  1600. }
  1601. }
  1602. .dialog-bargaining {
  1603. overflow: visible;
  1604. }
  1605. .species {
  1606. height: 234px !important;
  1607. }
  1608. .glory,
  1609. .red-packet {
  1610. position: absolute;
  1611. top: 90%;
  1612. left: 50%;
  1613. }
  1614. .glory {
  1615. top: 116%;
  1616. transform: translate(-50%, -110%) scale(1.5);
  1617. }
  1618. .red-packet {
  1619. width: 259px !important;
  1620. height: 318px !important;
  1621. transform: translate(-50%, -90%);
  1622. }
  1623. .red-packet-title {
  1624. width: 90%;
  1625. height: 146px;
  1626. position: absolute;
  1627. top: 0;
  1628. left: 50%;
  1629. transform: translateX(-50%);
  1630. }
  1631. .end-visible-img {
  1632. width: 289px;
  1633. height: 264px;
  1634. margin: 0 auto;
  1635. display: block;
  1636. }
  1637. .mb-24 {
  1638. margin-bottom: 24px !important;
  1639. }
  1640. .mask {
  1641. z-index: 4000;
  1642. }
  1643. </style>