wice_grid_mongoid 0.5.7 → 6.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (54) hide show
  1. data/.gitignore +4 -1
  2. data/Gemfile +17 -0
  3. data/Gemfile.lock +140 -0
  4. data/README.rdoc +19 -3
  5. data/Rakefile +1 -3
  6. data/VERSION +1 -1
  7. data/lib/filter_conditions_generators.rb +126 -0
  8. data/{generators/wice_grid_assets_prototype/templates/stylesheets → lib/generators/wice_grid/templates}/calendarview.css +0 -0
  9. data/{generators/wice_grid_assets_prototype/templates/javascripts → lib/generators/wice_grid/templates}/calendarview.js +0 -0
  10. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/arrow_down.gif +0 -0
  11. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/arrow_up.gif +0 -0
  12. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/calendar_view_month.png +0 -0
  13. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/delete.png +0 -0
  14. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/expand.png +0 -0
  15. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/page_white_excel.png +0 -0
  16. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/page_white_find.png +0 -0
  17. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/table.png +0 -0
  18. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/table_refresh.png +0 -0
  19. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/tick_all.png +0 -0
  20. data/{generators/common_templates → lib/generators/wice_grid/templates}/icons/untick_all.png +0 -0
  21. data/{generators/common_templates/stylesheets → lib/generators/wice_grid/templates}/wice_grid.css +0 -0
  22. data/{generators/common_templates/locales → lib/generators/wice_grid/templates}/wice_grid.yml +0 -0
  23. data/{generators/common_templates/initializers → lib/generators/wice_grid/templates}/wice_grid_config.rb +0 -0
  24. data/{generators/wice_grid_assets_jquery/templates/javascripts → lib/generators/wice_grid/templates}/wice_grid_jquery.js +0 -0
  25. data/{generators/wice_grid_assets_prototype/templates/javascripts → lib/generators/wice_grid/templates}/wice_grid_prototype.js +0 -0
  26. data/lib/generators/wice_grid/wice_grid_assets_jquery_generator.rb +32 -0
  27. data/lib/generators/wice_grid/wice_grid_assets_prototype_generator.rb +34 -0
  28. data/lib/grid_renderer.rb +36 -20
  29. data/lib/helpers/js_calendar_helpers.rb +0 -5
  30. data/lib/helpers/wice_grid_view_helpers.rb +113 -133
  31. data/lib/mongoid_field.rb +50 -0
  32. data/{tasks → lib/tasks}/wice_grid_tasks.rake +0 -0
  33. data/lib/view_columns.rb +23 -29
  34. data/lib/wice_grid.rb +91 -379
  35. data/lib/wice_grid_misc.rb +3 -3
  36. data/mongoid_wice_grid.gemspec +122 -0
  37. data/test/blueprint.rb +17 -0
  38. data/test/public/javascripts/jquery-1.4.2.min.js +154 -0
  39. data/test/public/javascripts/wice_grid.js +163 -0
  40. data/test/rails_mongoid_test.rb +104 -0
  41. data/test/rails_test_app.rb +71 -0
  42. data/test/require_gems.rb +19 -0
  43. data/test/spec_helper.rb +22 -0
  44. data/test/wice_grid_initializer.rb +215 -0
  45. data/wice_grid_mongoid.gemspec +43 -30
  46. metadata +45 -34
  47. data/generators/wice_grid_assets_jquery/templates/USAGE +0 -6
  48. data/generators/wice_grid_assets_jquery/wice_grid_assets_jquery_generator.rb +0 -35
  49. data/generators/wice_grid_assets_prototype/USAGE +0 -8
  50. data/generators/wice_grid_assets_prototype/wice_grid_assets_prototype_generator.rb +0 -37
  51. data/init.rb +0 -1
  52. data/install.rb +0 -1
  53. data/lib/table_column_matrix.rb +0 -51
  54. data/uninstall.rb +0 -1
