- $tree->fid('solution_modal')->fclass('modal-body')->replace_content(literal $args{solution});
- }
- if ($args{cansubmit}) {
- $tree->fid('nosubmit')->detach;
- $tree->look_down(name => 'problem')->attr(value => $args{id});
- my $contest = $tree->look_down(name => 'contest');
- $contest->attr(value => $args{args}{contest}) if $args{args}{contest};
- $contest->detach unless $args{args}{contest}
- } else {
- $tree->fid('nosubmit')->find('a')->edit_href(sub{s/id/$args{id}/});
- $tree->fid('submit')->detach