dat.GUI - How to link (coordinate, synchronize) 2 (or more) controllers? - dat.gui

Could anyone explain how to link (coordinate, synchronize) 2 (or more) controllers in dat.gui in general?
Here is an exemple from the official site of dat.gui (https://workshop.chromeexperiments.com/examples/gui/#2--Constraining-Input)
In this exemple, I'd like to link controller "growthSpeed" and "speed".
The number of "growthSpeed" remains stacked in 0.2 when I choose "Fast"... It must be changed to 5!
(And vice versa... if I change the number in "growthSpeed", it must deselect "Fast"...)
Thank you in advance for your help.

As long as you set controller GrowthSpeed to .listen() it will update as soon as that variable is changed. So if the callback for the dropdown changes the variable that growthSpeed is listening to, it will update automatically.

Related

is there a possibility to create an editable checkbox column?

I'm looking for a way to show a boolean value as a clickable checkbox in the table.
In my current example, I have a value called "charged". Currently this is shown as a check. It would be great to have it as a checkbox in order to update the value really quick, instead of clicking on edit on the specific row and update it there.
Example screenshot
Would appreciate any recommendations.
Thanks
The Backpack team has something in the works for this - a package they call "editable columns". But it will probably be launched in Feb-March 2022.
Until then, you can
(A) create a custom column type that will make an AJAX call. For the javascript, take a look at the delete button for inspiration.
(B) Send an email to hello#backpackforlaravel.com for beta access to that package (includes editable_checkbox, editable_switch and editable_text column types right now.

Reload a subpanel when another subpanel's values are changed

There is a logic hook that fires when values of sub-panel (A) are updated, when that happens 2 more additional sub-panels are updated through a logic hook, but we can't see the changes unless we reload the page.
I'm trying to find a way to update the values in the other 2 sub-panels without a page reload.
I know it's possible to add custom JS to detailview that will listen to sub-panel updates and when they take place it will update more sub-panels (described here: https://community.sugarcrm.com/thread/31390-how-do-i-refresh-a-subpanel-when-a-record-is-added-to-a-different-subpanel), but all code examples are for later versions. I can't find any examples for the suitecrm or sugarCRM CE.
Would appreciate if someone can point me in the right direction.
Need to create a custom controller in
custom/modules/PARENT_MODULE/controller.php
When you change something in your sub-panel it will generate a new $_REQUEST (in real-time) so when you're satisfied that the right sub-panel is being manipulated you can fire the showSubpanel('FIELD_NAME',null,true); action.
Following tutorial explains it step by step: https://www.youtube.com/watch?v=wqLAIp52CIA

Create / Edit / View the same form with Angular

I am creating a slightly elaborated form with Angular. This form can be submitted, then modified or simply displayed (with everything in read-only for example).
For now I have 3 templates with 3 controllers for each action (submit / edit / view) and the form is added as a partial (ng-include). The form has also its own controller. Is it the right way?
Also, should I make the form's controller the children of the templates' controllers or the opposite? I am using the same model for each action behind the form and I guess it should be injected through the template's controller.
It's my very first attempt to do this and I would like to have a few advice's and hints since I am afraid of going the wrong way. Thank you!
yo can use different template for each of them with single controller, different controller for each of them is not a good idea because there may be some common function in them then you need to write that function in each of them.
you can use common model for them,i am doing the same.
I see this is promising solutions to what you are looking for
can you try this http://vitalets.github.io/angular-xeditable/#editable-form

bada - Tab bar control

I am new to bada programming and I am facing some problems. I am currently creating an app that consists of 6 tab bar item, each of which have a different form and have different controls in each form. I have tried following the example on http://www.badadev.com/forms-management-in-bada-part-3-managing-forms/ , however, I have set up all the controls in the form, but it does not respond and does not AppLog when I clicked on the button. Can someone please help me on this???
It is very hard to solve your problem that way(without seeing your code). Take look on a XmlParserApp example. It is using FormMgr and maybe you can get some good ideas. Or it is important that you have base class tabsForm that all the forms inherit?

SegmentControll problem in iphone

A new bie here...
I am using a segmentController..in that there are three segments...Say segment A,B,C
Now I want this functionality...
when I press Segment A..Table A comes up..
when I press Segment B..Table B comes up..and
when I press Segment c..Table C comes up
well I know all the label change and that stuff...but what about the tables?? and again when I press the row elements they navigates me to another views and I want segment control to be displayed in navigated view also..
well ... can anyone please tell me how to do this??
any suggestion..any tutorial..any example code...any logic...anything....:)
Here is the link shows the simple Segment control. And when you want to add a Table , it is having the sample process , connect the delegates and data source. HERE is the descussion on the kind of similar question as your one.
This is the Class Reference of Segment control, which provides you a lot many examples this shall help you.
Hope this will help you.