| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- <!-- 我的 -->
- <template>
- <view id="mine">
- <teacherMine class="flex-box-page" ref="teacherMine" v-if="userType==1"></teacherMine>
- <pupilMine class="flex-box-page" ref="pupilMine" v-if="userType==2"></pupilMine>
- </view>
- </template>
- <script>
- import {
- teacherMine
- } from '@/pages/views/teacherPage/teacherMine'
- import {
- pupilMine
- } from '@/pages/views/pupilPage/pupilMine'
-
- export default {
- onShareAppMessage(res) {
- return {
- title: '实验室安全智慧化管控系统',
- path: '/pages/views/login/login'
- }
- },
- components: {
- teacherMine,
- pupilMine,
- },
-
- data() {
- return {
- userType: 0,
- }
- },
- onLoad() {
- },
- onShow() {
- this.userType = uni.getStorageSync('userType')
- this.$nextTick(()=>{
- if(this.userType == 1){
- this.$refs.teacherMine.initialize();
- }else if(this.userType == 2){
- this.$refs.pupilMine.initialize();
- }
- })
- },
- methods: {
-
- },
- }
- </script>
- <style lang="stylus" scoped>
- #mine {
- height: 100%;
- display: flex;
- flex-direction: column;
- .flex-box-page{
- flex:1;
- display: flex;
- flex-direction: column;
- }
- }
- </style>
|