diff --git a/matsen-tool/src/app/_components/search-select/search-select.component.html b/matsen-tool/src/app/_components/search-select/search-select.component.html
index f5bef98..5831c18 100644
--- a/matsen-tool/src/app/_components/search-select/search-select.component.html
+++ b/matsen-tool/src/app/_components/search-select/search-select.component.html
@@ -14,4 +14,4 @@
>
-
\ No newline at end of file
+
diff --git a/matsen-tool/src/app/_views/account/layout.component.html b/matsen-tool/src/app/_views/account/layout.component.html
index 134a1de..7e3b7ce 100644
--- a/matsen-tool/src/app/_views/account/layout.component.html
+++ b/matsen-tool/src/app/_views/account/layout.component.html
@@ -1,3 +1,3 @@
-
\ No newline at end of file
+
diff --git a/matsen-tool/src/app/_views/contacts/contact-list/contact-list.component.ts b/matsen-tool/src/app/_views/contacts/contact-list/contact-list.component.ts
index 651f431..390615d 100644
--- a/matsen-tool/src/app/_views/contacts/contact-list/contact-list.component.ts
+++ b/matsen-tool/src/app/_views/contacts/contact-list/contact-list.component.ts
@@ -1,5 +1,4 @@
import {AfterViewInit, Component, Input, OnInit, ViewChild} from '@angular/core';
-import {Subscription} from "rxjs";
import {ContactJsonld, ContactService, PartnerJsonld} from "@app/core/api/v1";
import {MatTableDataSource} from "@angular/material/table";
import {NewContactComponent} from "@app/_views/contacts/new-contact/new-contact.component";
@@ -8,16 +7,15 @@ import {AppHelperService} from "@app/_helpers/app-helper.service";
import {PagingComponent} from "@app/_components/paging/paging.component";
@Component({
- selector: 'app-contact-list',
- templateUrl: './contact-list.component.html',
- styleUrl: './contact-list.component.scss'
+ selector: 'app-contact-list',
+ templateUrl: './contact-list.component.html',
+ styleUrl: './contact-list.component.scss'
})
export class ContactListComponent implements OnInit, AfterViewInit {
@Input() public partner!: PartnerJsonld;
- @ViewChild("pagingComponent", { static: false }) pagingComponent!: PagingComponent;
+ @ViewChild("pagingComponent", {static: false}) pagingComponent!: PagingComponent;
- protected contactsSub: Subscription;
protected contacts: Array;
protected dataSource;
@@ -26,7 +24,6 @@ export class ContactListComponent implements OnInit, AfterViewInit {
private contactService: ContactService,
protected appHelperService: AppHelperService
) {
- this.contactsSub = new Subscription();
this.contacts = [];
this.dataSource = new MatTableDataSource(this.contacts);
}
@@ -39,7 +36,7 @@ export class ContactListComponent implements OnInit, AfterViewInit {
}
getData = () => {
- this.contactsSub = this.contactService.contactsGetCollection(
+ this.contactService.contactsGetCollection(
this.pagingComponent.getPageIndex(),
this.pagingComponent.getPageSize(),
this.partner.id
@@ -54,7 +51,7 @@ export class ContactListComponent implements OnInit, AfterViewInit {
openModalNewContact() {
let contact: ContactJsonld = {} as ContactJsonld;
contact.partnerIri = this.partner.id ?? null;
- this.appHelperService.openModal(NewContactComponent, { 'contact': contact }, this.getData);
+ this.appHelperService.openModal(NewContactComponent, {'contact': contact}, this.getData);
}
navigateToContactDetails(element: any) {
diff --git a/matsen-tool/src/app/_views/contacts/contacts-detail/contacts-detail.component.ts b/matsen-tool/src/app/_views/contacts/contacts-detail/contacts-detail.component.ts
index dce59b6..6cfd93f 100644
--- a/matsen-tool/src/app/_views/contacts/contacts-detail/contacts-detail.component.ts
+++ b/matsen-tool/src/app/_views/contacts/contacts-detail/contacts-detail.component.ts
@@ -1,6 +1,8 @@
import {AfterViewInit, Component, OnInit, ViewChild} from '@angular/core';
import {
- ContactJsonld, ContactPartnerProduct, ContactPartnerProductJsonld, ContactPartnerProductService,
+ ContactJsonld,
+ ContactPartnerProductJsonld,
+ ContactPartnerProductService,
ContactService,
PartnerJsonld,
PartnerService,
@@ -21,10 +23,10 @@ import {ProductListComponent} from "@app/_views/products/product-list/product-li
styleUrl: './contacts-detail.component.scss'
})
export class ContactsDetailComponent implements OnInit, AfterViewInit {
- @ViewChild("togglePosts", { static: true }) togglePosts!: ToggleComponent;
- @ViewChild("postListComponent", { static: false }) postsComponent!: PostListComponent;
- @ViewChild("toggleProducts", { static: true }) toggleProducts!: ToggleComponent;
- @ViewChild("productListComponent", { static: false }) productsComponent!: ProductListComponent;
+ @ViewChild("togglePosts", {static: true}) togglePosts!: ToggleComponent;
+ @ViewChild("postListComponent", {static: false}) postsComponent!: PostListComponent;
+ @ViewChild("toggleProducts", {static: true}) toggleProducts!: ToggleComponent;
+ @ViewChild("productListComponent", {static: false}) productsComponent!: ProductListComponent;
protected user: User | null;
@@ -101,7 +103,7 @@ export class ContactsDetailComponent implements OnInit, AfterViewInit {
}
openModalEditContact() {
- let data: any = { 'contact': this.contact }
+ let data: any = {'contact': this.contact}
if (this.contact.birthday !== undefined) {
data.birthdayValue = this.appHelperService.convertDate(this.contact.birthday);
}
diff --git a/matsen-tool/src/app/_views/contacts/new-contact/new-contact.component.html b/matsen-tool/src/app/_views/contacts/new-contact/new-contact.component.html
index 05276ae..675af87 100644
--- a/matsen-tool/src/app/_views/contacts/new-contact/new-contact.component.html
+++ b/matsen-tool/src/app/_views/contacts/new-contact/new-contact.component.html
@@ -49,7 +49,7 @@
-

+
{{'system.delete-image' | translate}}
@@ -57,4 +57,3 @@
-
diff --git a/matsen-tool/src/app/_views/contacts/new-contact/new-contact.component.ts b/matsen-tool/src/app/_views/contacts/new-contact/new-contact.component.ts
index 40fcd46..5ec0caf 100644
--- a/matsen-tool/src/app/_views/contacts/new-contact/new-contact.component.ts
+++ b/matsen-tool/src/app/_views/contacts/new-contact/new-contact.component.ts
@@ -2,7 +2,6 @@ import {AfterViewInit, Component, EventEmitter, Input, OnInit, Output} from '@an
import {FormGroup} from "@angular/forms";
import {contactForm} from "@app/_forms/apiForms";
import {ContactJsonld, ContactService, MediaObjectService} from "@app/core/api/v1";
-import {firstValueFrom, Subscription, window} from "rxjs";
import {ModalStatus} from "@app/_helpers/modal.states";
import {FormGroupInitializer} from "@app/_helpers/formgroup.initializer";
import {TranslateService} from "@ngx-translate/core";
@@ -20,8 +19,6 @@ export class NewContactComponent implements OnInit, AfterViewInit {
protected contactForm: FormGroup;
protected selectedImage: File | null;
- protected contactSub: Subscription;
- protected mediaSub: Subscription;
protected birthdayValue: string;
constructor(
@@ -32,8 +29,6 @@ export class NewContactComponent implements OnInit, AfterViewInit {
) {
this.contactForm = contactForm;
this.selectedImage = null;
- this.contactSub = new Subscription();
- this.mediaSub = new Subscription();
this.birthdayValue = "";
}
@@ -56,7 +51,7 @@ export class NewContactComponent implements OnInit, AfterViewInit {
// On submit form: Check if image is set
onSubmit() {
if (this.selectedImage !== null) {
- this.mediaSub = this.mediaObjectService.mediaObjectsPost(
+ this.mediaObjectService.mediaObjectsPost(
this.selectedImage
).subscribe(
data => {
@@ -73,7 +68,7 @@ export class NewContactComponent implements OnInit, AfterViewInit {
if (this.contactForm.valid) {
if (this.contact.id === null || this.contact.id === undefined) {
// Create new contact
- this.contactSub = this.contactService.contactsPost(
+ this.contactService.contactsPost(
this.contactForm.value as ContactJsonld
).subscribe(
data => {
@@ -83,7 +78,7 @@ export class NewContactComponent implements OnInit, AfterViewInit {
);
} else {
// Edit contact
- this.contactSub = this.contactService.contactsIdPatch(
+ this.contactService.contactsIdPatch(
this.appHelperService.extractId(this.contact.id),
this.contactForm.value as ContactJsonld
).subscribe(
diff --git a/matsen-tool/src/app/_views/documents/document-list/document-list.component.html b/matsen-tool/src/app/_views/documents/document-list/document-list.component.html
index e468bad..bd9b9dd 100644
--- a/matsen-tool/src/app/_views/documents/document-list/document-list.component.html
+++ b/matsen-tool/src/app/_views/documents/document-list/document-list.component.html
@@ -12,4 +12,3 @@
[showDetailButton]="false"
>
-
diff --git a/matsen-tool/src/app/_views/documents/document-list/document-list.component.ts b/matsen-tool/src/app/_views/documents/document-list/document-list.component.ts
index 8a467fc..8152036 100644
--- a/matsen-tool/src/app/_views/documents/document-list/document-list.component.ts
+++ b/matsen-tool/src/app/_views/documents/document-list/document-list.component.ts
@@ -1,23 +1,22 @@
import {AfterViewInit, Component, Input, OnInit, ViewChild} from '@angular/core';
import {DocumentJsonld, DocumentService, PartnerJsonld, ProductJsonld} from "@app/core/api/v1";
import {AppHelperService} from "@app/_helpers/app-helper.service";
-import {MatSort, Sort} from "@angular/material/sort";
-import {MatTableDataSource} from "@angular/material/table";
+import {Sort} from "@angular/material/sort";
import {OrderFilter} from "@app/_models/orderFilter";
import {NewDocumentComponent} from "@app/_views/documents/new-document/new-document.component";
import {ListComponent} from "@app/_components/list/list.component";
import {ListColDefinition} from "@app/_components/list/list-col-definition";
@Component({
- selector: 'app-document-list',
- templateUrl: './document-list.component.html',
- styleUrl: './document-list.component.scss'
+ selector: 'app-document-list',
+ templateUrl: './document-list.component.html',
+ styleUrl: './document-list.component.scss'
})
export class DocumentListComponent implements OnInit, AfterViewInit {
@Input() public product!: ProductJsonld;
@Input() public partner!: PartnerJsonld;
- @ViewChild("listComponent", { static: false }) listComponent!: ListComponent;
+ @ViewChild("listComponent", {static: false}) listComponent!: ListComponent;
protected listColDefinitions!: ListColDefinition[];
@@ -76,7 +75,7 @@ export class DocumentListComponent implements OnInit, AfterViewInit {
];
}
- ngOnInit(){
+ ngOnInit() {
}
ngAfterViewInit() {
@@ -112,11 +111,11 @@ export class DocumentListComponent implements OnInit, AfterViewInit {
openModalNewDocument() {
let document: DocumentJsonld = {} as DocumentJsonld;
- this.appHelperService.openModal(NewDocumentComponent, { 'document': document }, this.listComponent.getData);
+ this.appHelperService.openModal(NewDocumentComponent, {'document': document}, this.listComponent.getData);
}
openModalEditDocument(element: DocumentJsonld) {
- this.appHelperService.openModal(NewDocumentComponent, { 'document': element }, this.listComponent.getData);
+ this.appHelperService.openModal(NewDocumentComponent, {'document': element}, this.listComponent.getData);
}
}
diff --git a/matsen-tool/src/app/_views/documents/new-document/new-document.component.ts b/matsen-tool/src/app/_views/documents/new-document/new-document.component.ts
index 167f553..e3e81ba 100644
--- a/matsen-tool/src/app/_views/documents/new-document/new-document.component.ts
+++ b/matsen-tool/src/app/_views/documents/new-document/new-document.component.ts
@@ -18,11 +18,11 @@ import {ListGetDataFunctionType} from "@app/_components/list/list-get-data-funct
templateUrl: './new-document.component.html',
styleUrl: './new-document.component.scss'
})
-export class NewDocumentComponent implements OnInit, AfterViewInit {
+export class NewDocumentComponent implements OnInit, AfterViewInit {
@Input() public document!: DocumentJsonld;
@Output() public submit: EventEmitter = new EventEmitter();
- @ViewChild('partnerSearchSelect', { static: false }) partnerSearchSelect!: SearchSelectComponent;
- @ViewChild('productSearchSelect', { static: false }) productSearchSelect!: SearchSelectComponent;
+ @ViewChild('partnerSearchSelect', {static: false}) partnerSearchSelect!: SearchSelectComponent;
+ @ViewChild('productSearchSelect', {static: false}) productSearchSelect!: SearchSelectComponent;
protected readonly SearchSelectComponent = SearchSelectComponent;
protected documentForm: FormGroup;
@@ -47,7 +47,7 @@ export class NewDocumentComponent implements OnInit, AfterViewInit {
ngAfterViewInit(): void {
}
- getPartners: ListGetDataFunctionType = (index: number, pageSize: number, term?: string): Observable => {
+ getPartners: ListGetDataFunctionType = (index: number, pageSize: number, term?: string): Observable => {
return this.partnerService.partnersGetCollection(
index,
pageSize,
@@ -57,7 +57,7 @@ export class NewDocumentComponent implements OnInit, AfterViewInit {
);
}
- getProducts: ListGetDataFunctionType = (index: number, pageSize: number, term?: string): Observable => {
+ getProducts: ListGetDataFunctionType = (index: number, pageSize: number, term?: string): Observable => {
return this.productService.productsGetCollection(
index,
pageSize,
diff --git a/matsen-tool/src/app/_views/sales/sales-detail/sales-detail.component.html b/matsen-tool/src/app/_views/sales/sales-detail/sales-detail.component.html
index 488f752..7c34370 100644
--- a/matsen-tool/src/app/_views/sales/sales-detail/sales-detail.component.html
+++ b/matsen-tool/src/app/_views/sales/sales-detail/sales-detail.component.html
@@ -2,29 +2,29 @@
-
{{'overview.sale-user' | translate }}: {{ sale.owner?.fullName }}
+
{{ 'overview.sale-user' | translate }}: {{ sale.owner?.fullName }}
- - {{'overview.partner' | translate}}:
+ - {{ 'overview.partner' | translate }}:
- {{ sale.partner?.name }}
- - {{'overview.product' | translate}}:
+ - {{ 'overview.product' | translate }}:
- {{ sale.product?.name }}
- - {{'overview.turnover' | translate}}:
+ - {{ 'overview.turnover' | translate }}:
- {{ sale.turnover }}
- - {{'overview.profit' | translate}}:
+ - {{ 'overview.profit' | translate }}:
- {{ sale.profit }}
- - {{'overview.comment' | translate}}:
+ - {{ 'overview.comment' | translate }}:
-
+
+
-
+
diff --git a/matsen-tool/src/app/_views/tasks/task-list/task-list.component.html b/matsen-tool/src/app/_views/tasks/task-list/task-list.component.html
index c944293..f7b68de 100644
--- a/matsen-tool/src/app/_views/tasks/task-list/task-list.component.html
+++ b/matsen-tool/src/app/_views/tasks/task-list/task-list.component.html
@@ -52,8 +52,6 @@