in reply to Mime::Lite::TT::HTML Input Hash Name?
If I'm understanding you correctly, the %emailOptions that you're passing to MIME::Lite::TT::HTML has essentially random keys, unknown until runtime. What you need is a key name with which to loop over the ticket info from %emailOptions. Can you modify %emailOptions to be:
my %emailOptions = { tickets => [ { key => '<random ID>', 'queue' = 'Mig', 'priority' = 'high'}, { key => '<random ID 2>', 'queue' = 'Inf', 'priority' = 'high'}, { key => '<random ID 3>', 'queue' = 'Mig', 'priority' = 'low'}, ], };
Then your template would include:
[% FOREACH ticket IN tickets %] <td>[% ticket.key %]</td> <td>[% ticket.queue %]</td> <td>[% ticket.priority %]</td> [% END %]
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Mime::Lite::TT::HTML Input Hash Name?
by doubletb (Initiate) on Oct 04, 2011 at 15:15 UTC |