Home › Forums › Classic DFFS › Show the value from this field above the tabs
- This topic has 4 replies, 3 voices, and was last updated 8 years, 1 month ago by Ian Patrick.
-
AuthorPosts
-
-
October 10, 2016 at 17:51 #13575
I’m using the setting on the Misc config page called “Show the value from this field above the tabs” to display the value of a status field (ReadyToSubmit) above my new form.
If the user changes the value of the ReadyToSubmit field, the display above the form does not change until the user clicks one of the tab selectors to select a different tab. Causing the tab selection to change on field change using a rule does NOT change the value displayed above the form.
Is this a known bug? I’m using Backend v4.4.1|CSS version: 4.16 / 4.16|spjs-utility version: 1.267. I’ve looked at the change logs but don’t see it listed as something that has been fixed since v4.4.1.
Is there perhaps a quick fix I can implement in the Custom JS section?
-
October 10, 2016 at 20:36 #13590
Hi,
I have changed this in the upcoming release so it will change when the field changes and not on click of the tab. In the meantime you can add this to the Custom JS to fix it:spjs.$("#dffs_ReadyToSubmit").on("change blur",function(){ spjs.$("#formCustomLabel").html(spjs.utility.getFieldValue({"fin":"ReadyToSubmit"})); });
Please note that this example uses the “ReadyToSubmit” field so if someone wants to use another field this name must be change.
Also note that you need to set up the “Misc tab setting” in addition to adding this code snippet.
Alexander
-
October 17, 2016 at 09:34 #13677
Hi Alexander,
Not sure if this is a similar issue. I’m using a field name in a Heading and it only updates the Heading value when the item is saved. Would there be a similar fix for this issue.
Many thanksIan
-
October 17, 2016 at 19:32 #13682
Hi,
There is no easy method for doing this without inserting a custom placeholder in the heading, and adding a custom change event on the field like described above.I will address this in the next release, but if you need it working now you can add this wrapper around your “heading text” like this:
This is the value in the field FIN: <span id='custom-header-text-FIN'>{FIN}</span>
and use code like this in Custom JS:
spjs.$("#dffs_FIN").on("change blur",function(){ spjs.$("#custom-header-text-FIN").html(spjs.utility.getFieldValue({"fin":"FIN"})); });
Change FIN with your field name.
Alexander
-
October 18, 2016 at 11:30 #13685
Hi Alexander,
This solution works fine. Thanks for the solution.
Kind regards
Ian
-
-
AuthorPosts
- You must be logged in to reply to this topic.