[rt-users] ExtractCustomFieldValues and CF Select type

Kevin Falcone falcone at bestpractical.com
Mon Aug 26 13:51:36 EDT 2013


On Mon, Aug 26, 2013 at 07:30:08AM -0700, elifree wrote:
> I'm using RT 4.0.10 (on a test machine) and I'm testing the extension
> ExtractCustomFieldValues to insert a value to a custom field (Select type
> with a list of 4 values).
> 
> The incoming mail contains the value :
>    Type du ticket->Incident
> 
> the template contains :
>    Type du ticket|Body|Type du ticket->(.+)$|q|
> 
> then The ticket is created, and displays on the main page :
>    Type du ticket: 	Incident 
> 
> but when I modify the ticket (the basics), on the list of values of this CF,
> the blue line is set on (no information) and not on Incident.
> 
> So if I want to modify any field there, I must re-select the value Incident
> before saving, otherwise it's lost.
> 
> For example, the history of the ticket shows  :
> - at the creation of the ticket :
>    The RT System itself - Type du ticket Incident added 
> - after modifying :
>    '/the name of the owne/r' - Type du ticket Incident removed
>  
> With CF using type Freeform there is no problem, the value is correctly
> inserted at creation time.
> 
> I've been searching for a while, I suppose it's simple, but even after some
> holidays, I still don't find the reason why the correct value is not
> selected.

I'd bet your greedy regex (.+)$ is grabbing trailing whitespace, which
doesn't exactly match the value in the select one CF.

You can go look in the ObjectCustomFieldValues table for the value of
the CF on your test ticket and check to see what the actual Content
is.

-kevin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 235 bytes
Desc: not available
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20130826/6ba63fa3/attachment.sig>


More information about the rt-users mailing list