From 1773aff4e35916372f7a4f2d297ba63dbe6c1656 Mon Sep 17 00:00:00 2001 From: Le Deng Date: Mon, 6 Mar 2017 09:30:49 -0500 Subject: [PATCH] latest --- .../edit-book/edit-book.component.html | 8 +-- .../src/app/services/upload-image.service.ts | 2 +- bookstore-api/.idea/workspace.xml | 51 +++++++++++------- .../main/resources/static/image/book/5.png | Bin 57573 -> 14760 bytes 4 files changed, 36 insertions(+), 25 deletions(-) diff --git a/admin-portal/src/app/components/edit-book/edit-book.component.html b/admin-portal/src/app/components/edit-book/edit-book.component.html index c1ee4ba..98a37b8 100644 --- a/admin-portal/src/app/components/edit-book/edit-book.component.html +++ b/admin-portal/src/app/components/edit-book/edit-book.component.html @@ -1,5 +1,5 @@
-
+

Update Book Information * is a required field

@@ -40,7 +40,7 @@ - + Paperback Hardcover @@ -79,7 +79,7 @@  ounces  - + English Spanish @@ -114,7 +114,7 @@
-
+

Book updated successfully!

diff --git a/admin-portal/src/app/services/upload-image.service.ts b/admin-portal/src/app/services/upload-image.service.ts index fda3161..cba2f8b 100644 --- a/admin-portal/src/app/services/upload-image.service.ts +++ b/admin-portal/src/app/services/upload-image.service.ts @@ -19,7 +19,7 @@ export class UploadImageService { modify(bookId: number) { console.log(this.filesToUpload); - if (this.filesToUpload!=null) { + if (this.filesToUpload.length>0) { this.makeFileRequest("http://localhost:8181/book/update/image?id=" + bookId, [], this.filesToUpload).then((result) => { console.log(result); }, (error) => { diff --git a/bookstore-api/.idea/workspace.xml b/bookstore-api/.idea/workspace.xml index 5b321a2..6be07a5 100644 --- a/bookstore-api/.idea/workspace.xml +++ b/bookstore-api/.idea/workspace.xml @@ -15,7 +15,18 @@ - + + + + + + + + + + + +