1 <% include('/elements/header.html', "View Message catalog", menubar(
2 'Edit message catalog' => $p. "edit/msgcat.cgi",
6 %my $widget = new HTML::Widgets::SelectLayers(
7 % 'selected_layer' => 'en_US',
8 % 'options' => { 'en_US'=>'en_US' },
9 % 'layer_callback' => sub {
11 % my $html = "<BR>Messages for locale $layer<BR>". table().
12 % "<TR><TH COLSPAN=2>Code</TH>".
14 % $html .= "<TH>en_US Message</TH>" unless $layer eq 'en_US';
17 % #foreach my $msgcat ( sort { $a->msgcode cmp $b->msgcode }
18 % # qsearch('msgcat', { 'locale' => $layer } ) ) {
19 % foreach my $msgcat ( qsearch('msgcat', { 'locale' => $layer } ) ) {
20 % $html .= '<TR><TD>'. $msgcat->msgnum. '</TD>'.
21 % '<TD>'. $msgcat->msgcode. '</TD>'.
22 % '<TD>'. $msgcat->msg. '</TD>';
23 % unless ( $layer eq 'en_US' ) {
24 % my $en_msgcat = qsearchs('msgcat', {
25 % 'locale' => 'en_US',
26 % 'msgcode' => $msgcat->msgcode,
28 % $html .= '<TD>'. $en_msgcat->msg. '</TD>';
33 % $html .= '</TABLE>';
42 <% include('/elements/footer.html') %>