bargainingAssistance.vue 46 KB

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