diff --git a/api/community/communityApi.js b/api/community/communityApi.js index 7b37bce..f154e79 100755 --- a/api/community/communityApi.js +++ b/api/community/communityApi.js @@ -103,4 +103,29 @@ export function recoveryCommunityInfo(_obj){ }) }) +} + +/** + * 查询业主小区 + * @param {Object} dataObj 对象 + */ +export function getOwnerCommunitys(dataObj) { + return new Promise( + (resolve, reject) => { + request({ + url: url.listCommunitys, + method: "GET", + data: dataObj, + //动态数据 + success: function(res) { + if (res.statusCode == 200) { + let _communtiys = res.data.communitys; + resolve(_communitys); + } + }, + fail: function(e) { + reject(e); + } + }); + }) } \ No newline at end of file diff --git a/pages.json b/pages.json index 4ed83e0..cbf1fc6 100755 --- a/pages.json +++ b/pages.json @@ -611,6 +611,15 @@ "enablePullDownRefresh": false } } + ,{ + "path" : "pages/changeOwnerCommunity/changeOwnerCommunity", + "style" : + { + "navigationBarTitleText": "切换小区", + "enablePullDownRefresh": false + } + + } ], "tabBar": { "color": "#272636", diff --git a/pages/changeOwnerCommunity/changeOwnerCommunity.vue b/pages/changeOwnerCommunity/changeOwnerCommunity.vue new file mode 100644 index 0000000..7eed462 --- /dev/null +++ b/pages/changeOwnerCommunity/changeOwnerCommunity.vue @@ -0,0 +1,60 @@ + + + + + diff --git a/pages/my/my.vue b/pages/my/my.vue index 071faa6..7627c2a 100755 --- a/pages/my/my.vue +++ b/pages/my/my.vue @@ -24,10 +24,13 @@ - + - - 我的小区 + + 切换小区 + + + {{currentCommunityName}} @@ -237,6 +240,12 @@ url: '/pages/myAccount/myAccount', }); }, + //切换小区 + _changeCommunity:function(){ + uni.navigateTo({ + url:"/pages/changeOwnerCommunity/changeOwnerCommunity" + }); + }, } };