indico icon indicating copy to clipboard operation
indico copied to clipboard

Reactify custom WTForms fields

Open duartegalvao opened this issue 1 year ago • 3 comments
trafficstars

This PR adds the following components:

  • a FinalPersonLinkField, so that the PersonLinkField can be added to final forms
    • also includes a wrapper for abstracts and contributions, with predefined roles
  • a SessionColorPicker and a FinalSessionColorPicker
  • a LocationField and a FinalLocationField
  • an ItemListField, a FinalItemListField and a FinalReferencesField

Moreover, it includes a new dev module with a page to test all of the custom React fields in /dev/react/fields. Also, the ChoicesSetup was refactored using the new ItemListField.

This will be important for future rectifying of timetable-related dialogs for #6220.

duartegalvao avatar Apr 02 '24 14:04 duartegalvao

I recommend adding some wrappers for the different object types - check the PersonLinkListFieldBase subclasses in Python what roles we set and on which conditions this depends.

ThiefMaster avatar Apr 02 '24 14:04 ThiefMaster

I recommend adding some wrappers for the different object types - check the PersonLinkListFieldBase subclasses in Python what roles we set and on which conditions this depends.

I guess we can skip the abstracts one for now, right?

duartegalvao avatar Apr 02 '24 14:04 duartegalvao

yeah... unless we want to move all dialogs in one go, which might actually not be such a bad idea considering the huge amount of awful complexity the wtforms-based backend of this field requires (for sending back the data when re-rendering the form)

ThiefMaster avatar Apr 02 '24 14:04 ThiefMaster

merged into timetable branch

duartegalvao avatar Mar 18 '25 10:03 duartegalvao