[Rt-commit] [rtir] 01/03: While 95e9b9bb correctly passed an object, it forgot to pass CFs on Create
Kevin Falcone
falcone at bestpractical.com
Fri Apr 18 21:20:07 EDT 2014
This is an automated email from the git hooks/post-receive script.
falcone pushed a commit to branch master
in repository rtir.
commit 192f6eb1ee3883f3bf1275ddbbdd726b852e8b2c
Author: Kevin Falcone <falcone at bestpractical.com>
Date: Fri Apr 18 13:22:16 2014 -0400
While 95e9b9bb correctly passed an object, it forgot to pass CFs on Create
If you pass an object to /Elements/EditCustomFields without passing
CustomFields, RT will just call $Object->CustomFields, which will be
empty on empty tickets. You have to pass $Queue->TicketCustomFields
along, like share/html/Ticket/Create.html does.
Since this element does double duty throughout RT, figure out if the
ticket is empty or not and assume that means that it's a Create form.
Without this, all you got on Create was Constituency.
---
html/RTIR/Elements/EditCustomFields | 1 +
1 file changed, 1 insertion(+)
diff --git a/html/RTIR/Elements/EditCustomFields b/html/RTIR/Elements/EditCustomFields
index 5a5cc0c..2fa3077 100644
--- a/html/RTIR/Elements/EditCustomFields
+++ b/html/RTIR/Elements/EditCustomFields
@@ -48,6 +48,7 @@
<& /Elements/EditCustomFields,
Object => $TicketObj,
QueueObj => $QueueObj,
+ ($TicketObj->Id ? () : (CustomFields => $QueueObj->TicketCustomFields)), # on ticket creation, use Queue CFs
%ARGS,
InTable => 1,
&>
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the rt-commit
mailing list