Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
#78 improve typo and remove duplicated components
  • Loading branch information
daros10 committed Apr 13, 2020
commit 586535f9eae8a2fc208b566d003b4733e53fbc55
4 changes: 1 addition & 3 deletions src/app/app-routing.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import { AzureGuardService } from './guards/azure-guard.service';
import { ReportsComponent } from './modules/reports/pages/reports.component';
import { TimeClockComponent } from './modules/time-clock/pages/time-clock.component';
import { TimeEntriesComponent } from './modules/time-entries/pages/time-entries.component';
import { ProjectManagementComponent } from './modules/project-management/pages/project-management.component';
import { ActivitiesManagementComponent } from './modules/activities-management/pages/activities-management.component';
import { HomeComponent } from './modules/home/home.component';
import { LoginComponent } from './modules/login/login.component';
Expand All @@ -20,9 +19,8 @@ const routes: Routes = [
{ path: 'reports', component: ReportsComponent },
{ path: 'time-clock', component: TimeClockComponent },
{ path: 'time-entries', component: TimeEntriesComponent },
{ path: 'project-management', component: ProjectManagementComponent },
{ path: 'activities-management', component: ActivitiesManagementComponent },
{ path: 'customer', component: CustomerComponent },
{ path: 'customer-managment', component: CustomerComponent },
{ path: '', pathMatch: 'full', redirectTo: 'time-clock' },
],
},
Expand Down
17 changes: 6 additions & 11 deletions src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,7 @@ import { UserComponent } from './modules/shared/components/user/user.component';
import { SidebarComponent } from './modules/shared/components/sidebar/sidebar.component';
import { ClockComponent } from './modules/shared/components/clock/clock.component';
import { TimeClockComponent } from './modules/time-clock/pages/time-clock.component';
import { ProjectManagementComponent } from './modules/project-management/pages/project-management.component';
import { TimeEntriesComponent } from './modules/time-entries/pages/time-entries.component';
import { ProjectListComponent } from './modules/project-management/components/project-list/project-list.component';
import { CreateProjectComponent } from './modules/project-management/components/create-project/create-project.component';
import { DetailsFieldsComponent } from './modules/shared/components/details-fields/details-fields.component';
import { ProjectListHoverComponent } from './modules/time-clock/components/project-list-hover/project-list-hover.component';
import { ModalComponent } from './modules/shared/components/modal/modal.component';
Expand All @@ -42,11 +39,11 @@ import { CustomerComponent } from './modules/customer-managment/pages/customer.c
import { CustomerListComponent } from './modules/customer-managment/components/customer-info/components/customer-list/customer-list.component';
import { SearchComponent } from './modules/customer-managment/components/search/search.component';
// tslint:disable-next-line: max-line-length
import { ManagmentCustomerProjectsComponent } from './modules/customer-managment/components/managment-customer-projects/managment-customer-projects.component';
import { ManagementCustomerProjectsComponent } from './modules/customer-managment/components/management-customer-projects/management-customer-projects.component';
import { CreateCustomerComponent } from './modules/customer-managment/components/customer-info/components/create-customer/create-customer';
// tslint:disable-next-line: max-line-length
import { CreateeProjectComponent } from './modules/customer-managment/components/projects/components/create-project/createe-project.component';
import { ProjectLiistComponent } from './modules/customer-managment/components/projects/components/project-liist/project-liist.component';
import { CreateProjectComponent } from './modules/customer-managment/components/projects/components/create-project/create-project.component';
import { ProjectListComponent } from './modules/customer-managment/components/projects/components/project-list/project-list.component';
// tslint:disable-next-line: max-line-length
import { ProjectTypeListComponent } from './modules/customer-managment/components/projects-type/components/project-type-list/project-type-list.component';
// tslint:disable-next-line: max-line-length
Expand All @@ -60,8 +57,6 @@ import { CreateProjectTypeComponent } from './modules/customer-managment/compone
SidebarComponent,
ClockComponent,
TimeClockComponent,
ProjectManagementComponent,
ProjectListComponent,
CreateProjectComponent,
TimeClockComponent,
DetailsFieldsComponent,
Expand All @@ -81,10 +76,10 @@ import { CreateProjectTypeComponent } from './modules/customer-managment/compone
CustomerComponent,
CustomerListComponent,
SearchComponent,
ManagmentCustomerProjectsComponent,
ManagementCustomerProjectsComponent,
CreateCustomerComponent,
CreateeProjectComponent,
ProjectLiistComponent,
CreateProjectComponent,
ProjectListComponent,
ProjectTypeListComponent,
CreateProjectTypeComponent,
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ describe('InputCustomerComponent', () => {
fixture.detectChanges();
});

it('should create', () => {
it('component should create', () => {
expect(component).toBeTruthy();
});
});
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
import { Component, OnInit } from '@angular/core';
import { Component } from '@angular/core';

