fnitu / edu-hospice

Application developed for SIIT Challenge Accepted – CODVIDHACK 2020
https://edu-hospice.herokuapp.com
2 stars 2 forks source link

Upload course image #79

Open fnitu opened 3 years ago

fnitu commented 3 years ago

Uploading the course picture will be done in a new tab "Images".

When a new course is created, the tab will be disabled, similar to "Course content". When the course is saved, i.e. when a course id is received from the server, the tab will be enabled.

Components:

  1. The image upload control with a drag and drop zone will be displayed, similar to the user profile image popup.

  2. Another component with the list of images (right now the upload for course image will be limited to single upload) should be displayed below in order to allow the user to view and delete the current image (separate request)

If no image is uploaded the course should have a default image (https://www.hospice.ro/wp-content/themes/hospice/img/social-default.jpg) stored on the client side, and used when no image URL is received from the server.

A mock JSON will be used as the first step, it will contain a list with one image URL, that currently is in the course details tab, on image URL field.

When clicking the image, it will open in a photo gallery lightbox, using https://blueimp.github.io/Gallery/.

Adrian-Moldovan commented 3 years ago

Please move the "Load image" tab on second position, after the "Course details" tab.

Adrian-Moldovan commented 3 years ago

Step1 (doable): Please display a delete icon on the images list; on click a confirmation popup message should be displayed.

Step2 (pending for BE): After confirming, the image should be deleted based on server request. A ticket for the backend should be added to implement this feature.

Adrian-Moldovan commented 3 years ago

Development suspended until BE integration of file upload