Skip to content

Commit

Permalink
Enable Sort Togglz For Professional & Educational activities
Browse files Browse the repository at this point in the history
  • Loading branch information
leomendoza123 committed Oct 6, 2023
1 parent 94d44fd commit c24923b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@
[(expandedContent)]="expandedContent['EDUCATION_AND_QUALIFICATION']"
(expandedContentChange)="expandedContentChange.emit(expandedContent)"
[isPublicRecord]="isPublicRecord"
[sortTypes]="['title', 'start', 'end', 'source']"
[sortTypes]="educationAndQualification"
[sortType]="'end'"
(sort)="sortEvent($event, 'EDUCATION_AND_QUALIFICATION')"
id="cy-affiliation-education-and-qualification"
Expand Down Expand Up @@ -289,7 +289,7 @@
[(expandedContent)]="expandedContent['PROFESSIONAL_ACTIVITIES']"
(expandedContentChange)="expandedContentChange.emit(expandedContent)"
[isPublicRecord]="isPublicRecord"
[sortTypes]="['title', 'type', 'start', 'end', 'source']"
[sortTypes]="professionalActivitiesSortTypes"
(sort)="sortEvent($event, 'PROFESSIONAL_ACTIVITIES')"
[professionalActivitiesTogglz]="professionalActivitiesTogglz"
id="cy-affiliation-professional-activities"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@ export class AffiliationStacksGroupsComponent implements OnInit {
expandedContentChange: EventEmitter<MainPanelsState> = new EventEmitter()
professionalActivitiesTogglz = false
sortTypes: SortOrderType[] = ['title', 'start', 'end']

professionalActivitiesSortTypes: SortOrderType[] = ['title', 'type', 'start', 'end']
educationAndQualification: SortOrderType[] = ['title', 'start', 'end']
constructor(
private _record: RecordService,
private _recordAffiliationService: RecordAffiliationService,
Expand All @@ -73,6 +74,8 @@ export class AffiliationStacksGroupsComponent implements OnInit {
.subscribe((sourceSortingTogglz: boolean) => {
if (sourceSortingTogglz) {
this.sortTypes.push('source')
this.professionalActivitiesSortTypes.push('source')
this.educationAndQualification.push('source')
}
})
this.$loading = this._recordAffiliationService.$loading
Expand Down

0 comments on commit c24923b

Please sign in to comment.