From 13031a4180e2817cb0a3fdbee7cbf9eaf041dbd5 Mon Sep 17 00:00:00 2001 From: mk <2403457699@qq.com> Date: Wed, 7 Jun 2023 14:48:57 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=B3=A8=E5=86=8C=E9=A1=B5?= =?UTF-8?q?=E9=80=89=E6=8B=A9=E7=A4=BE=E5=8C=BA=E8=BF=9B=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- epdc-resident-mp-yushan/app.json | 4 +- .../pages/toRegister/toRegister.js | 6 +- .../pages/toRegister/toRegister.wxml | 1 + .../pages/toRegister/toRegister.wxss | 18 +++++ .../project.private.config.json | 16 ++++- .../gridArmy/pages/gridEntry/index.js | 36 ++++++++++ .../gridArmy/pages/gridEntry/index.json | 4 ++ .../gridArmy/pages/gridEntry/index.wxml | 11 +++ .../gridArmy/pages/gridEntry/index.wxss | 68 +++++++++++++++++++ .../gridArmy/pages/gridEntryTwo/index.js | 52 ++++++++++++++ .../gridArmy/pages/gridEntryTwo/index.json | 4 ++ .../gridArmy/pages/gridEntryTwo/index.wxml | 10 +++ .../gridArmy/pages/gridEntryTwo/index.wxss | 68 +++++++++++++++++++ epdc-resident-mp-yushan/utils/api.js | 5 ++ 14 files changed, 300 insertions(+), 3 deletions(-) create mode 100644 epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.js create mode 100644 epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.json create mode 100644 epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.wxml create mode 100644 epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.wxss create mode 100644 epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.js create mode 100644 epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.json create mode 100644 epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.wxml create mode 100644 epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.wxss diff --git a/epdc-resident-mp-yushan/app.json b/epdc-resident-mp-yushan/app.json index b2d9133..a860586 100644 --- a/epdc-resident-mp-yushan/app.json +++ b/epdc-resident-mp-yushan/app.json @@ -194,7 +194,9 @@ "pages": [ "pages/index/index", "pages/communityList/communityList", - "pages/categoryList/categoryList" + "pages/categoryList/categoryList", + "pages/gridEntry/index", + "pages/gridEntryTwo/index" ] }, { diff --git a/epdc-resident-mp-yushan/pages/toRegister/toRegister.js b/epdc-resident-mp-yushan/pages/toRegister/toRegister.js index b743b96..217573e 100644 --- a/epdc-resident-mp-yushan/pages/toRegister/toRegister.js +++ b/epdc-resident-mp-yushan/pages/toRegister/toRegister.js @@ -65,6 +65,10 @@ Page({ wx.navigateTo({ url: '/subpages/home/pages/agreement/agreement' }) + }, + toCommunity(){ + wx.navigateTo({ + url: '/subpages/gridArmy/pages/gridEntry/index' + }) } - }) diff --git a/epdc-resident-mp-yushan/pages/toRegister/toRegister.wxml b/epdc-resident-mp-yushan/pages/toRegister/toRegister.wxml index 2e11773..ecbf221 100644 --- a/epdc-resident-mp-yushan/pages/toRegister/toRegister.wxml +++ b/epdc-resident-mp-yushan/pages/toRegister/toRegister.wxml @@ -5,6 +5,7 @@ + 查看用户服务协议 diff --git a/epdc-resident-mp-yushan/pages/toRegister/toRegister.wxss b/epdc-resident-mp-yushan/pages/toRegister/toRegister.wxss index e5ef20c..923543f 100644 --- a/epdc-resident-mp-yushan/pages/toRegister/toRegister.wxss +++ b/epdc-resident-mp-yushan/pages/toRegister/toRegister.wxss @@ -74,6 +74,10 @@ checkbox .wx-checkbox-input.wx-checkbox-input-checked::before { .check text{ color: #5295FF; } +.buttons{ + position: relative; + top:-80rpx; +} .buttons .btn2 { background-image: linear-gradient(to right , #ff2d29, #ff4e4e); @@ -88,6 +92,20 @@ checkbox .wx-checkbox-input.wx-checkbox-input-checked::before { outline: 0; font-weight: normal; } +.buttons .btn3{ + /* background-image: linear-gradient(to right , #ff2d29, #ff4e4e); */ + background-color: #fff; + height:84rpx; + line-height: 84rpx; + text-align:center; + color: #ff2d29; + font-size: 36rpx; + border-radius: 16rpx; + padding: 0; + margin-top: 20rpx; + outline: 0; + font-weight: normal; +} .buttons .hover-btn { background: red; } \ No newline at end of file diff --git a/epdc-resident-mp-yushan/project.private.config.json b/epdc-resident-mp-yushan/project.private.config.json index 2fb8d3b..b9ad90f 100644 --- a/epdc-resident-mp-yushan/project.private.config.json +++ b/epdc-resident-mp-yushan/project.private.config.json @@ -108,11 +108,25 @@ "query": "", "launchMode": "default", "scene": null + }, + { + "name": "注册", + "pathName": "pages/toRegister/toRegister", + "query": "", + "launchMode": "default", + "scene": null + }, + { + "name": "社区进入", + "pathName": "subpages/gridArmy/pages/gridEntry/index", + "query": "", + "launchMode": "default", + "scene": null } ] } }, "description": "项目私有配置文件。此文件中的内容将覆盖 project.config.json 中的相同字段。项目的改动优先同步到此文件中。详见文档:https://developers.weixin.qq.com/miniprogram/dev/devtools/projectconfig.html", - "projectname": "%2525E7%25258E%2525B0%2525E4%2525BB%2525A3%2525E6%2525A6%252586%2525E5%2525B1%2525B1-%2525E5%2525B1%252585%2525E6%2525B0%252591%2525E7%2525AB%2525AF", + "projectname": "%252525E7%2525258E%252525B0%252525E4%252525BB%252525A3%252525E6%252525A6%25252586%252525E5%252525B1%252525B1-%252525E5%252525B1%25252585%252525E6%252525B0%25252591%252525E7%252525AB%252525AF", "libVersion": "2.10.4" } \ No newline at end of file diff --git a/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.js b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.js new file mode 100644 index 0000000..dbf1f5f --- /dev/null +++ b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.js @@ -0,0 +1,36 @@ +const api = require('../../../../utils/api') +Page({ + data: { + gridList: [], + }, + onShow () { + this.loadGridList('1258587398679126017') + }, + // 加载网格长管辖的网格列表 + loadGridList (id) { + //默认写死传榆山街道id + let par = { + pid:id?id:'1258587398679126017' + } + api.getCommunityList(par).then(res => { + if (res.code === 0 && res.msg === 'success') { + const gridList = res.data + + this.setData({ + gridList, + }) + } + + console.log(res); + }).catch(err => { + console.log(err) + }) + }, + + // 点击进入 + changeGrid (e) { + wx.navigateTo({ + url: `/subpages/gridArmy/pages/gridEntryTwo/index?id=${e.currentTarget.dataset.id}`, + }) + } +}) \ No newline at end of file diff --git a/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.json b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.json new file mode 100644 index 0000000..2780f2a --- /dev/null +++ b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.json @@ -0,0 +1,4 @@ +{ + "navigationBarTitleText": "现代榆山", + "usingComponents": {} +} \ No newline at end of file diff --git a/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.wxml b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.wxml new file mode 100644 index 0000000..56e5793 --- /dev/null +++ b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.wxml @@ -0,0 +1,11 @@ + + + + + {{item.name}} + 进入 + + + + + \ No newline at end of file diff --git a/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.wxss b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.wxss new file mode 100644 index 0000000..8a38e4a --- /dev/null +++ b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntry/index.wxss @@ -0,0 +1,68 @@ +/* subpages/gridArmy/pages/gridEntry/index.wxss */ +.change-grid { + width: 100%; + height: 100vh; + background: #f7f7f7; + } + .nav { + height: 94rpx; + background: #ffffff; + width: 100%; + display: flex; + justify-content: space-between; + align-items: center; + } + .nav .nav-left image { + width: 32rpx; + height: 32rpx; + margin: 0 9rpx 0 20rpx; + } + .nav .nav-left text { + font-size: 32rpx; + font-weight: bold; + color: #f13d3c; + } + .nav .nav-right { + font-size: 26rpx; + color: #999; + margin-right: 20rpx; + } + + .grid-list { + width: 100%; + box-sizing: border-box; + padding: 20rpx; + height: auto; + } + .grid-list .content { + width: 100%; + height: 100%; + background: #ffffff; + border-radius: 16rpx; + box-sizing: border-box; + padding: 0 23rpx; + } + .grid-list .grid-item { + height: 100rpx; + width: 100%; + display: flex; + justify-content: space-between; + align-items: center; + } + .content > .grid-item + .grid-item { + border-top: 1rpx solid #eaeaea; + } + .grid-list .grid-item .name { + font-size: 34rpx; + color: #333; + } + .grid-list .grid-item .enter { + width:80rpx; + height:40rpx; + border: 1rpx solid #C0C0C0; + border-radius:4px; + line-height: 40rpx; + font-size: 24rpx; + color: #aeaeae; + text-align:center; + } \ No newline at end of file diff --git a/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.js b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.js new file mode 100644 index 0000000..af9359e --- /dev/null +++ b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.js @@ -0,0 +1,52 @@ +const api = require('../../../../utils/api') +Page({ + data: { + gridList: [], + }, + onShow () { + }, + onLoad (options) { + wx.showLoading({ + title: "加载中", + mask: true, + }) + this.loadGridList(options.id) + wx.hideLoading() + }, + // 加载网格长管辖的网格列表 + loadGridList (id) { + //默认写死传榆山街道id + let par = { + pid:id + } + api.getCommunityList(par).then(res => { + if (res.code === 0 && res.msg === 'success') { + const gridList = res.data + if (gridList.length > 0) { + }else{ + wx.showToast({ + title: '暂无网格信息', + icon: 'none', + duration: 2500 + }) + return false + } + this.setData({ + gridList, + }) + } + + console.log(res); + }).catch(err => { + console.log(err) + }) + }, + + // 点击进入 + changeGrid (e) { + + wx.navigateTo({ + url: `/pages/index/index?scene=${e.currentTarget.dataset.id}` + }) + } +}) \ No newline at end of file diff --git a/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.json b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.json new file mode 100644 index 0000000..27f5ab8 --- /dev/null +++ b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.json @@ -0,0 +1,4 @@ +{ + "navigationBarTitleText": "现代榆山", + "usingComponents": {} + } \ No newline at end of file diff --git a/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.wxml b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.wxml new file mode 100644 index 0000000..8da9568 --- /dev/null +++ b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.wxml @@ -0,0 +1,10 @@ + + + + + {{item.name}} + 进入 + + + + \ No newline at end of file diff --git a/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.wxss b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.wxss new file mode 100644 index 0000000..b7f510e --- /dev/null +++ b/epdc-resident-mp-yushan/subpages/gridArmy/pages/gridEntryTwo/index.wxss @@ -0,0 +1,68 @@ +/* subpages/gridArmy/pages/gridEntryTwo/index.wxss */ +.change-grid { + width: 100%; + height: 100vh; + background: #f7f7f7; + } + .nav { + height: 94rpx; + background: #ffffff; + width: 100%; + display: flex; + justify-content: space-between; + align-items: center; + } + .nav .nav-left image { + width: 32rpx; + height: 32rpx; + margin: 0 9rpx 0 20rpx; + } + .nav .nav-left text { + font-size: 32rpx; + font-weight: bold; + color: #f13d3c; + } + .nav .nav-right { + font-size: 26rpx; + color: #999; + margin-right: 20rpx; + } + + .grid-list { + width: 100%; + box-sizing: border-box; + padding: 20rpx; + height: auto; + } + .grid-list .content { + width: 100%; + height: 100%; + background: #ffffff; + border-radius: 16rpx; + box-sizing: border-box; + padding: 0 23rpx; + } + .grid-list .grid-item { + height: 100rpx; + width: 100%; + display: flex; + justify-content: space-between; + align-items: center; + } + .content > .grid-item + .grid-item { + border-top: 1rpx solid #eaeaea; + } + .grid-list .grid-item .name { + font-size: 34rpx; + color: #333; + } + .grid-list .grid-item .enter { + width:80rpx; + height:40rpx; + border: 1rpx solid #C0C0C0; + border-radius:4px; + line-height: 40rpx; + font-size: 24rpx; + color: #aeaeae; + text-align:center; + } \ No newline at end of file diff --git a/epdc-resident-mp-yushan/utils/api.js b/epdc-resident-mp-yushan/utils/api.js index 0174ea7..116f7b6 100644 --- a/epdc-resident-mp-yushan/utils/api.js +++ b/epdc-resident-mp-yushan/utils/api.js @@ -89,6 +89,7 @@ module.exports = { getHousesalerentinfo, getmypublishedlist, deleteHouse, + getCommunityList, } function getToken(wxCode) { @@ -643,4 +644,8 @@ function getmypublishedlist(params) { //删除房屋 function deleteHouse(id){ return fly.post(`custom/housesalerentinfo/resi/delete/${id}`) + } + //获取社区列表 + function getCommunityList(id){ + return fly.get(`admin/dept/getDeptInfoByPid`,id) } \ No newline at end of file