analysis-box.vue 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. <template>
  2. <view>
  3. <view class="block" v-if="!subscribe">
  4. <view class="item-container" @click="navRoseChart">
  5. <view class="analysis-name">
  6. <view class="t-icon t-icon-xtubiao-"></view>
  7. <text class="analysis-text">优劣科目分析</text>
  8. </view>
  9. </view>
  10. <view class="item-container" @click="navRadarChart">
  11. <view class="analysis-name">
  12. <view class="t-icon t-icon-xtubiao-3"></view>
  13. <text class="analysis-text">考试能力分析</text>
  14. </view>
  15. </view>
  16. <view class="item-container" @click="navArcbarChart">
  17. <view class="analysis-name">
  18. <view class="t-icon t-icon-xtubiao-6"></view>
  19. <text class="analysis-text">成绩占比分析</text>
  20. </view>
  21. </view>
  22. </view>
  23. <view class="nosub-box" v-if="subscribe">
  24. <view style="display: flex; align-items: center;margin: 30rpx 0 0 15rpx;">
  25. <!-- <view class="t-icon t-icon-xtubiao-3" style="width: 50rpx;height: 50rpx;"></view> -->
  26. <view class="nosub-text">综合分析模块</view>
  27. </view>
  28. <view class="nosub-content">对孩子成绩综合全面分析</view>
  29. <view class="nosub-content">点击订阅</view>
  30. </view>
  31. </view>
  32. </template>
  33. <script>
  34. import {mapState} from 'vuex'
  35. export default {
  36. name: "analysis-box",
  37. computed:{
  38. ...mapState('m_parent',['subscribe'])
  39. },
  40. data() {
  41. return {
  42. };
  43. },
  44. methods: {
  45. //导航玫瑰图页面
  46. navRoseChart(e) {
  47. console.log(e);
  48. uni.navigateTo({
  49. url: "/gradepkg/rose-chart/rose-chart"
  50. })
  51. },
  52. //导航雷达图页面
  53. navRadarChart(e) {
  54. console.log(e);
  55. uni.navigateTo({
  56. url: "/gradepkg/radar-chart/radar-chart"
  57. })
  58. },
  59. //导航到进度条页面
  60. navArcbarChart(e) {
  61. console.log(e);
  62. uni.navigateTo({
  63. url: "/gradepkg/arcbar-chart/arcbar-chart"
  64. })
  65. },
  66. }
  67. }
  68. </script>
  69. <style lang="scss">
  70. .block {
  71. display: flex;
  72. flex-direction: column;
  73. justify-content: space-between;
  74. width: 347rpx;
  75. height: 345rpx;
  76. .item-container {
  77. display: flex;
  78. align-items: center;
  79. border-radius: 16rpx;
  80. background-color: #FFFFFF;
  81. box-shadow: 0 4rpx 8rpx rgba(0, 0, 0, 0.05);
  82. width: 347rpx;
  83. height: 100rpx;
  84. .analysis-name {
  85. display: flex;
  86. align-items: center;
  87. justify-content: flex-start;
  88. width: 100%;
  89. margin: 20rpx 0rpx 20rpx 40rpx;
  90. .analysis-text {
  91. margin: 26rpx;
  92. font-size: 30rpx;
  93. font-weight: bold;
  94. color: #3B4144;
  95. }
  96. }
  97. }
  98. }
  99. .nosub-box{
  100. display: flex;
  101. flex-direction: column;
  102. border-radius: 16rpx;
  103. background: $card-back-base64;
  104. background-size: cover;//背景图片自适应
  105. box-shadow: 0 4rpx 8rpx rgba(0, 0, 0, 0.05);
  106. width: 347rpx;
  107. height: 345rpx;
  108. .nosub-text{
  109. font-size: 40rpx;
  110. font-weight: bold;
  111. color: #ab725c;
  112. margin-left: 10rpx;
  113. }
  114. .nosub-content{
  115. margin: 25rpx 25rpx 0 25rpx;
  116. font-size: 45rpx;
  117. font-weight: bold;
  118. color: #ab725c;
  119. }
  120. }
  121. </style>