-
-
-
+
-
Communities
+
-
+
-
+
-
+
-
-
-
-
-
{
self.communities = [community];
- this.communitiesCheckboxes.push({community : community, checked : false});
+ this.checkboxes.push({community : community, checked : false});
},
error => this.handleError('System error retrieving communities', error));
}
@@ -70,7 +70,7 @@ export class CommunitiesComponent implements OnInit {
self.communities = communities;
communities.forEach(_ => {
- this.communitiesCheckboxes.push({community : _, checked : false});
+ this.checkboxes.push({community : _, checked : false});
});
},
error => this.handleError('System error retrieving communities', error));
@@ -81,22 +81,22 @@ export class CommunitiesComponent implements OnInit {
}
public toggleCheckBoxes(event) {
- this.communitiesCheckboxes.forEach(_ => _.checked = event.target.checked);
+ this.checkboxes.forEach(_ => _.checked = event.target.checked);
}
public applyCheck(flag : boolean) {
console.info("applyCheck "+flag);
- this.communitiesCheckboxes.forEach(_ => _.checked = flag);
+ this.checkboxes.forEach(_ => _.checked = flag);
}
public getSelectedCommunities() : string[] {
- return this.communitiesCheckboxes.filter(community => community.checked == true).map(checkedCommunity => checkedCommunity.community).map(res => res._id);
+ return this.checkboxes.filter(community => community.checked == true).map(checkedCommunity => checkedCommunity.community).map(res => res._id);
}
private deleteCommunitiesFromArray(ids : string[]) : void {
for(let id of ids) {
- let i = this.communitiesCheckboxes.findIndex(_ => _.community._id == id);
- this.communitiesCheckboxes.splice(i, 1);
+ let i = this.checkboxes.findIndex(_ => _.community._id == id);
+ this.checkboxes.splice(i, 1);
}
}
@@ -118,19 +118,19 @@ export class CommunitiesComponent implements OnInit {
}
public editCommunity(i : number) {
- let community : Community = this.communitiesCheckboxes[i].community;
+ let community : Community = this.checkboxes[i].community;
this.formGroup.patchValue(community);
this.updateModal.showModal();
}
public communitySavedSuccessfully(community: Community) {
- this.communitiesCheckboxes.push({community : community, checked : false});
- console.info("checkboxes length: "+this.communitiesCheckboxes.length);
+ this.checkboxes.push({community : community, checked : false});
+ console.info("checkboxes length: "+this.checkboxes.length);
this.applyCheck(false);
}
public communityUpdatedSuccessfully(community : Community) {
- this.communitiesCheckboxes.find(checkItem => checkItem.community._id==community._id).community = community;
+ this.checkboxes.find(checkItem => checkItem.community._id==community._id).community = community;
this.applyCheck(false);
}
@@ -140,9 +140,9 @@ export class CommunitiesComponent implements OnInit {
}
public applyFilter() {
- this.communitiesCheckboxes = [];
+ this.checkboxes = [];
this.communities.filter(item => this.filterCommunities(item)).forEach(
- _ => this.communitiesCheckboxes.push({community: _, checked: false})
+ _ => this.checkboxes.push({community: _, checked: false})
);
}
diff --git a/app/pages/faq/questions.component.html b/app/pages/faq/questions.component.html
index a214066..5096752 100644
--- a/app/pages/faq/questions.component.html
+++ b/app/pages/faq/questions.component.html
@@ -151,4 +151,3 @@
Are you sure you want to delete the selected question(s)?
-
diff --git a/app/pages/helpcontent/edit-page-help-content.component.html b/app/pages/helpcontent/edit-page-help-content.component.html
index 9cd9eb5..e5e8a0c 100644
--- a/app/pages/helpcontent/edit-page-help-content.component.html
+++ b/app/pages/helpcontent/edit-page-help-content.component.html
@@ -11,7 +11,7 @@
Bulk Actions
-
+ -
-
- Delete -
+
@@ -40,32 +36,34 @@ Communities
+
+
+
+
-
+
- Delete +
-
-
-
-
- 0">
-
-
-
-
-
-
@@ -74,7 +72,6 @@ Communities
+
+
+
+ Name
+ Actions
+
+
+
+
+
-
-
+
+
-
-
-
-
+
+
+
+
+
+
{{check.community.name}}
-
-
+
-
No communities found
+
+
No communities found
diff --git a/app/pages/helpcontent/entities.component.html b/app/pages/helpcontent/entities.component.html
index 97d01cb..a1d8b53 100644
--- a/app/pages/helpcontent/entities.component.html
+++ b/app/pages/helpcontent/entities.component.html
@@ -13,11 +13,11 @@
-
+
-
+
-
{entity : _, checked : false});
+ self.checkboxes.push({entity : _, checked : false});
});
},
error => this.handleError('System error retrieving entities', error));
@@ -79,22 +79,22 @@ export class EntitiesComponent implements OnInit {
}
public toggleCheckBoxes(event) {
- this.entitiesCheckboxes.forEach(_ => _.checked = event.target.checked);
+ this.checkboxes.forEach(_ => _.checked = event.target.checked);
}
public applyCheck(flag : boolean) {
console.info("applyCheck "+flag);
- this.entitiesCheckboxes.forEach(_ => _.checked = flag);
+ this.checkboxes.forEach(_ => _.checked = flag);
}
public getSelectedEntities() : string[] {
- return this.entitiesCheckboxes.filter(entity => entity.checked == true).map(checkedEntity => checkedEntity.entity).map(res => res._id);
+ return this.checkboxes.filter(entity => entity.checked == true).map(checkedEntity => checkedEntity.entity).map(res => res._id);
}
private deleteEntitiesFromArray(ids : string[]) : void {
for(let id of ids) {
- let i = this.entitiesCheckboxes.findIndex(_ => _.entity._id == id);
- this.entitiesCheckboxes.splice(i, 1);
+ let i = this.checkboxes.findIndex(_ => _.entity._id == id);
+ this.checkboxes.splice(i, 1);
}
}
@@ -116,18 +116,18 @@ export class EntitiesComponent implements OnInit {
}
public editEntity(i : number) {
- let entity : Entity = this.entitiesCheckboxes[i].entity;
+ let entity : Entity = this.checkboxes[i].entity;
this.formGroup.patchValue(entity);
this.updateModal.showModal();
}
public entitySavedSuccessfully(entity: Entity) {
- this.entitiesCheckboxes.push({entity : entity, checked : false});
+ this.checkboxes.push({entity : entity, checked : false});
this.applyCheck(false);
}
public entityUpdatedSuccessfully(entity : Entity) {
- this.entitiesCheckboxes.find(checkItem => checkItem.entity._id==entity._id).entity = entity;
+ this.checkboxes.find(checkItem => checkItem.entity._id==entity._id).entity = entity;
this.applyCheck(false);
}
@@ -137,9 +137,9 @@ export class EntitiesComponent implements OnInit {
}
public applyFilter() {
- this.entitiesCheckboxes = [];
+ this.checkboxes = [];
this.entities.filter(item => this.filterEntities(item)).forEach(
- _ => this.entitiesCheckboxes.push({entity: _, checked: false})
+ _ => this.checkboxes.push({entity: _, checked: false})
);
}
@@ -169,8 +169,8 @@ export class EntitiesComponent implements OnInit {
public toggleEntity(status : boolean, id : string) {
this._helpContentService.toggleEntity(this.selectedCommunityId,id,status).subscribe(
() => {
- let i = this.entitiesCheckboxes.findIndex(_ => _.entity._id == id);
- this.entitiesCheckboxes[i].entity.isEnabled=status;
+ let i = this.checkboxes.findIndex(_ => _.entity._id == id);
+ this.checkboxes[i].entity.isEnabled=status;
this.applyCheck(false);
},
error => this.handleError('System error changing the status of the selected entity(-ies)', error)
diff --git a/app/pages/helpcontent/new-page-help-content.component.html b/app/pages/helpcontent/new-page-help-content.component.html
index d1487eb..c32b667 100644
--- a/app/pages/helpcontent/new-page-help-content.component.html
+++ b/app/pages/helpcontent/new-page-help-content.component.html
@@ -11,7 +11,7 @@
+
@@ -63,7 +63,7 @@
-
+
@@ -88,8 +88,8 @@
-
diff --git a/app/pages/helpcontent/entities.component.ts b/app/pages/helpcontent/entities.component.ts
index ece2fd3..5f1a189 100644
--- a/app/pages/helpcontent/entities.component.ts
+++ b/app/pages/helpcontent/entities.component.ts
@@ -27,7 +27,7 @@ export class EntitiesComponent implements OnInit {
@ViewChild(EntityFormComponent)
public formComponent : EntityFormComponent;
- public entitiesCheckboxes : CheckEntity[] = [];
+ public checkboxes : CheckEntity[] = [];
public entities : Entity[] = [];
@@ -65,10 +65,10 @@ export class EntitiesComponent implements OnInit {
this._helpContentService.getCommunityEntities(community_id).subscribe(
entities => {
self.entities = entities;
- self.entitiesCheckboxes = [];
+ self.checkboxes = [];
entities.forEach(_ => {
- self.entitiesCheckboxes.push(
-
No entities found
+
+
No entities found
diff --git a/app/pages/helpcontent/page-form.component.html b/app/pages/helpcontent/page-form.component.html
index 6435757..35a37d4 100644
--- a/app/pages/helpcontent/page-form.component.html
+++ b/app/pages/helpcontent/page-form.component.html
@@ -16,105 +16,28 @@
-
+
+
+
+ Are you sure you want to delete the selected page content(s)?
+ -->
+
+
+
Are you sure you want to delete the selected page content(s)?
diff --git a/app/pages/helpcontent/page-help-contents.component.ts b/app/pages/helpcontent/page-help-contents.component.ts
index 13d44df..bfad1b6 100644
--- a/app/pages/helpcontent/page-help-contents.component.ts
+++ b/app/pages/helpcontent/page-help-contents.component.ts
@@ -31,7 +31,7 @@ export class PageHelpContentsComponent implements OnInit {
@ViewChild('deleteConfirmationModal')
public deleteConfirmationModal : DeleteConfirmationDialogComponent;
- public pageHelpContentsCheckboxes : CheckPageHelpContent[] = [];
+ public checkboxes : CheckPageHelpContent[] = [];
public pageHelpContents : PageHelpContent[] = [];
@@ -120,17 +120,17 @@ export class PageHelpContentsComponent implements OnInit {
pageHelpContents => {
self.pageHelpContents = pageHelpContents as Array;
self.counter.all = self.pageHelpContents.length;
- self.pageHelpContentsCheckboxes = [];
+ self.checkboxes = [];
/*self.pageHelpContents.forEach(_ => {
let page: Page = _.page as Page;
if(!self.selectedPageId || (page._id == self.selectedPageId)) {
- self.pageHelpContentsCheckboxes.push({pageHelpContent : _, checked : false});
+ self.checkboxes.push({pageHelpContent : _, checked : false});
}
});*/
for (let i = self.pageHelpContents.length - 1; i >= 0; i -= 1) {
let page: Page = self.pageHelpContents[i].page as Page;
if(!self.selectedPageId || (page._id == self.selectedPageId)) {
- self.pageHelpContentsCheckboxes.push({pageHelpContent : self.pageHelpContents[i], checked : false});
+ self.checkboxes.push({pageHelpContent : self.pageHelpContents[i], checked : false});
} else {
self.pageHelpContents.splice(i, 1);
}
@@ -146,17 +146,17 @@ export class PageHelpContentsComponent implements OnInit {
// }
public toggleCheckBoxes(event) {
- this.pageHelpContentsCheckboxes.forEach(_ => _.checked = event.target.checked);
+ this.checkboxes.forEach(_ => _.checked = event.target.checked);
this.checkboxAll = event.target.checked;
}
public applyCheck(flag : boolean) {
- this.pageHelpContentsCheckboxes.forEach(_ => _.checked = flag);
+ this.checkboxes.forEach(_ => _.checked = flag);
this.checkboxAll = false;
}
public getSelectedPageHelpContents() : string[] {
- return this.pageHelpContentsCheckboxes.filter(pageHelpContent => pageHelpContent.checked == true)
+ return this.checkboxes.filter(pageHelpContent => pageHelpContent.checked == true)
.map(checkedPageHelpContent => checkedPageHelpContent.pageHelpContent).map(res => res._id);
}
@@ -179,9 +179,9 @@ export class PageHelpContentsComponent implements OnInit {
private deletePageHelpContentsFromArray(ids : string[]) : void {
for(let id of ids) {
- let iqc = this.pageHelpContentsCheckboxes.findIndex(_ => _.pageHelpContent._id == id);
+ let iqc = this.checkboxes.findIndex(_ => _.pageHelpContent._id == id);
let iq = this.pageHelpContents.findIndex(_ => _._id == id);
- this.pageHelpContentsCheckboxes.splice(iqc, 1);
+ this.checkboxes.splice(iqc, 1);
this.pageHelpContents.splice(iqc, 1);
}
}
@@ -199,9 +199,9 @@ export class PageHelpContentsComponent implements OnInit {
this._helpService.togglePageHelpContents(ids,status).subscribe(
() => {
for(let id of ids) {
- let i = this.pageHelpContentsCheckboxes.findIndex(_ => _.pageHelpContent._id == id);
+ let i = this.checkboxes.findIndex(_ => _.pageHelpContent._id == id);
console.info(i);
- this.pageHelpContentsCheckboxes[i].pageHelpContent.isActive=status;
+ this.checkboxes[i].pageHelpContent.isActive=status;
}
this.countPageHelpContents();
this.applyCheck(false);
@@ -219,14 +219,14 @@ export class PageHelpContentsComponent implements OnInit {
}
public pageHelpContentSavedSuccessfully(pageHelpContent: PageHelpContent) {
- this.pageHelpContentsCheckboxes.push({pageHelpContent : pageHelpContent, checked : false});
+ this.checkboxes.push({pageHelpContent : pageHelpContent, checked : false});
this.pageHelpContents.push(pageHelpContent);
this.applyCheck(false);
this.countPageHelpContents();
}
public pageHelpContentUpdatedSuccessfully(pageHelpContent : PageHelpContent) {
- this.pageHelpContentsCheckboxes.find(checkItem => checkItem.pageHelpContent._id==pageHelpContent._id).pageHelpContent = pageHelpContent;
+ this.checkboxes.find(checkItem => checkItem.pageHelpContent._id==pageHelpContent._id).pageHelpContent = pageHelpContent;
let index = this.pageHelpContents.findIndex(checkItem => checkItem._id==pageHelpContent._id);
this.pageHelpContents[index] = pageHelpContent;
this.applyCheck(false);
@@ -242,9 +242,9 @@ export class PageHelpContentsComponent implements OnInit {
}
public applyFilter() {
- this.pageHelpContentsCheckboxes = [];
+ this.checkboxes = [];
this.pageHelpContents.filter(item => this.filterPageHelpContent(item,this.filters)).forEach(
- _ => this.pageHelpContentsCheckboxes.push({pageHelpContent: _, checked: false})
+ _ => this.checkboxes.push({pageHelpContent: _, checked: false})
);
this.countPageHelpContents();
}
diff --git a/app/pages/helpcontent/pages.component.html b/app/pages/helpcontent/pages.component.html
index b42c140..f0e67a5 100644
--- a/app/pages/helpcontent/pages.component.html
+++ b/app/pages/helpcontent/pages.component.html
@@ -1,4 +1,4 @@
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+{{entity.name}},
-
+
+
+
+
+
+
+
+
+
+ {{entity.name}}
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/app/pages/helpcontent/page-form.component.ts b/app/pages/helpcontent/page-form.component.ts
index a50cfc5..b43b75c 100644
--- a/app/pages/helpcontent/page-form.component.ts
+++ b/app/pages/helpcontent/page-form.component.ts
@@ -3,8 +3,6 @@
*/
import {Component, OnInit, Input} from '@angular/core';
import {FormGroup, FormArray, FormBuilder, Validators} from "@angular/forms";
-import { CollapseDirective } from 'ngx-bootstrap/collapse';
-//import { AccordionDirective } from 'ngx-bootstrap/accordion';
import {Entity} from '../../domain/entity';
import { HelpContentService } from "../../services/help-content.service";
diff --git a/app/pages/helpcontent/page-help-content-form.component.html b/app/pages/helpcontent/page-help-content-form.component.html
index 688cb3f..cd1cb88 100644
--- a/app/pages/helpcontent/page-help-content-form.component.html
+++ b/app/pages/helpcontent/page-help-content-form.component.html
@@ -1,4 +1,4 @@
-
-
-
- {{entity.name}},
-
-
-
-
-
-
-
-
-
-
- {{entity.name}}
-
-
- {{errorMessage}}
+{{errorMessage}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
- Activate +
- Deactivate +
- Delete +
+
+
+
+ Go back to {{pageType}} pages
+
+
+
+
+
+
+
+
+
+
+
+
+ Filter by community:
+
+
+
+
+
+ Filter page contents:
+
+ Filter by page:
+
+
+ -
+
- + All Page Contents {{counter.all}} + +
- + Active {{counter.active}} + +
- + Inactive {{counter.inactive}} + +
+ | Page | +Community | +Content | +Placement | +Order | +Active | +Actions | +
---|---|---|---|---|---|---|---|
+ | +
+ {{check.pageHelpContent.page.name}}
+ |
+
+ {{check.pageHelpContent.community.name}}
+ |
+
+ {{check.pageHelpContent.content}}
+ |
+
+ {{check.pageHelpContent.placement}}
+ |
+
+ {{check.pageHelpContent.order}}
+
+ |
+
+
+
+
+
+
+
+ |
+
+
+
+
+
+ |
+
+
+ No page contents found
+
+
@@ -73,7 +72,6 @@
{{check.page.name}}
-
@@ -124,6 +122,144 @@
+
+ Are you sure you want to delete the selected page(s)?
+ -->
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
Are you sure you want to delete the selected page(s)?
diff --git a/app/pages/helpcontent/pages.component.ts b/app/pages/helpcontent/pages.component.ts
index 7c32a2b..be06b3d 100644
--- a/app/pages/helpcontent/pages.component.ts
+++ b/app/pages/helpcontent/pages.component.ts
@@ -32,7 +32,7 @@ export class PagesComponent implements OnInit {
@ViewChild(PageFormComponent)
public formComponent : PageFormComponent;
- public pagesCheckboxes : CheckPage[] = [];
+ public checkboxes : CheckPage[] = [];
public pages : Page[] = [];
@@ -83,10 +83,10 @@ export class PagesComponent implements OnInit {
pagesReturned(pages: Page[]) {
this.pages = pages;
- this.pagesCheckboxes = [];
+ this.checkboxes = [];
pages.forEach(_ => {
- this.pagesCheckboxes.push({page : _, checked : false});
+ this.checkboxes.push({page : _, checked : false});
});
}
@@ -106,22 +106,22 @@ export class PagesComponent implements OnInit {
}
public toggleCheckBoxes(event) {
- this.pagesCheckboxes.forEach(_ => _.checked = event.target.checked);
+ this.checkboxes.forEach(_ => _.checked = event.target.checked);
}
public applyCheck(flag : boolean) {
console.info("applyCheck "+flag);
- this.pagesCheckboxes.forEach(_ => _.checked = flag);
+ this.checkboxes.forEach(_ => _.checked = flag);
}
public getSelectedPages() : string[] {
- return this.pagesCheckboxes.filter(page => page.checked == true).map(checkedPage => checkedPage.page).map(res => res._id);
+ return this.checkboxes.filter(page => page.checked == true).map(checkedPage => checkedPage.page).map(res => res._id);
}
private deletePagesFromArray(ids : string[]) : void {
for(let id of ids) {
- let i = this.pagesCheckboxes.findIndex(_ => _.page._id == id);
- this.pagesCheckboxes.splice(i, 1);
+ let i = this.checkboxes.findIndex(_ => _.page._id == id);
+ this.checkboxes.splice(i, 1);
}
}
@@ -143,7 +143,7 @@ export class PagesComponent implements OnInit {
}
public editPage(i : number) {
- let page : Page = this.pagesCheckboxes[i].page;
+ let page : Page = this.checkboxes[i].page;
this.formGroup.patchValue(page);
const entityFGs = (page.entities as Entity[]).map(entity => this.formComponent._fb.group(entity));
const entityFormArray = this.formComponent._fb.array(entityFGs);
@@ -153,16 +153,16 @@ export class PagesComponent implements OnInit {
}
public pageSavedSuccessfully(page: Page) {
- this.pagesCheckboxes.push({page : page, checked : false});
- console.info("checkboxes length: "+this.pagesCheckboxes.length);
+ this.checkboxes.push({page : page, checked : false});
+ console.info("checkboxes length: "+this.checkboxes.length);
this.applyCheck(false);
}
public pageUpdatedSuccessfully(page : Page) {
console.info(page._id);
- console.info(this.pagesCheckboxes.find(checkItem => (checkItem.page._id == page._id)));
+ console.info(this.checkboxes.find(checkItem => (checkItem.page._id == page._id)));
console.info(page.entities);
- this.pagesCheckboxes.find(checkItem => checkItem.page._id==page._id).page = page;
+ this.checkboxes.find(checkItem => checkItem.page._id==page._id).page = page;
this.applyCheck(false);
}
@@ -172,9 +172,9 @@ export class PagesComponent implements OnInit {
}
public applyFilter() {
- this.pagesCheckboxes = [];
+ this.checkboxes = [];
this.pages.filter(item => this.filterPages(item)).forEach(
- _ => this.pagesCheckboxes.push({page: _, checked: false})
+ _ => this.checkboxes.push({page: _, checked: false})
);
}
@@ -205,12 +205,12 @@ export class PagesComponent implements OnInit {
this._helpContentService.togglePage(this.selectedCommunityId,id,status).subscribe(
() => {
// for(let id of ret) {
- // let i = this.pagesCheckboxes.findIndex(_ => _.page._id == id);
- // this.pagesCheckboxes[i].page.isEnabled=status;
+ // let i = this.checkboxes.findIndex(_ => _.page._id == id);
+ // this.checkboxes[i].page.isEnabled=status;
// }
//this.countPageHelpContents();
- let i = this.pagesCheckboxes.findIndex(_ => _.page._id == id);
- this.pagesCheckboxes[i].page.isEnabled=status;
+ let i = this.checkboxes.findIndex(_ => _.page._id == id);
+ this.checkboxes[i].page.isEnabled=status;
this.applyCheck(false);
},
error => this.handleError('System error changing the status of the selected page(s)', error)
diff --git a/app/pages/helpcontent/selectEntities.component.html b/app/pages/helpcontent/selectEntities.component.html
index 9d1fa3e..bf41291 100644
--- a/app/pages/helpcontent/selectEntities.component.html
+++ b/app/pages/helpcontent/selectEntities.component.html
@@ -16,11 +16,11 @@
+
+
+
+
+
+
+ Pages
+
+ New Page
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
- Delete +
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Filter by community:
+
+
+ + | Name | +State | +Type | +Related Entities | +Route | +Actions | +Help Contents | +
---|---|---|---|---|---|---|---|
+ | +
+ {{check.page.name}}
+ |
+
+
+
+
+
+
+
+ |
+
+ {{check.page.type}}
+ |
+
+
+ {{entity.name}},
+
+ |
+
+ {{check.page.route}}
+ |
+
+
+
+
+
+
+ |
+ + edit + | +
+
+ No pages found
+
-
+
-
+
-
diff --git a/app/pages/modal-form.component.html b/app/pages/modal-form.component.html
index 9b12991..fc81662 100644
--- a/app/pages/modal-form.component.html
+++ b/app/pages/modal-form.component.html
@@ -8,7 +8,7 @@
+
@@ -69,7 +69,7 @@
-
No entities found
+ No entities found
{{titleText}}
-
{{ errorMessage }}
+ {{ errorMessage }}