projects
/
MojoFacets.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
added remove class on storable unlink
[MojoFacets.git]
/
templates
/
data
/
index.html.ep
diff --git
a/templates/data/index.html.ep
b/templates/data/index.html.ep
index
0102cd3
..
80565e7
100644
(file)
--- a/
templates/data/index.html.ep
+++ b/
templates/data/index.html.ep
@@
-1,18
+1,28
@@
% layout 'default';
% layout 'default';
+% my $path = session('path');
+
<h2>Select data file to load</h2>
<form method=post action=/data/load >
<h2>Select data file to load</h2>
<form method=post action=/data/load >
+<input type=submit value="Load">
+
<table>
<table>
-<tr><th>name</th><th title="on disk">bytes</th><th>items</th><th title="loaded in memory">m</th><th>columns</th></tr>
+<tr><th rowspan=2>name</th><th colspan=2>size</th><th rowspan=2>items</th><th rowspan=2>changes</th><th rowspan=2 title="loaded in memory">m</th><th colspan=2>columns</th></tr>
+<tr><th>disk</th><th>storable</th></tr>
% foreach my $n ( @$files ) {
<tr><td>
<label>
% foreach my $n ( @$files ) {
<tr><td>
<label>
-<input name=path type=radio value="<%= $n %>" <%=
defined $loaded->{session('path')}->{data} eq $n
? 'disabled' : '' %>>
+<input name=path type=radio value="<%= $n %>" <%=
$n eq $path && defined $loaded->{$path}->{data}
? 'disabled' : '' %>>
<%= $n %>
</label>
<%= $n %>
</label>
-</td><td align=right><%= $size->{$n} %>
+</td><td class=bytes><%= $size->{$n} %>
+</td><td class=bytes>
+% if ( my $size = -s $dump_path->{$n} ) {
+<a class="remove" title="remove" href="/data/unlink?path=<%= $dump_path->{$n} %>"><%= $size %></a>
+% }
</td><td align=right><%= defined $loaded->{$n}->{data} ? $#{ $loaded->{$n}->{data}->{items} } + 1 : '' %>
</td><td align=right><%= defined $loaded->{$n}->{data} ? $#{ $loaded->{$n}->{data}->{items} } + 1 : '' %>
+</td><td align=right><%= defined $changes->{$n} ? $#{ $changes->{$n} } + 1 : '' %>
</td><td><input name=paths type=checkbox value="<%= $n %>" <%= defined $loaded->{$n}->{stats} ? 'checked' : '' %>>
</td><td>
% if ( defined $loaded->{$n}->{columns} ) {
</td><td><input name=paths type=checkbox value="<%= $n %>" <%= defined $loaded->{$n}->{stats} ? 'checked' : '' %>>
</td><td>
% if ( defined $loaded->{$n}->{columns} ) {
@@
-29,5
+39,7
@@
</form>
</form>
+%#<pre class=debug><%= dumper $changes %></pre>
<pre class=debug><%= dumper $loaded %></pre>
<pre class=debug><%= dumper $filters %></pre>
<pre class=debug><%= dumper $loaded %></pre>
<pre class=debug><%= dumper $filters %></pre>
+<pre class=debug><%= dumper $dump_path %></pre>