Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: ff5b0d753a
Fetching contributors…

Cannot retrieve contributors at this time

30 lines (28 sloc) 0.944 kb
% title 'Upload';
% use Data::Dumper;
% use Try::Tiny;
%= form_for upload => (method => 'post')=> (enctype => 'multipart/form-data')=> begin
%= file_field 'example'
%= submit_button 'Upload'
% end
% if (param('example'))
% {
% my $example=param('example');
% push @{ $self->session->{error_messages} }, 'File is too big'
% if $self->req->is_limit_exceeded;
% my $size = $example->size;
% my $name = $example->filename;
% my $curr_dt=scalar localtime;
% $curr_dt=~s/ /-/g;$curr_dt=~s/--*/-/g;
%# try {
%# system qq[mv $ENV{MIS}/tmp/$name $ENV{MIS}/tmp/${name}$curr_dt ];
%# }
% $example->move_to(qq[$ENV{MIS}/tmp/$name]);
%
% # print STDERR Dumper(\$example);
<br>
Thanks for uploading <%= $size %> byte file <%= $name %>.<br>
% my $x= join("<br>",split (/\n/,
% qx[$ENV{MIS}/script/parsexcel.pl $ENV{MIS}/tmp/$name] ));
<%== $x %>
% }
Jump to Line
Something went wrong with that request. Please try again.