diff --git a/core/app/src/app/app-routing.module.ts b/core/app/src/app/app-routing.module.ts index 00e0e029c..13b6ea0bf 100644 --- a/core/app/src/app/app-routing.module.ts +++ b/core/app/src/app/app-routing.module.ts @@ -2,10 +2,14 @@ import {NgModule} from '@angular/core'; import {Routes, RouterModule} from '@angular/router'; import {ClassicViewUiComponent} from '@components/classic-view/classic-view.component'; import {ClassicViewResolver} from '@services/api/resolvers/classic-view.resolver'; - +import {ListComponent} from '../../views/list/list.component'; import {AuthGuard} from '../services/auth/auth-guard.service'; const routes: Routes = [ + { + path: ':module/list', + component: ListComponent + }, { path: 'Accounts/index', loadChildren: () => import('../components/account/account.module').then(m => m.AccountUiModule) diff --git a/core/app/src/app/app.module.ts b/core/app/src/app/app.module.ts index 720615de8..e48eed1fa 100644 --- a/core/app/src/app/app.module.ts +++ b/core/app/src/app/app.module.ts @@ -15,6 +15,7 @@ import {ClassicViewUiModule} from '../components/classic-view/classic-view.modul import {MessageUiModule} from '../components/message/message.module'; import {FilterUiModule} from '../components/filter/filter.module'; import {ColumnchooserUiModule} from '../components/columnchooser/columnchooser.module'; +import {ListModule} from '../../views/list/list.module'; import {BrowserAnimationsModule} from '@angular/platform-browser/animations'; import {NgbModule} from '@ng-bootstrap/ng-bootstrap'; @@ -45,6 +46,7 @@ import { FetchPolicy } from 'apollo-client/core/watchQueryOptions'; MessageUiModule, ClassicViewUiModule, FilterUiModule, + ListModule, ColumnchooserUiModule, BrowserAnimationsModule, NgbModule diff --git a/core/app/src/test.ts b/core/app/src/test.ts index 850a66ea1..fe136b066 100644 --- a/core/app/src/test.ts +++ b/core/app/src/test.ts @@ -30,5 +30,11 @@ getTestBed().initTestEnvironment( const context = require.context('./', true, /\.spec\.ts$/); // And load the modules. context.keys().map(context); + +// Then we find all the tests. +const context_views = require.context('../views', true, /\.spec\.ts$/); +// And load the modules. +context_views.keys().map(context_views); + // Finally, start Karma to run the tests. __karma__.start(); diff --git a/core/app/tsconfig.json b/core/app/tsconfig.json index 06fd2689f..590776641 100644 --- a/core/app/tsconfig.json +++ b/core/app/tsconfig.json @@ -17,6 +17,7 @@ "paths": { "@app/*": ["./src/app/*"], "@base/*": ["./src/*"], + "@views/*": ["./views/*"], "@services/*": ["./src/services/*"], "@components/*": ["./src/components/*"] }, diff --git a/core/app/views/list/list.component.html b/core/app/views/list/list.component.html new file mode 100644 index 000000000..55a737fdb --- /dev/null +++ b/core/app/views/list/list.component.html @@ -0,0 +1 @@ +

list works!

diff --git a/core/app/views/list/list.component.spec.ts b/core/app/views/list/list.component.spec.ts new file mode 100644 index 000000000..beacd156f --- /dev/null +++ b/core/app/views/list/list.component.spec.ts @@ -0,0 +1,25 @@ +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { ListComponent } from './list.component'; + +describe('ListComponent', () => { + let component: ListComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ ListComponent ] + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(ListComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/core/app/views/list/list.component.ts b/core/app/views/list/list.component.ts new file mode 100644 index 000000000..bccd47547 --- /dev/null +++ b/core/app/views/list/list.component.ts @@ -0,0 +1,15 @@ +import { Component, OnInit } from '@angular/core'; + +@Component({ + selector: 'scrm-list', + templateUrl: './list.component.html', + styleUrls: [] +}) +export class ListComponent implements OnInit { + + constructor() { } + + ngOnInit() { + } + +} diff --git a/core/app/views/list/list.module.ts b/core/app/views/list/list.module.ts new file mode 100644 index 000000000..9d31ef8ec --- /dev/null +++ b/core/app/views/list/list.module.ts @@ -0,0 +1,12 @@ +import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { CommonModule } from '@angular/common'; +import { ListComponent } from './list.component'; + +@NgModule({ +declarations: [ListComponent], +exports: [ListComponent], +imports: [ + CommonModule, +] +}) +export class ListModule {} \ No newline at end of file diff --git a/core/app/views/list/list.php b/core/app/views/list/list.php deleted file mode 100644 index 508431445..000000000 --- a/core/app/views/list/list.php +++ /dev/null @@ -1,3 +0,0 @@ -