bargainingAssistance.vue 45 KB

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