mirror of
https://gitee.com/java110/MicroCommunityWeb.git
synced 2026-06-12 10:00:56 +08:00
优化代码
This commit is contained in:
parent
9cff3d1ea6
commit
0f73e6c924
@ -16,11 +16,12 @@
|
|||||||
},
|
},
|
||||||
_initEvent: function() {
|
_initEvent: function() {
|
||||||
vc.on('editPropertyCommunity', 'openEditPropertyCommunityModal', function(_param) {
|
vc.on('editPropertyCommunity', 'openEditPropertyCommunityModal', function(_param) {
|
||||||
|
$that.editPropertyCommunityInfo.groupIds = [];
|
||||||
|
$that.editPropertyCommunityInfo.communityId = _param.communityId;
|
||||||
$that._listEditPropertyCommunityMenuGroups();
|
$that._listEditPropertyCommunityMenuGroups();
|
||||||
$that._listMenuGroupCommunity();
|
$that._listMenuGroupCommunity();
|
||||||
|
|
||||||
$that.editPropertyCommunityInfo.memberId = _param.storeId;
|
$that.editPropertyCommunityInfo.memberId = _param.storeId;
|
||||||
$that.editPropertyCommunityInfo.communityId = _param.communityId;
|
|
||||||
$that.editPropertyCommunityInfo.name = _param.name;
|
$that.editPropertyCommunityInfo.name = _param.name;
|
||||||
$('#editPropertyCommunityModel').modal('show');
|
$('#editPropertyCommunityModel').modal('show');
|
||||||
});
|
});
|
||||||
@ -66,11 +67,13 @@
|
|||||||
changeEditAllCommunity: function() {
|
changeEditAllCommunity: function() {
|
||||||
$that.editPropertyCommunityInfo.groupIds = [];
|
$that.editPropertyCommunityInfo.groupIds = [];
|
||||||
if (!$that.editPropertyCommunityInfo.isAll) {
|
if (!$that.editPropertyCommunityInfo.isAll) {
|
||||||
|
$that.editPropertyCommunityInfo.isAll = true;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
$that.editPropertyCommunityInfo.menuGroups.forEach(item => {
|
$that.editPropertyCommunityInfo.menuGroups.forEach(item => {
|
||||||
$that.editPropertyCommunityInfo.groupIds.push(item.groupId);
|
//$that.editPropertyCommunityInfo.groupIds.push(item.groupId);
|
||||||
|
$that.editPropertyCommunityInfo.groupIds.push(item.gId);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
changeEditItemCommunity: function() {
|
changeEditItemCommunity: function() {
|
||||||
@ -97,6 +100,7 @@
|
|||||||
let _propertyCompanyManageInfo = JSON.parse(json);
|
let _propertyCompanyManageInfo = JSON.parse(json);
|
||||||
$that.editPropertyCommunityInfo.menuGroups = _propertyCompanyManageInfo.data;
|
$that.editPropertyCommunityInfo.menuGroups = _propertyCompanyManageInfo.data;
|
||||||
|
|
||||||
|
$that._listMenuGroupCommunity();
|
||||||
},
|
},
|
||||||
function(errInfo, error) {
|
function(errInfo, error) {
|
||||||
console.log('请求失败处理');
|
console.log('请求失败处理');
|
||||||
@ -122,7 +126,7 @@
|
|||||||
_propertyCompanyManageInfo.data.forEach(item => {
|
_propertyCompanyManageInfo.data.forEach(item => {
|
||||||
$that.editPropertyCommunityInfo.groupIds.push(item.gId);
|
$that.editPropertyCommunityInfo.groupIds.push(item.gId);
|
||||||
})
|
})
|
||||||
|
$that.changeEditItemCommunity();
|
||||||
},
|
},
|
||||||
function(errInfo, error) {
|
function(errInfo, error) {
|
||||||
console.log('请求失败处理');
|
console.log('请求失败处理');
|
||||||
|
|||||||
@ -19,7 +19,7 @@
|
|||||||
vc.component._loadAllFloorInfo(1, 10);
|
vc.component._loadAllFloorInfo(1, 10);
|
||||||
});
|
});
|
||||||
vc.on('searchFloor', 'paginationPlus', 'page_event', function(_currentPage) {
|
vc.on('searchFloor', 'paginationPlus', 'page_event', function(_currentPage) {
|
||||||
vc.component._loadAllFloorInfo(_currentPage, 10);
|
$that._loadAllFloorInfo(_currentPage, 10);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user