diff --git a/app.json b/app.json
index fbd5b69..28c91e0 100644
--- a/app.json
+++ b/app.json
@@ -64,12 +64,7 @@
"iconPath": "images/home/work.png",
"selectedIconPath": "images/home/workSelected.png"
},
- {
- "pagePath": "pages/information/information",
- "text": "数据",
- "iconPath": "images/home/information.png",
- "selectedIconPath": "images/home/informationSelected.png"
- },
+
{
"pagePath": "pages/mine/mine",
"text": "我的",
diff --git a/pages/index/index.js b/pages/index/index.js
index 4e2872b..ae8758e 100644
--- a/pages/index/index.js
+++ b/pages/index/index.js
@@ -1,7 +1,7 @@
// index.js
// 获取应用实例
const app = getApp()
-import {getIntelligentMessage,getToken,getStaffbasicinfo} from "../../utils/api"
+import {getIntelligentMessage,getToken,getStaffbasicinfo,clearMessage} from "../../utils/api"
Page({
data: {
selectList:['全部信息','居民信息采集','房屋信息采集','社区满意度自查'],
@@ -26,7 +26,9 @@ Page({
await this.getIntelligentMessage()
await this.getStaffbasicinfo()
},
-
+ onShow(){
+ this.getStaffbasicinfo()
+ },
onScrollToLower(e){
if (this.data.loadMoreType === 'more') {
this.setData({
@@ -44,7 +46,6 @@ onScrollToLower(e){
})
const parm = {
type:this.data.selectValue == 0? null :this.data.selectValue - 1,
- readFlag:0,
limit:this.data.pageSize,
page:this.data.pageNo
}
@@ -102,6 +103,9 @@ onScrollToLower(e){
app.globalData.user = res.data
}).catch(err=>{
console.log(err);
+ wx.navigateTo({
+ url: '/pages/login/login',
+ })
})
},
handleChangeFilter(e){
@@ -110,5 +114,15 @@ onScrollToLower(e){
tableData:[],
})
this.getIntelligentMessage()
+ },
+ handelClickClear(){
+ clearMessage().then(res=>{
+ this.setData({
+ tableData:[]
+ })
+ this.getIntelligentMessage()
+ }).catch(err=>{
+ console.log(err);
+ })
}
})
diff --git a/pages/index/index.wxml b/pages/index/index.wxml
index 92463cd..8092e71 100644
--- a/pages/index/index.wxml
+++ b/pages/index/index.wxml
@@ -14,12 +14,12 @@
{{selectValue == 1?'居民信息采集':selectValue == 2?'房屋信息采集':selectValue == 3?'社区满意度自查':'全部信息'}}
- 全部已读
+ 全部已读
- {{item.content}}
+ {{item.content}}
diff --git a/pages/login/login.js b/pages/login/login.js
index 43f1021..0841abf 100644
--- a/pages/login/login.js
+++ b/pages/login/login.js
@@ -86,13 +86,10 @@ Page({
wx.showToast({
title: '请输入密码',
icon:'none',
- duration:3000
+ duration:3000
})
return
}
- wx.showLoading({
- title:"登录中..."
- })
const parm = {
wxCode :'',
...this.data.formData
@@ -102,22 +99,19 @@ Page({
parm.wxCode = res.code
console.log(parm.wxCode);
userLoginlog(parm).then((res)=>{
- wx.hideLoading()
console.log(res);
if(res.code == 0){
wx.switchTab({
url: '/pages/index/index',
})
wx.setStorageSync('token', res.data.token)
- }else{
- wx.showToast({
- title: res.msg,
- icon:'none',
- duration:2000
- })
}
}).catch(err=>{
- wx.hideLoading()
+ wx.showToast({
+ title: res.msg,
+ icon:'none',
+ duration:3000
+ })
console.log(err);
})
},
diff --git a/pages/work/work.js b/pages/work/work.js
index 1f68f00..1d19669 100644
--- a/pages/work/work.js
+++ b/pages/work/work.js
@@ -138,5 +138,10 @@ Page({
wx.navigateTo({
url: '/subpages/searchResult/pages/searchRecords/searchRecords',
})
+ },
+ toGatherInformation(){
+ wx.navigateTo({
+ url: '/subpages/gatherInformation/pages/gatherInformation/gatherInformation',
+ })
}
})
\ No newline at end of file
diff --git a/pages/work/work.wxml b/pages/work/work.wxml
index 243384f..fd13603 100644
--- a/pages/work/work.wxml
+++ b/pages/work/work.wxml
@@ -12,7 +12,7 @@
- 搜索
+ 搜索
@@ -32,7 +32,7 @@
信息采集
- 采集记录>
+ 采集记录 >
关注官方公众号,可接受重要消息提醒。
@@ -57,7 +57,7 @@
-
+
\ No newline at end of file
diff --git a/pages/work/work.wxss b/pages/work/work.wxss
index 40d8af1..ac85301 100644
--- a/pages/work/work.wxss
+++ b/pages/work/work.wxss
@@ -111,12 +111,17 @@ page {
}
.header .content .inout_box .btn_box{
width: 69rpx;
- height: 30rpx;
- line-height: 30rpx;
+ height: 50rpx;
position: absolute;
top: 24rpx;
right:30rpx;
+}
+.header .content .inout_box .btn_box text{
+ width: 69rpx;
+ height: 30rpx;
+ line-height: 30rpx;
font-size: 28rpx;
+ box-sizing: border-box;
color:#3A80E7;
padding-left: 15rpx;
border-left:2rpx #3A80E7 solid ;
diff --git a/subpages/addResi/pages/addResi/addResi.js b/subpages/addResi/pages/addResi/addResi.js
index 431a990..a58baa4 100644
--- a/subpages/addResi/pages/addResi/addResi.js
+++ b/subpages/addResi/pages/addResi/addResi.js
@@ -386,7 +386,14 @@ Page({
if (this.data.isFirstLoadGrid) {
// 编辑回填逻辑
const id = this.data.form.gridId;
- const gridName = this.data.gridList.filter(item => item.value == id)[0].label;
+ const temp = this.data.gridList.filter(item => item.value == id);
+ const gridName = ''
+ if(temp.length != 0){
+ gridName = temp[0].label
+ }else{
+ this.showToast('网格信息有误')
+ return
+ }
this.setData({
'form.gridName': gridName,
"form.gridId": id
diff --git a/subpages/addResi/pages/addResi/addResi.json b/subpages/addResi/pages/addResi/addResi.json
index 6123174..ef839c2 100644
--- a/subpages/addResi/pages/addResi/addResi.json
+++ b/subpages/addResi/pages/addResi/addResi.json
@@ -1,7 +1,5 @@
{
"usingComponents": {
- "wux-cell-group": "../../../../components/dist/cell-group",
- "wux-cell": "../../../../components/dist/cell",
"wux-select": "../../../../components/dist/select"
},
"navigationStyle": "custom"
diff --git a/subpages/gatherInformation/pages/gatherInformation/gatherInformation.wxml b/subpages/gatherInformation/pages/gatherInformation/gatherInformation.wxml
index 9572d12..420ea00 100644
--- a/subpages/gatherInformation/pages/gatherInformation/gatherInformation.wxml
+++ b/subpages/gatherInformation/pages/gatherInformation/gatherInformation.wxml
@@ -11,7 +11,7 @@
请选择时间
-
+
筛选
diff --git a/subpages/searchResult/pages/searchRecords/searchRecords.js b/subpages/searchResult/pages/searchRecords/searchRecords.js
index 6e8c38c..081b522 100644
--- a/subpages/searchResult/pages/searchRecords/searchRecords.js
+++ b/subpages/searchResult/pages/searchRecords/searchRecords.js
@@ -113,5 +113,10 @@ Page({
this.setData({
SearchRecordsList:[]
})
+ },
+ back(){
+ wx.navigateBack({
+ delta: 1
+ })
}
})
\ No newline at end of file
diff --git a/utils/api.js b/utils/api.js
index 828cb27..68e7aec 100644
--- a/utils/api.js
+++ b/utils/api.js
@@ -26,12 +26,16 @@ module.exports = {
saveCommunityHouse,
updateCommunityHouse,
getClearHouseDeatilById,
- getCollect
+ getCollect,
+ clearMessage
}
// 消息列表
function getIntelligentMessage(param){
return fly.get(`message/intelligentMessage/page`,param)
}
+function clearMessage () {
+ return fly.post('message/intelligentMessage/msg/clear')
+ }
/**
*小程序用户登录
*/
diff --git a/utils/config.js b/utils/config.js
index ba3fce9..03cf0b3 100644
--- a/utils/config.js
+++ b/utils/config.js
@@ -7,7 +7,7 @@ module.exports = {
function BASEURL() {
// return 'https://epdc-shibei.elinkservice.cn/epdc-api/api/' // 正式环境
- return 'http://192.168.1.144/api/' // 测试环境
+ return 'https://epmet-preview.elinkservice.cn/api/' // 测试环境
}
function WEBROOT() {