diff --git a/angular/.idea/workspace.xml b/angular/.idea/workspace.xml
index b8199fc..dc81c1a 100644
--- a/angular/.idea/workspace.xml
+++ b/angular/.idea/workspace.xml
@@ -3,12 +3,13 @@
-
-
-
-
-
-
+
+
+
+
+
+
+
@@ -82,7 +83,7 @@
1597514077609
-
+
@@ -94,13 +95,13 @@
-
+
-
-
+
+
-
+
\ No newline at end of file
diff --git a/angular/src/app/features/data/immutable/immutable.component.ts b/angular/src/app/features/data/immutable/immutable.component.ts
index 56b8a9f..f370eeb 100644
--- a/angular/src/app/features/data/immutable/immutable.component.ts
+++ b/angular/src/app/features/data/immutable/immutable.component.ts
@@ -56,7 +56,6 @@ export class ImmutableComponent implements OnInit {
this.store.dispatch(fetchCustomersForImmutableData());
}
- // You must implement this method for the delta row model
getRowNodeId(customer: Customer): number {
return customer.id;
}
diff --git a/angular/src/app/features/styling/cell/cell.component.ts b/angular/src/app/features/styling/cell/cell.component.ts
index a75dd29..4194f3e 100644
--- a/angular/src/app/features/styling/cell/cell.component.ts
+++ b/angular/src/app/features/styling/cell/cell.component.ts
@@ -8,12 +8,12 @@ import {
customers,
orderItems,
orders,
- products
+ products,
} from '../../../../../data/data.json';
@Component({
templateUrl: './cell.component.html',
- styleUrls: ['./cell.component.scss']
+ styleUrls: ['./cell.component.scss'],
})
export class CellComponent {
/**
@@ -24,18 +24,19 @@ export class CellComponent {
headerName: 'Customer Name',
field: 'customer.name',
filter: 'agTextColumnFilter',
- cellStyle: { color: '#fff', 'background-color': '#37474f' }
+ cellStyle: { color: '#fff', 'background-color': '#37474f' },
},
{
headerName: 'Account No',
field: 'account.accountNumber',
- filter: 'agNumberColumnFilter'
+ filter: 'agNumberColumnFilter',
},
{
headerName: 'Date of Order',
field: 'dateOfOrder',
filter: 'agDateColumnFilter',
- valueFormatter: ({ value }) => this.datePipe.transform(value, 'shortDate')
+ valueFormatter: ({ value }) =>
+ this.datePipe.transform(value, 'shortDate'),
},
{
headerName: 'Total',
@@ -45,9 +46,9 @@ export class CellComponent {
editable: true,
cellClassRules: {
'cell-value-negative': ({ value }) => value < 0,
- 'cell-value-positive': ({ value }) => value >= 0
- }
- }
+ 'cell-value-positive': ({ value }) => value >= 0,
+ },
+ },
];
/**
@@ -56,16 +57,16 @@ export class CellComponent {
*/
rowData: Array<{
[key: string]: boolean | string | number | object;
- }> = orders.map(order => ({
+ }> = orders.map((order) => ({
...order,
dateOfOrder: new Date(`${order.dateOfOrder.slice(0, 10)}T00:00:00.0`),
- account: accounts.find(account => account.id === order.accountId),
- customer: customers.find(customer => customer.id === order.customerId),
- orderItems: orderItems.filter(item => item.orderId === order.id),
+ account: accounts.find((account) => account.id === order.accountId),
+ customer: customers.find((customer) => customer.id === order.customerId),
+ orderItems: orderItems.filter((item) => item.orderId === order.id),
total: orderItems
- .filter(item => item.orderId === order.id)
- .map(item => products.find(product => product.id === item.productId))
- .reduce((prev, current) => prev + Number(current.price), 0)
+ .filter((item) => item.orderId === order.id)
+ .map((item) => products.find((product) => product.id === item.productId))
+ .reduce((prev, current) => prev + Number(current.price), 0),
}));
constructor(
diff --git a/angular/src/app/features/styling/css-overrides/css-overrides.component.scss b/angular/src/app/features/styling/css-overrides/css-overrides.component.scss
index ce8d19f..a2412e5 100644
--- a/angular/src/app/features/styling/css-overrides/css-overrides.component.scss
+++ b/angular/src/app/features/styling/css-overrides/css-overrides.component.scss
@@ -1,19 +1,3 @@
-@import '~ag-grid-community/src/styles/ag-theme-alpine/sass/ag-theme-alpine-mixin';
-
-.ag-theme-alpine {
- @include ag-theme-alpine(
- (
- // use theme parameters where possible
- alpine-active-color: deeppink
- )
- );
-
- .ag-header {
- // or write CSS selectors to make customisations beyond what the parameters support
- text-shadow: deeppink;
- }
-}
-
ag-grid-angular {
height: 500px;
width: 100%;
diff --git a/angular/src/app/features/styling/css-overrides/css-overrides.component.ts b/angular/src/app/features/styling/css-overrides/css-overrides.component.ts
index 178ea0d..5b2c474 100644
--- a/angular/src/app/features/styling/css-overrides/css-overrides.component.ts
+++ b/angular/src/app/features/styling/css-overrides/css-overrides.component.ts
@@ -8,13 +8,13 @@ import {
customers,
orderItems,
orders,
- products
+ products,
} from '../../../../../data/data.json';
@Component({
selector: 'app-css-overrides',
templateUrl: './css-overrides.component.html',
- styleUrls: ['./css-overrides.component.scss']
+ styleUrls: ['./css-overrides.component.scss'],
})
export class CssOverridesComponent {
/**
@@ -24,26 +24,27 @@ export class CssOverridesComponent {
{
headerName: 'Customer Name',
field: 'customer.name',
- filter: 'agTextColumnFilter'
+ filter: 'agTextColumnFilter',
},
{
headerName: 'Account No',
field: 'account.accountNumber',
- filter: 'agNumberColumnFilter'
+ filter: 'agNumberColumnFilter',
},
{
headerName: 'Date of Order',
field: 'dateOfOrder',
filter: 'agDateColumnFilter',
- valueFormatter: ({ value }) => this.datePipe.transform(value, 'shortDate')
+ valueFormatter: ({ value }) =>
+ this.datePipe.transform(value, 'shortDate'),
},
{
headerName: 'Total',
field: 'total',
filter: 'agNumberColumnFilter',
valueFormatter: ({ value }) => this.currencyPipe.transform(String(value)),
- editable: true
- }
+ editable: true,
+ },
];
/**
@@ -52,16 +53,16 @@ export class CssOverridesComponent {
*/
rowData: Array<{
[key: string]: boolean | string | number | object;
- }> = orders.map(order => ({
+ }> = orders.map((order) => ({
...order,
dateOfOrder: new Date(`${order.dateOfOrder.slice(0, 10)}T00:00:00.0`),
- account: accounts.find(account => account.id === order.accountId),
- customer: customers.find(customer => customer.id === order.customerId),
- orderItems: orderItems.filter(item => item.orderId === order.id),
+ account: accounts.find((account) => account.id === order.accountId),
+ customer: customers.find((customer) => customer.id === order.customerId),
+ orderItems: orderItems.filter((item) => item.orderId === order.id),
total: orderItems
- .filter(item => item.orderId === order.id)
- .map(item => products.find(product => product.id === item.productId))
- .reduce((prev, current) => prev + Number(current.price), 0)
+ .filter((item) => item.orderId === order.id)
+ .map((item) => products.find((product) => product.id === item.productId))
+ .reduce((prev, current) => prev + Number(current.price), 0),
}));
constructor(
diff --git a/angular/src/app/shared/components/date-editor/date-editor.component.ts b/angular/src/app/shared/components/date-editor/date-editor.component.ts
index c2e1d5c..0fa9e05 100644
--- a/angular/src/app/shared/components/date-editor/date-editor.component.ts
+++ b/angular/src/app/shared/components/date-editor/date-editor.component.ts
@@ -59,8 +59,4 @@ export class DateEditorComponent
getValue(): any {
return this.value;
}
-
- isPopup(): boolean {
- return false;
- }
}
diff --git a/angular/src/app/shared/components/slider-filter/slider-filter.component.html b/angular/src/app/shared/components/slider-filter/slider-filter.component.html
index bedfb6c..7b7c42d 100644
--- a/angular/src/app/shared/components/slider-filter/slider-filter.component.html
+++ b/angular/src/app/shared/components/slider-filter/slider-filter.component.html
@@ -4,4 +4,3 @@
[value]="value"
(input)="onInput($event)"
>
-
diff --git a/angular/src/app/shared/components/slider-filter/slider-filter.component.ts b/angular/src/app/shared/components/slider-filter/slider-filter.component.ts
index 059d94a..6b40b99 100644
--- a/angular/src/app/shared/components/slider-filter/slider-filter.component.ts
+++ b/angular/src/app/shared/components/slider-filter/slider-filter.component.ts
@@ -37,16 +37,6 @@ export class SliderFilterComponent
this.min = params.min;
}
- onChange(event: MatSliderChange): void {
- // const value = event.value;
- // this.params.parentFilterInstance((instance: NumberFilter) =>
- // instance.onFloatingFilterChanged(
- // 'greaterThan',
- // value === 0 ? null : value
- // )
- // );
- }
-
onInput(event: MatSliderChange): void {
const value = event.value;
this.params.parentFilterInstance((instance: NumberFilter) =>