Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
C
Core
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 930
    • Issues 930
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Operations
    • Operations
    • Incidents
  • Analytics
    • Analytics
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
  • Development
  • Core
  • Issues
  • #818

Closed
Open
Opened Mar 25, 2019 by eileen@eileen🎱Owner

CQ: Switch core forms to be Entity Forms

We have switched some forms already to use the EntityFormTrait as part of the following goals

  1. move data about the fields on the forms into the schema xml - this will be important to help us migrate away from quick form
  2. support custom data on a wide range of entities - several entities already support custom data as a result of having been switched to entity forms - relationship type form, membership status, financial type, price set etc
  3. support parameters passed through the url in a non ad-hoc way - we have a history of security issues are url parameters so any new retrieval should be stdised & we need to work to remove existing ones
  4. support extension intervention in the fields displayed - this is particularly supported by the tpl changes in the entity form structure
  5. generalised reduction in unecessary code
  6. improving translation consistency

What is involved in the Entity Form is best understood by looking at existing examples but basically it consists of

  • using the EntityFormTrait
  • ensuring the relevant things are declared on the class to support that
  • declaring all the fields that can be added through metadata in the metadata array
  • working towards simplifying the tpl to a single line {include file="CRM/Core/Form/EntityForm.tpl"}

Generally in any change we can take steps towards this rather than fully implement it

Edited Apr 04, 2019 by eileen
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None
Reference: dev/core#818