Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • Rex Dri Rex Dri
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 33
    • Issues 33
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Rex Dri
  • Rex DriRex Dri
  • Issues
  • #51
Closed
Open
Issue created Feb 22, 2019 by Florent Chehab@chehabflOwner

Review everything related to Editors / Modules

This issue is more abstract.

A review of the all the stuff related to editors/modules is needed. It's not very well commented but I would be happy to help explaining what is going on.

A Module displays basically information corresponding to a Django model.

The Editor can be thought as Form Manager. It contains Fields.

Each module should have a custom editor.

You also have groupModules to handle cases where you can have multiple times the same module (for example several CountryScholarships).

Few improvements I see:

  • Remove all the formManager={this} (and add field / removeField: the Editor should be able to detect its field by looking through its props.children
  • Instead of giving a value to a field and a fieldMapping, maybe give it modelData and fieldMapping (it would reduce redundancy). Or better create a new prop and give it an array of [modelData, fieldMapping]. You would need to add a prop extractValue, a function that takes props.modelData[props.fieldMapping] and make the potential necessary conversions (e.g. dates).
  • Review the stuff related to invalidate...
Edited Feb 24, 2019 by Florent Chehab
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking