feat:调用物业公积金接口-未完成

This commit is contained in:
qiaojiale 2025-07-10 14:48:53 +08:00
parent a44b8dc457
commit 5bf36b96e9
20 changed files with 492 additions and 484 deletions

View File

@ -19,4 +19,7 @@ export const apiArr = {
categoryPage: '/api/v2/wechat/announcement-category-crud/page', // 公告分类信息分页
infoPage: '/api/v2/wechat/announcement-crud/page', // 公告信息分页
getAnnounceInfo:"/api/v2/wechat/announcement-crud/info" ,//公告详情
getGovernmentByRoom:"/api/v2/wechat/government-housing-fund-flow-crud/room", //根据房源获取公积金信息
};

View File

@ -48,14 +48,15 @@
<view class="funcList">
<u-grid :col="rowNum" :border="false">
<u-grid-item v-for="(item, index) in functionList" @click="jump(iteitem.mini_program_urlm)" :key="index">
<u-grid-item v-for="(item, index) in functionList" @click="jump(item.mini_program_url)" :key="index">
<image class="grid_Pic" :src="item.nav_icon" mode=""></image>
<text>{{ item.nav_name }}</text>
</u-grid-item>
</u-grid>
</view>
<div v-for="(item, index) in tileList" :key="index" :class="['ads', index == 0 ? 'ads_first' : '']" @click="headerServerClick(item)">
<div v-for="(item, index) in tileList" :key="index" :class="['ads', index == 0 ? 'ads_first' : '']"
@click="headerServerClick(item)">
<image :src="item.ad_picture" mode="aspectFill" />
</div>
@ -156,15 +157,17 @@
tileList: [], //广
largePopList: [], //广
popList: [], //广
categoryList: [],
infoList: [],
selectedTab: 0,
currentAdIndex: 0,
rowNum: 0,
colNum: 0,
page_size:10,
page_num:1,
flag:false
}
},
async onLoad(options) {
@ -178,12 +181,37 @@
}
this.communityVal = uni.getStorageSync('changeCommData').name
await this.getfunctionNum()
this.getfunctionNum()
this.getAdvertising()
this.getCategoryList()
},
//
onPullDownRefresh() {
this.communityVal = uni.getStorageSync('changeCommData').name
this.bannerList = []
this.currentIdx = 0
this.streamerList = [] //广
this.tileList = [] //广
this.largePopList = [] //广
this.popList = [] //广
this.categoryList = []
this.infoList = []
this.selectedTab = 0
this.currentAdIndex = 0
this.getfunctionNum()
this.getAdvertising()
this.getCategoryList()
uni.stopPullDownRefresh();
},
//
onReachBottom() {
if(this.flag){
this.page_num++
this.getCategoryList()
}
},
methods: {
@ -211,24 +239,6 @@
NavgateTo("/packages/community/myCommunity/index")
},
// getCommunityList() {
// let that = this
// request(apiArr.getCommunityList, 'POST', {
// page_num: that.queryPage.page_num,
// page_size: that.queryPage.page_size,
// user_id:""
// }).then(res => {
// console.log(res)
// if (res.rows.length == that.queryPage.page_size) {
// that.queryPage.page_num++
// that.flag = true
// that.communityList = that.communityList.concat(res.rows)
// }else{
// that.flag = false
// that.communityList = that.communityList.concat(res.rows)
// }
// })
// },
swipers(event) {
//
this.currentIdx = event.detail.current;
@ -243,26 +253,14 @@
return await this.getfunctionList()
},
// async getfunctionList() {
// const res = await request(apiArr.navPage, "POST", {
// community_id: Number(uni.getStorageSync('changeCommData').id),
// page_num: 1,
// page_size: 50
// })
// this.functionList = res.rows.map(item => {
// return {
// ...item,
// nav_icon: picUrl + item.nav_icon
// };
// });
// console.log(this.functionList)
// },
async getfunctionList() {
const res = await request(apiArr.navPage, "POST", {
community_id: Number(uni.getStorageSync('changeCommData').id),
page_num: 1,
page_size: 50
});
console.log(res, 'xx');
// rowNum colNum
const totalItems = this.rowNum * this.colNum;
// 使 slice totalItems
@ -277,11 +275,6 @@
},
async getAdvertising() {
// bannerList
// streamerList
// tileList
// largePopList
// popList
const res = await request(apiArr.advPage, "POST", {
community_id: Number(uni.getStorageSync('changeCommData').id),
ad_position: 1,
@ -410,7 +403,6 @@
this.currentAdIndex = e.detail.current;
},
onDetailClick() {
console.log('1111');
// 广
const currentAd = this.popList[this.currentAdIndex];
if (currentAd) {
@ -454,15 +446,21 @@
announcement_category_id: item.id,
title: '',
category_name: '',
page_num: 1,
page_size: 10,
page_num: this.page_num,
page_size: this.page_size,
})
this.infoList = res.rows.map(item => {
if(res.rows && res.rows.length == this.page_size){
this.flag= true
}else{
this.flag= false
}
res.rows = res.rows.map(item => {
return {
...item,
list_image: picUrl + item.list_image,
};
});
this.infoList = this.infoList.concat(res.rows)
},

View File

@ -13,14 +13,17 @@
</view>
</view>
<view class="main">
<view class="person_info" v-for="(item,index) in list" :key="index">
<view class="person_info" v-for="(item,index) in list.owners" :key="index">
<view class="item">
<view class="label">姓名</view>
<view class="desc">{{ item.name }}</view>
</view>
<view class="item">
<view class="label">身份</view>
<view class="desc">{{ item.identity }}</view>
<view class="desc" v-if="item.type == 1">业主</view>
<view class="desc" v-if="item.type == 2">家属</view>
<view class="desc" v-if="item.type == 3">租户</view>
<view class="desc" v-if="item.type == 4">访客</view>
</view>
<view class="item">
<view class="label">手机号</view>
@ -28,7 +31,7 @@
</view>
<view class="item">
<view class="label">房产总数</view>
<view class="desc">{{ item.houseNum }}</view>
<view class="desc">{{ item.count_of_rooms }}</view>
</view>
<view class="item">
<view class="label fix">
@ -39,7 +42,7 @@
<view class="angle"></view>
</view>
</view>
<view class="desc">{{item.fund}}</view>
<view class="desc">{{item.property_fund_balance}}</view>
</view>
</view>
</view>
@ -50,7 +53,7 @@
<view class="header">
<view></view>
<view class="title">选择房源</view>
<view class="close">取消</view>
<view class="close" @click="close">取消</view>
</view>
<view class="line"></view>
<view class="main">
@ -96,74 +99,23 @@ export default {
desc: '物业公积金可通用至您加入的所有房产,任一房产的物业相关费用均可用该物业公积金抵扣。',
defaultName: '',
list: [
{
name: '高尚',
identity: '业主',
mobile: '15931111111',
houseNum: '9',
fund: '50.00',
popupShow: false
},
{
name: '李明',
identity: '家属',
mobile: '15931111122',
houseNum: '6',
fund: '50.00',
popupShow: false
},
{
name: '王五',
identity: '租户',
mobile: '15931111316',
houseNum: '2',
fund: '50.00',
popupShow: false
}
],
houseList: [
{
name: '2323世纪名城1号楼1单元101室',
checked: false,
},
{
name: '2323世纪名城1号楼1单元102室',
checked: false,
},
{
name: '2323世纪名城1号楼1单元103室',
checked: false,
},
{
name: '2323世纪名城1号楼1单元104室',
checked: false,
},
{
name: '2323世纪名城1号楼1单元105室',
checked: false,
},
{
name: '2323世纪名城1号楼1单元201室',
checked: false,
},
{
name: '2323世纪名城1号楼1单元202室',
checked: false,
},
{
name: '2323世纪名城1号楼1单元203室',
checked: false,
},
]
],
roomList:[]
}
},
onLoad(options) {
async onLoad(options) {
this.defaultName = {
...this.houseList[0],
checked: true
};
const meun = menuButtonInfo();
this.top = meun.height + meun.top;
await this.getRoomList()
await this.getInfo()
},
@ -174,10 +126,12 @@ export default {
checked: true
};
this.show = false;
this.getInfo()
},
//
headerSwitchClick() {
this.show = true;
const newRes = this.houseList.map(item => {
const newRes = this.roomList.map(item => {
if (item.name === this.defaultName.name) {
return {
...item,
@ -192,14 +146,37 @@ export default {
console.log('newResnewRes', newRes);
this.houseList = newRes;
},
//
headerIconClick(ind) {
this.list[ind].popupShow = !this.list[ind].popupShow
this.list.owners[ind].popupShow = !this.list.owners[ind].popupShow
},
close() {
this.show = false;
},
async getRoomList(){
await request(apiArr.getCommunityList,"POST",{
page_num:1,
page_size:50,
community_id:uni.getStorageSync("changeCommData").id
}).then(res=>{
res.rows.forEach(item=>{
item.checked = false
})
this.roomList = res.rows
this.defaultName = res.rows[0]
})
},
async getInfo(){
await request(apiArr.getGovernmentByRoom,"POST",{
room_id:this.defaultName.room_id
}).then(res=>{
res.owners.forEach(item => {
item.popupShow = false
});
this.list = res
})
},
},
}
</script>

View File

@ -168,3 +168,22 @@ page {
margin: 0 auto;
margin-top: 200rpx;
}
.empty {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
font-weight: normal;
font-size: 28rpx;
color: #999999;
margin-top: 110rpx;
width: 100%;
}
.empty image {
width: 366rpx;
height: 226rpx;
margin-bottom: 27rpx;
}

View File

@ -1,18 +1,9 @@
<template>
<view class="box">
<div
class="searchBox"
:style="{ height: localHeight + 'px', paddingTop: top + 'px' }"
>
<div class="searchBox" :style="{ height: localHeight + 'px', paddingTop: top + 'px' }">
<div class="searchBox_add">
<div class="searchBox_left">
<u-icon
bold
color="#000"
size="40"
name="arrow-left"
@click="back"
></u-icon>
<u-icon bold color="#000" size="40" name="arrow-left" @click="back"></u-icon>
</div>
<div class="searchBox_mid">我的报修</div>
<div class="searchBox_right"></div>
@ -20,33 +11,21 @@
</div>
<div class="tabList">
<div
:class="active == 1 ? 'tab active' : 'tab'"
@click="headerTabsClick(1)"
>
<div :class="active == 1 ? 'tab active' : 'tab'" @click="headerTabsClick(1)">
待指派 <span>({{ awaitingNumb }})</span>
</div>
<div
:class="active == 2 ? 'tab active' : 'tab'"
@click="headerTabsClick(2)"
>
<div :class="active == 2 ? 'tab active' : 'tab'" @click="headerTabsClick(2)">
进行中 <span>({{ underwayNum }})</span>
</div>
<div
:class="active == 4 ? 'tab active' : 'tab'"
@click="headerTabsClick(4)"
>
<div :class="active == 4 ? 'tab active' : 'tab'" @click="headerTabsClick(4)">
已作废 <span>({{ discardNum }})</span>
</div>
<div
:class="active == 3 ? 'tab active' : 'tab'"
@click="headerTabsClick(3)"
>
<div :class="active == 3 ? 'tab active' : 'tab'" @click="headerTabsClick(3)">
已完成 <span>({{ doneNum }})</span>
</div>
</div>
<div class="orderList" v-for="(item, index) in list" :key="index">
<div v-if="list.length !== 0" class="orderList" v-for="(item, index) in list" :key="index">
<div class="orderItem" @click="handlerDetailClick(item.id)">
<div :class="['orderItemTit', statusType[item.status].style]">
<div class="orderItemTit_left">工单编号{{ item.order_code }}</div>
@ -90,6 +69,12 @@
</div>
</div>
<div v-if="list.length == 0" class="empty">
<image src="https://wechat-img-file.oss-cn-beijing.aliyuncs.com/property-img-file/com_nearbyList_empty.png"
mode="aspectFill"></image>
暂无数据
</div>
<div class="addBtn" @click="oneRepair">在线报修</div>
</view>
</template>
@ -238,6 +223,14 @@ export default {
this.init();
}
},
onPullDownRefresh() {
this.list = [];
this.flag = false;
this.page_num = 1;
this.getTabsList();
uni.stopPullDownRefresh();
},
};
</script>

View File

@ -139,7 +139,8 @@
"navigationStyle": "custom",
"usingComponents": {
"nav-footer": "/components/nav/nav"
}
},
"enablePullDownRefresh": true
}
},
{
@ -212,7 +213,8 @@
"style": {
"navigationStyle": "custom",
"navigationBarTitleText": "",
"navigationBarBackgroundColor": "#F9F9F9"
"navigationBarBackgroundColor": "#F9F9F9",
"enablePullDownRefresh":true
}
},
{

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -6726,7 +6726,10 @@ var apiArr = {
// 公告分类信息分页
infoPage: '/api/v2/wechat/announcement-crud/page',
// 公告信息分页
getAnnounceInfo: "/api/v2/wechat/announcement-crud/info" //公告详情
getAnnounceInfo: "/api/v2/wechat/announcement-crud/info",
//公告详情
getGovernmentByRoom: "/api/v2/wechat/government-housing-fund-flow-crud/room" //根据房源获取公积金信息
};
exports.apiArr = apiArr;

View File

@ -3,5 +3,18 @@
"projectname": "uniapp-ZHSQ",
"setting": {
"compileHotReLoad": true
},
"condition": {
"miniprogram": {
"list": [
{
"name": "packages/community/providentFund/index",
"pathName": "packages/community/providentFund/index",
"query": "",
"scene": null,
"launchMode": "default"
}
]
}
}
}