Skip to content

Commit 19fe38b

Browse files
authored
Merge 2ed3335 into 94ce9d5
2 parents 94ce9d5 + 2ed3335 commit 19fe38b

File tree

4 files changed

+14
-8
lines changed

4 files changed

+14
-8
lines changed

src/app/modules/customer-management/components/projects/components/project-list/project-list.component.html

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,20 @@
22
<table class="table table-sm table-bordered table-striped">
33
<thead class="thead-blue">
44
<tr class="d-flex">
5-
<th scope="col" class="col-4 text-center">Project ID</th>
5+
<th scope="col" class="col-3 text-center">Project ID</th>
66
<th scope="col" class="col-3 text-center">Project</th>
7-
<th scope="col" class="col-3 text-center">Project Type</th>
7+
<th scope="col" class="col-2 text-center">Technologies</th>
8+
<th scope="col" class="col-2 text-center">Project Type</th>
89
<th scope="col" class="col-1 text-center">Options</th>
910
<th scope="col" class="col-1 text-center">Visibility</th>
1011
</tr>
1112
</thead>
1213
<tbody>
1314
<tr class="d-flex" *ngFor="let project of projects">
14-
<td class="col-sm-4">{{ project.id }}</td>
15+
<td class="col-sm-3">{{ project.id }}</td>
1516
<td class="col-sm-3">{{ project.name }}</td>
16-
<td class="col-sm-3">{{ getProjectTypeName(project.project_type_id) }}</td>
17+
<td class="col-sm-2">{{ project.technologies ? project.technologies.toString() : ""}}</td>
18+
<td class="col-sm-2">{{ getProjectTypeName(project.project_type_id) }}</td>
1719
<td class="col-sm-1 text-center">
1820
<button type="button" class="btn btn-sm btn-primary" (click)="updateProject(project)">
1921
<i class="fa fa-pencil fa-xs"></i>
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
@import '../../../../../../../styles/colors.scss';
22

33
.project-list {
4-
max-height: 300px; overflow: auto; display:inline-block; width: 100%;
4+
height: 300%; overflow: auto; display:inline-block; width: 100%;
55
}

src/app/modules/customer-management/components/projects/components/project-list/project-list.component.spec.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ describe('ProjectListComponent', () => {
1818
let getCustomerProjectsSelectorMock;
1919
let allCustomerProjectsSelectorMock;
2020

21-
const project = { id: '123', name: 'aaa', description: 'xxx', project_type_id: '1234', status: 'inactive' };
21+
const project = { id: '123', name: 'aaa', description: 'xxx', project_type_id: '1234', technologies: ['python', 'angular'], status: 'inactive' };
2222

2323
const state: ProjectState = {
2424
projects: [project],
@@ -125,6 +125,7 @@ describe('ProjectListComponent', () => {
125125
name: 'aaa',
126126
description: 'xxx',
127127
project_type_id: '1234',
128+
technologies: ['python', 'angular'],
128129
status: 'activate',
129130
key: 'activate',
130131
_status: false,
@@ -144,6 +145,7 @@ describe('ProjectListComponent', () => {
144145
name: 'aaa',
145146
description: 'xxx',
146147
project_type_id: '1234',
148+
technologies: ['python', 'angular'],
147149
status: 'inactive',
148150
key: 'inactive',
149151
_status: true,
@@ -172,10 +174,10 @@ describe('ProjectListComponent', () => {
172174
expect(tableRows.length).toBe(2);
173175

174176
const headerRow = tableRows[0];
175-
expect(headerRow.cells[2].innerHTML).toBe('Project Type');
177+
expect(headerRow.cells[3].innerHTML).toBe('Project Type');
176178

177179
const dataRow = tableRows[1];
178-
expect(dataRow.cells[2].innerHTML).toBe('BK');
180+
expect(dataRow.cells[3].innerHTML).toBe('BK');
179181

180182
done();
181183
});

src/app/modules/shared/models/project.model.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ export interface Project {
66
description?: string;
77
project_type_id?: string;
88
search_field?: string;
9+
technologies?: string[];
910
status?: any;
1011
}
1112

@@ -17,6 +18,7 @@ export interface ProjectUI {
1718
description?: string;
1819
project_type_id?: string;
1920
search_field?: string;
21+
technologies?: string[];
2022
status?: any;
2123
key?: string;
2224
btnColor?: string;

0 commit comments

Comments
 (0)