% $m->comp("/widgets/wrappers/sharky/table_top.mc",
% caption => "Notes",
% number => $number);
 |
% foreach my $n (@notes) {
% if ($flag) {
% } # if
<% $n->{id} %> |
<% $n->{note} %> |
% $flag = 1;
% } # foreach
% unless (@notes) {
<% $lang->maketext('No existing notes.')%> |
 |
% } # unless
% $m->comp("/widgets/wrappers/sharky/table_bottom.mc");
<%args>
$widget
$number
%args>
<%init>
my $notes = get_state_data($widget, 'notes');
my @notes = map { { id => $_, note => $notes->{$_} } }
sort { $notes->{$a} <=> $notes->{$b} } keys %$notes;
my $flag;
%init>