@Component({
selector: 'app-create-customer',
templateUrl: './create-customer.html',
styleUrls: ['./create-customer.scss'],
})
export class CreateCustomerComponent implements OnInit {
export class CreateCustomerComponent {
constructor() {}

ngOnInit(): void {}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<tbody>
<tr
class="d-flex"
*ngFor="let customer of customers | paginate: { itemsPerPage: 5, currentPage: initPage1, id: 'first' }"
*ngFor="let customer of customers | paginate: { itemsPerPage: itemsPerPage, currentPage: initPage1, id: 'first' }"
>
<td class="col-sm-9">{{ customer.name }}</td>
<td class="col-sm-3 text-center">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ describe('CustomerTableListComponent', () => {
fixture.detectChanges();
});

it('should create', () => {
it('component should create', () => {
expect(component).toBeTruthy();
});

Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';
import { Component, Input, Output, EventEmitter } from '@angular/core';
import { ITEMS_PER_PAGE } from 'src/environments/environment';

@Component({
selector: 'app-customer-list',
templateUrl: './customer-list.component.html',
styleUrls: ['./customer-list.component.scss'],
})
export class CustomerListComponent implements OnInit {
export class CustomerListComponent {
initPage1 = 1;
itemsPerPage = ITEMS_PER_PAGE;

customers = [
{
Expand All @@ -32,8 +34,6 @@ export class CustomerListComponent implements OnInit {

constructor() {}

ngOnInit(): void {}

activateCustomerForm() {
this.showCustomerForm = true;
this.changeShowCustomerForm.emit(this.showCustomerForm);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
<app-create-customer></app-create-customer>
</div>
<div class="tab-pane fade mt-3" id="projects" role="tabpanel" aria-labelledby="projects-tab">
<app-createe-project></app-createe-project>
<app-create-project></app-create-project>
</div>
<div class="tab-pane fade mt-3" id="projectsType" role="tabpanel" aria-labelledby="projects-type-tab">
<app-create-project-type></app-create-project-type>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing';

import { ManagementCustomerProjectsComponent } from './management-customer-projects.component';

describe('ManagmentCustomerProjectsComponent', () => {
let component: ManagementCustomerProjectsComponent;
let fixture: ComponentFixture<ManagementCustomerProjectsComponent>;

beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ManagementCustomerProjectsComponent],
}).compileComponents();
}));

beforeEach(() => {
fixture = TestBed.createComponent(ManagementCustomerProjectsComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});

it('component should create', () => {
expect(component).toBeTruthy();
});
});
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import { Component } from '@angular/core';

@Component({
selector: 'app-management-customer-projects',
templateUrl: './management-customer-projects.component.html',
styleUrls: ['./management-customer-projects.component.scss'],
})
export class ManagementCustomerProjectsComponent {
constructor() {}
}

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<input type="text" class="form-control form-control-sm" id="" aria-describedby="" placeholder="Name" />
<textarea
class="form-control form-control-sm mt-2"
id="exampleFormControlTextarea1"
id="descriptionTextArea"
rows="3"
placeholder="Description"
></textarea>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ describe('InputProjectTypeComponent', () => {
fixture.detectChanges();
});

it('should create', () => {
it('component should create', () => {
expect(component).toBeTruthy();
});
});
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
import { Component, OnInit } from '@angular/core';
import { Component } from '@angular/core';

@Component({
selector: 'app-create-project-type',
templateUrl: './create-project-type.component.html',
styleUrls: ['./create-project-type.component.scss'],
})
export class CreateProjectTypeComponent implements OnInit {
export class CreateProjectTypeComponent {
constructor() {}

ngOnInit(): void {}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@
<tbody>
<tr
class="d-flex"
*ngFor="let projectType of projectsType | paginate: { itemsPerPage: 3, currentPage: initPage2, id: 'second' }"
*ngFor="
let projectType of projectsType | paginate: { itemsPerPage: itemsPerPage, currentPage: initPage2, id: 'second' }
"
>
<td class="col-sm-9">{{ projectType.name }}</td>
<td class="col-sm-3 text-center">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ describe('ProjectTypeTableListComponent', () => {
fixture.detectChanges();
});

it('should create', () => {
it('component should create', () => {
expect(component).toBeTruthy();
});
});
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
import { Component, OnInit } from '@angular/core';
import { Component } from '@angular/core';
import { ITEMS_PER_PAGE } from 'src/environments/environment';

@Component({
selector: 'app-project-type-list',
templateUrl: './project-type-list.component.html',
styleUrls: ['./project-type-list.component.scss'],
})
export class ProjectTypeListComponent implements OnInit {
export class ProjectTypeListComponent {
initPage2 = 1;
itemsPerPage = ITEMS_PER_PAGE;

projectsType = [
{
id: '1',
Expand All @@ -19,6 +22,4 @@ export class ProjectTypeListComponent implements OnInit {
];

constructor() {}

ngOnInit(): void {}
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,5 @@
<hr />
<app-search></app-search>
</div>
<app-project-liist></app-project-liist>
<app-project-list></app-project-list>
</div>
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing';

import { CreateeProjectComponent } from './createe-project.component';
import { CreateProjectComponent } from './create-project.component';

describe('InputProjectComponent', () => {
let component: CreateeProjectComponent;
let fixture: ComponentFixture<CreateeProjectComponent>;
let component: CreateProjectComponent;
let fixture: ComponentFixture<CreateProjectComponent>;

beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [CreateeProjectComponent],
declarations: [CreateProjectComponent],
}).compileComponents();
}));

beforeEach(() => {
fixture = TestBed.createComponent(CreateeProjectComponent);
fixture = TestBed.createComponent(CreateProjectComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});

it('should create', () => {
it('component should create', () => {
expect(component).toBeTruthy();
});
});
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import { Component } from '@angular/core';

@Component({
selector: 'app-create-project',
templateUrl: './create-project.component.html',
styleUrls: ['./create-project.component.scss'],
})
export class CreateProjectComponent {
constructor() {}
}

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<tbody>
<tr
class="d-flex"
*ngFor="let project of projects | paginate: { itemsPerPage: 3, currentPage: initPage3, id: 'third' }"
*ngFor="let project of projects | paginate: { itemsPerPage: itemsPerPage, currentPage: initPage3, id: 'third' }"
>
<td class="col-sm-9">{{ project.name }}</td>
<td class="col-sm-3 text-center">
Expand Down
Loading