diff --git a/src/MistoxWebsite.Client/src/app/models/Product.ts b/src/MistoxWebsite.Client/src/app/models/Product.ts
index 1904aab..8676bdd 100644
--- a/src/MistoxWebsite.Client/src/app/models/Product.ts
+++ b/src/MistoxWebsite.Client/src/app/models/Product.ts
@@ -11,5 +11,5 @@ export class Product {
export class ProductImage {
imageID: number = 0;
productID: number = 0;
- imageSrc: string = "";
+ imageSrc: Blob = new Blob;
}
\ No newline at end of file
diff --git a/src/MistoxWebsite.Client/src/app/pages/store/catalog/catalog.component.html b/src/MistoxWebsite.Client/src/app/pages/store/catalog/catalog.component.html
index dc4e4eb..752147c 100644
--- a/src/MistoxWebsite.Client/src/app/pages/store/catalog/catalog.component.html
+++ b/src/MistoxWebsite.Client/src/app/pages/store/catalog/catalog.component.html
@@ -6,7 +6,7 @@
0" >
-
![]()
+
{{ product.name }}
diff --git a/src/MistoxWebsite.Client/src/app/pages/store/catalog/catalog.component.ts b/src/MistoxWebsite.Client/src/app/pages/store/catalog/catalog.component.ts
index 6871181..a5e2cf9 100644
--- a/src/MistoxWebsite.Client/src/app/pages/store/catalog/catalog.component.ts
+++ b/src/MistoxWebsite.Client/src/app/pages/store/catalog/catalog.component.ts
@@ -29,7 +29,7 @@ export class CatalogComponent {
this.Products.forEach(item => {
item.images.forEach(img => {
http.get("https://mistox.com/api/productimage/get?ProductID=" + img.productID + "&ImageID=" + img.imageID, { responseType: 'blob' }).subscribe(blob => {
- img.imageSrc = URL.createObjectURL(blob);
+ img.imageSrc = blob;
});
});
});
@@ -37,4 +37,8 @@ export class CatalogComponent {
}
)
};
+
+ createImageUrl(blob: Blob): string {
+ return URL.createObjectURL(blob);
+ }
}
\ No newline at end of file