1 package Reaction::UI::ViewPort::Field::File;
4 use Reaction::Types::File;
6 class File is 'Reaction::UI::ViewPort::Field', which {
8 has '+value' => (isa => 'File', required => 0);
10 #has '+layout' => (default => 'file');
12 override apply_our_events => sub {
13 my ($self, $ctx, $events) = @_;
14 my $value_key = join(':', $self->location, 'value');
15 if (my $upload = $ctx->req->upload($value_key)) {
16 local $events->{$value_key} = $upload;
29 Reaction::UI::ViewPort::Field::File
35 =head2 L<Reaction::UI::ViewPort::Field>
39 See L<Reaction::Class> for authors.
43 See L<Reaction::Class> for the license.