mine.vue 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347
  1. <!-- 我的 -->
  2. <template>
  3. <view id="mine">
  4. <teacherMine class="flex-box-page" ref="teacherMine" v-if="userType==1"></teacherMine>
  5. <pupilMine class="flex-box-page" ref="pupilMine" v-if="userType==2"></pupilMine>
  6. </view>
  7. </template>
  8. <script>
  9. import {
  10. teacherMine
  11. } from '@/pages/views/teacherPage/teacherMine'
  12. import {
  13. pupilMine
  14. } from '@/pages/views/pupilPage/pupilMine'
  15. export default {
  16. components: {
  17. teacherMine,
  18. pupilMine,
  19. },
  20. data() {
  21. return {
  22. userType: 0,
  23. }
  24. },
  25. onLoad() {
  26. },
  27. onShow() {
  28. this.userType = uni.getStorageSync('userType')
  29. this.$nextTick(()=>{
  30. if(this.userType == 1){
  31. this.$refs.teacherMine.initialize();
  32. }else if(this.userType == 2){
  33. this.$refs.pupilMine.initialize();
  34. }
  35. })
  36. },
  37. methods: {
  38. },
  39. }
  40. </script>
  41. <style lang="stylus" scoped>
  42. #mine {
  43. height: 100%;
  44. display: flex;
  45. flex-direction: column;
  46. .flex-box-page{
  47. flex:1;
  48. display: flex;
  49. flex-direction: column;
  50. }
  51. .top-max-big-box {
  52. /*background:#ffffff;*/
  53. .user-top-max-box-one {
  54. overflow hidden;
  55. background url("@/pages/images/img_wd_bg.png") no-repeat;
  56. background-size: 100%;
  57. height: 350rpx;
  58. .top-max-box-one {
  59. background #fff;
  60. margin: 40rpx 40rpx 0;
  61. z-index: 1;
  62. height: 180rpx;
  63. border-top-right-radius 20rpx;
  64. border-top-left-radius 20rpx;
  65. display flex;
  66. overflow hidden;
  67. .user-img-box {
  68. height: 120rpx;
  69. width: 100rpx;
  70. margin: 30rpx 53rpx 0 22rpx;
  71. img {
  72. height: 100rpx;
  73. width: 100rpx;
  74. border-radius: 50%;
  75. }
  76. view {
  77. font-size: 22rpx;
  78. color: #666666;
  79. text-align center;
  80. line-height: 22rpx;
  81. margin-top: 10rpx;
  82. }
  83. }
  84. .name-box {
  85. margin-top: 30rpx;
  86. .name-box-min {
  87. display flex;
  88. overflow hidden;
  89. margin-bottom: 11rpx;
  90. view:nth-child(1) {
  91. height: 48rpx;
  92. line-height: 48rpx;
  93. font-size: 30rpx;
  94. color: #333;
  95. }
  96. view:nth-child(2) {
  97. height: 30rpx;
  98. line-height: 30rpx;
  99. font-size: 20rpx;
  100. padding: 0 20rpx;
  101. margin: 9rpx 0 9rpx 20rpx;
  102. }
  103. .view-color-one {
  104. background #FDD255;
  105. }
  106. .view-color-two {
  107. background #A2A2A2;
  108. }
  109. .view-color-tree {
  110. background #0183FA;
  111. }
  112. }
  113. .name-box-user {
  114. line-height: 41rpx;
  115. font-size: 22rpx;
  116. color: #333;
  117. }
  118. }
  119. }
  120. .num-max-box {
  121. width: 670rpx;
  122. background #fff;
  123. border-bottom-right-radius 20rpx;
  124. border-bottom-left-radius 20rpx;
  125. height: 130rpx;
  126. margin: 0 40rpx;
  127. display flex;
  128. .min-num-box {
  129. flex: 1;
  130. .min-num-view {
  131. margin-top: 30rpx;
  132. height: 30rpx;
  133. line-height: 30rpx;
  134. font-size: 22rpx;
  135. text-align center
  136. }
  137. .color-one {
  138. font-weight: 700;
  139. font-size: 26rpx;
  140. color: #2B99FE;
  141. }
  142. .color-two {
  143. font-weight: 700;
  144. font-size: 26rpx;
  145. color: #FDD255;
  146. }
  147. .bottom-min-num-view {
  148. display flex;
  149. margin-top: 20rpx;
  150. .img-one {
  151. width: 25rpx;
  152. height: 28rpx;
  153. margin: 0 10rpx 0 58rpx;
  154. }
  155. .img-two {
  156. width: 28rpx;
  157. height: 26rpx;
  158. margin: 0 10rpx 0 59rpx;
  159. }
  160. view {
  161. font-size: 22rpx;
  162. }
  163. }
  164. }
  165. }
  166. .null-p {
  167. background #dedede;
  168. height: 30rpx;
  169. width: 2rpx;
  170. margin: 50rpx 0 0;
  171. }
  172. }
  173. .top-max-box-two {
  174. background: #0183FA;
  175. height: 180rpx;
  176. display flex;
  177. overflow hidden;
  178. .user-img-box {
  179. height: 120rpx;
  180. width: 100rpx;
  181. margin: 50rpx 53rpx 0 22rpx;
  182. img {
  183. height: 100rpx;
  184. width: 100rpx;
  185. border-radius: 50%;
  186. }
  187. view {
  188. font-size: 22rpx;
  189. color: #fff;
  190. text-align center;
  191. line-height: 22rpx;
  192. margin-top: 10rpx;
  193. }
  194. }
  195. .name-box {
  196. margin-top: 50rpx;
  197. view:nth-child(1) {
  198. line-height: 48rpx;
  199. margin-bottom: 11rpx;
  200. font-size: 30rpx;
  201. color: #fff;
  202. }
  203. view:nth-child(2) {
  204. line-height: 41rpx;
  205. font-size: 22rpx;
  206. color: #fff;
  207. }
  208. }
  209. }
  210. .button-max-big-box {
  211. background #fff;
  212. padding: 0 20rpx;
  213. margin-top: 30rpx;
  214. .button-max-box {
  215. height: 100rpx;
  216. display flex;
  217. border-top: 1rpx solid #e0e0e0;
  218. .left-img {
  219. height: 30rpx;
  220. width: 30rpx;
  221. margin: 34rpx 44rpx 0 0;
  222. }
  223. view {
  224. line-height: 100rpx;
  225. }
  226. view:nth-child(2) {
  227. flex: 1;
  228. color: #333333;
  229. font-size: 30rpx;
  230. }
  231. .right-img {
  232. height: 24rpx;
  233. width: 12rpx;
  234. margin: 39rpx 0 0 0;
  235. }
  236. .colorA {
  237. color: #E45656 !important;
  238. }
  239. .marginType {
  240. margin-right: 12rpx;
  241. }
  242. .view-three-one {
  243. width: 30rpx;
  244. height: 30rpx;
  245. text-align center;
  246. background #FF4552;
  247. border-radius: 50%;
  248. font-size: 20rpx;
  249. line-height: 30rpx;
  250. color: #fff;
  251. margin: 36rpx 20rpx;
  252. }
  253. .view-three-two {
  254. width: 30rpx;
  255. height: 30rpx;
  256. text-align center;
  257. border-radius: 50%;
  258. font-size: 20rpx;
  259. line-height: 30rpx;
  260. color: #999;
  261. margin: 36rpx 20rpx;
  262. }
  263. .view-three-type {
  264. width: 120rpx;
  265. text-align center;
  266. color: #CCCCCC;
  267. font-size: 26rpx;
  268. }
  269. }
  270. .button-max-box:nth-child(1) {
  271. border: none;
  272. }
  273. }
  274. }
  275. .out-button {
  276. position absolute;
  277. bottom: 140rpx;
  278. left: 25rpx;
  279. width: 700rpx;
  280. height: 100rpx;
  281. line-height: 100rpx;
  282. border-radius: 10rpx;
  283. text-align center;
  284. background #E0E0E0;
  285. color: #0183FA;
  286. font-size: 30rpx;
  287. margin: 0 auto;
  288. }
  289. }
  290. </style>