detail.vue 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686
  1. <template>
  2. <div class="page md:flex md:justify-between">
  3. <div class="page-title">机构认证</div>
  4. <div class="page-top">
  5. <div class="swiper">
  6. <SimpleSwiper :imageList="clubInfo.bannerList"></SimpleSwiper>
  7. <img
  8. class="auth-card"
  9. :src="authCardImage"
  10. @click="onShowAuthCard"
  11. v-if="!showAuthCard"
  12. />
  13. </div>
  14. </div>
  15. <div class="page-content">
  16. <div class="bg-container">
  17. <!-- 机构信息 -->
  18. <div class="club-info">
  19. <div class="section flex justify-between items-center">
  20. <div class="info">
  21. <div class="name" v-text="clubInfo.authParty"></div>
  22. <div class="mobile" @click="callMobile(clubInfo.mobile)">
  23. {{ clubInfo.mobile | formatEmpty }}
  24. </div>
  25. <div class="address" v-text="address"></div>
  26. </div>
  27. <div class="logo"><img :src="clubInfo.logo" /></div>
  28. </div>
  29. <div class="section flex justify-between items-center mt-6">
  30. <div class="navigation" @click="onMapNav">导航</div>
  31. <div
  32. class="distance"
  33. v-if="clubInfo.distance && clubInfo.distance < 99999"
  34. v-text="'距你' + clubInfo.distance + 'km'"
  35. ></div>
  36. </div>
  37. </div>
  38. <!-- 机构授权信息 -->
  39. <div class="auth">
  40. <div class="auth-icon"></div>
  41. <div class="auth-info">
  42. <span>该机构由</span>
  43. <span class="font-bold">{{ supplierInfo.shopName }}</span>
  44. <span class="font-bold">官方授权</span>
  45. </div>
  46. </div>
  47. </div>
  48. <!-- 分割 -->
  49. <div class="divider"></div>
  50. <div class="device-list">
  51. <div class="title">已认证设备</div>
  52. <div class="list">
  53. <div
  54. class="device flex justify-between items-center"
  55. v-for="item in clubInfo.productList"
  56. :key="item.productId"
  57. >
  58. <div class="info">
  59. <div class="name" v-text="item.productName"></div>
  60. <div class="code">SN码:{{ item.snCode | formatSnCode }}</div>
  61. </div>
  62. <div class="detail" @click="toDetail(item)">查看认证</div>
  63. </div>
  64. </div>
  65. </div>
  66. <SimpleEmpty
  67. v-if="isEmpty"
  68. name="icon-empty-device.png"
  69. description="暂无已认证设备"
  70. ></SimpleEmpty>
  71. </div>
  72. <SimpleMapNav
  73. ref="mapNav"
  74. @click="navigation"
  75. color="#f3920d"
  76. ></SimpleMapNav>
  77. <!-- 授权牌弹窗 -->
  78. <div class="mask" v-if="showAuthCard" @click="onHideAuthCard"></div>
  79. <transition
  80. enter-active-class="animate__zoomIn"
  81. leave-active-class="animate__zoomOut"
  82. >
  83. <div class="auth-card-content animate__animated" v-if="showAuthCard">
  84. <div class="auth-card-popup">
  85. <span class="el-icon-circle-close" @click="onHideAuthCard"></span>
  86. <img :src="authCardImage" />
  87. </div>
  88. </div>
  89. </transition>
  90. </div>
  91. </template>
  92. <script>
  93. import clubDetailMixin from '@/mixins/clubDetail'
  94. export default {
  95. layout: 'app-ross',
  96. mixins: [clubDetailMixin],
  97. }
  98. </script>
  99. <style scoped lang="scss">
  100. .mask {
  101. width: 100vw;
  102. height: 100vh;
  103. position: fixed;
  104. left: 0;
  105. top: 0;
  106. z-index: 8;
  107. background: rgba(0, 0, 0, 0.5);
  108. }
  109. // pc 端
  110. @media screen and (min-width: 768px) {
  111. .page {
  112. position: relative;
  113. width: 1200px;
  114. height: 612px;
  115. margin-left: auto;
  116. margin-right: auto;
  117. margin-top: 80px;
  118. background-color: #fff;
  119. box-sizing: border-box;
  120. padding: 16px;
  121. padding-right: 0;
  122. }
  123. .auth-card-content {
  124. width: 100vw;
  125. height: 100vh;
  126. position: fixed;
  127. left: 0;
  128. top: 0;
  129. display: flex;
  130. justify-content: center;
  131. align-items: center;
  132. z-index: 9;
  133. .auth-card-popup {
  134. position: relative;
  135. width: 622px;
  136. img {
  137. display: block;
  138. width: 100%;
  139. height: auto;
  140. }
  141. .el-icon-circle-close {
  142. position: absolute;
  143. top: -50px;
  144. right: 0;
  145. font-size: 32px;
  146. color: #fff;
  147. cursor: pointer;
  148. }
  149. }
  150. }
  151. .page-title {
  152. position: absolute;
  153. font-size: 24px;
  154. color: #333;
  155. top: -50px;
  156. left: 0;
  157. }
  158. .page-top {
  159. margin-right: 24px;
  160. .swiper {
  161. position: relative;
  162. width: 580px;
  163. height: 580px;
  164. background: #f7f7f7;
  165. ::v-deep {
  166. img {
  167. width: 580px;
  168. height: 580px;
  169. }
  170. }
  171. .auth-card {
  172. position: absolute;
  173. width: auto;
  174. height: 110px;
  175. display: block;
  176. bottom: 24px;
  177. left: 24px;
  178. z-index: 2;
  179. cursor: pointer;
  180. }
  181. }
  182. }
  183. .page-content {
  184. width: 580px;
  185. overflow-y: auto;
  186. &::-webkit-scrollbar {
  187. width: 8px;
  188. // background-color: #eeeeee;
  189. }
  190. &::-webkit-scrollbar-thumb {
  191. border-radius: 4px;
  192. background-color: #eeeeee;
  193. }
  194. .bg-container {
  195. background: url(~assets/theme-images/ross/h5-club-info-bg.png) center
  196. no-repeat;
  197. background-size: 100%;
  198. box-sizing: border-box;
  199. background-position-y: 20px;
  200. background-color: #f3920d;
  201. padding-bottom: 24px;
  202. }
  203. .auth {
  204. width: 524px;
  205. box-sizing: border-box;
  206. background: #fef5e8;
  207. margin: 0 auto;
  208. margin-top: 8px;
  209. padding: 12px 16px;
  210. border-radius: 2px;
  211. .auth-icon {
  212. height: 28px;
  213. background: url(~assets/theme-images/ross/h5-icon-auth.png) no-repeat
  214. left center;
  215. background-size: auto 28px;
  216. }
  217. .auth-info {
  218. font-size: 0;
  219. margin-top: 10px;
  220. span {
  221. font-size: 20px;
  222. line-height: 1.6;
  223. color: #f3920d;
  224. &.font-bold {
  225. font-weight: bold;
  226. }
  227. }
  228. }
  229. }
  230. .club-info {
  231. padding: 32px 24px;
  232. width: 564px;
  233. min-height: 264px;
  234. .info {
  235. width: 360px;
  236. .name {
  237. font-size: 24px;
  238. color: #fff;
  239. font-weight: bold;
  240. margin-bottom: 34px;
  241. }
  242. .mobile,
  243. .address {
  244. position: relative;
  245. padding-left: 28px;
  246. margin-top: 16px;
  247. line-height: 24px;
  248. font-size: 16px;
  249. color: #fff;
  250. &::after {
  251. content: '';
  252. display: block;
  253. width: 24px;
  254. height: 24px;
  255. position: absolute;
  256. left: 0;
  257. top: 0;
  258. background-size: 20px;
  259. background-repeat: no-repeat;
  260. background-position: center;
  261. }
  262. }
  263. .mobile {
  264. cursor: pointer;
  265. &::after {
  266. @include themify($themes) {
  267. background-image: themed('pc-icon-mobile');
  268. }
  269. }
  270. }
  271. .address {
  272. &::after {
  273. @include themify($themes) {
  274. background-image: themed('h5-icon-address');
  275. }
  276. }
  277. }
  278. }
  279. .logo {
  280. position: relative;
  281. width: 114px;
  282. height: 114px;
  283. border-radius: 50% 50% 0 50%;
  284. overflow: hidden;
  285. background: #fff;
  286. display: flex;
  287. &::after {
  288. position: absolute;
  289. bottom: 0;
  290. right: 0;
  291. content: '';
  292. display: block;
  293. width: 23px;
  294. height: 23px;
  295. background: url(~assets/theme-images/ross/pc-icon-avatar-v.png)
  296. no-repeat center;
  297. background-size: 23px;
  298. }
  299. }
  300. .navigation {
  301. display: flex;
  302. justify-content: center;
  303. align-items: center;
  304. width: 72px;
  305. height: 32px;
  306. border-radius: 4px;
  307. font-size: 16px;
  308. color: #f3920d;
  309. border: 1px solid #fff;
  310. background-color: #fff;
  311. cursor: pointer;
  312. &::after {
  313. content: '';
  314. display: block;
  315. width: 16px;
  316. height: 16px;
  317. margin-left: 4px;
  318. @include themify($themes) {
  319. background: themed('pc-icon-navigation') no-repeat center;
  320. }
  321. background-size: 16px;
  322. }
  323. }
  324. .distance {
  325. font-size: 14px;
  326. color: #fff;
  327. }
  328. }
  329. .device-list {
  330. .title {
  331. position: relative;
  332. font-size: 20px;
  333. font-weight: bold;
  334. color: #282828;
  335. line-height: 30px;
  336. padding-left: 32px;
  337. margin-top: 46px;
  338. margin-bottom: 24px;
  339. &::before {
  340. content: '';
  341. display: block;
  342. width: 30px;
  343. height: 30px;
  344. background: url(~assets/theme-images/ross/pc-icon-device-list.png)
  345. no-repeat center;
  346. position: absolute;
  347. left: 0;
  348. top: 0;
  349. }
  350. }
  351. .list {
  352. padding-right: 16px;
  353. }
  354. .device {
  355. padding: 20px 16px;
  356. box-sizing: border-box;
  357. background: #f3f5f6;
  358. margin-top: 16px;
  359. &:first-child {
  360. margin-top: 0;
  361. }
  362. .info {
  363. width: 80%;
  364. .name {
  365. font-size: 18px;
  366. color: #282828;
  367. }
  368. .code {
  369. margin-top: 12px;
  370. font-size: 14px;
  371. color: #666;
  372. }
  373. }
  374. .detail {
  375. display: flex;
  376. justify-content: center;
  377. align-items: center;
  378. width: 80px;
  379. height: 32px;
  380. border-radius: 4px;
  381. font-size: 14px;
  382. color: #ffffff;
  383. cursor: pointer;
  384. @include themify($themes) {
  385. background: themed('color');
  386. }
  387. }
  388. }
  389. }
  390. }
  391. }
  392. // 移动 端
  393. @media screen and (max-width: 768px) {
  394. .page-title {
  395. display: none;
  396. }
  397. .auth-card-content {
  398. width: 100vw;
  399. height: 100vh;
  400. position: fixed;
  401. left: 0;
  402. top: 0;
  403. display: flex;
  404. justify-content: center;
  405. align-items: center;
  406. z-index: 9;
  407. .auth-card-popup {
  408. position: relative;
  409. width: 86vw;
  410. img {
  411. display: block;
  412. width: 100%;
  413. height: auto;
  414. }
  415. .el-icon-circle-close {
  416. position: absolute;
  417. top: -8vw;
  418. right: 0;
  419. font-size: 7vw;
  420. color: #fff;
  421. cursor: pointer;
  422. }
  423. }
  424. }
  425. .page-top {
  426. .swiper {
  427. position: relative;
  428. height: 100vw;
  429. background: #f7f7f7;
  430. ::v-deep {
  431. img {
  432. height: 100vw;
  433. }
  434. }
  435. .auth-card {
  436. position: absolute;
  437. width: auto;
  438. height: 20.6vw;
  439. display: block;
  440. bottom: 4vw;
  441. left: 4vw;
  442. z-index: 2;
  443. }
  444. }
  445. }
  446. .page-content {
  447. .bg-container {
  448. background: url(~assets/theme-images/ross/h5-club-info-bg.png) center
  449. no-repeat;
  450. background-size: 100vw;
  451. box-sizing: border-box;
  452. background-position-y: 4vw;
  453. background-color: #f3920d;
  454. padding-bottom: 5vw;
  455. }
  456. .auth {
  457. width: 92vw;
  458. box-sizing: border-box;
  459. background: #fef5e8;
  460. margin: 0 auto;
  461. margin-top: 3.2vw;
  462. padding: 4vw 3.5vw;
  463. border-radius: 0.8vw;
  464. .auth-icon {
  465. height: 6.2vw;
  466. background: url(~assets/theme-images/ross/h5-icon-auth.png) no-repeat
  467. left center;
  468. background-size: auto 6.2vw;
  469. }
  470. .auth-info {
  471. font-size: 0;
  472. margin-top: 2.2vw;
  473. span {
  474. font-size: 3.6vw;
  475. line-height: 5.8vw;
  476. color: #f3920d;
  477. &.font-bold {
  478. font-weight: bold;
  479. }
  480. }
  481. }
  482. }
  483. .club-info {
  484. padding: 4vw;
  485. width: 100vw;
  486. min-height: 43.4vw;
  487. .info {
  488. width: 67vw;
  489. .name {
  490. font-size: 4.8vw;
  491. color: #fff;
  492. font-weight: bold;
  493. margin-bottom: 4vw;
  494. }
  495. .mobile,
  496. .address {
  497. position: relative;
  498. padding-left: 5vw;
  499. margin-top: 1.6vw;
  500. line-height: 5vw;
  501. font-size: 3.2vw;
  502. color: #fff;
  503. &::after {
  504. content: '';
  505. display: block;
  506. width: 4vw;
  507. height: 5vw;
  508. position: absolute;
  509. left: 0;
  510. top: 0;
  511. background-size: 4vw 4vw;
  512. background-repeat: no-repeat;
  513. background-position: center;
  514. }
  515. }
  516. .mobile {
  517. &::after {
  518. @include themify($themes) {
  519. background-image: themed('h5-icon-mobile');
  520. }
  521. }
  522. }
  523. .address {
  524. &::after {
  525. @include themify($themes) {
  526. background-image: themed('h5-icon-address');
  527. }
  528. }
  529. }
  530. }
  531. .logo {
  532. position: relative;
  533. width: 18vw;
  534. height: 18vw;
  535. border-radius: 9vw 9vw 0 9vw;
  536. overflow: hidden;
  537. background: #fff;
  538. display: flex;
  539. &::after {
  540. position: absolute;
  541. bottom: 0;
  542. right: 0;
  543. content: '';
  544. display: block;
  545. width: 3.6vw;
  546. height: 3.6vw;
  547. background: url(~assets/theme-images/ross/h5-icon-avatar-v.png)
  548. no-repeat center;
  549. background-size: 3.6vw;
  550. }
  551. }
  552. .navigation {
  553. display: flex;
  554. justify-content: center;
  555. align-items: center;
  556. width: 14.4vw;
  557. height: 6.4vw;
  558. border-radius: 0.4vw;
  559. font-size: 3.2vw;
  560. color: #f3920d;
  561. border: 1px solid #fff;
  562. background-color: #fff;
  563. &::after {
  564. content: '';
  565. display: block;
  566. width: 3.6vw;
  567. height: 3.6vw;
  568. margin-left: 0.4vw;
  569. @include themify($themes) {
  570. background: themed('h5-icon-navigation') no-repeat center;
  571. background-size: 3.6vw;
  572. }
  573. }
  574. }
  575. .distance {
  576. font-size: 3vw;
  577. color: #fff;
  578. }
  579. }
  580. .device-list {
  581. padding: 0 4vw;
  582. .title {
  583. position: relative;
  584. padding-left: 6.8vw;
  585. margin-top: 9.6vw;
  586. margin-bottom: 4vw;
  587. font-size: 4vw;
  588. font-weight: bold;
  589. color: #101010;
  590. &::before {
  591. content: '';
  592. display: block;
  593. width: 4.4vw;
  594. height: 4.4vw;
  595. background: url(~assets/theme-images/ross/h5-icon-device-list.png)
  596. no-repeat center;
  597. position: absolute;
  598. left: 0;
  599. top: 0;
  600. }
  601. }
  602. .device {
  603. padding: 4.4vw 3.2vw;
  604. background: #f3f5f6;
  605. margin-bottom: 3.2vw;
  606. .info {
  607. width: 74%;
  608. .name {
  609. font-size: 3.6vw;
  610. color: #282828;
  611. }
  612. .code {
  613. margin-top: 3.2vw;
  614. font-size: 3vw;
  615. color: #666;
  616. }
  617. }
  618. .detail {
  619. display: flex;
  620. justify-content: center;
  621. align-items: center;
  622. width: 15.8vw;
  623. height: 6.4vw;
  624. border-radius: 0.4vw;
  625. font-size: 3vw;
  626. color: #ffffff;
  627. @include themify($themes) {
  628. background: themed('color');
  629. }
  630. }
  631. }
  632. }
  633. }
  634. }
  635. </style>