Skip to content

Commit

Permalink
task filters
Browse files Browse the repository at this point in the history
  • Loading branch information
DenysVuika committed Jan 8, 2025
1 parent 442ac28 commit 9eab2df
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 45 deletions.
6 changes: 3 additions & 3 deletions lib/process-services-cloud/src/lib/task/task-cloud.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@

import { NgModule } from '@angular/core';
import { TaskListCloudModule } from './task-list/task-list-cloud.module';
import { TaskFiltersCloudModule } from './task-filters/task-filters-cloud.module';
import { TASK_FILTERS_CLOUD_DIRECTIVES } from './task-filters/task-filters-cloud.module';
import { TASK_DIRECTIVES } from './directives/task-directive.module';
import { TaskFormModule } from './task-form/task-form.module';
import { TaskHeaderCloudComponent } from './task-header/components/task-header-cloud.component';

@NgModule({
imports: [TaskListCloudModule, TaskFiltersCloudModule, TaskHeaderCloudComponent, ...TASK_DIRECTIVES, TaskFormModule],
exports: [TaskListCloudModule, TaskFiltersCloudModule, TaskHeaderCloudComponent, ...TASK_DIRECTIVES, TaskFormModule]
imports: [TaskListCloudModule, ...TASK_FILTERS_CLOUD_DIRECTIVES, TaskHeaderCloudComponent, ...TASK_DIRECTIVES, TaskFormModule],
exports: [TaskListCloudModule, ...TASK_FILTERS_CLOUD_DIRECTIVES, TaskHeaderCloudComponent, ...TASK_DIRECTIVES, TaskFormModule]
})
export class TaskCloudModule {}
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import { LocalPreferenceCloudService } from '../../../../../services/local-prefe
import { ProcessServiceCloudTestingModule } from '../../../../../testing/process-service-cloud.testing.module';
import { AppsProcessCloudService } from '../../../../../app/services/apps-process-cloud.service';
import { fakeApplicationInstance, fakeApplicationInstanceWithEnvironment } from '../../../../../app/mock/app-model.mock';
import { TaskFiltersCloudModule } from '../../../task-filters-cloud.module';
import { ServiceTaskFilterCloudService } from '../../../services/service-task-filter-cloud.service';
import { TaskCloudService } from '../../../../services/task-cloud.service';
import { fakeServiceFilter } from '../../../mock/task-filters-cloud.mock';
Expand Down Expand Up @@ -54,7 +53,7 @@ describe('EditServiceTaskFilterCloudComponent', () => {

beforeEach(() => {
TestBed.configureTestingModule({
imports: [ProcessServiceCloudTestingModule, TaskFiltersCloudModule, MatIconTestingModule, EditServiceTaskFilterCloudComponent],
imports: [ProcessServiceCloudTestingModule, MatIconTestingModule, EditServiceTaskFilterCloudComponent],
providers: [MatDialog, { provide: TASK_FILTERS_SERVICE_TOKEN, useClass: LocalPreferenceCloudService }]
});
fixture = TestBed.createComponent(EditServiceTaskFilterCloudComponent);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ import { LocalPreferenceCloudService } from '../../../../../services/local-prefe
import { ProcessServiceCloudTestingModule } from '../../../../../testing/process-service-cloud.testing.module';
import { AppsProcessCloudService } from '../../../../../app/services/apps-process-cloud.service';
import { fakeApplicationInstance } from '../../../../../app/mock/app-model.mock';
import { TaskFiltersCloudModule } from '../../../task-filters-cloud.module';
import { EditTaskFilterCloudComponent } from './edit-task-filter-cloud.component';
import { TaskFilterCloudService } from '../../../services/task-filter-cloud.service';
import { TaskCloudService } from '../../../../services/task-cloud.service';
Expand Down Expand Up @@ -74,13 +73,7 @@ describe('EditTaskFilterCloudComponent', () => {

beforeEach(() => {
TestBed.configureTestingModule({
imports: [
ProcessServiceCloudTestingModule,
TaskFiltersCloudModule,
PeopleCloudComponent,
MatIconTestingModule,
EditTaskFilterCloudComponent
],
imports: [ProcessServiceCloudTestingModule, PeopleCloudComponent, MatIconTestingModule, EditTaskFilterCloudComponent],
providers: [MatDialog, { provide: TASK_FILTERS_SERVICE_TOKEN, useClass: LocalPreferenceCloudService }]
});
fixture = TestBed.createComponent(EditTaskFilterCloudComponent);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ import { TASK_FILTERS_SERVICE_TOKEN } from '../../../../services/cloud-token.ser
import { LocalPreferenceCloudService } from '../../../../services/local-preference-cloud.service';
import { By } from '@angular/platform-browser';
import { ProcessServiceCloudTestingModule } from '../../../../testing/process-service-cloud.testing.module';
import { TaskFiltersCloudModule } from '../../task-filters-cloud.module';
import { fakeGlobalServiceFilters } from '../../mock/task-filters-cloud.mock';
import { ServiceTaskFilterCloudService } from '../../services/service-task-filter-cloud.service';
import { ServiceTaskFiltersCloudComponent } from './service-task-filters-cloud.component';
Expand All @@ -36,7 +35,7 @@ describe('ServiceTaskFiltersCloudComponent', () => {

beforeEach(() => {
TestBed.configureTestingModule({
imports: [ProcessServiceCloudTestingModule, TaskFiltersCloudModule, ServiceTaskFiltersCloudComponent],
imports: [ProcessServiceCloudTestingModule, ServiceTaskFiltersCloudComponent],
providers: [{ provide: TASK_FILTERS_SERVICE_TOKEN, useClass: LocalPreferenceCloudService }]
});
fixture = TestBed.createComponent(ServiceTaskFiltersCloudComponent);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,43 +16,25 @@
*/

import { NgModule } from '@angular/core';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { CommonModule } from '@angular/common';
import { TaskFiltersCloudComponent } from './components/task-filters/task-filters-cloud.component';
import { MaterialModule } from '../../material.module';
import { CoreModule } from '@alfresco/adf-core';
import { HttpClientModule } from '@angular/common/http';
import { EditServiceTaskFilterCloudComponent } from './components/edit-task-filters/edit-service-task-filter/edit-service-task-filter-cloud.component';
import { EditTaskFilterCloudComponent } from './components/edit-task-filters/edit-task-filter/edit-task-filter-cloud.component';
import { TaskFilterDialogCloudComponent } from './components/task-filter-dialog/task-filter-dialog-cloud.component';
import { ServiceTaskFiltersCloudComponent } from './components/service-task-filters/service-task-filters-cloud.component';
import { TaskAssignmentFilterCloudComponent } from './components/task-assignment-filter/task-assignment-filter.component';
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
import { APP_LIST_CLOUD_DIRECTIVES } from '../../app/app-list-cloud.module';
import { GroupCloudComponent } from '../../group/components/group-cloud.component';
import { PeopleCloudComponent } from '../../people/components/people-cloud.component';
import { DateRangeFilterComponent } from '../../common/date-range-filter/date-range-filter.component';

export const TASK_FILTERS_CLOUD_DIRECTIVES = [
TaskFilterDialogCloudComponent,
TaskFiltersCloudComponent,
ServiceTaskFiltersCloudComponent,
EditTaskFilterCloudComponent,
TaskAssignmentFilterCloudComponent,
EditServiceTaskFilterCloudComponent
] as const;

/** @deprecated use ...TASK_FILTERS_CLOUD_DIRECTIVES instead */
@NgModule({
imports: [
FormsModule,
ReactiveFormsModule,
HttpClientModule,
CommonModule,
MaterialModule,
...APP_LIST_CLOUD_DIRECTIVES,
CoreModule,
GroupCloudComponent,
DateRangeFilterComponent,
PeopleCloudComponent,
MatProgressSpinnerModule,
TaskFilterDialogCloudComponent,
TaskFiltersCloudComponent,
ServiceTaskFiltersCloudComponent,
EditTaskFilterCloudComponent,
TaskAssignmentFilterCloudComponent,
EditServiceTaskFilterCloudComponent
],
exports: [TaskFiltersCloudComponent, ServiceTaskFiltersCloudComponent, EditTaskFilterCloudComponent, EditServiceTaskFilterCloudComponent]
imports: [...TASK_FILTERS_CLOUD_DIRECTIVES],
exports: [...TASK_FILTERS_CLOUD_DIRECTIVES]
})
export class TaskFiltersCloudModule {}

0 comments on commit 9eab2df

Please sign in to comment.