diff --git a/matsen-tool/src/app/_components/paging/paging.component.html b/matsen-tool/src/app/_components/paging/paging.component.html
index ff7e0b0..7805013 100644
--- a/matsen-tool/src/app/_components/paging/paging.component.html
+++ b/matsen-tool/src/app/_components/paging/paging.component.html
@@ -15,7 +15,6 @@
showFirstLastButtons>
-{{loading}}
{{'form.no-data' | translate}}
diff --git a/matsen-tool/src/app/_views/products/product-list/product-list.component.html b/matsen-tool/src/app/_views/products/product-list/product-list.component.html
index c26d4e1..d01318a 100644
--- a/matsen-tool/src/app/_views/products/product-list/product-list.component.html
+++ b/matsen-tool/src/app/_views/products/product-list/product-list.component.html
@@ -68,6 +68,16 @@
+
+ |
+ {{ 'overview.details' | translate }}
+ |
+
+
+ |
+
+
diff --git a/matsen-tool/src/app/_views/products/product-list/product-list.component.ts b/matsen-tool/src/app/_views/products/product-list/product-list.component.ts
index 301c36d..00205e0 100644
--- a/matsen-tool/src/app/_views/products/product-list/product-list.component.ts
+++ b/matsen-tool/src/app/_views/products/product-list/product-list.component.ts
@@ -17,6 +17,7 @@ import {MatTableDataSource} from "@angular/material/table";
import {OrderFilter} from "@app/_models/orderFilter";
import {NewProductComponent} from "@app/_views/products/new-product/new-product.component";
import {AssignProductComponent} from "@app/_views/products/assign-product/assign-product.component";
+import {TranslateService} from "@ngx-translate/core";
@Component({
selector: 'app-product-list',
@@ -41,13 +42,14 @@ export class ProductListComponent implements OnInit, AfterViewInit {
constructor(
private router: Router,
private productService: ProductService,
+ private translateService: TranslateService,
private userProductService: UserProductService,
private partnerProductService: PartnerProductService,
private contactPartnerProductService: ContactPartnerProductService,
protected appHelperService: AppHelperService,
) {
this.sort = new MatSort();
- this.displayedColumns = ['details', 'pos', 'image', 'name', 'storage', 'number'];
+ this.displayedColumns = ['details', 'pos', 'image', 'name', 'storage', 'number', 'unassign'];
this.productsSub = new Subscription();
this.products = [];
@@ -214,4 +216,15 @@ export class ProductListComponent implements OnInit, AfterViewInit {
throw new Error('data not found')
}
}
+
+ unassignProduct(element: any) {
+ let confirmMessage = "";
+ this.translateService.get('system.confirm-unassign').subscribe((translation: string) => {
+ confirmMessage = translation;
+ });
+ const userConfirmed = window.confirm(confirmMessage);
+ if (userConfirmed) {
+ console.log(element);
+ }
+ }
}
diff --git a/matsen-tool/src/assets/i18n/de.json b/matsen-tool/src/assets/i18n/de.json
index d3576d7..262c2bf 100644
--- a/matsen-tool/src/assets/i18n/de.json
+++ b/matsen-tool/src/assets/i18n/de.json
@@ -5,7 +5,8 @@
"confirm-delete-image": "Möchten Sie das Bild wirklich löschen?",
"delete-file": "Datei löschen",
"confirm-delete-file": "Möchten Sie die Datei wirklich löschen?",
- "profit-larger-turnover": "Der Gewinn ist größer als der Umsatz!"
+ "profit-larger-turnover": "Der Gewinn ist größer als der Umsatz!",
+ "confirm-unassign": "Möchten Sie die Zuweisung wirklich aufheben?"
},
"basic":
{
diff --git a/matsen-tool/src/assets/scss/_basics.scss b/matsen-tool/src/assets/scss/_basics.scss
index 62e9a41..3413068 100644
--- a/matsen-tool/src/assets/scss/_basics.scss
+++ b/matsen-tool/src/assets/scss/_basics.scss
@@ -259,6 +259,7 @@ img {
position: fixed;
left: 50%;
top: 50%;
+ z-index: 9999;
background: #9eb3c1;
width: 130px;
height: 130px;