]> git.uio.no Git - usit-rt.git/blobdiff - share/html/Admin/Elements/ModifyTemplate
Upgrade to 4.0.10.
[usit-rt.git] / share / html / Admin / Elements / ModifyTemplate
index ebe7c73bc6eb78d01f0bec32e7e284e38013b643..f5bb866de71ca0f362dc4bddec72661d79c1714a 100644 (file)
@@ -2,7 +2,7 @@
 %#
 %# COPYRIGHT:
 %#
-%# This software is Copyright (c) 1996-2012 Best Practical Solutions, LLC
+%# This software is Copyright (c) 1996-2013 Best Practical Solutions, LLC
 %#                                          <sales@bestpractical.com>
 %#
 %# (Except where explicitly superseded by other copyright notices)
 </tr>
 <tr>
 <td class="label" valign="top"><&|/l&>Content</&>:</td>
-<td class="value"><textarea name="Content" rows="25" cols="80" wrap="soft"><%$Content||''%></textarea></td>
+<td class="value"><textarea name="Content" rows="25" cols="80" wrap="soft">
+<%$Content||''%></textarea></td>
 </tr>
 </table>
 
 <%INIT>
 
-$Type = 'Perl' if !$Type;
+unless ($Type) {
+    $Type = $session{'CurrentUser'}->HasRight(Right => 'ExecuteCode', Object => $RT::System) ?
+        'Perl' : 'Simple';
+}
 
 </%INIT>
 
@@ -77,5 +81,5 @@ $Type = 'Perl' if !$Type;
 $Name => ''
 $Description => ''
 $Content => ''
-$Type => 'Perl'
+$Type => ''
 </%ARGS>