去掉接口token
This commit is contained in:
@@ -2,13 +2,17 @@
|
||||
export default {
|
||||
onLaunch: function() {
|
||||
// console.log('App Launch')
|
||||
uni.removeStorageSync('token');
|
||||
},
|
||||
onShow: function() {
|
||||
// console.log('App Show')
|
||||
uni.removeStorageSync('token');
|
||||
},
|
||||
onHide: function() {
|
||||
console.log('App Hide')
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
@@ -125,7 +125,7 @@
|
||||
import { ref, watch } from 'vue'
|
||||
import { onLoad, onUnload, onShow } from '@dcloudio/uni-app'
|
||||
import moment from 'moment';
|
||||
import { getActivityList } from '../api/api.js'
|
||||
// import { getActivityList } from '../api/api.js'
|
||||
|
||||
// ===================== 响应式数据 =====================
|
||||
const activeTab = ref('list') // 'list' 或 'my'
|
||||
|
||||
@@ -212,7 +212,7 @@
|
||||
import { ref, onMounted } from 'vue'
|
||||
import {onLoad,onUnload} from '@dcloudio/uni-app'
|
||||
import moment from 'moment'
|
||||
import {getActivityDetails,confirmResident,cancelActivity,getActivityLive} from '../api/api.js'
|
||||
// import {getActivityDetails,confirmResident,cancelActivity,getActivityLive} from '../api/api.js'
|
||||
|
||||
// 响应式数据
|
||||
const activeTab = ref('detail') // 'detail' 或 'status'
|
||||
|
||||
@@ -84,7 +84,7 @@
|
||||
|
||||
<script setup>
|
||||
import { ref, computed, onUnmounted } from 'vue';
|
||||
import {getLoginBySms,getSendCode} from '../api/api.js'
|
||||
// import {getLoginBySms,getSendCode} from '../api/api.js'
|
||||
|
||||
// ========== 响应式数据 ==========
|
||||
// 手机号
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
<script setup>
|
||||
import { ref, computed } from 'vue';
|
||||
import {onLoad} from "@dcloudio/uni-app"
|
||||
import {getLoginPassword} from '../api/api.js'
|
||||
// import {getLoginPassword} from '../api/api.js'
|
||||
|
||||
// 响应式数据
|
||||
const phoneNumber = ref('');
|
||||
|
||||
@@ -56,7 +56,7 @@
|
||||
<script setup>
|
||||
import { ref } from 'vue'
|
||||
import { onLoad ,onShow,onUnload} from '@dcloudio/uni-app'
|
||||
import { getNoticeList } from '../api/api.js'
|
||||
// import { getNoticeList } from '../api/api.js'
|
||||
|
||||
const noticeList = ref([])
|
||||
const refreshing = ref(false)
|
||||
|
||||
@@ -73,7 +73,7 @@
|
||||
<script setup>
|
||||
import { ref, onMounted } from 'vue'
|
||||
import { onLoad, onShow } from '@dcloudio/uni-app'
|
||||
import {getNoticeDetails} from '../api/api.js'
|
||||
// import {getNoticeDetails} from '../api/api.js'
|
||||
|
||||
const isLoading = ref(false)
|
||||
const noticeDetail = ref({})
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
<script setup>
|
||||
import { ref } from 'vue'
|
||||
import {onLoad} from '@dcloudio/uni-app'
|
||||
import {getAccessDevices,getAccessOpen} from '../api/api.js'
|
||||
// import {getAccessDevices,getAccessOpen} from '../api/api.js'
|
||||
|
||||
// 响应式数据:选中的门索引、开门成功提示
|
||||
const selectedDoor = ref(-1) // -1表示未选中
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
<script setup>
|
||||
import { ref, computed, onMounted, watch } from 'vue'
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import { getVillageList, getVillageSwitch } from "../api/api.js"
|
||||
// import { getVillageList, getVillageSwitch } from "../api/api.js"
|
||||
|
||||
// 响应式数据
|
||||
const searchText = ref('')
|
||||
|
||||
@@ -197,7 +197,7 @@ const getNoticeMore = () =>{
|
||||
}
|
||||
// 接收选择小区返回的参数
|
||||
const slelctHomeData = (data) =>{
|
||||
console.log('收到B页面返回的数据:', data)
|
||||
// console.log('收到B页面返回的数据:', data)
|
||||
if(data.name){
|
||||
currentCommunity.value = data.name
|
||||
}
|
||||
@@ -299,10 +299,10 @@ const payMentClick =() =>{
|
||||
}
|
||||
// 点击小区选择
|
||||
const navigateToPage = () => {
|
||||
const token = uni.getStorageSync('token') || '';
|
||||
// const token = uni.getStorageSync('token') || '';
|
||||
const cachedVillageId = uni.getStorageSync('currentVillageId');
|
||||
// 未登录 或 未绑定小区 → 去我的页面认证
|
||||
if (!token || !cachedVillageId || cachedVillageId === '0' || cachedVillageId === 0) {
|
||||
if ( !cachedVillageId || cachedVillageId === '0' || cachedVillageId === 0) {
|
||||
currentCommunity.value = '请去认证小区';
|
||||
uni.setStorageSync('currentCommunity', '请去认证小区');
|
||||
uni.showToast({
|
||||
@@ -373,15 +373,10 @@ const moreClick = () =>{
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.content-class{
|
||||
// margin: 0 20rpx;
|
||||
// padding: 2rpx;
|
||||
background-color: #f9f9f9;
|
||||
padding-bottom: 100rpx;
|
||||
box-sizing: border-box; /* 保证padding不会撑大容器 */
|
||||
@@ -390,7 +385,6 @@ const moreClick = () =>{
|
||||
.nar-top{
|
||||
height: 400rpx;
|
||||
width: 100%;
|
||||
// background-color: #C0E4FB;
|
||||
background: repeating-linear-gradient(to right, #EDF4FA , #C0E4FB);
|
||||
position: absolute;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user