-<&|/l&>Queue Name&>: |
-Name || $Name %>" /> |
-
+<&|/l&>Queue Name&>: |
+% if ($InternalQueue) {
+<% $QueueObj->Name %>
+% } else {
+Name || $Name %>" />
+% }
+ |
<&|/l&>Description&>: |
Description || $Description || '' %>" size="60" /> |
-<&|/l&>Lifecycle&>: |
-<& /Widgets/Form/Select:InputOnly,
+ |
<&|/l&>Lifecycle&>: |
+% if ($InternalQueue) {
+<% $QueueObj->Lifecycle %>
+% } else {
+<& /Widgets/Form/Select:InputOnly,
Name => 'Lifecycle',
Values => [ sort { loc($a) cmp loc($b) } RT::Lifecycle->List ],
CurrentValue => $Create ? "default" : $QueueObj->Lifecycle || $ARGS{'Lifecycle'},
Default => 0,
-&> |
-
+&>
+% }
+
<&|/l&>Subject Tag&>: |
SubjectTag || '' ) %>" size="60" /> |
@@ -104,38 +111,40 @@
% my $CFs = $QueueObj->CustomFields;
% while (my $CF = $CFs->Next) {
-<% loc($CF->Name) %>:
+<% $CF->Name %>:
|
-<& /Elements/EditCustomField, CustomField => $CF,
- Object => $QueueObj,
- ($Create ? (NamePrefix => 'Object-RT::Queue--CustomField-')
- : () )&>
+<& /Elements/EditCustomField, CustomField => $CF,
+ Object => $QueueObj, &>
|
% }
-% if ( RT->Config->Get('GnuPG')->{'Enable'} ) {
-Sign? 'checked="checked"': '' |n%> /> |
-<&|/l&>Sign by default&> |
-Encrypt? 'checked="checked"': '' |n%> /> |
-<&|/l&>Encrypt by default&> |
+% if ( RT->Config->Get('Crypt')->{'Enable'} ) {
+
Sign? 'checked="checked"': '' |n%> /> |
+ |
+Encrypt? 'checked="checked"': '' |n%> /> |
+ |
-SignAuto? 'checked="checked"': '' |n%> /> |
-<&|/l_unsafe, "","","",""&>Sign all auto-generated mail. [_1]Caution[_2]: Enabling this option alters the signature from providing [_3]authentication[_4] to providing [_3]integrity[_4].&> |
+SignAuto? 'checked="checked"': '' |n%> /> |
+ |
% }
- /> |
-<&|/l&>Enabled (Unchecking this box disables this queue)&>
+% unless ($InternalQueue) {
+ |
/> |
+
+
% $m->callback( %ARGS, QueueObj => $QueueObj, results => \@results );
|
+% }
-% if ( RT->Config->Get('GnuPG')->{'Enable'} ) {
+% if ( RT->Config->Get('Crypt')->{'Enable'} ) {
+
% if ( my $email = $QueueObj->CorrespondAddress || RT->Config->Get('CorrespondAddress') ) {
<& /Admin/Elements/ShowKeyInfo, Type => 'private', EmailAddress => $email &>
% } else {
-<&|/Widgets/TitleBox, title => loc( 'GnuPG private keys') &>
-<&|/l&>You have enabled GnuPG support but have not set a correspondence address for this queue.&>
-<&|/l&>You must set a correspondence address for this queue in order to configure a GnuPG private key.&>
+<&|/Widgets/TitleBox, title => loc( 'Private keys') &>
+<&|/l&>You have enabled encryption support but have not set a correspondence address for this queue.&>
+<&|/l&>You must set a correspondence address for this queue in order to configure a private key.&>
&>
% }
|
@@ -143,9 +152,9 @@
% if ( my $email = $QueueObj->CommentAddress || RT->Config->Get('CommentAddress') ) {
<& /Admin/Elements/ShowKeyInfo, Type => 'private', EmailAddress => $email &>
% } else {
-<&|/Widgets/TitleBox, title => loc( 'GnuPG private keys') &>
-<&|/l&>You have enabled GnuPG support but have not set a comment address for this queue.&>
-<&|/l&>You must set a comment address for this queue in order to configure a GnuPG private key.&>
+<&|/Widgets/TitleBox, title => loc( 'Private keys') &>
+<&|/l&>You have enabled encryption support but have not set a comment address for this queue.&>
+<&|/l&>You must set a comment address for this queue in order to configure a private key.&>
&>
%}
@@ -188,8 +197,10 @@ if ( $QueueObj->Id ) {
# we're asking about enabled on the web page but really care about disabled
if ( $SetEnabled ) {
$Disabled = $ARGS{'Disabled'} = $Enabled? 0: 1;
+ }
+ if ( $SetCrypt ) {
$ARGS{$_} = 0 foreach grep !defined $ARGS{$_} || !length $ARGS{$_},
- qw(Sign SignAuto Encrypt Disabled);
+ qw(Sign SignAuto Encrypt);
}
$m->callback(
@@ -229,6 +240,8 @@ if ( $QueueObj->Id ) {
$title = loc("Create a queue");
}
+my $InternalQueue = ($QueueObj->Id and $QueueObj->Disabled == 2);
+
# This code does automatic redirection if any updates happen.
MaybeRedirectForResults(
Actions => \@results,
@@ -251,5 +264,6 @@ $InitialPriority => undef
$FinalPriority => undef
$DefaultDueIn => undef
$SetEnabled => undef
+$SetCrypt => undef
$Enabled => undef
%ARGS>