ll
liukangdong
2024-11-29 b850badcf800eff5819e0789d1b81e5e27fcd037
h5/pages/index.vue
@@ -1,6 +1,6 @@
<template>
   <view class="main_app">
      <view class="hone_name title">{{ userInfo.name }},欢迎登录</view>
      <view class="hone_name title">{{ userInfo.realname }},欢迎登录</view>
      <view class="home_con">
         <image class="bg" src="@/static/home/home_bg.jpg" mode=""></image>
         <view class="h1">阜宁文体中心</view>
@@ -20,19 +20,21 @@
            <view class="name">{{item.name}}</view>
         </view>
      </view>
      <view class="loginout" @click="loginOut">退出登陆</view>
   </view>
</template>
<script>
<script>
   import { logoutPost } from '@/api'
   export default {
      data() {
         return {
            userInfo: uni.getStorageSync('userInfo') || {},
            list1: [{
                  name: '扫码巡检',
                  url: '',
                  img: require('@/static/home/ic_fangkebaobei@2x.png'),
            list1: [
               {
                  name: '新增工单',
                  url: '/pages/workOrder/edit',
                  img: require('@/static/home/ic_xinzenggongdan@2x.png'),
                  auth: 'weixin:menu:visitcar'
               },
               {
@@ -72,7 +74,14 @@
               url: item.url
            })
         },
         loginOut() {
            this.$store.commit('empty')
            logoutPost()
            uni.redirectTo({
               url: '/pages/login'
            })
         },
      }
   }
</script>
@@ -131,5 +140,21 @@
            }
         }
      }
      .loginout {
         position: fixed;
         bottom: 88rpx;
         left: 50%;
         transform: translate(-50%, 0);
         width: 152rpx;
         height: 60rpx;
         border-radius: 30rpx;
         border: 1rpx solid $primaryColor;
         color: $primaryColor;
         font-size: 26rpx;
         display: flex;
         justify-content: center;
         align-items: center;
      }
   }
</style>