Bug #78460

Story #69712: Further FormEngine development

requestUpdate property for form input fields

Added by Sergio Catalá almost 3 years ago. Updated over 2 years ago.

Status:
New
Priority:
Could have
Assignee:
-
Category:
-
Target version:
-
Start date:
2016-10-27
Due date:
% Done:

0%

TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

For opened form input fields in the backend, the TCA property requestUpdate (https://docs.typo3.org/typo3cms/TCAReference/Reference/Ctrl/Index.html#requestupdate) is not working.

Is this a bug or a feature request?
If this is not allowed, is there a special reason for that?

Associated revisions

Revision 38a1bc5d (diff)
Added by Christian Kuhn over 2 years ago

[!!!][TASK] Improve flex and TCA handling in FormEngine

The patch adapts a series of nasty form engine areas to more solid
code. The evaluate condition code is rewritten and works much better
in flex form scenarios. The suggest wizard and svg tree are much
more solid in flex forms. The group element is rewritten
towards a better readable and easier to refactor code, dropping
method dbFileIcons(). A bunch of issues is resolved along the way.

  • TCA "default" now works in flex form section container elements
  • The "displayCond" parser is now strict and throws exceptions on
    invalid syntax and wrong referenced fields to help debugging
    faulty display conditions
  • TCA displayCond on flex fields can now be prefixed with the
    sheet name and can reference field values from neighbor sheets
  • TCA displayCond now works with flex section containers
  • TCA flex section container now throw an exception if select or
    group fields configure a MM relation - this is not supported
  • TCA ctrl requestUpdate field is dropped, onChange=reload is now allowed
    not only on flex form fields, but also on normal columns fields
  • TCA tree now works as section container element and initializes
    correctly on new records and new containers
  • GroupElement rewrite to drop dbFileIcons()
  • config option maxitems now optional for type=group and type=select
    and defaults to "many items allowed"
  • inline now works in "fancy" flex situations with "new" records
    by handing the final dataStructureIdentifier around
  • FormEngine no longer loads extJS

Change-Id: Id1d081627529cc1502bb198389e5bd69372815cd
Resolves: #78899
Resolves: #72307
Resolves: #75646
Resolves: #76637
Resolves: #72106
Resolves: #78824
Resolves: #76793
Resolves: #68247
Resolves: #69715
Related: #78460
Related: #67198
Related: #72294
Releases: master
Reviewed-on: https://review.typo3.org/50879
Tested-by: TYPO3com <>
Reviewed-by: Benni Mack <>
Tested-by: Benni Mack <>
Reviewed-by: Anja Leichsenring <>
Tested-by: Anja Leichsenring <>

History

#1 Updated by Anja Leichsenring almost 3 years ago

could you please provide steps to reproduce? I can't get your problem from your description. RequestUpdate works for me, for example the CType of tt_content implements that behaviour.

#2 Updated by Sergio Catalá almost 3 years ago

I am using the next code through flux extension:

        <flux:form options="{group:'Custom elements'}" 
                   id="headerstage" 
                   description="Teaser element">
            <flux:form.sheet name="content">
                <flux:field.input name="linkpage" requestUpdate="1">
                    <flux:wizard.link />
                </flux:field.input>
                <flux:field.input name="linktext" maxCharacters="50" displayCond="FIELD:linkpage:>:0"/>
            </flux:form.sheet>
        </flux:form>

When the linkpage field looses the focus, the backend should be reloaded, to allow the evaluation of the displayCond in the other field.

#3 Updated by Anja Leichsenring almost 3 years ago

  • Status changed from New to Needs Feedback

no idea about flux, sorry. RequestUpdate is not available for flexforms, too.

Have a look at https://wiki.typo3.org/Extension_Development,_using_Flexforms#Display_conditions_and_dynamic_reloading_of_form, maybe that helps.

#4 Updated by Nicole Cordes almost 3 years ago

  • Status changed from Needs Feedback to Closed

Hi Sergio,

requestUpdate is an option within your tables CTRL section. By reading the provided flux code, this means, flux has to change the TCA on the fly which doesn't work because TCA is cached. IMHO this is a problem of flux not using the TYPO3 TCA api correctly. Please contact the support of EXT:flux.

Closing this issue for now. If you have another way how to reproduce your problem, please report to another ticket. Thank you.

#5 Updated by Christian Kuhn over 2 years ago

  • Status changed from Closed to New

Actually, requestUpdate is available as "onChange=reload" within flex form fields. And yes, InputTextElements do not handle requestUpdate / onChange at all, I stumbled upon that during my current FormEngine patch.

My patch resolves this "requestUpdate does not exist in flex forms" issue by removing it from 'ctrl' section and allowing "onChange=reload" on all fields, also outside of flex forms.

So, the issue with the input fields is confirmed, and this area needs some JS side works anyway and the issue could be solved along the way.

I'll set a "Related" flag in my patch to point to this issue.

#6 Updated by Christian Kuhn over 2 years ago

  • Parent task set to #69712

Also available in: Atom PDF