fixed field_class
[catagits/Reaction.git] / lib / Reaction / UI / Widget / Field / Mutable / Boolean.pm
CommitLineData
2f670e13 1package Reaction::UI::Widget::Field::Mutable::Boolean;
2
3use Reaction::UI::WidgetClass;
4
5class Boolean is 'Reaction::UI::Widget::Field::Mutable', which {
6
3fad510b 7 after fragment widget {
8 arg 'field_type' => 'checkbox';
9 };
10
2f670e13 11 implements fragment is_checked {
384a9985 12 if ($_{viewport}->value_string) {
2f670e13 13 render 'is_checked_yes';
14 } else {
15 render 'is_checked_no';
16 }
17 };
18
19};
20
211;
22
23__END__;
24
25=head1 NAME
26
27Reaction::UI::Widget::Field::Boolean
28
29=head1 DESCRIPTION
30
31See L<Reaction::UI::Widget::Field>
32
33=head1 AUTHORS
34
35See L<Reaction::Class> for authors.
36
37=head1 LICENSE
38
39See L<Reaction::Class> for the license.
40
41=cut