@@ -0,0 +1,104 @@
1
+ require File.join(File.dirname(__FILE__), '/spec_helper')
2
+
3
+ describe UsersController do
4
+ include Capybara
5
+
6
+ context "3 users" do
7
+ before(:each) do
8
+ @aa = User.make(:first_name => 'aabbcc', :year => Time.parse('1980-01-01'), :archived => true)
9
+ @bb = User.make(:first_name => 'bbccdd', :year => Time.parse('1990-01-01'), :last_login => Time.parse('2010-01-01 4pm'))
10
+ @cc = User.make(:first_name => 'ccddee', :year => Time.parse('2000-01-01'), :computers_number => 3)
11
+ Computer.make(:user_id => @aa.id, :name => "aa_host_1")
12
+ Computer.make(:user_id => @aa.id, :name => "aa_host_2")
13
+ end
14
+
15
+ it "should render grid as table" do
16
+ UsersController.columns do |grid|
17
+ grid.column :column_name => 'First Name', :attribute_name => 'first_name'
18
+ end
19
+ visit '/users'
20
+ page.should have_selector('table tr')
21
+ end
22
+
23
+ it "should be possible to sort it by clicking titles" do
24
+ UsersController.columns do |grid|
25
+ grid.column :column_name => 'First Name', :attribute_name => 'first_name'
26
+ end
27
+ visit '/users'
28
+ page.should_not have_selector '.asc'
29
+ page.should_not have_selector '.desc'
30
+
31
+ click_link 'First Name'
32
+ page.should have_selector '.asc'
33
+ first_name_column = all('tbody td[1]').map(&:text)
34
+ first_name_column.should == ["aabbcc", "bbccdd", "ccddee"]
35
+
36
+ click_link 'First Name'
37
+ page.should have_selector '.desc'
38
+
39
+ first_name_column = all('tbody td[1]').map(&:text)
40
+ first_name_column.should == ["ccddee", "bbccdd", "aabbcc"]
41
+ end
42
+
43
+ it "should be possible to see String filters and use them" do
44
+ UsersController.columns do |grid|
45
+ grid.column :column_name => 'First Name', :attribute_name => 'first_name'
46
+ end
47
+ visit '/users'
48
+ fill_in "grid[f][first_name]", :with => 'bb'
49
+ visit '/users?grid[f][first_name][v]=bb&grid[f][first_name][n]=bb'
50
+ first_name_column = all('tbody td[1]').map(&:text)
51
+ first_name_column.size.should == 2
52
+ end
53
+
54
+ it "should be possible to see Date filters and use them" do
55
+ UsersController.columns do |grid|
56
+ grid.column :column_name => 'DOB', :attribute_name => 'year'
57
+ end
58
+ visit '/users?grid[f][year][fr]=1985-01-01&grid[f][year][to]=2005-01-01'
59
+ first_name_column = all('tbody td[1]').map(&:text)
60
+ first_name_column.size.should == 2
61
+ end
62
+
63
+ it "should be possible to see Time filters and use them" do
64
+ UsersController.columns do |grid|
65
+ grid.column :column_name => 'Last Login', :attribute_name => 'last_login'
66
+ end
67
+ visit URI.escape('/users?grid[f][last_login][fr]=2010-01-01 01:00&grid[f][last_login][to]=2010-01-03 01:00')
68
+ first_name_column = all('tbody td[1]').map(&:text)
69
+ first_name_column.size.should == 1
70
+ end
71
+
72
+ it "should be possible to see Integer filters and use them" do
73
+ UsersController.columns do |grid|
74
+ grid.column :column_name => 'Computers Number', :attribute_name => 'computers_number'
75
+ end
76
+ visit '/users?grid[f][computers_number][fr]=2&grid[f][computers_number][to]=5'
77
+ first_name_column = all('tbody td[1]').map(&:text)
78
+ first_name_column.size.should == 1
79
+ end
80
+
81
+ it "should be possible to see Boolean filters and use them" do
82
+ UsersController.columns do |grid|
83
+ grid.column :column_name => 'Archived', :attribute_name => 'archived'
84
+ end
85
+ visit '/users?grid[f][archived][]=f'
86
+ first_name_column = all('tbody td[1]').map(&:text)
87
+ first_name_column.size.should == 2
88
+ end
89
+
90
+ it "should be possible to see aggregated association data" do
91
+ UsersController.columns do |grid|
92
+ grid.column :column_name => 'Computers Number' do |user|
93
+ Computer.where(:user_id => user.id).count
94
+ end
95
+ end
96
+ visit '/users'
97
+ first_name_column = all('tbody td[1]').map(&:text)
98
+ first_name_column.map(&:to_i).sum.should == 2
99
+ end
100
+
101
+ end
102
+
103
+ end
104
+
@@ -0,0 +1,71 @@
1
+ require "action_controller/railtie"
2
+ require "active_resource/railtie"
3
+ require 'wice_grid'
4
+
5
+ module Test
6
+ class Application < Rails::Application
7
+ config.secret_token = '84198d9ba8d271b3d95d252b17601cb0f4b18b5a790d0c1d9bcce95e1c03d9d6f615b21b66986a2bf2ea9b5e850e30f09dfbfa9ffa2586b8ce1f5f1a2e4a460d'
8
+ config.public_path = File.join(File.dirname(__FILE__), '/public')
9
+ end
10
+ end
11
+
12
+ class Computer
13
+ include Mongoid::Document
14
+ belongs_to_related :user
15
+ field :name
16
+ end
17
+
18
+ class User
19
+ include Mongoid::Document
20
+
21
+ #identity :type => String
22
+ field :first_name
23
+ field :year, :type => Date
24
+ field :last_login, :type => Time
25
+ field :computers_number, :type => Integer
26
+ field :archived, :type => Boolean
27
+
28
+ def self.merge_conditions(*conditions)
29
+ ""
30
+ end
31
+ end
32
+
33
+ class UsersController < ActionController::Base
34
+
35
+ def self.columns(&block)
36
+ @@define_columns = block
37
+ end
38
+
39
+ def columns(grid)
40
+ @@define_columns.call(grid)
41
+ end
42
+
43
+ def index
44
+ @users_grid = initialize_grid(User)
45
+ render :inline => <<TEMPLATE
46
+
47
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
48
+ <html lang='en_us' xml:lang='en_us' xmlns='http://www.w3.org/1999/xhtml'>
49
+ <head>
50
+ <%= javascript_include_tag "jquery-1.4.2.min" %>
51
+ <%= include_wice_grid_assets %>
52
+ </head>
53
+ <body>
54
+ <%=
55
+ grid(@users_grid) do |g|
56
+ controller.columns(g)
57
+ end
58
+ %>
59
+ </body>
60
+ </html>
61
+ TEMPLATE
62
+ end
63
+ end
64
+
65
+ Test::Application.initialize!
66
+ Test::Application.routes.draw do
67
+ resources :users
68
+ end
69
+
70
+ require 'test/wice_grid_initializer'
71
+
@@ -0,0 +1,19 @@
1
+ lib_dir = File.dirname(__FILE__) + '/../lib'
2
+ $LOAD_PATH.unshift lib_dir unless $LOAD_PATH.include? lib_dir
3
+
4
+ require 'rubygems'
5
+
6
+ gemfile = File.expand_path('Gemfile', __FILE__)
7
+ begin
8
+ ENV['BUNDLE_GEMFILE'] = gemfile
9
+ require 'bundler'
10
+ Bundler.setup
11
+ rescue Bundler::GemNotFound => e
12
+ STDERR.puts e.message
13
+ STDERR.puts "Try running `bundle install`."
14
+ exit!
15
+ end if File.exist?(gemfile)
16
+
17
+ require 'bundler'
18
+ Bundler.require(:default, :test)# if defined?(Bundler)
19
+
@@ -0,0 +1,22 @@
1
+ require File.join(File.dirname(__FILE__), '/require_gems')
2
+ require File.join(File.dirname(__FILE__), '/rails_test_app')
3
+
4
+ require 'capybara'
5
+ require 'capybara/dsl'
6
+ Capybara.app = Rails.application
7
+ Capybara.save_and_open_page_path = File.join(File.dirname(__FILE__), '/public')
8
+
9
+ RSpec.configure do |rspec_config|
10
+ rspec_config.before(:each) do
11
+ Mongoid.configure do |mongoid_config|
12
+ name = "test_wice_grid"
13
+ host = "localhost"
14
+ mongoid_config.master = Mongo::Connection.new.db(name)
15
+ mongoid_config.master.collections.select{ |c| c.name != 'system.indexes' }.each { |c| c.drop }
16
+ end
17
+ end
18
+ end
19
+
20
+ require 'test/blueprint'
21
+
22
+
@@ -0,0 +1,215 @@
1
+ if defined?(Wice::Defaults)
2
+
3
+ Wice::Defaults::JS_FRAMEWORK = :jquery
4
+ # Wice::Defaults::JS_FRAMEWORK = :prototype
5
+
6
+ # Style of the view helper.
7
+ # +false+ is a usual view helper.
8
+ # +true+ will allow to embed erb content in column (cell) definitions.
9
+ Wice::Defaults::ERB_MODE = false
10
+
11
+ # Default number of rows to show per page.
12
+ Wice::Defaults::PER_PAGE = 20
13
+
14
+ # Default order direction
15
+ Wice::Defaults::ORDER_DIRECTION = 'asc'
16
+
17
+ # Default name for a grid. A grid name is the basis for a lot of
18
+ # names including parameter names, DOM IDs, etc
19
+ # The shorter the name is the shorter the request URI will be.
20
+ Wice::Defaults::GRID_NAME = 'grid'
21
+
22
+ # If REUSE_LAST_COLUMN_FOR_FILTER_ICONS is true and the last column doesn't have any filter and column name, it will be used
23
+ # for filter related icons (filter icon, reset icon, show/hide icon), otherwise an additional table column is added.
24
+ Wice::Defaults::REUSE_LAST_COLUMN_FOR_FILTER_ICONS = true
25
+
26
+ Wice::Defaults::SHOW_HIDE_FILTER_ICON = 'icons/grid/page_white_find.png'
27
+
28
+
29
+ # Icon to trigger filtering.
30
+ Wice::Defaults::FILTER_ICON = 'icons/grid/table_refresh.png'
31
+
32
+ # Icon to reset the filter.
33
+ Wice::Defaults::RESET_ICON = "icons/grid/table.png"
34
+
35
+ # Icon to reset the filter.
36
+ Wice::Defaults::TOGGLE_MULTI_SELECT_ICON = "/images/icons/grid/expand.png"
37
+
38
+ # CSV Export icon.
39
+ Wice::Defaults::CSV_EXPORT_ICON = "/images/icons/grid/page_white_excel.png"
40
+
41
+ # Tick-All icon for the action column.
42
+ Wice::Defaults::TICK_ALL_ICON = "/images/icons/grid/tick_all.png"
43
+
44
+ # Untick-All icon for the action column.
45
+ Wice::Defaults::UNTICK_ALL_ICON = "/images/icons/grid/untick_all.png"
46
+
47
+ # The label of the first option of a custom dropdown list meaning 'All items'
48
+ Wice::Defaults::CUSTOM_FILTER_ALL_LABEL = '--'
49
+
50
+
51
+ # Allow switching between a single and multiple selection modes in custom filters (dropdown boxes)
52
+ Wice::Defaults::ALLOW_MULTIPLE_SELECTION = true
53
+
54
+ # Show the upper pagination panel by default or not
55
+ Wice::Defaults::SHOW_UPPER_PAGINATION_PANEL = false
56
+
57
+ # Enabling CSV export by default
58
+ Wice::Defaults::ENABLE_EXPORT_TO_CSV = false
59
+
60
+
61
+ # The strategy when to show the filter.
62
+ # * <tt>:when_filtered</tt> - when the table is the result of filtering
63
+ # * <tt>:always</tt> - show the filter always
64
+ # * <tt>:no</tt> - never show the filter
65
+ Wice::Defaults::SHOW_FILTER = :always
66
+
67
+ # A boolean value specifying if a change in a filter triggers reloading of the grid.
68
+ Wice::Defaults::AUTO_RELOAD = false
69
+
70
+
71
+ # SQL operator used for matching strings in string filters.
72
+ Wice::Defaults::STRING_MATCHING_OPERATOR = 'LIKE'
73
+ # STRING_MATCHING_OPERATOR = 'ILIKE' # Use this for Postgresql case-insensitive matching.
74
+
75
+
76
+ # Defining one string matching operator globally for the whole application turns is not enough
77
+ # when you connect to two databases one of which is MySQL and the other is Postgresql.
78
+ # If the key for an adapter is missing it will fall back to Wice::Defaults::STRING_MATCHING_OPERATOR
79
+ Wice::Defaults::STRING_MATCHING_OPERATORS = {
80
+ 'ActiveRecord::ConnectionAdapters::MysqlAdapter' => 'LIKE',
81
+ 'ActiveRecord::ConnectionAdapters::PostgreSQLAdapter' => 'ILIKE'
82
+ }
83
+
84
+
85
+
86
+ # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
87
+ # Advanced Filters #
88
+
89
+ # Switch of the negation checkbox in all text filters
90
+ Wice::Defaults::NEGATION_IN_STRING_FILTERS = false
91
+
92
+
93
+
94
+ # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
95
+ # Showing All Queries #
96
+
97
+ # Enable or disable showing all queries (non-paginated table)
98
+ Wice::Defaults::ALLOW_SHOWING_ALL_QUERIES = true
99
+
100
+ # If number of all queries is more than this value, the user will be given a warning message
101
+ Wice::Defaults::START_SHOWING_WARNING_FROM = 100
102
+
103
+
104
+ # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
105
+ # Saving Queries #
106
+
107
+ # Icon to delete a saved query
108
+ Wice::Defaults::DELETE_QUERY_ICON = 'icons/grid/delete.png'
109
+
110
+ # ActiveRecord model to store queries. Read the documentation for details
111
+ # QUERY_STORE_MODEL = 'WiceGridSerializedQuery'
112
+ Wice::Defaults::QUERY_STORE_MODEL = 'WiceGridSerializedQuery'
113
+
114
+
115
+ # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
116
+ # Here go settings related to the calendar helpers #
117
+
118
+ # The default style of the date and datetime helper
119
+ # * <tt>:calendar</tt> - JS calendar
120
+ # * <tt>:standard</tt> - standard Rails date and datetime helpers
121
+ Wice::Defaults::HELPER_STYLE = :calendar
122
+
123
+ # Format of the datetime displayed.
124
+ # If you change the format, make sure to check if +DATETIME_PARSER+ can still parse this string.
125
+ Wice::Defaults::DATETIME_FORMAT = "%Y-%m-%d %H:%M"
126
+
127
+ # Format of the date displayed.
128
+ # If you change the format, make sure to check if +DATE_PARSER+ can still parse this string.
129
+ Wice::Defaults::DATE_FORMAT = "%Y-%m-%d"
130
+
131
+ # Format of the date displayed in jQuery's Datepicker
132
+ # If you change the format, make sure to check if +DATE_PARSER+ can still parse this string.
133
+ Wice::Defaults::DATE_FORMAT_JQUERY = "yy-mm-dd"
134
+
135
+
136
+ # With Calendar helpers enabled the parameter sent is the string displayed. This lambda will be given a date string in the
137
+ # format defined by +DATETIME_FORMAT+ and must generate a DateTime object.
138
+ # In many cases <tt>Time.zone.parse</tt> is enough, for instance, <tt>%Y-%m-%d</tt>. If you change the format, make sure to check this code
139
+ # and modify it if needed.
140
+ Wice::Defaults::DATETIME_PARSER = lambda{|datetime_string| Time.zone.parse(datetime_string) }
141
+
142
+ # With Calendar helpers enabled the parameter sent is the string displayed. This lambda will be given a date string in the
143
+ # format defined by +DATETIME+ and must generate a Date object.
144
+ # In many cases <tt>Date.parse</tt> is enough, for instance, <tt>%Y-%m-%d</tt>. If you change the format, make sure to check this code
145
+ # and modify it if needed.
146
+ Wice::Defaults::DATE_PARSER = lambda{|date_string| Date.parse(date_string) }
147
+
148
+ # Icon to popup the calendar.
149
+ Wice::Defaults::CALENDAR_ICON = "/images/icons/grid/calendar_view_month.png"
150
+
151
+ # popup calendar will be shown relative to the popup trigger element or to the mouse pointer
152
+ Wice::Defaults::POPUP_PLACEMENT_STRATEGY = :trigger # :pointer
153
+
154
+ ######## Messages ########
155
+
156
+ Wice::Defaults::SHOW_FILTER_TOOLTIP = 'Show filter'
157
+ Wice::Defaults::HIDE_FILTER_TOOLTIP = 'Hide filter'
158
+ Wice::Defaults::CSV_EXPORT_TOOLTIP = 'Export to CSV'
159
+
160
+ Wice::Defaults::FILTER_TOOLTIP = "Filter"
161
+ Wice::Defaults::RESET_FILTER_TOOLTIP = "Reset"
162
+
163
+ Wice::Defaults::BOOLEAN_FILTER_TRUE_LABEL = 'yes'
164
+ Wice::Defaults::BOOLEAN_FILTER_FALSE_LABEL = 'no'
165
+
166
+ Wice::Defaults::PREVIOUS_LABEL = '&#171; Previous'
167
+ Wice::Defaults::NEXT_LABEL = 'Next &#187;'
168
+
169
+ # Title of the icon clicking on which will show the calendar to set the FROM date.
170
+ Wice::Defaults::DATE_SELECTOR_TOOLTIP_FROM = 'From'
171
+ # Title of the icon clicking on which will show the calendar to set the TO date.
172
+ Wice::Defaults::DATE_SELECTOR_TOOLTIP_TO = 'To'
173
+
174
+ # The title of the checkox to turn on negation
175
+ Wice::Defaults::NEGATION_CHECKBOX_TITLE = 'Exclude'
176
+
177
+ # link to switch to "show all records"
178
+ Wice::Defaults::SHOW_ALL_RECORDS_LABEL = 'show all'
179
+
180
+ # tooltip for the link to switch to "show all records"
181
+ Wice::Defaults::SHOW_ALL_RECORDS_TOOLTIP = 'Show all records'
182
+
183
+ # Warning message shown when the user wants to switch to all-records mode
184
+ Wice::Defaults::ALL_QUERIES_WARNING = 'Are you sure you want to display all records?'
185
+
186
+ # link to paginated view
187
+ Wice::Defaults::SWITCH_BACK_TO_PAGINATED_MODE_LABEL = "back to paginated view"
188
+
189
+ # tooltip for the link to paginated view
190
+ Wice::Defaults::SWITCH_BACK_TO_PAGINATED_MODE_TOOLTIP = "Switch back to the view with pages"
191
+
192
+ # Title of the date string.
193
+ Wice::Defaults::DATE_STRING_TOOLTIP = 'Click to delete'
194
+
195
+
196
+ Wice::Defaults::SAVED_QUERY_PANEL_TITLE = 'Saved Queries'
197
+ Wice::Defaults::SAVE_QUERY_BUTTON_LABEL = 'Save the state of filters'
198
+
199
+ Wice::Defaults::SAVED_QUERY_DELETION_CONFIRMATION = 'Are you sure?'
200
+ Wice::Defaults::SAVED_QUERY_DELETION_LINK_TITLE = 'Delete query'
201
+ Wice::Defaults::SAVED_QUERY_LINK_TITLE = 'Load query'
202
+
203
+ Wice::Defaults::VALIDATES_UNIQUENESS_ERROR = "A query with this name already exists"
204
+ Wice::Defaults::VALIDATES_PRESENCE_ERROR = "Please sumbit the name of the custom query"
205
+
206
+ Wice::Defaults::QUERY_DELETED_MESSAGE = "Saved query deleted."
207
+ Wice::Defaults::QUERY_SAVED_MESSAGE = "Query saved."
208
+
209
+ Wice::Defaults::SELECT_ALL = "Select all"
210
+ Wice::Defaults::DESELECT_ALL = "Remove selection"
211
+
212
+ ######## Messages END ########
213
+
214
+ end
215
+
@@ -5,48 +5,47 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{wice_grid_mongoid}
8
- s.version = "0.5.7"
8
+ s.version = "6.0.3"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Yuri Leikind", "Aleksandr Furmanov"]
12
12
  s.date = %q{2010-11-30}
