Package option dependencies
Package option dependencies
- Subject: Package option dependencies
- From: Philip Petev <email@hidden>
- Date: Sat, 17 Nov 2012 17:07:18 +0200
Hi there
I want to set a dependencies between the options in the package. Right now, I have a group with three subgroups (the first has one item, the second has five items and the third has three items). Here's the function I'm using about the first item of the second subgroup:
function choice_2_2_1_selected()
{
var tSelected;
tSelected=(!choices.installer_choice_2_1.selected
&& !choices.installer_choice_2_2_2.selected
&& !choices.installer_choice_2_2_3.selected
&& !choices.installer_choice_2_2_4.selected
&& !choices.installer_choice_2_2_5.selected
&& !choices.installer_choice_2_3.selected);
return (tSelected && my.choice.selected);
}
This function is assigned to the "selected" property of this item and "start_selected" is set to false.
The idea is when any item in the entire group is selected, all other options to become deselected (no matter the subgroup they are in). This code works for me, but I have another group of options with total 26 option, divided in 12 subgroups (2 subgroups with 4 options, 4 subgroups with 3 options and 6 subgroups with 1 option) and I want to do the same with it. You can imagine how will look like the function for any item from this group. Is there any easier way for me to do these dependencies with as few as possible scripting?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden