kadmin 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +44 -44
- data/Rakefile +146 -146
- data/app/assets/javascripts/modular/app.js +1388 -1388
- data/app/assets/javascripts/modular/application.js +3 -3
- data/app/assets/javascripts/modular/vendor.js +57671 -57671
- data/app/assets/stylesheets/kadmin/typeahead-select.scss +2 -0
- data/app/assets/stylesheets/modular/app-blue.css +2795 -2795
- data/app/assets/stylesheets/modular/app-custom.css +2795 -2795
- data/app/assets/stylesheets/modular/app-green.css +2795 -2795
- data/app/assets/stylesheets/modular/app-orange.css +2795 -2795
- data/app/assets/stylesheets/modular/app-purple.css +2795 -2795
- data/app/assets/stylesheets/modular/app-red.css +2795 -2795
- data/app/assets/stylesheets/modular/app-seagreen.css +2795 -2795
- data/app/assets/stylesheets/modular/app.css +2795 -2795
- data/app/assets/stylesheets/modular/custom.css +51 -19
- data/app/assets/stylesheets/modular/vendor.css +12999 -12999
- data/app/controllers/kadmin/application_controller.rb +64 -64
- data/app/controllers/kadmin/auth_controller.rb +98 -98
- data/app/controllers/kadmin/concerns/authorized_user.rb +67 -67
- data/app/controllers/kadmin/dash_controller.rb +19 -19
- data/app/decorators/kadmin/finder_decorator.rb +50 -50
- data/app/decorators/kadmin/pager_decorator.rb +33 -33
- data/app/helpers/kadmin/alert_helper.rb +59 -59
- data/app/helpers/kadmin/application_helper.rb +4 -4
- data/app/helpers/kadmin/bootstrap_helper.rb +23 -23
- data/app/helpers/kadmin/form_builder.rb +9 -9
- data/app/helpers/kadmin/forms/inverted_check_box.rb +10 -10
- data/app/helpers/kadmin/navigation_helper.rb +28 -28
- data/app/helpers/kadmin/pagination_helper.rb +95 -95
- data/app/views/kadmin/auth/login.html.erb +4 -4
- data/app/views/kadmin/components/_finder.html.erb +14 -18
- data/app/views/kadmin/components/finder/_empty.html.erb +3 -3
- data/app/views/kadmin/components/finder/_form.erb +10 -10
- data/app/views/kadmin/components/finder/_header.html.erb +14 -11
- data/app/views/kadmin/dash/index.html.erb +5 -5
- data/app/views/kadmin/error.html.erb +5 -5
- data/app/views/kadmin/helpers/_alerts.html.erb +4 -4
- data/app/views/kadmin/helpers/_form_errors.html.erb +10 -10
- data/app/views/layouts/modular/application.html.erb +134 -132
- data/config/initializers/action_view.rb +2 -2
- data/config/initializers/assets.rb +5 -5
- data/config/locales/de.yml +25 -25
- data/config/locales/en.yml +24 -24
- data/config/routes.rb +12 -12
- data/lib/kadmin.rb +22 -22
- data/lib/kadmin/auth.rb +31 -31
- data/lib/kadmin/auth/configuration.rb +66 -66
- data/lib/kadmin/auth/unauthorized_error.rb +14 -14
- data/lib/kadmin/auth/user.rb +15 -15
- data/lib/kadmin/auth/user_store.rb +21 -21
- data/lib/kadmin/configuration.rb +18 -18
- data/lib/kadmin/engine.rb +15 -15
- data/lib/kadmin/error.rb +7 -7
- data/lib/kadmin/errors/authorization.rb +15 -15
- data/lib/kadmin/finder.rb +66 -66
- data/lib/kadmin/form.rb +179 -179
- data/lib/kadmin/pager.rb +93 -93
- data/lib/kadmin/version.rb +3 -3
- data/test/dummy/README.rdoc +28 -28
- data/test/dummy/Rakefile +6 -6
- data/test/dummy/app/assets/javascripts/application.js +13 -13
- data/test/dummy/app/assets/stylesheets/application.css +15 -15
- data/test/dummy/app/controllers/admin/application_controller.rb +11 -11
- data/test/dummy/app/controllers/admin/people_controller.rb +89 -89
- data/test/dummy/app/controllers/admin_controller.rb +4 -4
- data/test/dummy/app/controllers/application_controller.rb +5 -5
- data/test/dummy/app/controllers/authorized_controller.rb +8 -8
- data/test/dummy/app/helpers/application_helper.rb +2 -2
- data/test/dummy/app/models/group.rb +8 -8
- data/test/dummy/app/models/group_person.rb +6 -6
- data/test/dummy/app/models/person.rb +20 -20
- data/test/dummy/app/views/admin/index.html.erb +1 -1
- data/test/dummy/app/views/admin/people/_form.html.erb +34 -34
- data/test/dummy/app/views/admin/people/_table.html.erb +33 -33
- data/test/dummy/app/views/admin/people/edit.html.erb +4 -4
- data/test/dummy/app/views/admin/people/index.html.erb +3 -3
- data/test/dummy/app/views/admin/people/new.html.erb +5 -5
- data/test/dummy/app/views/admin/people/show.html.erb +3 -3
- data/test/dummy/app/views/authorized/index.html.erb +1 -1
- data/test/dummy/app/views/layouts/application.html.erb +14 -14
- data/test/dummy/bin/bundle +3 -3
- data/test/dummy/bin/rails +4 -4
- data/test/dummy/bin/rake +4 -4
- data/test/dummy/bin/setup +29 -29
- data/test/dummy/config.ru +4 -4
- data/test/dummy/config/application.rb +39 -39
- data/test/dummy/config/boot.rb +5 -5
- data/test/dummy/config/database.yml +22 -22
- data/test/dummy/config/environment.rb +5 -5
- data/test/dummy/config/environments/development.rb +41 -41
- data/test/dummy/config/environments/production.rb +79 -79
- data/test/dummy/config/environments/test.rb +42 -42
- data/test/dummy/config/initializers/assets.rb +10 -10
- data/test/dummy/config/initializers/backtrace_silencers.rb +7 -7
- data/test/dummy/config/initializers/cookies_serializer.rb +3 -3
- data/test/dummy/config/initializers/filter_parameter_logging.rb +4 -4
- data/test/dummy/config/initializers/inflections.rb +16 -16
- data/test/dummy/config/initializers/kadmin.rb +24 -24
- data/test/dummy/config/initializers/mime_types.rb +4 -4
- data/test/dummy/config/initializers/session_store.rb +3 -3
- data/test/dummy/config/initializers/wrap_parameters.rb +14 -14
- data/test/dummy/config/locales/en.yml +17 -17
- data/test/dummy/config/routes.rb +13 -13
- data/test/dummy/config/secrets.yml +22 -22
- data/test/dummy/db/migrate/20161006114509_create_people.rb +11 -11
- data/test/dummy/db/migrate/20161006134459_create_groups.rb +11 -11
- data/test/dummy/db/migrate/20161006134746_create_group_people.rb +11 -11
- data/test/dummy/db/schema.rb +43 -43
- data/test/dummy/lib/forms/group_form.rb +16 -16
- data/test/dummy/lib/forms/person_form.rb +19 -19
- data/test/dummy/public/404.html +67 -67
- data/test/dummy/public/422.html +67 -67
- data/test/dummy/public/500.html +66 -66
- data/test/dummy/test/fixtures/children.yml +11 -11
- data/test/dummy/test/fixtures/group_people.yml +11 -11
- data/test/dummy/test/fixtures/groups.yml +11 -11
- data/test/dummy/test/fixtures/people.yml +11 -11
- data/test/dummy/test/models/group_person_test.rb +7 -7
- data/test/dummy/test/models/group_test.rb +7 -7
- data/test/kadmin/form_test.rb +6 -6
- data/test/test_helper.rb +32 -32
- metadata +54 -53
@@ -1,11 +1,11 @@
|
|
1
|
-
# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
|
2
|
-
|
3
|
-
# This model initially had no columns defined. If you add columns to the
|
4
|
-
# model remove the '{}' from the fixture names and add the columns immediately
|
5
|
-
# below each fixture, per the syntax in the comments below
|
6
|
-
#
|
7
|
-
one: {}
|
8
|
-
# column: value
|
9
|
-
#
|
10
|
-
two: {}
|
11
|
-
# column: value
|
1
|
+
# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
|
2
|
+
|
3
|
+
# This model initially had no columns defined. If you add columns to the
|
4
|
+
# model remove the '{}' from the fixture names and add the columns immediately
|
5
|
+
# below each fixture, per the syntax in the comments below
|
6
|
+
#
|
7
|
+
one: {}
|
8
|
+
# column: value
|
9
|
+
#
|
10
|
+
two: {}
|
11
|
+
# column: value
|
@@ -1,7 +1,7 @@
|
|
1
|
-
require 'test_helper'
|
2
|
-
|
3
|
-
class GroupPersonTest < ActiveSupport::TestCase
|
4
|
-
# test "the truth" do
|
5
|
-
# assert true
|
6
|
-
# end
|
7
|
-
end
|
1
|
+
require 'test_helper'
|
2
|
+
|
3
|
+
class GroupPersonTest < ActiveSupport::TestCase
|
4
|
+
# test "the truth" do
|
5
|
+
# assert true
|
6
|
+
# end
|
7
|
+
end
|
@@ -1,7 +1,7 @@
|
|
1
|
-
require 'test_helper'
|
2
|
-
|
3
|
-
class GroupTest < ActiveSupport::TestCase
|
4
|
-
# test "the truth" do
|
5
|
-
# assert true
|
6
|
-
# end
|
7
|
-
end
|
1
|
+
require 'test_helper'
|
2
|
+
|
3
|
+
class GroupTest < ActiveSupport::TestCase
|
4
|
+
# test "the truth" do
|
5
|
+
# assert true
|
6
|
+
# end
|
7
|
+
end
|
data/test/kadmin/form_test.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
require 'test_helper'
|
2
|
-
|
3
|
-
module Kadmin
|
4
|
-
class FormTest < ActiveSupport::TestCase
|
5
|
-
end
|
6
|
-
end
|
1
|
+
require 'test_helper'
|
2
|
+
|
3
|
+
module Kadmin
|
4
|
+
class FormTest < ActiveSupport::TestCase
|
5
|
+
end
|
6
|
+
end
|
data/test/test_helper.rb
CHANGED
@@ -1,32 +1,32 @@
|
|
1
|
-
# Configure Rails Environment
|
2
|
-
ENV['RAILS_ENV'] = 'test'
|
3
|
-
$VERBOSE = false
|
4
|
-
|
5
|
-
# SimpleCov setup
|
6
|
-
require 'simplecov'
|
7
|
-
require 'simplecov-cobertura'
|
8
|
-
require 'simplecov-formatter-shield'
|
9
|
-
SimpleCov::Formatter::ShieldFormatter.filename = 'kadmin-shield.png'.freeze
|
10
|
-
SimpleCov.formatters = [SimpleCov::Formatter::CoberturaFormatter, SimpleCov::Formatter::ShieldFormatter]
|
11
|
-
SimpleCov.start
|
12
|
-
|
13
|
-
# Rails setup
|
14
|
-
require File.expand_path('../../test/dummy/config/environment.rb', __FILE__)
|
15
|
-
ActiveRecord::Migrator.migrations_paths = [File.expand_path('../../test/dummy/db/migrate', __FILE__)]
|
16
|
-
ActiveRecord::Migrator.migrations_paths << File.expand_path('../../db/migrate', __FILE__)
|
17
|
-
require 'rails/test_help'
|
18
|
-
|
19
|
-
# Setup Minitest
|
20
|
-
require 'minitest/reporters'
|
21
|
-
Minitest.backtrace_filter = Minitest::BacktraceFilter.new
|
22
|
-
Minitest::Reporters.use!([Minitest::Reporters::ProgressReporter.new, Minitest::Reporters::JUnitReporter.new], ENV,
|
23
|
-
Minitest.backtrace_filter)
|
24
|
-
|
25
|
-
# Load support files
|
26
|
-
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }
|
27
|
-
|
28
|
-
# Setup Flexmock
|
29
|
-
require 'flexmock/minitest'
|
30
|
-
|
31
|
-
# Load Kadmin
|
32
|
-
require 'kadmin'
|
1
|
+
# Configure Rails Environment
|
2
|
+
ENV['RAILS_ENV'] = 'test'
|
3
|
+
$VERBOSE = false
|
4
|
+
|
5
|
+
# SimpleCov setup
|
6
|
+
require 'simplecov'
|
7
|
+
require 'simplecov-cobertura'
|
8
|
+
require 'simplecov-formatter-shield'
|
9
|
+
SimpleCov::Formatter::ShieldFormatter.filename = 'kadmin-shield.png'.freeze
|
10
|
+
SimpleCov.formatters = [SimpleCov::Formatter::CoberturaFormatter, SimpleCov::Formatter::ShieldFormatter]
|
11
|
+
SimpleCov.start
|
12
|
+
|
13
|
+
# Rails setup
|
14
|
+
require File.expand_path('../../test/dummy/config/environment.rb', __FILE__)
|
15
|
+
ActiveRecord::Migrator.migrations_paths = [File.expand_path('../../test/dummy/db/migrate', __FILE__)]
|
16
|
+
ActiveRecord::Migrator.migrations_paths << File.expand_path('../../db/migrate', __FILE__)
|
17
|
+
require 'rails/test_help'
|
18
|
+
|
19
|
+
# Setup Minitest
|
20
|
+
require 'minitest/reporters'
|
21
|
+
Minitest.backtrace_filter = Minitest::BacktraceFilter.new
|
22
|
+
Minitest::Reporters.use!([Minitest::Reporters::ProgressReporter.new, Minitest::Reporters::JUnitReporter.new], ENV,
|
23
|
+
Minitest.backtrace_filter)
|
24
|
+
|
25
|
+
# Load support files
|
26
|
+
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }
|
27
|
+
|
28
|
+
# Setup Flexmock
|
29
|
+
require 'flexmock/minitest'
|
30
|
+
|
31
|
+
# Load Kadmin
|
32
|
+
require 'kadmin'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kadmin
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nicolas Pepin-Perreault
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2016-11-
|
13
|
+
date: 2016-11-10 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: rails
|
@@ -113,6 +113,7 @@ files:
|
|
113
113
|
- app/assets/javascripts/modular/application.js
|
114
114
|
- app/assets/javascripts/modular/custom.js
|
115
115
|
- app/assets/javascripts/modular/vendor.js
|
116
|
+
- app/assets/stylesheets/kadmin/typeahead-select.scss
|
116
117
|
- app/assets/stylesheets/modular/app-blue.css
|
117
118
|
- app/assets/stylesheets/modular/app-custom.css
|
118
119
|
- app/assets/stylesheets/modular/app-green.css
|
@@ -255,68 +256,68 @@ signing_key:
|
|
255
256
|
specification_version: 4
|
256
257
|
summary: Collection of utility, configuration, etc., for admin areas
|
257
258
|
test_files:
|
258
|
-
- test/
|
259
|
-
- test/dummy/
|
259
|
+
- test/test_helper.rb
|
260
|
+
- test/dummy/config.ru
|
261
|
+
- test/dummy/bin/rake
|
262
|
+
- test/dummy/bin/setup
|
263
|
+
- test/dummy/bin/bundle
|
264
|
+
- test/dummy/bin/rails
|
265
|
+
- test/dummy/public/404.html
|
266
|
+
- test/dummy/public/favicon.ico
|
267
|
+
- test/dummy/public/422.html
|
268
|
+
- test/dummy/public/500.html
|
269
|
+
- test/dummy/Rakefile
|
270
|
+
- test/dummy/app/controllers/authorized_controller.rb
|
271
|
+
- test/dummy/app/controllers/application_controller.rb
|
272
|
+
- test/dummy/app/controllers/admin_controller.rb
|
273
|
+
- test/dummy/app/controllers/admin/people_controller.rb
|
260
274
|
- test/dummy/app/controllers/admin/application_controller.rb
|
261
275
|
- test/dummy/app/controllers/admin/groups_controller.rb
|
262
|
-
- test/dummy/app/
|
263
|
-
- test/dummy/app/
|
264
|
-
- test/dummy/app/controllers/application_controller.rb
|
265
|
-
- test/dummy/app/controllers/authorized_controller.rb
|
266
|
-
- test/dummy/app/helpers/application_helper.rb
|
267
|
-
- test/dummy/app/models/group.rb
|
276
|
+
- test/dummy/app/assets/stylesheets/application.css
|
277
|
+
- test/dummy/app/assets/javascripts/application.js
|
268
278
|
- test/dummy/app/models/group_person.rb
|
279
|
+
- test/dummy/app/models/group.rb
|
269
280
|
- test/dummy/app/models/person.rb
|
281
|
+
- test/dummy/app/helpers/application_helper.rb
|
282
|
+
- test/dummy/app/views/authorized/index.html.erb
|
283
|
+
- test/dummy/app/views/layouts/application.html.erb
|
270
284
|
- test/dummy/app/views/admin/index.html.erb
|
271
|
-
- test/dummy/app/views/admin/people/_form.html.erb
|
272
|
-
- test/dummy/app/views/admin/people/_table.html.erb
|
273
|
-
- test/dummy/app/views/admin/people/edit.html.erb
|
274
285
|
- test/dummy/app/views/admin/people/index.html.erb
|
286
|
+
- test/dummy/app/views/admin/people/_form.html.erb
|
275
287
|
- test/dummy/app/views/admin/people/new.html.erb
|
288
|
+
- test/dummy/app/views/admin/people/edit.html.erb
|
289
|
+
- test/dummy/app/views/admin/people/_table.html.erb
|
276
290
|
- test/dummy/app/views/admin/people/show.html.erb
|
277
|
-
- test/dummy/
|
278
|
-
- test/dummy/
|
279
|
-
- test/dummy/
|
280
|
-
- test/dummy/
|
281
|
-
- test/dummy/
|
282
|
-
- test/dummy/
|
283
|
-
- test/dummy/
|
284
|
-
- test/dummy/config/boot.rb
|
285
|
-
- test/dummy/config/database.yml
|
286
|
-
- test/dummy/config/environment.rb
|
287
|
-
- test/dummy/config/environments/development.rb
|
288
|
-
- test/dummy/config/environments/production.rb
|
289
|
-
- test/dummy/config/environments/test.rb
|
290
|
-
- test/dummy/config/initializers/assets.rb
|
291
|
-
- test/dummy/config/initializers/backtrace_silencers.rb
|
292
|
-
- test/dummy/config/initializers/cookies_serializer.rb
|
293
|
-
- test/dummy/config/initializers/filter_parameter_logging.rb
|
294
|
-
- test/dummy/config/initializers/inflections.rb
|
295
|
-
- test/dummy/config/initializers/kadmin.rb
|
296
|
-
- test/dummy/config/initializers/mime_types.rb
|
297
|
-
- test/dummy/config/initializers/session_store.rb
|
298
|
-
- test/dummy/config/initializers/wrap_parameters.rb
|
299
|
-
- test/dummy/config/locales/en.yml
|
300
|
-
- test/dummy/config/routes.rb
|
301
|
-
- test/dummy/config/secrets.yml
|
302
|
-
- test/dummy/config.ru
|
303
|
-
- test/dummy/db/migrate/20161006114509_create_people.rb
|
291
|
+
- test/dummy/test/models/group_person_test.rb
|
292
|
+
- test/dummy/test/models/group_test.rb
|
293
|
+
- test/dummy/test/fixtures/people.yml
|
294
|
+
- test/dummy/test/fixtures/children.yml
|
295
|
+
- test/dummy/test/fixtures/groups.yml
|
296
|
+
- test/dummy/test/fixtures/group_people.yml
|
297
|
+
- test/dummy/db/schema.rb
|
304
298
|
- test/dummy/db/migrate/20161006134459_create_groups.rb
|
299
|
+
- test/dummy/db/migrate/20161006114509_create_people.rb
|
305
300
|
- test/dummy/db/migrate/20161006134746_create_group_people.rb
|
306
|
-
- test/dummy/db/schema.rb
|
307
301
|
- test/dummy/lib/forms/group_form.rb
|
308
302
|
- test/dummy/lib/forms/person_form.rb
|
309
|
-
- test/dummy/public/404.html
|
310
|
-
- test/dummy/public/422.html
|
311
|
-
- test/dummy/public/500.html
|
312
|
-
- test/dummy/public/favicon.ico
|
313
|
-
- test/dummy/Rakefile
|
314
303
|
- test/dummy/README.rdoc
|
315
|
-
- test/dummy/
|
316
|
-
- test/dummy/
|
317
|
-
- test/dummy/
|
318
|
-
- test/dummy/
|
319
|
-
- test/dummy/
|
320
|
-
- test/dummy/
|
304
|
+
- test/dummy/config/initializers/session_store.rb
|
305
|
+
- test/dummy/config/initializers/kadmin.rb
|
306
|
+
- test/dummy/config/initializers/mime_types.rb
|
307
|
+
- test/dummy/config/initializers/inflections.rb
|
308
|
+
- test/dummy/config/initializers/filter_parameter_logging.rb
|
309
|
+
- test/dummy/config/initializers/assets.rb
|
310
|
+
- test/dummy/config/initializers/backtrace_silencers.rb
|
311
|
+
- test/dummy/config/initializers/wrap_parameters.rb
|
312
|
+
- test/dummy/config/initializers/cookies_serializer.rb
|
313
|
+
- test/dummy/config/routes.rb
|
314
|
+
- test/dummy/config/boot.rb
|
315
|
+
- test/dummy/config/environment.rb
|
316
|
+
- test/dummy/config/database.yml
|
317
|
+
- test/dummy/config/locales/en.yml
|
318
|
+
- test/dummy/config/secrets.yml
|
319
|
+
- test/dummy/config/application.rb
|
320
|
+
- test/dummy/config/environments/test.rb
|
321
|
+
- test/dummy/config/environments/development.rb
|
322
|
+
- test/dummy/config/environments/production.rb
|
321
323
|
- test/kadmin/form_test.rb
|
322
|
-
- test/test_helper.rb
|