bargainingAssistance.vue 46 KB

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