Re: [rt-users] Looking for correct place to put callback
2013/3/25 Raymond Corbett raymond.corb...@arcproductions.com Stubborn I guess but I just keep refusing to give up. ** ** Bart offered this solution to me: ** ** Basically, get his callback which adds the CF's to the ticket update page and add it to your callback which will get loaded for the quick create box. ** ** The only thing I don't know is the name of the callback, but I think you could look in the code of the file you just created and search for callback and you'll get some names (I hope). Otherwise check the wiki page I just linked, it has some info on finding what callback you need to use. ** ** Since it is the Quick Create portlet that I want to affect: **· **I looked into rt4/local/html/Elements and I found QuickCreate which is the code that seems to populate the portlet with all the options **· **I found in this file% $m-callback(CallbackName = 'InFormElement'); ** ** Therefore I assumed that I had to name my callback file InFormElement so I did. ** ** My path is: Rt4/local/html/Callbacks/InterfaceCallbacks/Elements/QuickCreate/InFormElement ** ** But not go.I notice the customizing with CallBacks doc talks of path to html-page.There is a share/html/Ticket/Create.html but this not the case with Quick Create.It is not called QuickCreate.html ** ** Any suggestions to help me out. ** ** ** ** Looks like you might have to hack this one :S The callback you found is part of this line: form method=post action=%RT-Config-Get('WebPath')%/index.html % $m-callback(CallbackName = 'InFormElement'); I've tried what you did, and regarding callbacks thats the right way of using them, but it doesnt seem to work. I assume that the above line adds the QuickCreate box as an element on the index.html page using the callback InFromElement. So the callback you've tried was one from the index.html page... Hacking it is done this way (well, its another polite way of doing this): mkdir -p /opt/rt4/local/html/Elements cp /opt/rt4/share/html/Elements/QuickCreate /opt/rt4/local/html/Elements/ After that edit the title: (I'd also remove the big text of comments at the start, it's only a small piece of code so it makes reading a little easier) | /Widgets/TitleBox, title = loc('Quick ticket creation NEW') And then restart the server: service apache2 stop rm -rf /opt/rt4/var/mason_data/obj/* service apache2 start You've now replaced the stock quick create box with a new one, with your own title (just so you see the difference). After that you can try to add the custom fields, this is the code Ruslan used so you could try to add it in the QuickCreate code (your own) and see if it will do what you want it to: (2 callbacks) *BeforeUpdate* * * %ARGS $TicketObj $skip_update $results $ARGSRef = {} /%ARGS %INIT return unless $ARGSRef-{'SubmitTicket'}; my $CFs = $TicketObj-CustomFields; my $ValidCFs = $m-comp( '/Elements/ValidateCustomFields', CustomFields = $CFs, NamePrefix = Object-RT::Ticket-. $TicketObj-id .-CustomField-, ARGSRef = $ARGSRef ); unless ( $ValidCFs ) { $$skip_update = 1; while (my $CF = $CFs-Next) { my $msg = $m-notes('InvalidField-' . $CF-Id) or next; push @$results, loc($CF-Name) . ': ' . $msg; } } *AfterWorked* * * /Ticket/Elements/EditCustomFields, TicketObj = $Ticket, InTable = 1, DefaultsFromTopArguments = 0, %ARGS $Ticket This code hoever assumes a ticket is already in a certain queue, and then gets the custom fields associated with it. Since you're making a ticket, it's not yet in a queue, which makes it hard to lookup which CF it could set. So here you might have to take the piece of code inside the while loop and manually define the CF's you want in there. -- Bart G.
Re: [rt-users] MessageBoxRichText and Internet Explorer 10.
I have the same problem but I am not able to solve it with workarounds you suggested. Please help me. Thanks, Mario -- View this message in context: http://requesttracker.8502.n7.nabble.com/MessageBoxRichText-and-Internet-Explorer-10-tp52814p53192.html Sent from the Request Tracker - User mailing list archive at Nabble.com.
[rt-users] Migrating from 4.0.5 to 4.0.10 amd lost the RT taskbar (Home- Tickets)
Hello to all. I want to migrate mi centos 6.3 RT 4.0.5 to a new machine with Centos 6.4 and RT 4.0.10, I installed the new machine with RT 4.0.10, migrate the database, make and upgrade-database. All seems fine, but i don´t see the taskbar in the top of RT Homepage. Please check this image: http://imgur.com/epQQMHL Any help? Thanks. Kindest Regards. -- Un saludo. Juanjo Corral
Re: [rt-users] Migrating from 4.0.5 to 4.0.10 amd lost the RT taskbar (Home- Tickets)
Hi, Try to clean browser's cache. Make sure: * no errors in RT's and apache's logs * RT requests JS files via apache's access log * check browser's JS console for errors On Tue, Mar 26, 2013 at 3:57 PM, Juanjo juanji...@gmail.com wrote: Hello to all. I want to migrate mi centos 6.3 RT 4.0.5 to a new machine with Centos 6.4 and RT 4.0.10, I installed the new machine with RT 4.0.10, migrate the database, make and upgrade-database. All seems fine, but i don´t see the taskbar in the top of RT Homepage. Please check this image: http://imgur.com/epQQMHL Any help? Thanks. Kindest Regards. -- Un saludo. Juanjo Corral -- Best regards, Ruslan.
Re: [rt-users] Migrating from 4.0.5 to 4.0.10 amd lost the RT taskbar (Home- Tickets)
On Tue, Mar 26, 2013 at 4:36 PM, Juanjo juanji...@gmail.com wrote: Yes, i do a cleaning of browser cache, i use two differents browser. And i do test in two machines. No erros on log of httpd. No errors on log of RT (now is debug mode) Check Web* settings in RT site config. Open HTML of the page, find link that points at JS file and try to open it in browser's tab. Use browser's dev tools to make sure it can load all files linked from RT's page. Thanks for your help. 2013/3/26 Ruslan Zakirov r...@bestpractical.com Hi, Try to clean browser's cache. Make sure: * no errors in RT's and apache's logs * RT requests JS files via apache's access log * check browser's JS console for errors On Tue, Mar 26, 2013 at 3:57 PM, Juanjo juanji...@gmail.com wrote: Hello to all. I want to migrate mi centos 6.3 RT 4.0.5 to a new machine with Centos 6.4 and RT 4.0.10, I installed the new machine with RT 4.0.10, migrate the database, make and upgrade-database. All seems fine, but i don´t see the taskbar in the top of RT Homepage. Please check this image: http://imgur.com/epQQMHL Any help? Thanks. Kindest Regards. -- Un saludo. Juanjo Corral -- Best regards, Ruslan. -- Un saludo. Juanjo Corral -- Best regards, Ruslan.
[rt-users] Looks like you might have to hack this one (Bart)
Getting closer Bart: As per: Looks like you might have to hack this one :S The callback you found is part of this line: form method=post action=%RT-Config-Get('WebPath')%/index.html % $m-callback(CallbackName = 'InFormElement'); I am getting closer. Looks promising. However when I attempt to use code from Ruslan to see where I am at, I get an immediate error with a complaint about $TicketObj Error returned: (one line in read) error:no value sent for required parameter 'TicketObj' context: ... 91: my $type = $entry-{type}; 92: my $name = $entry-{'name'}; 93: if ( $type eq 'component' ) { 94: # XXX: security check etc. 95: $m-comp( $name, %{ $entry-{arguments} || {} } ); 96: } elsif ( $type eq 'system' ) { 97: $m-comp( '/Elements/ShowSearch', Name = $name, Override = { Rows = $Rows } ); 98: } elsif ( $type eq 'saved' ) { 99: $m-comp( '/Elements/ShowSearch', SavedSearch = $name, Override = { Rows = $Rows }, IgnoreMissing = 1 ); ... code stack: /n/software/linux/servers/rt4/share/html/Elements/MyRT:95 /n/software/linux/servers/rt4/share/html/index.html:78 /opt/rt4/sbin/../lib/RT/Interface/Web.pm:634 /opt/rt4/sbin/../lib/RT/Interface/Web.pm:335 /n/software/linux/servers/rt4/share/html/autohandler:53 raw error
[rt-users] Where are customfields stored
Where are customfields stored? For example, if I create a custom field and name it Dev Code for exmample. Where does that customfield actually exist in the code base. Assuming I want to load a customfield, how would I identify it by name? For example the one I called Dev Code
Re: [rt-users] Migrating from 4.0.5 to 4.0.10 amd lost the RT taskbar (Home- Tickets)
On Tue, Mar 26, 2013 at 12:57:49PM +0100, Juanjo wrote: I want to migrate mi centos 6.3 RT 4.0.5 to a new machine with Centos 6.4 and RT 4.0.10, I installed the new machine with RT 4.0.10, migrate the database, make and upgrade-database. All seems fine, but i don*t see the taskbar in the top of RT Homepage. I suspect you've run into this, as documented in the upgrade notes. http://bestpractical.com/rt/docs/latest/UPGRADING-4.0.html#Javascript-Changes If you've copied the entire RT_Config.pm to RT_SiteConfig.pm or copied @JSFiles to modify it, you will need to fix it. If you've copied all of RT_Config.pm to RT_SiteConfig.pm you should really resolve that or you'll run into future problems. -kevin pgpaadGU5kIgD.pgp Description: PGP signature
Re: [rt-users] Where are customfields stored
On Tue, Mar 26, 2013 at 7:44 PM, Raymond Corbett raymond.corb...@arcproductions.com wrote: Where are customfields stored? Have you looked at the list of tables in the DB? CustomFields is a table. For example, if I create a custom field and name it “Dev Code” for exmample. Where does that customfield actually exist in the code base. Have you looked at list of files in lib/ dir? lib/RT/CustomField.pm is a module. Assuming I want to load a customfield, how would I identify it by name? For example the one I called “Dev Code” http://bestpractical.com/rt/docs/latest/RT/CustomField.html#LoadByName-Queue-QUEUEID-Name-NAME Example in the following wiki article answers most of your questions and is first in the list after searching custom field: http://requesttracker.wikia.com/wiki/ImportCustomFieldValues Google is also very helpful if you search load rt custom field. -- Best regards, Ruslan.
Re: [rt-users] Where are customfields stored
On Tue, Mar 26, 2013 at 11:44 AM, Raymond Corbett raymond.corb...@arcproductions.com wrote: Assuming I want to load a customfield, how would I identify it by name? For example the one I called “Dev Code” If you want the value of a custom field in a ticket, the easiest way is $ticket-FirstCustomFieldValue(Dev Code); If you want to do something like write a query that takes into account the value of a custom field, then you end up doing a join with ObjectCustomFieldValues and CustomFields -- http://www.linkedin.com/in/paultomblin http://careers.stackoverflow.com/ptomblin
Re: [rt-users] Migrating from 4.0.5 to 4.0.10 amd lost the RT taskbar (Home- Tickets)
Thanks i will check it and share the results. Thanks El 26/03/2013 16:58, Kevin Falcone falc...@bestpractical.com escribió: On Tue, Mar 26, 2013 at 12:57:49PM +0100, Juanjo wrote: I want to migrate mi centos 6.3 RT 4.0.5 to a new machine with Centos 6.4 and RT 4.0.10, I installed the new machine with RT 4.0.10, migrate the database, make and upgrade-database. All seems fine, but i don*t see the taskbar in the top of RT Homepage. I suspect you've run into this, as documented in the upgrade notes. http://bestpractical.com/rt/docs/latest/UPGRADING-4.0.html#Javascript-Changes If you've copied the entire RT_Config.pm to RT_SiteConfig.pm or copied @JSFiles to modify it, you will need to fix it. If you've copied all of RT_Config.pm to RT_SiteConfig.pm you should really resolve that or you'll run into future problems. -kevin
[rt-users] Writing a Perl Module, assign new ticket to a group
Good afternoon, I want to assign a ticket to a group. Do I need to do this with AdminCC or can I do it by setting the owner in the ticket object? my ($child_id, $child_TransObj, $errorMsg) = $child_ticket-Create( Queue = $queue, Subject = $queue . ' - ' .$ticket-Id . ' : ' . $ticket-Subject, #same as above. Parents = $ticket-Id, Requestor = $mail, Owner = $group_id ); Thanks. -- Kevin Holleran Master of Science, Computer Information Systems Grand Valley State University Master of Business Administration Western Michigan University SANS GCFA, SANS GCFE, CCNA, ISA, MCSA, MCDST, MCP Do today what others won't, do tomorrow what others can't - SEALFit We are what we repeatedly do. Excellence, then, is not an act, but a habit. - Aristotle
[rt-users] Extract ticket contents into file(s)
I'm writing here while I do my own investigation due to time constraints. I got a request from a set of RT users to get the ticket contents in a file that can be parsed to categorize the ticket purpose. Setting aside the fact that custom fields would have prevented this, if there's a snippet of code out there that can extract that information from a given ticket, I think I can build the rest. Anyone else run into this situation? -Mark -- Mark Komarinski mark_komarin...@hms.harvard.edu Manager http://ritg.med.harvard.edu Research IT Group Harvard Medical School
Re: [rt-users] Extract ticket contents into file(s)
On Tue, Mar 26, 2013 at 02:09:51PM -0400, Mark Komarinski wrote: I'm writing here while I do my own investigation due to time constraints. I got a request from a set of RT users to get the ticket contents in a file that can be parsed to categorize the ticket purpose. Setting aside the fact that custom fields would have prevented this, if there's a snippet of code out there that can extract that information from a given ticket, I think I can build the rest. Anyone else run into this situation? -Mark -- Mark Komarinski mark_komarin...@hms.harvard.edu Manager http://ritg.med.harvard.edu Research IT Group Harvard Medical School Hi Mark, I think the REST interface can do what you want: http://requesttracker.wikia.com/wiki/REST Regards, Ken
[rt-users] Tie a Group to a Queue
Hello, I need to tie a group to a queue. I have a queue called CC - Dev a group called Dev. I need a way to tie the Dev group to the Queue. I assigned the proper rights to Dev on the queue, is there a way to query this from the queue in a perl script? A way to say 'Enumerate all the groups, pass in to Queue-HasRight(Group, someRightIAssigned)'? Or is it easier to create a custom field on the queue that only an admin can change (then how do I populate it with the current groups?) Thanks. -- Kevin Holleran Master of Science, Computer Information Systems Grand Valley State University Master of Business Administration Western Michigan University SANS GCFA, SANS GCFE, CCNA, ISA, MCSA, MCDST, MCP Do today what others won't, do tomorrow what others can't - SEALFit We are what we repeatedly do. Excellence, then, is not an act, but a habit. - Aristotle
Re: [rt-users] Tie a Group to a Queue
Perhaps I will make the group just an AdminCC. I do not necessarily want everyone in the group to have elevated privileges on the queue (which I think i can manage) or to receive a message/notification on every queue Thoughts on this approach? -- Kevin Holleran Master of Science, Computer Information Systems Grand Valley State University Master of Business Administration Western Michigan University SANS GCFA, SANS GCFE, CCNA, ISA, MCSA, MCDST, MCP Do today what others won't, do tomorrow what others can't - SEALFit We are what we repeatedly do. Excellence, then, is not an act, but a habit. - Aristotle On Tue, Mar 26, 2013 at 2:36 PM, Kevin Holleran holleran.ke...@gmail.comwrote: Hello, I need to tie a group to a queue. I have a queue called CC - Dev a group called Dev. I need a way to tie the Dev group to the Queue. I assigned the proper rights to Dev on the queue, is there a way to query this from the queue in a perl script? A way to say 'Enumerate all the groups, pass in to Queue-HasRight(Group, someRightIAssigned)'? Or is it easier to create a custom field on the queue that only an admin can change (then how do I populate it with the current groups?) Thanks. -- Kevin Holleran Master of Science, Computer Information Systems Grand Valley State University Master of Business Administration Western Michigan University SANS GCFA, SANS GCFE, CCNA, ISA, MCSA, MCDST, MCP Do today what others won't, do tomorrow what others can't - SEALFit We are what we repeatedly do. Excellence, then, is not an act, but a habit. - Aristotle
Re: [rt-users] Extract ticket contents into file(s)
On 03/26/2013 02:33 PM, k...@rice.edu wrote: I think the REST interface can do what you want: http://requesttracker.wikia.com/wiki/REST ticket/#/history?format=l looks like it might do what I need. Thanks! -Mark -- Mark Komarinski mark_komarin...@hms.harvard.edu Manager http://ritg.med.harvard.edu Research IT Group Harvard Medical School
[rt-users] WebExternalAuth
Hi, A couple of weeks ago I posted to the list asking if it was possible to have multiple databases associated with a single instance of RT4. I never got an answer nor have I been able to find anything in my web searches so I have had to move on... I am trying to upgrade a RT3.8.2 install to RT4.0.10. Everything appears to have upgraded properly with regard to the database, etc. However, the RT3 instance is using $WebExternalAuth and again I am not finding much information on it that can get me operational. In our scheme of things we use kerberos and LDAP for authentication. Are there modules that are required that I am not aware of or and directives other than the switches in the RT_SiteConf.pm that need to be set? I am on kind of a tight deadline with this so any help would be greatly appreciated. Joe Mervini Sandia National Laboratories High Performance Computing 505.844.6770 jame...@sandia.gov
Re: [rt-users] [EXTERNAL] WebExternalAuth
Hi, I was able to figure out what my problem was: I needed to specify the auth type in the conf file for each web instance. My misunderstanding of how httpd works. Sorry for the spam. Joe Mervini Sandia National Laboratories High Performance Computing 505.844.6770 jame...@sandia.gov On Mar 26, 2013, at 2:05 PM, Mervini, Joseph A wrote: Hi, A couple of weeks ago I posted to the list asking if it was possible to have multiple databases associated with a single instance of RT4. I never got an answer nor have I been able to find anything in my web searches so I have had to move on... I am trying to upgrade a RT3.8.2 install to RT4.0.10. Everything appears to have upgraded properly with regard to the database, etc. However, the RT3 instance is using $WebExternalAuth and again I am not finding much information on it that can get me operational. In our scheme of things we use kerberos and LDAP for authentication. Are there modules that are required that I am not aware of or and directives other than the switches in the RT_SiteConf.pm that need to be set? I am on kind of a tight deadline with this so any help would be greatly appreciated. Joe Mervini Sandia National Laboratories High Performance Computing 505.844.6770 jame...@sandia.gov