Added UploadService and controller on backend to save given file as bytes in MongoDB using GridFS library.
The client receives the filename that identifies the uploaded file and we store it in Trecipe object (in the image field).
When retrieving image, we set the src of tag to get endpoint with the stored image filename like so:
Added UploadService and controller on backend to save given file as bytes in MongoDB using GridFS library.
The client receives the filename that identifies the uploaded file and we store it in Trecipe object (in the
image
field). When retrieving image, we set the src of tag to get endpoint with the stored image filename like so:baseURL
is thelocalhost:7000/api/v1
part.