[Rt-commit] r6021 - in rtir/branches/2.1-EXPERIMENTAL: html/RTIR html/RTIR/Incident/Elements

ruz at bestpractical.com ruz at bestpractical.com
Fri Sep 22 17:57:11 EDT 2006


Author: ruz
Date: Fri Sep 22 17:57:10 2006
New Revision: 6021

Modified:
   rtir/branches/2.1-EXPERIMENTAL/   (props changed)
   rtir/branches/2.1-EXPERIMENTAL/html/RTIR/Create.html
   rtir/branches/2.1-EXPERIMENTAL/html/RTIR/Incident/Elements/Create

Log:
 r1617 at cubic-pc:  cubic | 2006-09-23 01:59:21 +0400
 Constituency
 * don't allow user to change constituency value when he creates
   linked ticket


Modified: rtir/branches/2.1-EXPERIMENTAL/html/RTIR/Create.html
==============================================================================
--- rtir/branches/2.1-EXPERIMENTAL/html/RTIR/Create.html	(original)
+++ rtir/branches/2.1-EXPERIMENTAL/html/RTIR/Create.html	Fri Sep 22 17:57:10 2006
@@ -144,12 +144,14 @@
   <tr>
     <td class="labeltop"><&|/l&>Constituency</&>:</td>
     <td class="value" colspan="2">
+% unless ( $Incident ) {
       <& /RTIR/Elements/EditRTIRField, 
          QueueObj => $QueueObj, 
          Name     => 'Constituency',
-         Default  => $Incident?
-            $IncidentObj->FirstCustomFieldValue('_RTIR_Constituency'):
-            scalar RT->Config->Get('_RTIR_Constituency_default') &>
+         Default  => scalar RT->Config->Get('_RTIR_Constituency_default') &>
+% } else {
+      <& /RTIR/Elements/ShowRTIRField, Ticket => $IncidentObj, Name => 'Constituency' &>
+% }
     </td>
   </tr>
 

Modified: rtir/branches/2.1-EXPERIMENTAL/html/RTIR/Incident/Elements/Create
==============================================================================
--- rtir/branches/2.1-EXPERIMENTAL/html/RTIR/Incident/Elements/Create	(original)
+++ rtir/branches/2.1-EXPERIMENTAL/html/RTIR/Incident/Elements/Create	Fri Sep 22 17:57:10 2006
@@ -39,14 +39,17 @@
 
 <tr><td class="label"><&|/l&>Constituency</&>:</td>
 <td class="value">
+% unless ( $ChildObj ) {
 <& /RTIR/Elements/EditRTIRField,
     QueueObj => $QueueObj,
     Name     => 'Constituency',
-    Default  => $ChildObj?
-        $ChildObj->FirstCustomFieldValue('_RTIR_Constituency'):
-        scalar RT->Config->Get('_RTIR_Constituency_default'),
+    Default  => scalar RT->Config->Get('_RTIR_Constituency_default'),
     Rows     => 1,
-&></td></tr>
+&>
+% } else {
+<& /RTIR/Elements/ShowRTIRField, Ticket => $ChildObj, Name => 'Constituency' &>
+% }
+</td></tr>
 
 <tr><td class="label"><&|/l&>Function</&>:</td>
 <td class="value">


More information about the Rt-commit mailing list