File Coverage

blib/lib/Data/MuForm/Field/Submit.pm
Criterion Covered Total %
statement 11 11 100.0
branch n/a
condition n/a
subroutine 5 5 100.0
pod 1 4 25.0
total 17 20 85.0


line stmt bran cond sub pod time code
1             package Data::MuForm::Field::Submit;
2             # ABSTRACT: Submit field
3              
4 9     9   5902 use Moo;
  9         13  
  9         52  
5             extends 'Data::MuForm::Field';
6              
7             has 'value' => ( is => 'rw', default => 'Save' );
8             has '+no_update' => ( default => 1 );
9              
10 4     4 0 85 sub build_input_type { 'submit' }
11              
12 7     7 0 20 sub no_fif {1}
13 5     5 1 104 sub fif { shift->value }
14              
15             sub base_render_args {
16 5     5 0 95 my $self = shift;
17 5         21 my $args = $self->next::method(@_);
18 5         10 $args->{layout_type} = 'element';
19 5         10 $args->{wrapper} = 'none';
20 5         18 return $args;
21             }
22              
23             1;
24              
25             __END__
26              
27             =pod
28              
29             =encoding UTF-8
30              
31             =head1 NAME
32              
33             Data::MuForm::Field::Submit - Submit field
34              
35             =head1 VERSION
36              
37             version 0.03
38              
39             =head1 AUTHOR
40              
41             Gerda Shank
42              
43             =head1 COPYRIGHT AND LICENSE
44              
45             This software is copyright (c) 2017 by Gerda Shank.
46              
47             This is free software; you can redistribute it and/or modify it under
48             the same terms as the Perl 5 programming language system itself.
49              
50             =cut