13
13
  s.description = %q{A Rails grid plugin to create grids with sorting, pagination, and (automatically generated) filters }
14
- s.email = ["yuri.leikind@gmail.com", "aleksandr.furmanov@gmail.com"]
14
+ s.email = %q{aleksandr.furmanov@gmail.com}
15
15
  s.extra_rdoc_files = [
16
16
  "README.rdoc"
17
17
  ]
18
18
  s.files = [
19
19
  ".gitignore",
20
20
  "CHANGELOG",
21
+ "Gemfile",
22
+ "Gemfile.lock",
21
23
  "MIT-LICENSE",
22
24
  "README.rdoc",
23
25
  "Rakefile",
24
26
  "SAVED_QUERIES_HOWTO.rdoc",
25
27
  "VERSION",
26
- "generators/common_templates/icons/arrow_down.gif",
27
- "generators/common_templates/icons/arrow_up.gif",
28
- "generators/common_templates/icons/calendar_view_month.png",
29
- "generators/common_templates/icons/delete.png",
30
- "generators/common_templates/icons/expand.png",
31
- "generators/common_templates/icons/page_white_excel.png",
32
- "generators/common_templates/icons/page_white_find.png",
33
- "generators/common_templates/icons/table.png",
34
- "generators/common_templates/icons/table_refresh.png",
35
- "generators/common_templates/icons/tick_all.png",
36
- "generators/common_templates/icons/untick_all.png",
37
- "generators/common_templates/initializers/wice_grid_config.rb",
38
- "generators/common_templates/locales/wice_grid.yml",
39
- "generators/common_templates/stylesheets/wice_grid.css",
40
- "generators/wice_grid_assets_jquery/templates/USAGE",
41
- "generators/wice_grid_assets_jquery/templates/javascripts/wice_grid_jquery.js",
42
- "generators/wice_grid_assets_jquery/wice_grid_assets_jquery_generator.rb",
43
- "generators/wice_grid_assets_prototype/USAGE",
44
- "generators/wice_grid_assets_prototype/templates/javascripts/calendarview.js",
45
- "generators/wice_grid_assets_prototype/templates/javascripts/wice_grid_prototype.js",
46
- "generators/wice_grid_assets_prototype/templates/stylesheets/calendarview.css",
47
- "generators/wice_grid_assets_prototype/wice_grid_assets_prototype_generator.rb",
48
- "init.rb",
49
- "install.rb",
28
+ "lib/filter_conditions_generators.rb",
29
+ "lib/generators/wice_grid/templates/calendarview.css",
30
+ "lib/generators/wice_grid/templates/calendarview.js",
31
+ "lib/generators/wice_grid/templates/icons/arrow_down.gif",
32
+ "lib/generators/wice_grid/templates/icons/arrow_up.gif",
33
+ "lib/generators/wice_grid/templates/icons/calendar_view_month.png",
34
+ "lib/generators/wice_grid/templates/icons/delete.png",
35
+ "lib/generators/wice_grid/templates/icons/expand.png",
36
+ "lib/generators/wice_grid/templates/icons/page_white_excel.png",
37
+ "lib/generators/wice_grid/templates/icons/page_white_find.png",
38
+ "lib/generators/wice_grid/templates/icons/table.png",
39
+ "lib/generators/wice_grid/templates/icons/table_refresh.png",
40
+ "lib/generators/wice_grid/templates/icons/tick_all.png",
41
+ "lib/generators/wice_grid/templates/icons/untick_all.png",
42
+ "lib/generators/wice_grid/templates/wice_grid.css",
43
+ "lib/generators/wice_grid/templates/wice_grid.yml",
44
+ "lib/generators/wice_grid/templates/wice_grid_config.rb",
45
+ "lib/generators/wice_grid/templates/wice_grid_jquery.js",
46
+ "lib/generators/wice_grid/templates/wice_grid_prototype.js",
47
+ "lib/generators/wice_grid/wice_grid_assets_jquery_generator.rb",
48
+ "lib/generators/wice_grid/wice_grid_assets_prototype_generator.rb",
50
49
  "lib/grid_output_buffer.rb",
51
50
  "lib/grid_renderer.rb",
52
51
  "lib/helpers/js_calendar_helpers.rb",
@@ -56,7 +55,8 @@ Gem::Specification.new do |s|
56
55
  "lib/js_adaptors/jquery_adaptor.rb",
57
56
  "lib/js_adaptors/js_adaptor.rb",
58
57
  "lib/js_adaptors/prototype_adaptor.rb",
59
- "lib/table_column_matrix.rb",
58
+ "lib/mongoid_field.rb",
59
+ "lib/tasks/wice_grid_tasks.rake",
60
60
  "lib/view_columns.rb",
61
61
  "lib/views/create.rjs",
62
62
  "lib/views/delete.rjs",
@@ -67,20 +67,27 @@ Gem::Specification.new do |s|
67
67
  "lib/wice_grid_serialized_queries_controller.rb",
68
68
  "lib/wice_grid_serialized_query.rb",
69
69
  "lib/wice_grid_spreadsheet.rb",
70
- "tasks/wice_grid_tasks.rake",
70
+ "mongoid_wice_grid.gemspec",
71
71
  "test/.gitignore",
72
+ "test/blueprint.rb",
72
73
  "test/database.yml",
74
+ "test/public/javascripts/jquery-1.4.2.min.js",
75
+ "test/public/javascripts/wice_grid.js",
76
+ "test/rails_mongoid_test.rb",
77
+ "test/rails_test_app.rb",
78
+ "test/require_gems.rb",
73
79
  "test/schema.rb",
80
+ "test/spec_helper.rb",
74
81
  "test/test_helper.rb",
75
82
  "test/views/projects_and_people_grid.html.erb",
76
83
  "test/views/projects_and_people_grid_invalid.html.erb",
77
84
  "test/views/simple_projects_grid.html.erb",
78
85
  "test/wice_grid_core_ext_test.rb",
79
86
  "test/wice_grid_functional_test.rb",
87
+ "test/wice_grid_initializer.rb",
80
88
  "test/wice_grid_misc_test.rb",
81
89
  "test/wice_grid_test.rb",
82
90
  "test/wice_grid_view_helper_test.rb",
83
- "uninstall.rb",
84
91
  "wice_grid_mongoid.gemspec"
85
92
  ]
86
93
  s.homepage = %q{http://github.com/afurmanov/wice_grid}
@@ -89,10 +96,16 @@ Gem::Specification.new do |s|
89
96
  s.rubygems_version = %q{1.3.7}
90
97
  s.summary = %q{Rails Grid Plugin}
91
98
  s.test_files = [
92
- "test/schema.rb",
99
+ "test/blueprint.rb",
100
+ "test/rails_mongoid_test.rb",
101
+ "test/rails_test_app.rb",
102
+ "test/require_gems.rb",
103
+ "test/schema.rb",
104
+ "test/spec_helper.rb",
93
105
  "test/test_helper.rb",
94
106
  "test/wice_grid_core_ext_test.rb",
95
107
  "test/wice_grid_functional_test.rb",
108
+ "test/wice_grid_initializer.rb",
96
109
  "test/wice_grid_misc_test.rb",
97
110
  "test/wice_grid_test.rb",
98
111
  "test/wice_grid_view_helper_test.rb"