Skip to content

Draft: Admin Edit, Delete Controllers and Templates

Fixes Fixes for #87 (closed) no by @dakshp07

Description Added admin-side controllers, templates to provide the functionality of edit, delete.

Testing

  1. Import the images.sql given in this PR description.
  2. Spin up the framework. Sign in with the admin credentials.
  3. Visit http://localhost:2354/images. This page is the index of the images table.
  4. Visit http://localhost:2354/images/110 to view the images related to one specific artifact. Make sure that the images are displaying properly.
  5. The URL http://localhost:2354/images/110 will display two entries one for type lineart and other for type lineart_detail click on edit button near to the asset of type lineart. This will take you to single view for that asset.
  6. Click on the edit button on the type lineart_detail. This will take you to the edit page for that visual asset.
  7. Change the type of visual asset to lineart (first option) and click on the Update button.
  8. Check if the error box flashes with appropriate information of overwriting.
  9. You will be taken back to http://localhost:2354/images/110 make sure there is just one entry of type lineart_detail. The images take a few minutes (max 5 minutes in my case) to get updated.

Table images.sql

Checklist:

  • My pull request has a descriptive title (not a vague title like "Update index.md").
  • My pull request targets the phoenix/develop branch of the repository.
  • My commit messages follow best practices.
  • My code follows the established code style of the repository.
  • I added tests for the changes I made (if applicable).
  • I added or updated documentation (if applicable).
  • I tried running the project locally and verified that there are no visible errors.
Edited by Daksh Paleria

Merge request reports