Revision 7fb610a5
Von Moritz Bunkus vor mehr als 13 Jahren hinzugefügt
bin/mozilla/amcvar.pl | ||
---|---|---|
90 | 90 |
|
91 | 91 |
my @configs = @{ CVar->get_configs(module => $form->{module}) }; |
92 | 92 |
|
93 |
my $previous_config; |
|
94 |
|
|
95 | 93 |
foreach my $config (@configs) { |
96 | 94 |
$config->{type_tr} = $translations{$config->{type}}; |
97 |
|
|
98 |
if ($previous_config) { |
|
99 |
$previous_config->{next_id} = $config->{id}; |
|
100 |
$config->{previous_id} = $previous_config->{id}; |
|
101 |
} |
|
102 |
|
|
103 |
$previous_config = $config; |
|
104 | 95 |
} |
105 | 96 |
|
106 | 97 |
$form->{title} = $locale->text('List of custom variables'); |
... | ... | |
219 | 210 |
$main::lxdebug->leave_sub(); |
220 | 211 |
} |
221 | 212 |
|
222 |
sub swap_cvar_configs { |
|
223 |
$main::lxdebug->enter_sub(); |
|
224 |
|
|
225 |
my $form = $main::form; |
|
226 |
my %myconfig = %main::myconfig; |
|
227 |
|
|
228 |
AM->swap_sortkeys(\%myconfig, $form, 'custom_variable_configs'); |
|
229 |
|
|
230 |
list_cvar_configs(); |
|
231 |
|
|
232 |
$main::lxdebug->leave_sub(); |
|
233 |
} |
|
234 |
|
|
235 | 213 |
sub dispatcher { |
236 | 214 |
my $form = $main::form; |
237 | 215 |
my $locale = $main::locale; |
Auch abrufbar als: Unified diff
Sortieren von benutzerdefinierten Variablen auf Drag-n-Drop & AJAX mittels jQuery UI Sortable umgestellt