- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-08-2022 01:25 AM
I have a custom with label variable in a record producer that is connected to this widget and I am trying to display data from a value that has been set in the client script. (green box)
How to implement it so it will show the value in a text field?
Solved! Go to Solution.
- Labels:
-
Service Portal Development
-
Studio
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-08-2022 02:07 AM
okay
i think i got your requirement now .
you are storing total cost in total cost variable .
If yes then do like this
in client controller add this line
c.data.cost=totatCost;
HTML
<div>
<input type="text" value ={{c.data.cost}}>
</div>
try this and let me know

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-08-2022 01:37 AM
Hi,
Please check below links:
You need to use two way data binding to update values in fields created in HTML part.
https://www.youtube.com/watch?v=0gz3XzBM-Gs
I guess g_form will not work as you are not using OOB form widget to display record. This API is only supported with OOB form widget.
Thanks,
Anil Lande
Thanks
Anil Lande
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-08-2022 01:54 AM
Hello Anil,
I have checked it but I am still confused. Can you give an example on its implementation regarding in my case? I apologize as I am still new.
Additionally, the alerts in the script are working but I am not really sure as to why It's not displaying its value in a text field.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-08-2022 01:44 AM
hellp
you can try this in HTML
<div>
<input type="text" value ="c.data.label"/>
</div>
In client controller store the value in a variable like below
c.data.label = $scope.page.g_form.setValue('total_amount',totalCost);
MARK MY ANSWER CORRECT IF IT HELPS YOU
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-08-2022 01:51 AM