stroke over hidden actions
[MojoFacets.git] / templates / actions / index.html.ep
index 431e9b7..b8ee3af 100644 (file)
@@ -46,11 +46,12 @@ $(document).ready( function(){
                                var form = $(data).filter('form');
                                console.debug('ajax',e,form);
                                e.html( form )
-                               .addClass( 'action_box' )
+                               .addClass( 'action_view' )
+                               .removeClass( 'action_hide' )
                                .append(
                                        $('<input type=button value=hide>').click( function() {
 console.debug(this,link_html);
-                                       e.html( link_html ).removeClass( 'action_box' ).addClass( 'action_viewed' );
+                                       e.html( link_html ).removeClass( 'action_view' ).addClass( 'action_hide' );
                                        })
                                )
                                ;
@@ -68,5 +69,15 @@ console.debug(this,link_html);
                }).css({ 'background': '#ffe' });
        });
 
+       $('label.checkbox_to_text span.value' ).live( 'dblclick', function() {
+               console.debug('checkbox to text',this);
+               var $checkbox = $(this).find('input[type=checkbox]');
+               $(this).html(
+                       '<input type=text name="'+$checkbox.attr('name')+'" value="'+$checkbox.attr('value')+'">'
+               );
+
+       });
+
+       console.debug('ready');
 });
 </script>