Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shared Form View But With Objects #2101

Closed
1 task done
mithra62 opened this issue May 31, 2022 · 0 comments · Fixed by #2102 or ExpressionEngine/ExpressionEngine-User-Guide#462
Closed
1 task done

Shared Form View But With Objects #2101

mithra62 opened this issue May 31, 2022 · 0 comments · Fixed by #2102 or ExpressionEngine/ExpressionEngine-User-Guide#462

Comments

@mithra62
Copy link
Contributor

Is your feature request related to a problem? Please describe.
Would make things more fun if we could build forms programmatically.

Describe the solution you'd like
Something like this:

$form = ee('Cp/Form');
$form->asTab();
$form->asFileUpload();
$field_group = $form->getGroup('header 1');
$field_set = $field_group->getFieldSet('first_name');
$field_set->getField('first_name', 'text')
    ->setDisabled(true)
    ->setValue('Eric');

$form->toArray();

Describe alternatives you've considered
Not writing it, I guess?

Teachability, Documentation, Adoption, Migration Strategy
Docs should be written, yes, I agree. The implementation will be backwards compatible and conform to how Shared Form arrays are expected.

  • I am capable and would like to work on implementation of this feature if it is considered.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants