% return if !@options; % my $prefix = $Name.'Rules-'; % foreach my $o (@options) { % my $curr_value = $rules{ $o->{'name'} }; % } #foreach $o
<% $o->{'label'} %>: % if ( $o->{'type'} eq 'text' ) { % } % elsif ( $o->{'type'} eq 'checkbox' ) { > % } % elsif ( $o->{'type'} eq 'select' and ref $o->{'options'} ) { % } # else $o->{'type'}
<%INIT> my (@options, %rules); if ( $ScripX ) { my $ScripXObj = "RT::Scrip$Name"->new($session{'CurrentUser'}); $ScripXObj->Load($ScripX); my $QueueObj = RT::Queue->new($session{'CurrentUser'}); $QueueObj->Load($Queue); my $method = "Load$Name"; my $XObj = $ScripXObj->$method(); @options = $XObj->Options('QueueObj' => $QueueObj); %rules = split("\n", $Default); } <%ARGS> $Name => undef $Default => undef $Queue => 0 $ScripX => undef