physionet-build icon indicating copy to clipboard operation
physionet-build copied to clipboard

Project sections dynamically added from database

Open lbulgarelli opened this issue 5 years ago • 39 comments

This is the second part of the changes required to add more flexibility on the project content.

Project section (e.g. Background, etc) are added from the fixtures written to the database, so the same as the project types PR, any adjustments on sections are added without having to change code.

  • New model ProjectSection, composed of name, description and a FK to the project type for which that section is available.
  • New model SectionContent, which contains FKs to both ProjectSection and CoreProject, storing in the content field, the content for each section of each project
  • Fixtures for the current sections of all Database, Software, Challenge and Model entities were created
  • Fixtures for the demo projects were updated to reflect the changes
  • Migration handles moving the content for all existing projects in this new approach
  • Views, forms and html pages were updated to use the ProjectSection and SectionContent to show and update the content of projects

lbulgarelli avatar Jul 17 '19 20:07 lbulgarelli