球星卡微信小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

747 lines
18 KiB

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
4 years ago
4 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
  1. <template>
  2. <view class="flex-col page">
  3. <lf-header :spreadOut="true" :diy="true" :boderBottom="true" bgColor="#ffffff">
  4. <view class="header-nav">
  5. <image class="searchIcon" src="@/static/icon/search.png" @click="$url('/pages/ratingQuery/ratingQuery')"></image>
  6. <text class="title">评级中心</text>
  7. </view>
  8. </lf-header>
  9. <view class="flex-col items-center group_3">
  10. <image src="@/static/icon/line.png" class="image_6" />
  11. <view class="flex-col section_2">
  12. <view class="flex-col">
  13. <!-- 用户信息 -->
  14. <view class="flex-col section_3" @click="nextToSettings">
  15. <view class="bottom-group flex-col items-center view_3">
  16. <view class="flex-col items-end image-wrapper">
  17. <image class="avatar" :src="user.avatar" mode="aspectFill" v-if="user.avatar"></image>
  18. <image class="avatar" src="@/static/mrtx.png" mode="aspectFill" v-else></image>
  19. <image src="@/static/icon/level.png" class="image_7" />
  20. <view class="flex-col items-center badge" v-if="$isRight(dots.system)">
  21. <text>{{ dots.system > 99 ? '99+' : dots.system }}</text>
  22. </view>
  23. </view>
  24. </view>
  25. <view class="justify-center group_5">
  26. <view class="user-name">{{ user.nick_name || '您未登录,点击登录' }}</view>
  27. <image src="@/static/icon/rightArrow.png" class="image_8" />
  28. </view>
  29. </view>
  30. <!-- 我的订单 -->
  31. <view class="section_4 flex-col">
  32. <view class="justify-between">
  33. <text class="text_4">我的订单</text>
  34. <view class="right-group flex-row" @click="nextToOrder">
  35. <text>全部</text>
  36. <image src="@/static/icon/rightArrow.png" class="image_8" />
  37. </view>
  38. </view>
  39. <view class="justify-between equal-division" >
  40. <view class="equal-division-item flex-col" @click="nextToOrder(1)">
  41. <view class="top-group flex-col items-center">
  42. <image src="@/static/icon/order1.png" class="image_11" />
  43. <view class="flex-col items-center badge_1" v-if="$isRight(dots.unconfirmed)">
  44. <text>{{ dots.unconfirmed }}</text>
  45. </view>
  46. </view>
  47. <text class="text_7">待确认</text>
  48. </view>
  49. <view class="flex-col items-center equal-division-item_1" @click="nextToOrder(2)">
  50. <view class="top-group flex-col items-center">
  51. <image src="@/static/icon/order2.png" class="image_11" />
  52. <view class="flex-col items-center badge_2" v-if="$isRight(dots.rating)">
  53. <text>{{ dots.rating }}</text>
  54. </view>
  55. </view>
  56. <text class="text_7">评级中</text>
  57. </view>
  58. <view class="flex-col items-center equal-division-item_2" @click="nextToOrder(3)">
  59. <view class="top-group flex-col items-center">
  60. <image src="@/static/icon/order3.png" class="image_11" />
  61. <view class="flex-col items-center badge_2" v-if="$isRight(dots.paying)">
  62. <text>{{ dots.paying }}</text>
  63. </view>
  64. </view>
  65. <text class="text_11">待付款</text>
  66. </view>
  67. <view class="equal-division-item flex-col" @click="nextToOrder(4)">
  68. <view class="top-group flex-col items-center">
  69. <image src="@/static/icon/order4.png" class="image_11" />
  70. <view class="flex-col items-center badge_2" v-if="$isRight(dots.shipping)">
  71. <text>{{ dots.shipping }}</text>
  72. </view>
  73. </view>
  74. <text class="text_7">待收货</text>
  75. </view>
  76. </view>
  77. </view>
  78. <view class="tips_panel" v-if="tips.length > 0">
  79. <u-notice-bar :text="tips" direction="column" speed="250" @click="tipsDetail"></u-notice-bar>
  80. </view>
  81. <!-- 快速评级 -->
  82. <view class="section_4 flex-col">
  83. <view class="justify-between group_9">
  84. <view class="group_10">
  85. <text class="text_14">开始评级</text>
  86. </view>
  87. <view class="right-group flex-row" @click="$url('/packages/article/article?type=service_standard')">
  88. <text>服务及收费标准</text>
  89. <image src="@/static/icon/rightArrow.png" class="image_8" />
  90. </view>
  91. </view>
  92. <view class="grid">
  93. <view class="flex-col items-center grid-item_1" @click="rateIndex = 0" :class="{'grid-item-active': rateIndex == 0}">
  94. <text class="qxk-iconfont qxk-icon-mulu lf-font-40"></text>
  95. <view class="qxk-title">
  96. <text class="text_17">卡品&签字评级</text>
  97. </view>
  98. <text class="qxk-subtitle">卡片品相和签字品相评级鉴定</text>
  99. </view>
  100. <view class="flex-col items-center grid-item_1" @click="rateIndex = 1" :class="{'grid-item-active': rateIndex == 1}">
  101. <text class="qxk-iconfont qxk-icon-xinwen-moren lf-font-40"></text>
  102. <view class="qxk-title">
  103. <text class="text_9">卡品评级</text>
  104. </view>
  105. <text class="qxk-subtitle">仅对卡片品相评级鉴定</text>
  106. </view>
  107. <view class="grid-item_2 flex-col items-center" @click="rateIndex = 2" :class="{'grid-item-active': rateIndex == 2}">
  108. <text class="qxk-iconfont qxk-icon-tuwenguanli lf-font-40"></text>
  109. <view class="qxk-title">
  110. <text class="text_19">签字评级</text>
  111. </view>
  112. <text class="qxk-subtitle">仅对卡片签字评级鉴定</text>
  113. </view>
  114. <view class="grid-item_2 flex-col items-center" @click="rateIndex = 3" :class="{'grid-item-active': rateIndex == 3}">
  115. <text class="qxk-iconfont qxk-icon-kefujiqirenbeifen lf-font-70"></text>
  116. <view class="qxk-title">
  117. <text class="text_19">鉴定装壳服务</text>
  118. </view>
  119. <text class="qxk-subtitle">仅对卡片鉴定真伪并套壳封固</text>
  120. </view>
  121. </view>
  122. <view class="flex-col group_11">
  123. <view class="justify-between group_12">
  124. <view class="flex-row">
  125. <checkbox-group @change="onAgreementCheck()">
  126. <checkbox color="#e6a33c" :checked="isConsentAgreement"></checkbox>
  127. </checkbox-group>
  128. <view class="group_14">
  129. <text class="text_22">阅读并同意</text>
  130. <text class="text_23" @click="$url('/packages/article/article?type=grade_agreement')">服务协议</text>
  131. </view>
  132. </view>
  133. <!-- <text class="text_24">45/</text> -->
  134. </view>
  135. <view class="flex-col items-center button" @click="nextToGrading">
  136. <text>下一步</text>
  137. </view>
  138. </view>
  139. </view>
  140. <!-- 已评卡 -->
  141. <view class="flex-col section_8" v-if="$isRight(evaluated_order)">
  142. <view class="justify-between group_15" @click="nextToSuOrderList">
  143. <text>已评卡</text>
  144. <image
  145. src="@/static/icon/rightArrow.png"
  146. class="image_8" />
  147. </view>
  148. <view class="flex-row equal-division_1">
  149. <view class="flex-col items-center equal-division-item_3" @click="toSubOrder(item.id)" v-for="(item, index) in evaluated_order" :key="index">
  150. <image :src="item.itemImage" class="image_23" mode="aspectFill" />
  151. <text class="text_27">{{ item.title }}</text>
  152. </view>
  153. </view>
  154. </view>
  155. <!-- 评级标准 -->
  156. <view class="justify-between section_9" @click="$url('/pages/ratingCriteria/ratingCriteria')">
  157. <text>评级标准</text>
  158. <image
  159. src="@/static/icon/rightArrow.png"
  160. class="image_8" />
  161. </view>
  162. </view>
  163. </view>
  164. </view>
  165. </view>
  166. </template>
  167. <script>
  168. import lfHeader from '@/components/lf-header.vue';
  169. import { my ,sysInfo } from '@/service/index.js';
  170. import { ratingSearch } from '@/service/grading.js';
  171. export default {
  172. components: {
  173. lfHeader
  174. },
  175. data() {
  176. return {
  177. isConsentAgreement: false,
  178. rateIndex: 0,
  179. user: {},
  180. dots: {},
  181. evaluated_order: [],
  182. showCount: 0,
  183. tipsDatas:[],
  184. tips:[],
  185. };
  186. },
  187. onShow(){
  188. this.showCount++;
  189. if(this.showCount > 1){
  190. this.getUserCenterDetail();
  191. }
  192. },
  193. async onLoad(query){
  194. //如果看过协议,默认协议勾选住
  195. if(uni.getStorageSync('AgreementChecked')){
  196. this.isConsentAgreement = true
  197. }
  198. this.getSysInfo();
  199. if(query && query.q){
  200. const q = decodeURIComponent(query.q);
  201. console.log("query",q);
  202. let sid = q.split('s=')[1];
  203. console.log("sid",sid)
  204. if(sid){
  205. let res = await ratingSearch(sid);
  206. let datas = res.data.datas;
  207. if(this.$isRight(datas.sub_order)){ // 查询到订单,默认取第一条
  208. let base_data = encodeURIComponent(JSON.stringify(datas));
  209. this.$url('/packages/ratingQueryDetail/ratingQueryDetail?data='+ base_data);
  210. }else{
  211. uni.showModal({
  212. title: '提示',
  213. content: '该评级编号暂无订单,换个编号试试?',
  214. showCancel: false
  215. })
  216. }
  217. }
  218. }else{
  219. this.getUserCenterDetail();
  220. }
  221. },
  222. methods: {
  223. onAgreementCheck(e){
  224. this.isConsentAgreement = !this.isConsentAgreement
  225. },
  226. tipsDetail(index){
  227. console.log("tipsDetail",index)
  228. console.log("tipsDetail id",this.tipsDatas[index].id)
  229. if(this.tipsDatas[index].jump){
  230. uni.navigateTo({
  231. url:'/packages/article/article?type=tips&id='+this.tipsDatas[index].id
  232. })
  233. }
  234. },
  235. async getSysInfo(){
  236. let res = await sysInfo();
  237. //console.log("getSysInfo res",res)
  238. let sysInfoDatas = res.data.datas;
  239. uni.setStorageSync('qxk_sysinfo',sysInfoDatas);
  240. let datas = res.data.datas.tips;
  241. this.tipsDatas = datas;
  242. this.tips = datas.map((item)=>{
  243. return item.title
  244. })
  245. },
  246. async toSubOrder(value){
  247. let res = await ratingSearch(value);
  248. let datas = res.data.datas;
  249. let base_data = encodeURIComponent(JSON.stringify(datas));
  250. this.$url('/packages/ratingQueryDetail/ratingQueryDetail?data='+ base_data);
  251. },
  252. async getUserCenterDetail(){
  253. let res = await my();
  254. if(this.$isRight(res)){
  255. uni.setStorageSync('userInfo', res.data.datas.user);
  256. this.user = res.data.datas.user;
  257. this.dots = res.data.datas.dots;
  258. let evaluated_order = res.data.datas.evaluated_order;
  259. evaluated_order.forEach(item => item.itemImage = String(item.itemImage).split(',')[0]);
  260. this.evaluated_order = evaluated_order;
  261. }
  262. },
  263. nextToGrading(){
  264. if(!this.isConsentAgreement) return this.$msg('请先阅读并同意协议');
  265. let rateIndex = this.rateIndex;
  266. if(this.$isRight(this.user)){
  267. this.$url('/pages/write/baseInfo?rate_index='+ rateIndex);
  268. }else{
  269. this.$url('/pages/login/login');
  270. }
  271. },
  272. nextToOrder(current){
  273. if(this.$isRight(this.user)){
  274. let url = '/pages/order/order';
  275. if(this.$valueType(current) === 'number'){
  276. url += '?current='+ current;
  277. }
  278. this.$url(url);
  279. }else{
  280. this.$url('/pages/login/login');
  281. }
  282. },
  283. nextToSuOrderList(){
  284. this.$url('/packages/subOrderList/subOrderList')
  285. },
  286. nextToSettings(){
  287. if(this.$isRight(this.user)){
  288. this.$url('/pages/settings/settings');
  289. }else{
  290. // this.$url('/pages/login/login', {type: 'redirect'})
  291. this.$url('/pages/login/login');
  292. }
  293. }
  294. }
  295. };
  296. </script>
  297. <style scoped lang="scss">
  298. .tips_panel{
  299. background-color: white;
  300. }
  301. .header-nav{
  302. text-align: center;
  303. position: relative;
  304. width: 720rpx;
  305. display: flex;
  306. justify-content: center;
  307. .searchIcon{
  308. position: absolute;
  309. left: 10rpx;
  310. top: 5rpx;
  311. width: 40rpx;
  312. height: 40rpx;
  313. z-index: 999999;
  314. }
  315. }
  316. .bottom-group {
  317. position: relative;
  318. }
  319. .section_4 {
  320. border-top:solid 1px #F1F1F1;
  321. padding: 40rpx 32rpx;
  322. background-color: rgb(255, 255, 255);
  323. }
  324. .image_8 {
  325. width: 44rpx;
  326. height: 44rpx;
  327. }
  328. .equal-division-item {
  329. width: 84rpx;
  330. }
  331. .grid-item_2 {
  332. color: rgb(51, 51, 51);
  333. font-size: 28rpx;
  334. font-weight: 500;
  335. line-height: 40rpx;
  336. white-space: nowrap;
  337. padding: 28rpx 0 24rpx;
  338. border-radius: 10rpx;
  339. border: solid 2rpx rgb(195, 195, 195);
  340. }
  341. .top-group {
  342. color: rgb(255, 255, 255);
  343. font-size: 24rpx;
  344. font-weight: 500;
  345. line-height: 26rpx;
  346. white-space: nowrap;
  347. padding-top: 2rpx;
  348. position: relative;
  349. }
  350. .image_11 {
  351. width: 60rpx;
  352. height: 60rpx;
  353. }
  354. .image_17 {
  355. width: 50rpx;
  356. height: 50rpx;
  357. }
  358. .image_23 {
  359. border-radius: 10rpx;
  360. width: 200rpx;
  361. height: 240rpx;
  362. }
  363. .right-group {
  364. color: rgb(153, 153, 153);
  365. font-size: 28rpx;
  366. font-weight: 500;
  367. line-height: 40rpx;
  368. white-space: nowrap;
  369. }
  370. .text_7 {
  371. margin-top: 12rpx;
  372. color: rgb(85, 85, 85);
  373. font-size: 28rpx;
  374. font-weight: 500;
  375. line-height: 40rpx;
  376. white-space: nowrap;
  377. }
  378. .text_9 {
  379. margin-top: 14rpx;
  380. }
  381. .text_19 {
  382. margin-top: 14rpx;
  383. }
  384. .page {
  385. background-color: #f6f6f6;
  386. width: 100%;
  387. overflow-y: auto;
  388. height: 100%;
  389. }
  390. .group_3 {
  391. padding-bottom: 2024rpx;
  392. flex: 1 1 auto;
  393. overflow-y: auto;
  394. position: relative;
  395. }
  396. .image_6 {
  397. width: 100vw;
  398. height: 1vw;
  399. }
  400. .section_2 {
  401. padding-bottom: 14rpx;
  402. background-color: rgb(246, 246, 246);
  403. top: 0;
  404. right: 0;
  405. bottom: 0;
  406. left: 0;
  407. position: absolute;
  408. }
  409. .section_3 {
  410. padding: 40rpx 0 38rpx;
  411. background-color: rgb(255, 255, 255);
  412. }
  413. .section_8 {
  414. margin-top: 30rpx;
  415. padding: 40rpx 0;
  416. background-color: rgb(255, 255, 255);
  417. }
  418. .section_9 {
  419. margin-top: 30rpx;
  420. padding: 40rpx 32rpx 30rpx;
  421. color: rgb(51, 51, 51);
  422. font-size: 32rpx;
  423. font-weight: 700;
  424. line-height: 44rpx;
  425. white-space: nowrap;
  426. background-color: rgb(255, 255, 255);
  427. }
  428. .view_3 {
  429. color: rgb(255, 255, 255);
  430. font-size: 24rpx;
  431. font-weight: 500;
  432. line-height: 34rpx;
  433. white-space: nowrap;
  434. }
  435. .group_5 {
  436. margin-top: 20rpx;
  437. color: rgb(51, 51, 51);
  438. font-size: 34rpx;
  439. font-weight: 600;
  440. line-height: 48rpx;
  441. white-space: nowrap;
  442. }
  443. .equal-division {
  444. margin: 36rpx 28rpx 0;
  445. }
  446. .qxk-title{
  447. margin-top:15rpx;
  448. }
  449. // .qxk-title .qxk-iconfont{
  450. // font-size:40rpx !important;
  451. // }
  452. .qxk-subtitle{
  453. white-space:normal;
  454. opacity: 0.6;
  455. font-size:18rpx;
  456. text-align:center;
  457. }
  458. .grid {
  459. margin-top: 40rpx;
  460. height: 400rpx;
  461. display: grid;
  462. grid-template-columns: repeat(2, 1fr);
  463. grid-row-gap: 20rpx;
  464. grid-column-gap: 20rpx;
  465. }
  466. .group_11 {
  467. margin-top: 40rpx;
  468. }
  469. .group_15 {
  470. padding: 0 32rpx;
  471. color: rgb(51, 51, 51);
  472. font-size: 32rpx;
  473. font-weight: 700;
  474. line-height: 44rpx;
  475. white-space: nowrap;
  476. }
  477. .equal-division_1 {
  478. margin-top: 40rpx;
  479. padding: 0 32rpx;
  480. color: rgb(51, 51, 51);
  481. font-size: 28rpx;
  482. font-weight: 500;
  483. line-height: 40rpx;
  484. white-space: nowrap;
  485. }
  486. .image-wrapper {
  487. padding-top: 72rpx;
  488. width: 112rpx;
  489. position: relative;
  490. .avatar{
  491. position: absolute;
  492. top: 0;
  493. left: 0;
  494. width: 100%;
  495. height: 100%;
  496. border-radius: 50%;
  497. }
  498. }
  499. .badge {
  500. background-color: rgb(234, 43, 43);
  501. border-radius: 17rpx;
  502. min-width: 34rpx;
  503. position: absolute;
  504. // right: 284rpx;
  505. left: 78rpx;
  506. top: 0;
  507. }
  508. .text_4 {
  509. color: rgb(51, 51, 51);
  510. font-size: 32rpx;
  511. font-weight: 700;
  512. line-height: 44rpx;
  513. white-space: nowrap;
  514. }
  515. .equal-division-item_1 {
  516. color: rgb(85, 85, 85);
  517. font-size: 28rpx;
  518. font-weight: 500;
  519. line-height: 40rpx;
  520. white-space: nowrap;
  521. }
  522. .equal-division-item_2 {
  523. padding-top: 2rpx;
  524. color: rgb(85, 85, 85);
  525. font-size: 28rpx;
  526. font-weight: 500;
  527. line-height: 40rpx;
  528. white-space: nowrap;
  529. }
  530. .group_10 {
  531. white-space: nowrap;
  532. height: 44rpx;
  533. }
  534. .grid-item {
  535. padding: 22rpx 0 30rpx;
  536. color: rgb(231, 162, 63);
  537. font-size: 28rpx;
  538. font-weight: 500;
  539. line-height: 40rpx;
  540. white-space: nowrap;
  541. border-radius: 10rpx;
  542. border: solid 2rpx rgb(231, 162, 63);
  543. }
  544. .grid-item-active{
  545. color: rgb(231, 162, 63) !important;
  546. border: solid 2rpx rgb(231, 162, 63) !important;
  547. }
  548. .grid-item_1 {
  549. padding: 30rpx 0 25rpx;
  550. color: rgb(51, 51, 51);
  551. font-size: 28rpx;
  552. font-weight: 500;
  553. line-height: 40rpx;
  554. white-space: nowrap;
  555. border-radius: 10rpx;
  556. border: solid 2rpx rgb(195, 195, 195);
  557. }
  558. .group_12 {
  559. padding-bottom: 20rpx;
  560. }
  561. .button {
  562. padding: 26rpx 0;
  563. color: rgb(255, 255, 255);
  564. font-size: 32rpx;
  565. font-weight: 600;
  566. line-height: 44rpx;
  567. white-space: nowrap;
  568. background-color: rgb(231, 162, 63);
  569. border-radius: 10rpx;
  570. }
  571. .equal-division-item_3 {
  572. // flex: 1 1 244rpx;
  573. align-items: flex-start;
  574. margin-right: 42rpx;
  575. &:nth-child(3n){
  576. margin-right: 0rpx;
  577. }
  578. }
  579. .equal-division-item_4 {
  580. flex: 1 1 244rpx;
  581. }
  582. .equal-division-item_5 {
  583. flex: 1 1 244rpx;
  584. }
  585. .image_7 {
  586. margin-right: 12rpx;
  587. border-radius: 50%;
  588. width: 40rpx;
  589. height: 40rpx;
  590. position: relative;
  591. z-index: 99;
  592. }
  593. .text_11 {
  594. margin-top: 12rpx;
  595. }
  596. .text_14 {
  597. color: rgb(51, 51, 51);
  598. font-size: 32rpx;
  599. font-weight: 700;
  600. line-height: 44rpx;
  601. }
  602. .text_15 {
  603. color: rgb(119, 119, 119);
  604. font-size: 24rpx;
  605. font-weight: 500;
  606. line-height: 34rpx;
  607. }
  608. .text_17 {
  609. margin-top: 14rpx;
  610. }
  611. .text_24 {
  612. color: rgb(119, 119, 119);
  613. font-size: 28rpx;
  614. line-height: 40rpx;
  615. white-space: nowrap;
  616. }
  617. .text_27 {
  618. margin-top: 10rpx;
  619. }
  620. .text_28 {
  621. margin-top: 10rpx;
  622. }
  623. .text_29 {
  624. margin-top: 10rpx;
  625. }
  626. .badge_1 {
  627. background-color: rgb(234, 43, 43);
  628. border-radius: 13rpx;
  629. min-width: 26rpx;
  630. position: absolute;
  631. right: 6rpx;
  632. top: 0;
  633. }
  634. .badge_2 {
  635. background-color: rgb(234, 43, 43);
  636. border-radius: 13rpx;
  637. width: 26rpx;
  638. position: absolute;
  639. right: 0;
  640. top: 0;
  641. }
  642. .section_7 {
  643. border-radius: 50%;
  644. width: 40rpx;
  645. height: 40rpx;
  646. border: solid 2rpx rgb(195, 195, 195);
  647. }
  648. .group_14 {
  649. margin-left: 14rpx;
  650. white-space: nowrap;
  651. height: 40rpx;
  652. }
  653. .text_22 {
  654. color: rgb(119, 119, 119);
  655. font-size: 28rpx;
  656. line-height: 40rpx;
  657. }
  658. .text_23 {
  659. color: rgb(209, 161, 28);
  660. font-size: 28rpx;
  661. line-height: 40rpx;
  662. }
  663. .user-name{
  664. max-width: 360rpx;
  665. white-space:nowrap;
  666. overflow:hidden;
  667. text-overflow:ellipsis;
  668. }
  669. /deep/checkbox .wx-checkbox-input {
  670. border-radius: 50% !important;
  671. }
  672. </style>