ajax_scaffold_generator 3.0.3 → 3.0.4
Sign up to get free protection for your applications and to get access to all the features.
data/ajax_scaffold_generator.rb
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
<%% current_sort_direction = session[params[:scaffold_id]][:sort_direction] %>
|
3
3
|
<%% for column in <%= model_name %>.content_columns %>
|
4
4
|
<%% sort_direction = current_sort == column.name && current_sort_direction == "asc" ? "desc" : "asc" %>
|
5
|
-
<%% sort_params = params.merge(:controller => '<%=
|
5
|
+
<%% sort_params = params.merge(:controller => '<%= controller_file_path %>', :action => 'component_update', :sort => column.name, :sort_direction => sort_direction, :page => 1) %>
|
6
6
|
<th id="<%%= scaffold_column_header_id(sort_params.merge(:column_name => column.name)) %>" <%%= "class=\"sorted #{current_sort_direction}\"" if column.name == current_sort %>>
|
7
7
|
<%%= link_to_remote column.human_name,
|
8
8
|
{ :url => sort_params,
|
@@ -1,6 +1,6 @@
|
|
1
1
|
<%% # The following is used when the browser doesn't have javascript enabled %>
|
2
2
|
<%% classAttr = cycle("", "class=\"even\"") %>
|
3
|
-
<%% @options = params.merge(:controller => '<%=
|
3
|
+
<%% @options = params.merge(:controller => '<%= controller_file_path %>', :action => "view", :id => <%= singular_name %>.id) %>
|
4
4
|
|
5
5
|
<tr <%%= classAttr %> id="<%%= element_row_id(@options) %>" <%%= "style=\"display: none;\"" if hidden %>>
|
6
6
|
<%% for column in <%= model_name %>.content_columns %>
|
@@ -5,9 +5,9 @@
|
|
5
5
|
<tr id="<%%= element_row_id(@options) %>" class="<%%= @options[:action] %>" <%%= "style=\"display:none;\"" if request.xhr? %>>
|
6
6
|
<td id="<%%= element_cell_id(@options) %>" colspan="<%%= num_columns %>">
|
7
7
|
|
8
|
-
<%%= form_remote_tag :url => @options.merge(:controller => '<%=
|
8
|
+
<%%= form_remote_tag :url => @options.merge(:controller => '<%= controller_file_path %>'),
|
9
9
|
:loading => "Element.show('#{loading_indicator_id(@options)}');",
|
10
|
-
:html => { :href => url_for(@options.merge(:controller => '<%=
|
10
|
+
:html => { :href => url_for(@options.merge(:controller => '<%= controller_file_path %>')),
|
11
11
|
:id => element_form_id(@options) } %>
|
12
12
|
|
13
13
|
<%%= hidden_field_tag "scaffold_id", @options[:scaffold_id] %>
|
@@ -30,7 +30,7 @@
|
|
30
30
|
<%% on_cancel += "AjaxScaffold.displayMessageIfEmpty('#{scaffold_tbody_id(@options)}','#{empty_message_id(@options)}');" if @options[:action] == "create" %>
|
31
31
|
<%% end %>
|
32
32
|
<%%= link_to_function "Cancel", on_cancel,
|
33
|
-
:href => url_for(:controller => '<%=
|
33
|
+
:href => url_for(:controller => '<%= controller_file_path %>', :action => 'return_to_main') %>
|
34
34
|
<%%= loading_indicator_tag @options %>
|
35
35
|
</p>
|
36
36
|
<%%= end_form_tag %>
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<%% pagination_params = params.merge(:controller => '<%=
|
2
|
-
<%% indicator_params =
|
1
|
+
<%% pagination_params = params.merge(:controller => '<%= controller_file_path %>', :action => 'component_update') %>
|
2
|
+
<%% indicator_params = pagination_params.merge(:action => 'pagination') %>
|
3
3
|
<%%= loading_indicator_tag indicator_params %>
|
4
4
|
<%%= link_to_remote('Previous',
|
5
5
|
{ :url => pagination_params.merge(:page => paginator.current.previous),
|
@@ -4,7 +4,7 @@
|
|
4
4
|
<%% end %>
|
5
5
|
<div class="ajax-scaffold-header">
|
6
6
|
<div class="actions">
|
7
|
-
<%% new_params = params.merge(:controller => '<%=
|
7
|
+
<%% new_params = params.merge(:controller => '<%= controller_file_path %>', :action => 'new') %>
|
8
8
|
<%%= loading_indicator_tag(new_params) %>
|
9
9
|
<%%= link_to_remote "Create New",
|
10
10
|
{ :url => new_params,
|
metadata
CHANGED
@@ -3,7 +3,7 @@ rubygems_version: 0.8.11
|
|
3
3
|
specification_version: 1
|
4
4
|
name: ajax_scaffold_generator
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 3.0.
|
6
|
+
version: 3.0.4
|
7
7
|
date: 2006-04-14 00:00:00 -04:00
|
8
8
|
summary: Ajax scaffold generator is a rails generator for ajaxified scaffolds
|
9
9
|
require_paths:
|