Data::Dump breaks Mojo::JSON https://rt.cpan.org/Public/Bug/Display.html?id=86592
[MojoFacets.git] / templates / admin.html.ep
index b3d29d3..0cfb378 100644 (file)
 <script>
 $(document).ready( function() {
        $('#switch_dataset').change( function() {
-               console.log( 'switch_dataset', this );
+               console.debug( 'switch_dataset', this );
                $(this).submit();
        });
        console.debug('installed switch_dataset' );
 });
 </script>
 % } else {
-<tt><%= session('path') %>
+<tt><%= session('path') %></tt>
 % }
 
 <a href="<%= url_for( controller => 'data', action => 'index', id => 0 ) %>">load</a>
@@ -59,11 +59,13 @@ items:
 <a href="<%= url_for( controller => 'changes', action => 'index', id => 0 ) %>">changes</a>
 <a href="<%= url_for( controller => 'actions', action => 'index', id => 0 ) %>">actions</a>
 
-% if ( session('modified') ) {
-%  my $path = session('path');
+% my $visible_class = session('modified') ? '' : 'hide';
+% my $path = session('path');
+<span class="save_actions <%= $visible_class %>">
 &middot;
-<a class=save_actions title="<%= $path %>" href="<%= url_for( controller => 'data', action => 'save', id => $path ) %>">save</a>
-% }
+<a title="<%= $path %>" href="<%= url_for( controller => 'data', action => 'save' ) %>" >save</a>
+</span>
+
 </span>
 
 </div>