diff --git a/property-uniapp-project/manifest.json b/property-uniapp-project/manifest.json
index f51dc21..39b84ec 100644
--- a/property-uniapp-project/manifest.json
+++ b/property-uniapp-project/manifest.json
@@ -2,8 +2,8 @@
"name" : "花开物业",
"appid" : "__UNI__29C3D60",
"description" : "智慧社区居民端面向小区业主使用,支持注册、验证码、账号密码多种登录方式,提供密码找回功能,账号使用安全便捷。支持多小区切换,首页设有轮播 banner、社区公告,集成远程开门、生活缴费、在线报修、访客邀请、社区活动常用服务。全服务板块统一涵盖门禁开门、线上缴费、报修申报、访客预约、投诉反馈、问卷调研、活动报名、社区公示、一键联系物业功能。个人中心可管理房屋、住户、车位、车辆信息,支持更换手机号、修改密码、消息通知设置、版本更新及账号退出,一站式满足业主居家生活、社区服务、房产车辆管理需求,实现社区生活数字化、便捷化。",
- "versionName" : "1.1.2",
- "versionCode" : 125,
+ "versionName" : "1.1.3",
+ "versionCode" : 126,
"transformPx" : false,
"uniCloud" : {
"provider" : "aliyun",
diff --git a/property-uniapp-project/pageSubPack/activity-list/activityListDetails.vue b/property-uniapp-project/pageSubPack/activity-list/activityListDetails.vue
index e275de4..e01d00a 100644
--- a/property-uniapp-project/pageSubPack/activity-list/activityListDetails.vue
+++ b/property-uniapp-project/pageSubPack/activity-list/activityListDetails.vue
@@ -177,8 +177,8 @@
取消报名
-
-
+
+
@@ -257,6 +257,12 @@ const isActivityStarted = computed(() => {
return moment().isSameOrAfter(moment(activityConent.value.startTime))
})
+// 判断活动是否已到结束时间
+const isActivityEndedByTime = computed(() => {
+ if (!activityConent.value.endTime) return false
+ return moment().isAfter(moment(activityConent.value.endTime))
+})
+
diff --git a/property-uniapp-project/pageSubPack/api/api.js b/property-uniapp-project/pageSubPack/api/api.js
index 9b15f21..2a8288b 100644
--- a/property-uniapp-project/pageSubPack/api/api.js
+++ b/property-uniapp-project/pageSubPack/api/api.js
@@ -119,7 +119,7 @@ export const getQueryRepair = (data) =>{
}
// 获取房屋列表
export const getHouseList = (data) =>{
- return get('/api/resident/my/house/list',data)
+ return get('/repairOrder/certifiedHouseList',data)
}
// 报修详情
export const getRepairDetail = (data) =>{
diff --git a/property-uniapp-project/pageSubPack/api/request.js b/property-uniapp-project/pageSubPack/api/request.js
index 1e61ae6..db4784c 100644
--- a/property-uniapp-project/pageSubPack/api/request.js
+++ b/property-uniapp-project/pageSubPack/api/request.js
@@ -2,8 +2,8 @@ import { navigateToLogin } from '@/common/checkLogin.js'
let baseUrl = '';
if (process.env.NODE_ENV === 'development') {
- // baseUrl = 'http://192.168.1.6:8080'; // 开发环境
- baseUrl = 'http://192.168.1.222:8080';
+ baseUrl = 'http://192.168.1.6:8080'; // 开发环境
+ // baseUrl = 'http://192.168.1.222:8080';
} else {
baseUrl = 'https://wuyeapi.ckdzkj.com'; // 生产环境
}
diff --git a/property-uniapp-project/pageSubPack/api/useImageUpload.js b/property-uniapp-project/pageSubPack/api/useImageUpload.js
index ffe75b0..2566576 100644
--- a/property-uniapp-project/pageSubPack/api/useImageUpload.js
+++ b/property-uniapp-project/pageSubPack/api/useImageUpload.js
@@ -1,6 +1,6 @@
// 服务器地址(与 request.js 保持一致)
const baseUrl = 'https://wuyeapi.ckdzkj.com';
-// const baseUrl = "http://192.168.1.222:8080"
+// const baseUrl = "http://192.168.1.6:8080"
/**
* 图片上传 Hook
diff --git a/property-uniapp-project/pageSubPack/inspection-revenue/inspection-details.vue b/property-uniapp-project/pageSubPack/inspection-revenue/inspection-details.vue
index 3914147..c913bf5 100644
--- a/property-uniapp-project/pageSubPack/inspection-revenue/inspection-details.vue
+++ b/property-uniapp-project/pageSubPack/inspection-revenue/inspection-details.vue
@@ -21,31 +21,16 @@
巡检点:{{ detail.pointNames }}
-
-
- 巡检结果
- 巡检人:{{ detail.inspectorName }}
- 手机号码:{{ detail.phoneNumber }}
- 巡检时间:{{ detail.inspectTime }}
- 巡检结果:
-
- {{ idx + 1 }}.{{ r }}
-
- 巡检照片:
-
-
-
-
- 暂无照片
-
-
-
- {{ sub.pointName }}
+ 巡检结果
+ 巡检点:{{ sub.pointName }}
+ 巡检人:{{ detail.inspectorName }}
+ 手机号码:{{ detail.phoneNumber }}
巡检时间:{{ sub.checkTime }}
+ 巡检状态:{{ getXunJianStatus(sub.status) }}
巡检结果:{{ sub.checkResult }}
- 备注:{{ sub.remark }}
+
巡检照片:
@@ -82,6 +67,15 @@
fetchDetail()
}
})
+
+ // 巡检状态字段映射 0正常,1异常
+ function getXunJianStatus(status){
+ const staMap = {
+ "0":'正常',
+ "1":"异常"
+ }
+ return staMap[status]
+ }
const fetchDetail = async () => {
if (!recordId) return
diff --git a/property-uniapp-project/pageSubPack/my/houseDetail.vue b/property-uniapp-project/pageSubPack/my/houseDetail.vue
index 3360096..aa41b43 100644
--- a/property-uniapp-project/pageSubPack/my/houseDetail.vue
+++ b/property-uniapp-project/pageSubPack/my/houseDetail.vue
@@ -37,7 +37,7 @@
业主
- {{form.ownerName}}
+ {{form.name}}
房间状态
@@ -58,7 +58,7 @@
住户
- {{form.name}}
+ {{form.residentName}}
房间号
@@ -220,6 +220,10 @@
id: id.value
}).then(res => {
if (res.code === 200) {
+ // 删除后清空小区缓存,避免首页仍显示已删除的小区
+ uni.setStorageSync('needReloadUserInfo', true)
+ uni.removeStorageSync('currentVillageId')
+ uni.removeStorageSync('home_cache_' + (uni.getStorageSync('userId') || ''))
uni.showToast({
title: '删除成功',
icon: 'success'
diff --git a/property-uniapp-project/pageSubPack/my/myCarIndex.vue b/property-uniapp-project/pageSubPack/my/myCarIndex.vue
index 9a44431..d62741d 100644
--- a/property-uniapp-project/pageSubPack/my/myCarIndex.vue
+++ b/property-uniapp-project/pageSubPack/my/myCarIndex.vue
@@ -162,7 +162,7 @@
min-height: 0;
height: 0;
overflow-y: auto;
- padding: 0px 40rpx;
+ padding: 0px 40rpx 140rpx;
box-sizing: border-box;
}
@@ -183,9 +183,15 @@
}
.bottom-btn {
- padding: 20rpx 30rpx 40rpx;
+ position: fixed;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ padding: 20rpx 30rpx;
+ padding-bottom: calc(20rpx + env(safe-area-inset-bottom));
flex-shrink: 0;
background-color: #f5f7fa;
+ box-shadow: 0 -4rpx 20rpx rgba(0, 0, 0, 0.05);
}
.car-item {
diff --git a/property-uniapp-project/pageSubPack/my/myHouseIndex.vue b/property-uniapp-project/pageSubPack/my/myHouseIndex.vue
index 04f229b..54d1a87 100644
--- a/property-uniapp-project/pageSubPack/my/myHouseIndex.vue
+++ b/property-uniapp-project/pageSubPack/my/myHouseIndex.vue
@@ -2,6 +2,11 @@
+
+
+
+ 暂无数据
+
@@ -218,6 +223,24 @@
box-sizing: border-box;
}
+ /* 空状态 */
+ .empty-state {
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ justify-content: center;
+ height: 100%;
+ min-height: 500rpx;
+ color: #ccc;
+ }
+
+ .empty-text {
+ font-size: 32rpx;
+ color: #999;
+ margin-top: 20rpx;
+ margin-bottom: 10rpx;
+ }
+
/* 列表 */
.house-list {
}
diff --git a/property-uniapp-project/pageSubPack/my/myParkingSpaceIndex.vue b/property-uniapp-project/pageSubPack/my/myParkingSpaceIndex.vue
index 860b6b6..2412eb3 100644
--- a/property-uniapp-project/pageSubPack/my/myParkingSpaceIndex.vue
+++ b/property-uniapp-project/pageSubPack/my/myParkingSpaceIndex.vue
@@ -196,7 +196,7 @@
.page {
flex: 1;
overflow-y: auto;
- padding: 0px 40rpx;
+ padding: 0px 40rpx 140rpx;
box-sizing: border-box;
}
@@ -217,7 +217,14 @@
}
.bottom-btn {
- padding: 20rpx 30rpx 40rpx;
+ position: fixed;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ padding: 20rpx 30rpx;
+ padding-bottom: calc(20rpx + env(safe-area-inset-bottom));
+ background: #f5f7fa;
+ box-shadow: 0 -4rpx 20rpx rgba(0, 0, 0, 0.05);
}
.parkingSpace-card {
diff --git a/property-uniapp-project/pageSubPack/my/parkingSpaceDetail.vue b/property-uniapp-project/pageSubPack/my/parkingSpaceDetail.vue
index 50bdef3..63de357 100644
--- a/property-uniapp-project/pageSubPack/my/parkingSpaceDetail.vue
+++ b/property-uniapp-project/pageSubPack/my/parkingSpaceDetail.vue
@@ -24,7 +24,7 @@
- 房屋信息
+ 车位信息
小区
diff --git a/property-uniapp-project/pageSubPack/my/selectParingLot.vue b/property-uniapp-project/pageSubPack/my/selectParingLot.vue
index 7a301b8..1a8c67b 100644
--- a/property-uniapp-project/pageSubPack/my/selectParingLot.vue
+++ b/property-uniapp-project/pageSubPack/my/selectParingLot.vue
@@ -26,6 +26,9 @@
ref,
onMounted
} from 'vue'
+ import {
+ onUnload
+ } from '@dcloudio/uni-app'
import {
getResidentCarAreaManageAreaListByVillageId,
getResidentCarAreaManageParkingListByAreaId
@@ -37,6 +40,8 @@
const selectedParkingLot = ref(uni.getStorageSync('parkingLotId'))
const selectedParkingSpace = ref(uni.getStorageSync('parkingSpaceId'))
const isSubmitting = ref(false)
+ let navTimer = null
+ let lockTimer = null
onMounted(() => {
checkType.value = uni.getStorageSync('checkType')
@@ -94,37 +99,38 @@
}
const selectedParking = (item) => {
+ // 防重复点击锁:处理中直接返回,避免重复选择/重复跳转
if (isSubmitting.value) return
isSubmitting.value = true
- console.log(item);
- if (checkType.value == '停车场') {
- selectedParkingLot.value = item.id
- } else if (checkType.value == '车位编号') {
- selectedParkingSpace.value = item.id
- }
-
- setTimeout(() => {
- uni.showToast({
- title: '选择成功',
- icon: 'success'
- })
- console.log(checkType.value);
+ try {
if (checkType.value == '停车场') {
+ selectedParkingLot.value = item.id
uni.setStorageSync('parkingLotId', item.id)
uni.setStorageSync('parkingLotName', item.name)
uni.removeStorageSync('parkingSpaceId')
uni.removeStorageSync('parkingSpaceName')
uni.setStorageSync('checkType', '车位编号')
} else if (checkType.value == '车位编号') {
- console.log(item.id);
+ selectedParkingSpace.value = item.id
uni.setStorageSync('parkingSpaceId', item.id)
uni.setStorageSync('parkingSpaceName', item.name)
}
- }, 1000)
- setTimeout(() => {
- goFreash()
- }, 2500)
+
+ uni.showToast({
+ title: '选择成功',
+ icon: 'success'
+ })
+
+ navTimer = setTimeout(() => {
+ goFreash()
+ }, 1500)
+ } finally {
+ // 正常跳转后页面会销毁,防止异常时锁死
+ lockTimer = setTimeout(() => {
+ isSubmitting.value = false
+ }, 1500)
+ }
}
const goFreash = () => {
@@ -149,6 +155,18 @@
}
uni.navigateBack()
}
+
+ // 页面销毁时清理定时器,避免手势返回后延迟跳转仍触发
+ onUnload(() => {
+ if (navTimer) {
+ clearTimeout(navTimer)
+ navTimer = null
+ }
+ if (lockTimer) {
+ clearTimeout(lockTimer)
+ lockTimer = null
+ }
+ })
diff --git a/property-uniapp-project/pageSubPack/online-repair/personalRepair.vue b/property-uniapp-project/pageSubPack/online-repair/personalRepair.vue
index 339c08a..0383f38 100644
--- a/property-uniapp-project/pageSubPack/online-repair/personalRepair.vue
+++ b/property-uniapp-project/pageSubPack/online-repair/personalRepair.vue
@@ -29,7 +29,7 @@
问题描述
-
+
{{ form.desc.length }}/200
diff --git a/property-uniapp-project/pageSubPack/online-repair/publicRepair.vue b/property-uniapp-project/pageSubPack/online-repair/publicRepair.vue
index 263ad8b..b31974d 100644
--- a/property-uniapp-project/pageSubPack/online-repair/publicRepair.vue
+++ b/property-uniapp-project/pageSubPack/online-repair/publicRepair.vue
@@ -22,7 +22,7 @@
问题描述
-
+
{{ form.desc.length }}/200
diff --git a/property-uniapp-project/pageSubPack/online-repair/selectHouse.vue b/property-uniapp-project/pageSubPack/online-repair/selectHouse.vue
index f3deaf2..656952a 100644
--- a/property-uniapp-project/pageSubPack/online-repair/selectHouse.vue
+++ b/property-uniapp-project/pageSubPack/online-repair/selectHouse.vue
@@ -27,8 +27,10 @@
-
-
+
+
+
+
@@ -55,7 +57,7 @@ const fetchHouseList = async () => {
try {
const res = await getHouseList({ pageNum: pageNum.value, pageSize: pageSize.value })
if (res.code === 200) {
- const list = res.rows || []
+ const list = res.data || []
houseList.value = list
// 仅当从表单页带入了房屋ID时,自动选中对应房屋;否则不默认选择
if (preSelectedHouseId.value) {
@@ -106,15 +108,12 @@ const confirmSelect = () => {
padding: 15px;
height: 100vh;
box-sizing: border-box;
- display: flex;
- flex-direction: column;
- justify-content: space-between;
background: #f9f9f9;
}
.house-list {
- flex: 1;
- min-height: 0;
+ height: 100%;
overflow-y: auto;
+ padding-bottom: 120rpx;
}
.house-item {
display: flex;
@@ -145,6 +144,17 @@ const confirmSelect = () => {
color: #666;
margin-top: 4px;
}
+.confirm-bar {
+ position: fixed;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ padding: 20rpx 30rpx;
+ padding-bottom: calc(20rpx + env(safe-area-inset-bottom));
+ background: #f9f9f9;
+ box-shadow: 0 -4rpx 20rpx rgba(0, 0, 0, 0.05);
+}
+
.confirm-btn {
width: 100%;
height: 44px;
@@ -153,8 +163,6 @@ const confirmSelect = () => {
color: #fff;
border-radius: 8px;
font-size: 28rpx;
- margin-top: 20px;
- margin-bottom: 20rpx;
}
/* 空状态 */
.empty-state {
diff --git a/property-uniapp-project/pages/index/index.vue b/property-uniapp-project/pages/index/index.vue
index 46c805b..4099cd6 100644
--- a/property-uniapp-project/pages/index/index.vue
+++ b/property-uniapp-project/pages/index/index.vue
@@ -272,16 +272,27 @@
dataLoaded.value = false
}
- const getCurrentCommunityData = () => {
+ const getCurrentCommunityData = (reloadedVillageId) => {
+ // 删除房屋后 reloadUserInfo 会返回 currentVillageId=0,
+ // 此时直接清空,避免再请求可能返回过期数据的 /village/current 导致小区名残留
+ if (reloadedVillageId === 0 || reloadedVillageId === '0') {
+ currentCommunity.value = '请绑定房屋'
+ currentVillageId.value = ''
+ uni.removeStorageSync('currentVillageId')
+ saveHomeCache()
+ return Promise.resolve()
+ }
return getCurrentVillage().then(res => {
if (res.code === 200 && res.data && res.data.villageId) {
- currentCommunity.value = res.data.villageName || '未命名小区'
+ currentCommunity.value = res.data.villageName
saveHomeCache()
currentVillageId.value = res.data.villageId
uni.setStorageSync('currentVillageId', res.data.villageId)
} else {
currentCommunity.value = '请绑定房屋'
currentVillageId.value = ''
+ uni.removeStorageSync('currentVillageId')
+ saveHomeCache()
}
}).catch(err => {
// 有 token 才提示错误(无 token 用户正常浏览首页,API 401 属于预期行为)
@@ -317,20 +328,23 @@
const token = uni.getStorageSync('token') || ''
dataLoaded.value = true
const needReload = uni.getStorageSync('needReloadUserInfo')
+ // 重新加载用户信息时,拿到权威的 currentVillageId(删除房屋后会变成 0)
+ let reloadedVillageId = null
if (token && needReload) {
uni.removeStorageSync('needReloadUserInfo')
- getReloadUserInfo().then(res => {
+ try {
+ const res = await getReloadUserInfo()
if (res.code === 200 && res.data) {
if (res.data.userId) uni.setStorageSync('userId', res.data.userId)
- const reloadedVillageId = res.data.currentVillageId || 0
+ reloadedVillageId = res.data.currentVillageId || 0
uni.setStorageSync('currentVillageId', reloadedVillageId)
}
- }).catch(err => {
+ } catch (err) {
console.error('重新加载用户信息失败', err)
- })
+ }
}
// 先获取小区信息,确保 villageId 已更新,再请求依赖 villageId 的接口
- await getCurrentCommunityData()
+ await getCurrentCommunityData(reloadedVillageId)
getNoticeData()
getNewActivityList()
getbannarData()
@@ -361,12 +375,14 @@
onShow(() => {
const currentUserId = uni.getStorageSync('userId') || ''
const userIdChanged = lastUserId.value !== currentUserId
+ const needReload = uni.getStorageSync('needReloadUserInfo')
refreshing.value = false
if (userIdChanged) {
resetPageData()
refreshAllData()
- } else if (!dataLoaded.value) {
+ } else if (!dataLoaded.value || needReload) {
// 首次进入且之前因无 token 跳过了 API,现在有 token 则补拉
+ // 或房屋/小区信息有变更(如删除房屋后),需要重新拉取
refreshAllData()
}
lastUserId.value = currentUserId