outpost-cms 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/README.md +19 -1
- data/Rakefile +0 -12
- data/app/assets/javascripts/outpost.js +1 -1
- data/app/assets/javascripts/outpost/auto_slug_field.js.coffee +6 -6
- data/app/assets/javascripts/outpost/date_time_input.js.coffee +13 -13
- data/app/assets/javascripts/outpost/field_counter.js.coffee +15 -15
- data/app/assets/javascripts/outpost/field_manager.js.coffee +3 -3
- data/app/assets/javascripts/outpost/global_plugins.js.coffee +16 -19
- data/app/assets/javascripts/outpost/index_manager.js.coffee +12 -12
- data/app/assets/javascripts/outpost/notification.js.coffee +33 -11
- data/app/assets/javascripts/outpost/preview.js.coffee +4 -4
- data/app/assets/javascripts/outpost/utilities.js.coffee +13 -0
- data/app/assets/stylesheets/outpost/_base.css.scss +9 -9
- data/app/assets/stylesheets/outpost/_forms.css.scss +28 -15
- data/app/assets/stylesheets/outpost/_index.css.scss +2 -2
- data/app/assets/stylesheets/outpost/_utility.css.scss +1 -1
- data/app/controllers/outpost/application_controller.rb +5 -3
- data/app/controllers/outpost/errors_controller.rb +2 -1
- data/app/controllers/outpost/resource_controller.rb +1 -1
- data/app/controllers/outpost/sessions_controller.rb +10 -5
- data/app/helpers/authorization_helper.rb +3 -3
- data/app/helpers/list_helper.rb +72 -49
- data/app/helpers/outpost_helper.rb +4 -4
- data/app/helpers/render_helper.rb +5 -5
- data/app/helpers/utility_helper.rb +5 -5
- data/app/models/permission.rb +8 -5
- data/app/views/layouts/outpost/application.html.erb +7 -7
- data/app/views/layouts/outpost/minimal.html.erb +1 -1
- data/app/views/outpost/errors/error_500.html.erb +1 -1
- data/app/views/outpost/resource/_errors.html.erb +2 -11
- data/app/views/outpost/resource/edit.html.erb +8 -4
- data/app/views/outpost/resource/new.html.erb +5 -1
- data/app/views/outpost/sessions/new.html.erb +1 -1
- data/app/views/outpost/shared/_filters.html.erb +2 -2
- data/app/views/outpost/shared/_form_block.html.erb +2 -2
- data/app/views/outpost/shared/_form_nav.html.erb +1 -1
- data/app/views/outpost/shared/_full_errors.html.erb +9 -0
- data/app/views/outpost/shared/_headers.html.erb +4 -4
- data/app/views/outpost/shared/_navigation.html.erb +4 -4
- data/app/views/outpost/shared/_submit_row.html.erb +5 -5
- data/lib/action_view/helpers/form_builder.rb +28 -16
- data/lib/outpost.rb +8 -5
- data/lib/outpost/breadcrumbs.rb +13 -11
- data/lib/outpost/config.rb +6 -6
- data/lib/outpost/controller.rb +8 -2
- data/lib/outpost/controller/actions.rb +3 -3
- data/lib/outpost/controller/authentication.rb +2 -1
- data/lib/outpost/controller/authorization.rb +3 -2
- data/lib/outpost/controller/callbacks.rb +2 -1
- data/lib/outpost/controller/custom_errors.rb +44 -13
- data/lib/outpost/controller/helpers.rb +1 -29
- data/lib/outpost/controller/ordering.rb +59 -16
- data/lib/outpost/controller/preferences.rb +3 -3
- data/lib/outpost/helpers/naming.rb +2 -2
- data/lib/outpost/hook.rb +5 -5
- data/lib/outpost/list.rb +3 -3
- data/lib/outpost/list/base.rb +23 -13
- data/lib/outpost/list/column.rb +13 -4
- data/lib/outpost/list/filter.rb +4 -4
- data/lib/outpost/model.rb +2 -2
- data/lib/outpost/model/authentication.rb +6 -2
- data/lib/outpost/model/authorization.rb +1 -2
- data/lib/outpost/model/identifier.rb +15 -10
- data/lib/outpost/model/methods.rb +2 -2
- data/lib/outpost/model/naming.rb +10 -7
- data/lib/outpost/model/routing.rb +6 -6
- data/lib/outpost/model/serializer.rb +3 -3
- data/lib/outpost/version.rb +1 -1
- data/spec/controllers/authentication_spec.rb +10 -10
- data/spec/controllers/sessions_controller_spec.rb +17 -17
- data/spec/factories.rb +1 -1
- data/spec/features/authentication_spec.rb +43 -0
- data/spec/features/authorization_spec.rb +28 -0
- data/spec/features/creating_spec.rb +44 -0
- data/spec/features/destroying_spec.rb +18 -0
- data/spec/features/editing_spec.rb +43 -0
- data/spec/features/save_options_spec.rb +35 -0
- data/spec/helpers/authorization_helper_spec.rb +8 -8
- data/spec/helpers/list_helper_spec.rb +34 -0
- data/spec/helpers/render_helper_spec.rb +1 -1
- data/spec/helpers/utility_helper_spec.rb +10 -10
- data/spec/internal/app/controllers/outpost/people_controller.rb +3 -3
- data/spec/internal/app/models/person.rb +3 -0
- data/spec/internal/config/routes.rb +1 -1
- data/spec/internal/db/combustion_test.sqlite +0 -0
- data/spec/internal/log/test.log +35260 -53251
- data/spec/internal/tmp/cache/assets/test/sass/20f5650af539e2cc0c7216330842920da53e851d/bootstrap.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/20f5650af539e2cc0c7216330842920da53e851d/datepicker.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_alerts.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_breadcrumbs.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_button-groups.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_buttons.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_close.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_code.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_component-animations.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_dropdowns.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_forms.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_grid.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_labels-badges.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_layouts.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_mixins.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_modals.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_navbar.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_navs.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_pager.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_pagination.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_reset.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_scaffolding.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_sprites.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_tables.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_type.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_utilities.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_variables.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/4867dc0a3f589a0a2c9635bfeae1ddc8691d74a0/_wells.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/56c521c2866fc194cbbf1ead1ad9e7d727f5e7b3/select2.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/87aa0c8b43c5e29ce88dd86b1a2c657232e4bb6f/outpost.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cde194af3b19eae3aef82845ab8bc0df6c0d84d4/select2.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_alerts.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_breadcrumbs.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_button-groups.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_buttons.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_close.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_code.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_component-animations.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_dropdowns.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_forms.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_grid.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_labels-badges.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_layouts.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_mixins.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_modals.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_navbar.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_navs.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_pager.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_pagination.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_reset.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_scaffolding.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_sprites.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_tables.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_type.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_utilities.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_variables.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/cee3b45c60038923cb15e74edf0b508296df0b89/_wells.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_alerts.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_breadcrumbs.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_button-groups.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_buttons.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_close.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_code.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_component-animations.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_dropdowns.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_forms.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_grid.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_labels-badges.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_layouts.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_mixins.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_modals.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_navbar.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_navs.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_pager.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_pagination.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_reset.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_scaffolding.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_sprites.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_tables.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_type.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_utilities.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_variables.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/db455d3ae1e484fbc281e7097adf4ecb850d7d10/_wells.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/e1eb86f6478445881765984079761fb4af85ab4e/select2.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/ea24470654f74c1fe92aa45b2fae66b2a464a390/_base.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/ea24470654f74c1fe92aa45b2fae66b2a464a390/_edit.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/ea24470654f74c1fe92aa45b2fae66b2a464a390/_forms.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/ea24470654f74c1fe92aa45b2fae66b2a464a390/_index.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/ea24470654f74c1fe92aa45b2fae66b2a464a390/_utility.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/ea24470654f74c1fe92aa45b2fae66b2a464a390/application.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/ea24470654f74c1fe92aa45b2fae66b2a464a390/outpost.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sass/ea24470654f74c1fe92aa45b2fae66b2a464a390/select2.css.scssc +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/00154e1fc60e5765eb3704d402af06d1 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/0122e4f8c5576de5137307df7d6163a0 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/016db564806ffd72c90385066f2d1526 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/0185dbaba82d3fbc0fd9d2383dc7338d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/01a8e4b866eb7fc8ea5ed3941f1b1877 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/02713d4140ec033db3e897e7597c2096 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/0377ae38f0ab4fa7131b364012d9a4fa +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/04effed13eef407140fbe39b6efae4b2 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/086d226e30e05ea260b6d01a4fbd8a29 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/0a032a3ea9ed2f90e27e350839fcc8dc +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/0bc810339d0afdbe60e338e0041023cc +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/0e167df01ba09061de9f5c49cfdccc99 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/0e69140d2c49ad3bd2a53e1a61ca911f +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/15a87828df71925cca15a55b77afcf64 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/19b0f301c27628308ff1f81a322fcaa9 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/1b718773e74da99a05a30cc200c74d2b +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/1d2a3ed3a5ee7d864dccd4feb0298858 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/1dfbb70993a8817b5e5aee44b888309d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/1e397e58ea65aa807232e81ba0646007 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/1e85a069dc1fa2fd3a325dd73115819a +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/1fa01b5b6a31a3380b9f7926508624cb +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/21f2bd9f5281712ad2d8c772fd407505 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/235664cdcf9cd81bf6a89a09e1e5711a +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/23643a6f2a1f5c182681eca82a12b3b5 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/25f2c3cb96afc04742cb792a8adf703a +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/26ad3186c36f3514d1028fb00180ed9c +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/271f465e2ee560eee64005efa04346de +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/29a5c683744eb88ed1292f59cd6063c9 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/2bb02e7009e6fec07e0ed0d01a1cf997 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/2cb954dcae3aa6f587625543070feb84 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/2f2c37a813522cd1889d2ebdfb2d2a66 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/316c469209d39a7bdac5c11828cf8d74 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/31be2b6ebd86190dc1ec80ce5f0833c5 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/36372f01bbdb43b410ec5192f7b6902f +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/3717c6d6d1b1afd049b633417ed63cdd +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/37abf1a201cc821dfc13cc427659a47b +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/38341483f58eeea1d871954dbe986267 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/38aa3f8364fc8f118029ff4651c72221 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/3e5a01607dc58566739854e9f3ce5024 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/3f1c054c86b6510099f8e6c5dfe7ff3a +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/3f744831928042565f7903a46a39791c +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/3fadb5164d4b3caf81ef217fcde0d142 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/44020d882ece5491178ab3560f0d47a6 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/450ba61c4dc9c4cfa9f7efa5c9bba83d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/4543f412f8a876cd357e5888a4453e5d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/4a0eb5dbdb969be5257139300ae901a9 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/4ad30c03a35f4b46291c9c6331c43567 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/4c55f0b46f9bfc697010c07487d932e1 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/4d5649fe189b1fdead6428fdd2b9fafd +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/4d779cbf3db6f14b3e022a5e5758d72d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/4ed642ba978ceb9502349fa8e6676440 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/4f6d52d657e0c1e635762f3edc6e8e20 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/50ae0bcf805250caf4ae4c4e01deebc9 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/53fc0263b1ce55a46ed55c461a2a8696 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/53fee1ff706022963c15ff24d5c53b54 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/54746a8bf1cdccbce2a3cfb4af05aef8 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/595ad1f5b58343141474f9211039df61 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/5c8c03be6364f23b4008487f351afa73 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/5d1e25ab219593639db982c901882c0f +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/5d676e2352411dd3f05c6cee14727d1c +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/5e2716f68ca78a5c0c83b157db90fc0d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/5e3f572f31041a301e0891c10f04604c +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/620148b9ab753da9e8644581b619731b +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/6471408d963e9165f8831b4bab80edd9 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/64a8cb638857a130dbabae4d1633618e +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/6503f1ef9797aafce9339deb9200cfca +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/6519463c3d8d8a34d743ef38eff5df45 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/656b07036edb74305c343f41eba55695 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/6571b577767caea14c3b89201d0643a2 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/6748f4abf46d0d2f516279ec032fd817 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/67a11a42996d51802481c92dc09c83fa +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/6873baccb9ed57b839e83cfb93738955 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/6b9d79602e3b6ff9dd067605adeb0888 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/6c3df81c5fb88b555bafde4f54db7db2 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/6c62bea96eebf0f05624a859e8666f9a +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/6cecd8ec655b80ac006bbec236b4263b +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/700c635c138594de7ac50ad4b0420a0f +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/70de8c6638b3ad61a4125dfb42e41f5b +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/72a7339f697b2dcde9bd4835eaa42642 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/756eb63f1239c0a7a3d85253ddb5ca0d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/76e213ff5da12faa448078def3d32db5 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/76e3360cc08985753a1273cd40c3084a +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/78f9aaf7b4a1253db9bdb2f2301a9b7d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/7ba5aaf62125e0b56d9e46603f5f8601 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/7e0d7eb383740100156a527b9e26d659 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/7e297a13578eea5ae51d5abb3be9df18 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/81670753eb8197bb1b9ca4d5a66a6fc5 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/896416332cf9f3e34262e6241b8237ef +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/8b99288467087dc247c025d41444f377 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/8c123b8d3cc73220c5b69f99d2168389 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/8c5dcc180f78ee4957d754df726e2248 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/8e6315300501d34a896b82c0c0ceb70c +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/90d6924223f69e10833fa8ef351e35ab +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9117ec941398c9b1340aa0b170ab2dc7 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/91d56ecde1551ea73ef462a44b77f650 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9676f39584b5a04f92b29c0729175a8c +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9788c645f0c65ea7466be1dc13f64eea +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9add31bfd5f6aaa920af7f38211f9aa2 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9b08bbf9ae722116682b8e22cb38c2ec +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9bc5469fea2a4926d4744c370bae613a +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9c1b3e8d4f1bab87ed819b82da42f535 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9c736faedfe2dfe359042f9d2ce85367 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9cf76f5ce68332b0f67c2f3b896a3475 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9d484a2e742210fa6bc8be543c6331b9 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/9dd86c42f919be9f13a14317e7607f31 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/a0743c695fe7f2f40fc5f188fd054c2b +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/a0b5c6371ce0b3308fc3be90c4f9ef5b +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/a1e23f12c8163631dc3a2a98efd393a1 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/a2668b2b36e10c17a0a37e15af1adf92 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/a2d1f22b3a5164f8bdf8a2e08456d9c3 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/a458e44cf710f6e94208e22d3eafae3f +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/a79a727e3b12ecb263735a8edecc86c2 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/aaa6c30950f43b707d50ee44229c1d0f +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ac25c69ce48ecf3a3a3808ba26537243 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/acb56c1b241b90a3a8694a04d7724e7d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ad5315bf4cd3b8c4d38f662ef41c44d0 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/b0e1d9e51dba635c57573102d479dea9 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/b1a78635932522eb99a619b6e190b898 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/b236b354a0e5045c17b85a70f66e612d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/b2a3274db2081478a289f8eeee8370c7 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/b49f83c898ca822909d8d2c32470cfec +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/b4c4d53c35d932c2b28bcefa990ec7fc +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/b6f987547de2c90ebc0413d3263b87e8 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/b832658770b677e87a9d095ed3a87c47 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/b9d76e389aeda53d2f9cc256f75e303b +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/bad56ba50db6ed97894b003103289ffe +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/bb4e55b9b1a8a3bb8a8f0a10d4c6b074 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/bc8ba0b8c4f10524a604a7163f16e3dd +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/bdfb9045b2f813ac4397c5cf0487f840 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/bf20d01df22f01e0fd66116d0ce58969 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/bf6fcb4c8c96d5406899b48c688e17a2 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c0291860b6abb7bdc04ccc1e990e38f0 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c1195a7d9d0e930545cda22ad40b0a9c +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c13a23e52c9d1956c61fb8540bfff8ef +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c1aa6b16696817c61530071b80c0cd43 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c3954ed4f5e4dced91ee1240e4f90a05 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c56fce185c88af8d191796b0172f498b +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c698133fe56541139a2f0d883ca07936 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c7fcb613d0a346398fdf7a3a6ee722a1 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c811799e9db5c939aab1e8e394df3b64 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c9a027b847d199e99825ea85000303cf +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c9f12fd289b0f7e670ede1eeb8d3c24c +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/c9f83bead35bd9bb5c671e327174c526 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/cb6a30f2c5219f77229df845e426ea71 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/cbbd567516b06004eb748f5a59bc14cc +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/cbf827028b6168652324eb60180e21bd +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/cc6766435593a06fcc9193244ea952a0 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ccf22a7e27ed81a71d47f42a7cdb8e0e +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/cd7d618755faec87f9c5cf47c6ae3365 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/cded6947b5642cfe05ffecc7a33ba54f +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/d3638dad50702ecfe0e1b3bc8e07afc4 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/d5693a0bc9ebc317ed346946e8fe94ba +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/d5c56cd3863549bedac1c7b3f28ae1d7 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/d6ba30bdd7d4b6d5205c150734acf5fa +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/dd47254dcdc30cdbffbe6c32c57032fe +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/dde6829bdb6fb77823831ab67644b76f +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ded9d8a2db25b4ab7f6d4f297208ded2 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/df8f0d31d3b82184ed7ded27b99b8ad4 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/e29bc5278f7e0bed414f714583faceee +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/e461582472217950b63ee3247041e99c +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/e521c94e59f66d600e517a555502fa11 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/e5be380a9dba4e6deae7a8511e4d7c13 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/e744b5ae603dc485f33ed176c899adfc +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/e80c7be4df818b60928137fb7c450a43 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/e8edf2c8d66f7e31710f9aa5068d1155 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ea8cf9239f191c63624cef6a3b6d2fbe +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ebb6acb80a5274f63d3ac5fd8df530b1 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ebf2e1ad04f201369fb43454efc7bbd7 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ec197b57d7a6b4163dac32744e3fa5b0 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/edb76e2e1ee82dc916a1086ca2d71de9 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/edc87d0b81267faccd7c5ada85675f9b +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ef4e09f768bb9330652eaa198bbd2c61 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ef64bea489660cf5e30a6feb53bf3a5d +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/f1b8af27ca9833a0ac2a5e10763efaa2 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/f5827ca48c75eb2925e0ae71f4545190 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/f60d687ea69fe491a8686efe8d6b3022 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/f66a526c31371958b5cd65928dd07d7f +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/f6d577e76daa020d3df860c5dc7f8f61 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/f71d6134d0f24cb1de62de79100e19ee +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/f7ace754f231b5ad97520f631ea60e01 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/f8f8cc64c68687e8c827d78d42ed93a4 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/fa2eaf4b4fc72c8cb321c6f9c022a55f +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/fa32e1bd0e55873cd424ac5e7ce5c5ac +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/fa9f906d3d676d23eac6d15f90f77876 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/fd8537c2a374241cc1d2d029ca4a3623 +0 -0
- data/spec/internal/tmp/cache/assets/test/sprockets/ff2e40602b14836c882af817459fa90e +0 -0
- data/spec/internal/tmp/capybara/capybara-201308160115352034044402.html +51 -0
- data/spec/internal/tmp/capybara/capybara-201308160118107572662369.html +140 -0
- data/spec/internal/tmp/capybara/capybara-201308160124322422773822.html +140 -0
- data/spec/internal/tmp/capybara/capybara-201308160216057700618069.html +71 -0
- data/spec/internal/tmp/capybara/capybara-201308160227299029704750.html +51 -0
- data/spec/internal/tmp/capybara/capybara-201308160227517375148134.html +51 -0
- data/spec/lib/breadcrumbs_spec.rb +5 -5
- data/spec/lib/config_spec.rb +11 -11
- data/spec/lib/controller/callbacks_spec.rb +1 -9
- data/spec/lib/controller/helpers_spec.rb +4 -4
- data/spec/lib/hook_spec.rb +1 -1
- data/spec/lib/list/base_spec.rb +18 -18
- data/spec/lib/list/column_spec.rb +4 -4
- data/spec/lib/list/filter_spec.rb +2 -2
- data/spec/lib/model/authentication_spec.rb +4 -4
- data/spec/lib/model/authorization_spec.rb +4 -4
- data/spec/lib/model/identifier_spec.rb +19 -18
- data/spec/lib/model/methods_spec.rb +1 -1
- data/spec/lib/model/naming_spec.rb +10 -10
- data/spec/lib/model/routing_spec.rb +14 -14
- data/spec/lib/model/serializer_spec.rb +1 -1
- data/spec/lib/outpost_spec.rb +5 -5
- data/spec/spec_helper.rb +7 -0
- data/spec/support/authentication_helper.rb +20 -0
- data/spec/support/authorization_helper.rb +13 -0
- metadata +632 -124
@@ -1,5 +1,5 @@
|
|
1
1
|
module OutpostHelper
|
2
|
-
# Public: Maps the standard Rails flash keys (+notice+, +alert+) to the
|
2
|
+
# Public: Maps the standard Rails flash keys (+notice+, +alert+) to the
|
3
3
|
# appropriate Bootstrap alert class (+success+, +error+ respectively).
|
4
4
|
# Falls back to just returning the passed-in symbol as a string.
|
5
5
|
#
|
@@ -16,7 +16,7 @@ module OutpostHelper
|
|
16
16
|
notice: "success",
|
17
17
|
alert: "error"
|
18
18
|
}
|
19
|
-
|
19
|
+
|
20
20
|
name_bootstrap_map[name.to_sym] || name.to_s
|
21
21
|
end
|
22
22
|
|
@@ -37,8 +37,8 @@ module OutpostHelper
|
|
37
37
|
end
|
38
38
|
|
39
39
|
# Public: Place a modal anywhere with a button to toggle it.
|
40
|
-
#
|
41
|
-
# options - (Hash) Options to pass into the modal template. Useful for
|
40
|
+
#
|
41
|
+
# options - (Hash) Options to pass into the modal template. Useful for
|
42
42
|
# CSS ID, and modal title.
|
43
43
|
# block - The block that gets captured and rendered inside of the modal.
|
44
44
|
#
|
@@ -13,9 +13,9 @@ module RenderHelper
|
|
13
13
|
#
|
14
14
|
# Returns a String of the table, or a message if no records are present.
|
15
15
|
def list_table(records, model, &block)
|
16
|
-
render '/outpost/shared/list_table',
|
17
|
-
:model => model,
|
18
|
-
:records => records,
|
16
|
+
render '/outpost/shared/list_table',
|
17
|
+
:model => model,
|
18
|
+
:records => records,
|
19
19
|
:table => capture(&block)
|
20
20
|
end
|
21
21
|
|
@@ -34,8 +34,8 @@ module RenderHelper
|
|
34
34
|
#
|
35
35
|
# Returns a String of the fieldset.
|
36
36
|
def form_block(title="", &block)
|
37
|
-
render "/outpost/shared/form_block",
|
38
|
-
:title => title,
|
37
|
+
render "/outpost/shared/form_block",
|
38
|
+
:title => title,
|
39
39
|
:body => capture(&block)
|
40
40
|
end
|
41
41
|
end
|
@@ -26,7 +26,7 @@ module UtilityHelper
|
|
26
26
|
# Returns String of the formatted date
|
27
27
|
def format_date(date, options={})
|
28
28
|
return nil if !date.respond_to?(:strftime)
|
29
|
-
|
29
|
+
|
30
30
|
format_str = options[:with] if options[:with].present?
|
31
31
|
|
32
32
|
format_str ||= case options[:format].to_s
|
@@ -35,7 +35,7 @@ module UtilityHelper
|
|
35
35
|
when "event" then "%A, %B %-d"
|
36
36
|
else "%b %-d, %Y"
|
37
37
|
end
|
38
|
-
|
38
|
+
|
39
39
|
format_str += ", %l:%M%P" if options[:time] == true
|
40
40
|
|
41
41
|
date.strftime(format_str)
|
@@ -84,9 +84,9 @@ module UtilityHelper
|
|
84
84
|
#
|
85
85
|
# elements - Zero or more strings to prepend onto the page title.
|
86
86
|
# The final argument can optionally be hash:
|
87
|
-
# :separator - (String) The separator to use between
|
87
|
+
# :separator - (String) The separator to use between
|
88
88
|
# elements (default: " | ").
|
89
|
-
#
|
89
|
+
#
|
90
90
|
# Examples
|
91
91
|
#
|
92
92
|
# set_page_title "Events", "Forum", separator: " :: "
|
@@ -102,7 +102,7 @@ module UtilityHelper
|
|
102
102
|
|
103
103
|
# Public: Generate the full page title.
|
104
104
|
#
|
105
|
-
# last_element - (String) The string that will be appendended onto the
|
105
|
+
# last_element - (String) The string that will be appendended onto the
|
106
106
|
# rest of the title.
|
107
107
|
# separator - (String) The separator to use between the title and the last
|
108
108
|
# element (default: " | ").
|
data/app/models/permission.rb
CHANGED
@@ -1,17 +1,20 @@
|
|
1
1
|
class Permission < ActiveRecord::Base
|
2
2
|
outpost_model
|
3
|
-
|
3
|
+
|
4
4
|
#-------------------
|
5
5
|
# Association
|
6
6
|
has_many :user_permissions
|
7
|
-
has_many :users,
|
8
|
-
|
7
|
+
has_many :users,
|
8
|
+
:class_name => Outpost.config.user_class,
|
9
|
+
:through => :user_permissions,
|
10
|
+
:dependent => :destroy
|
11
|
+
|
9
12
|
#-------------------
|
10
13
|
# Validation
|
11
14
|
validates :resource, uniqueness: true
|
12
|
-
|
15
|
+
|
13
16
|
#-------------------
|
14
|
-
|
17
|
+
|
15
18
|
def title
|
16
19
|
self.resource.titleize
|
17
20
|
end
|
@@ -5,7 +5,7 @@
|
|
5
5
|
<title><%= page_title %></title>
|
6
6
|
<%= stylesheet_link_tag "outpost/application" %>
|
7
7
|
<%= javascript_include_tag "outpost/application" %>
|
8
|
-
|
8
|
+
|
9
9
|
<link rel="shortcut icon" href="/favicon.ico" />
|
10
10
|
<%= csrf_meta_tags %>
|
11
11
|
</head>
|
@@ -15,10 +15,10 @@
|
|
15
15
|
<div class="navbar-inner">
|
16
16
|
<div class="container">
|
17
17
|
<a href="<%=outpost_root_path%>" class="brand">Outpost</a>
|
18
|
-
|
18
|
+
|
19
19
|
<% if current_user %>
|
20
20
|
<ul class="nav">
|
21
|
-
|
21
|
+
|
22
22
|
<!-- Full Navigation -->
|
23
23
|
<li class="dropdown">
|
24
24
|
<a href="#" class="dropdown-toggle" data-toggle="dropdown"><i class="icon-align-justify icon-white"></i> Navigation <b class="caret"></b></a>
|
@@ -31,23 +31,23 @@
|
|
31
31
|
<% if index % per_col == 0 %>
|
32
32
|
<div class="grouper">
|
33
33
|
<% end %>
|
34
|
-
|
34
|
+
|
35
35
|
<li>
|
36
36
|
<a href="<%=model.admin_index_path%>">
|
37
37
|
<%= model.name.titleize.pluralize %>
|
38
38
|
</a>
|
39
|
-
|
39
|
+
|
40
40
|
<div class="btn-links">
|
41
41
|
<% if model.respond_to?(:admin_new_path) %>
|
42
42
|
<a class="add btn btn-mini" href="<%=model.admin_new_path%>"><i class="icon-plus-sign"></i> Add</a>
|
43
43
|
<% end %>
|
44
44
|
</div>
|
45
45
|
</li>
|
46
|
-
|
46
|
+
|
47
47
|
<% if index % per_col == per_col - 1 or model == models.last %>
|
48
48
|
</div>
|
49
49
|
<% end %>
|
50
|
-
|
50
|
+
|
51
51
|
<% end %>
|
52
52
|
</ul> <!-- dropdown-menu -->
|
53
53
|
</li> <!-- dropdown -->
|
@@ -1,11 +1,2 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
<ul class="unstyled" style="margin-bottom: 0">
|
4
|
-
<% f.object.errors[:base].each do |message| %>
|
5
|
-
<li><%= message %></li>
|
6
|
-
<% end %>
|
7
|
-
</ul>
|
8
|
-
</div>
|
9
|
-
<% else %>
|
10
|
-
<%= f.error_notification %>
|
11
|
-
<% end %>
|
1
|
+
<%= f.full_errors(:base) %>
|
2
|
+
<%= f.error_notification %>
|
@@ -1,10 +1,14 @@
|
|
1
1
|
<% add_to_page_title "Editing: #{@record.to_title}" %>
|
2
2
|
|
3
|
-
<%= simple_form_for [:outpost, @record], html: { class: "form-horizontal" } do |f| %>
|
3
|
+
<%= simple_form_for [:outpost, @record], html: { class: "form-horizontal js-content-form" } do |f| %>
|
4
4
|
<%= render 'errors', f: f %>
|
5
5
|
<%= render 'form_fields', record: @record, f: f %>
|
6
6
|
<%= render 'extra_fields', f: f %>
|
7
7
|
<%= render "/outpost/shared/submit_row", record: @record %>
|
8
|
+
|
9
|
+
<% content_for :footer do %>
|
10
|
+
<script>outpost.Utilities.preventEnterFromSubmittingForm("#<%=f.options[:html][:id]%>");</script>
|
11
|
+
<% end %>
|
8
12
|
<% end %>
|
9
13
|
|
10
14
|
<% content_for :sidebar do %>
|
@@ -21,15 +25,15 @@
|
|
21
25
|
<% if @record.respond_to?(:published_at) && @record.respond_to?(:published?) && @record.published? %>
|
22
26
|
on <strong><%= format_date @record.published_at, time: true %></strong>
|
23
27
|
<% end %>
|
24
|
-
|
28
|
+
|
25
29
|
<% if @record.respond_to?(:publish_alarm) && @record.publish_alarm.present? && @record.publish_alarm.fire_at.present? %>
|
26
30
|
Alarm - <strong><%= format_date @record.publish_alarm.fire_at, time: true %></strong>
|
27
31
|
<% end %>
|
28
32
|
</li>
|
29
33
|
</ul>
|
30
|
-
|
34
|
+
|
31
35
|
<hr />
|
32
|
-
|
36
|
+
|
33
37
|
<div id="fixed-sidebar" data-spy="affix" data-offset-top="140">
|
34
38
|
<!-- Be sure to change the data-offset-top attribute on this element if you move it vertically -->
|
35
39
|
<%= render "/outpost/shared/form_nav" %>
|
@@ -1,10 +1,14 @@
|
|
1
1
|
<% add_to_page_title "Add #{model.to_title}" %>
|
2
2
|
|
3
|
-
<%= simple_form_for [:outpost, @record], html: { class: "form-horizontal" } do |f| %>
|
3
|
+
<%= simple_form_for [:outpost, @record], html: { class: "form-horizontal js-content-form" } do |f| %>
|
4
4
|
<%= render 'errors', f: f %>
|
5
5
|
<%= render 'form_fields', record: @record, f: f %>
|
6
6
|
<%= render 'extra_fields', f: f %>
|
7
7
|
<%= render "/outpost/shared/submit_row", record: @record %>
|
8
|
+
|
9
|
+
<% content_for :footer do %>
|
10
|
+
<script>outpost.Utilities.preventEnterFromSubmittingForm("#<%=f.options[:html][:id]%>");</script>
|
11
|
+
<% end %>
|
8
12
|
<% end %>
|
9
13
|
|
10
14
|
<% content_for :sidebar do %>
|
@@ -4,8 +4,8 @@
|
|
4
4
|
|
5
5
|
<%= form_tag model.admin_index_path, method: :get, class: "form-inline" do %>
|
6
6
|
<% list.filters.each do |attribute, filter| %>
|
7
|
-
<%= select_tag attribute,
|
8
|
-
options_for_select(filter.collection.call, params[:filter].present? ? params[:filter][attribute] : nil), include_blank: true,
|
7
|
+
<%= select_tag attribute,
|
8
|
+
options_for_select(filter.collection.call, params[:filter].present? ? params[:filter][attribute] : nil), include_blank: true,
|
9
9
|
data: { placeholder: filter.title }, name: "filter[#{attribute}]", class: "input-medium" %>
|
10
10
|
<% end %>
|
11
11
|
|
@@ -3,11 +3,11 @@
|
|
3
3
|
<% @sections[id] = title if @sections %>
|
4
4
|
<fieldset class="form-block" id="<%=id%>">
|
5
5
|
<legend><%= title %></legend>
|
6
|
-
|
6
|
+
|
7
7
|
<div class="hidden notification">
|
8
8
|
<p class="muted"><i>Click header to show fields</i></p>
|
9
9
|
</div>
|
10
|
-
|
10
|
+
|
11
11
|
<% else %>
|
12
12
|
<fieldset class="form-block">
|
13
13
|
<% end %>
|
@@ -0,0 +1,9 @@
|
|
1
|
+
<% if f.object.errors[attribute].present? %>
|
2
|
+
<div class="alert alert-error">
|
3
|
+
<ul class="unstyled" style="margin-bottom: 0">
|
4
|
+
<% f.object.errors[attribute].map { |msg| f.object.errors.full_message(attribute, msg) }.each do |message| %>
|
5
|
+
<li><%= message %></li>
|
6
|
+
<% end %>
|
7
|
+
</ul>
|
8
|
+
</div>
|
9
|
+
<% end %>
|
@@ -1,14 +1,14 @@
|
|
1
1
|
<th class="column-manage">Manage</th>
|
2
2
|
|
3
3
|
<% list.columns.each do |attribute, column| %>
|
4
|
-
<% is_sorting =
|
4
|
+
<% is_sorting = order_attribute == column.attribute.to_s %>
|
5
5
|
|
6
6
|
<th class="<%='header-highlighted' if is_sorting%> <%='header-sortable' if column.sortable?%> <%=column_attribute_class(column.attribute)%> <%=column_type_class(model, column.attribute)%>">
|
7
7
|
<% if column.sortable? || is_sorting %>
|
8
|
-
<i class="icon <%=
|
8
|
+
<i class="icon <%=direction_icon(is_sorting ? order_direction : column.default_order_direction)%>"></i>
|
9
9
|
|
10
|
-
<%= link_to_if column.sortable?, column.header, request.parameters.merge(order: column.attribute,
|
11
|
-
<%= render('/outpost/shared/cancel_link', href: url_for(request.parameters.merge(order: "",
|
10
|
+
<%= link_to_if column.sortable?, column.header, request.parameters.merge(order: column.attribute, direction: switch_direction(column, order_attribute, order_direction)), class: "js-sort-link" %>
|
11
|
+
<%= render('/outpost/shared/cancel_link', href: url_for(request.parameters.merge(order: "", direction: ""))) if (is_sorting && (order_attribute != list.default_order_attribute || order_direction != list.default_order_direction)) %>
|
12
12
|
<% else %>
|
13
13
|
<%= column.header %>
|
14
14
|
<% end %>
|
@@ -9,23 +9,23 @@
|
|
9
9
|
<% if index % per_col == 0 %>
|
10
10
|
<div class="grouper">
|
11
11
|
<% end %>
|
12
|
-
|
12
|
+
|
13
13
|
<li>
|
14
14
|
<a href="<%=model.admin_index_path%>">
|
15
15
|
<%= model.name.titleize.pluralize %>
|
16
16
|
</a>
|
17
|
-
|
17
|
+
|
18
18
|
<div class="btn-links">
|
19
19
|
<% if model.respond_to?(:admin_new_path) %>
|
20
20
|
<a class="add btn btn-mini" href="<%=model.admin_new_path%>"><i class="icon-plus-sign"></i> Add</a>
|
21
21
|
<% end %>
|
22
22
|
</div>
|
23
23
|
</li>
|
24
|
-
|
24
|
+
|
25
25
|
<% if index % per_col == per_col - 1 or model == models.last %>
|
26
26
|
</div>
|
27
27
|
<% end %>
|
28
|
-
|
28
|
+
|
29
29
|
<% end %>
|
30
30
|
</ul> <!-- dropdown-menu -->
|
31
31
|
</li> <!-- dropdown -->
|
@@ -1,7 +1,7 @@
|
|
1
1
|
<!-- This block is part of a form -->
|
2
2
|
<div class="form-actions submit-row">
|
3
3
|
<div class="container">
|
4
|
-
<div class="btn-group dropup pull-left">
|
4
|
+
<div class="btn-group dropup pull-left js-save-btns">
|
5
5
|
<%= button_tag "Save", name: "commit_action", value: "edit", class: "btn btn-primary btn-large span2" %>
|
6
6
|
<button class="btn btn-primary btn-large dropdown-toggle" data-toggle="dropdown">
|
7
7
|
<span class="caret"></span>
|
@@ -31,10 +31,10 @@
|
|
31
31
|
|
32
32
|
<% if record.persisted? %>
|
33
33
|
<%= link_to("View Live", record.public_path, class: "btn btn-success", target: "_blank") if record.public_path.present? %>
|
34
|
-
<%= link_to("Delete",
|
35
|
-
[:outpost, record],
|
36
|
-
class: "btn btn-danger",
|
37
|
-
method: :delete,
|
34
|
+
<%= link_to("Delete this #{model.to_title}",
|
35
|
+
[:outpost, record],
|
36
|
+
class: "btn btn-danger",
|
37
|
+
method: :delete,
|
38
38
|
data: { confirm: "Click OK to delete this #{model.to_title}.\nClick CANCEL to return to editing." }
|
39
39
|
) %>
|
40
40
|
<% end %>
|
@@ -12,58 +12,70 @@ module ActionView
|
|
12
12
|
module Helpers
|
13
13
|
class FormBuilder
|
14
14
|
def section(partial, options={}, &block)
|
15
|
-
@template.render(
|
16
|
-
:partial => "/outpost/shared/sections/#{partial}",
|
15
|
+
@template.render(
|
16
|
+
:partial => "/outpost/shared/sections/#{partial}",
|
17
17
|
:locals => {
|
18
18
|
:f => self,
|
19
|
-
:record => self.object,
|
19
|
+
:record => self.object,
|
20
20
|
:options => options,
|
21
21
|
:extra => block_given? ? @template.capture(&block) : ""
|
22
22
|
})
|
23
23
|
end
|
24
|
-
|
24
|
+
|
25
25
|
#----------------------
|
26
|
-
|
26
|
+
|
27
27
|
def render_fields(partial, options={})
|
28
|
-
@template.render(
|
29
|
-
:partial => "/outpost/shared/fields/#{partial}_fields",
|
28
|
+
@template.render(
|
29
|
+
:partial => "/outpost/shared/fields/#{partial}_fields",
|
30
30
|
:locals => {
|
31
31
|
:f => self,
|
32
32
|
:index => self.object.object_id,
|
33
33
|
:options => options
|
34
34
|
})
|
35
35
|
end
|
36
|
-
|
36
|
+
|
37
|
+
#----------------------
|
38
|
+
|
39
|
+
def full_errors(attribute, options={})
|
40
|
+
@template.render(
|
41
|
+
:partial => "/outpost/shared/full_errors",
|
42
|
+
:locals => {
|
43
|
+
:f => self,
|
44
|
+
:attribute => attribute,
|
45
|
+
:options => options
|
46
|
+
})
|
47
|
+
end
|
48
|
+
|
37
49
|
#----------------------
|
38
|
-
|
50
|
+
|
39
51
|
def link_to_add_fields(association, options={})
|
40
52
|
association = association.to_s
|
41
53
|
partial = options[:partial] || association.singularize
|
42
54
|
title = options[:title] || "Add Another #{association.singularize.titleize}"
|
43
|
-
|
55
|
+
|
44
56
|
new_object = self.object.send(association).klass.new
|
45
57
|
id = new_object.object_id
|
46
|
-
|
58
|
+
|
47
59
|
fields = self.simple_fields_for(association, new_object, child_index: id) do |nf|
|
48
60
|
nf.render_fields(partial)
|
49
61
|
end
|
50
|
-
|
51
|
-
@template.link_to(title, "#", class: "js-add-fields",
|
62
|
+
|
63
|
+
@template.link_to(title, "#", class: "js-add-fields has-many-add-link",
|
52
64
|
data: { id: id, build_target: options[:build_target], fields: fields.gsub("\n", "") })
|
53
65
|
end
|
54
66
|
|
55
67
|
#----------------------
|
56
|
-
|
68
|
+
|
57
69
|
def has_many_fields(association)
|
58
70
|
partial = association.to_s.singularize
|
59
71
|
fields = String.new
|
60
|
-
|
72
|
+
|
61
73
|
self.object.send(association).each do |obj|
|
62
74
|
fields << self.simple_fields_for(association, obj) do |nf|
|
63
75
|
nf.render_fields(partial)
|
64
76
|
end
|
65
77
|
end
|
66
|
-
|
78
|
+
|
67
79
|
fields.html_safe
|
68
80
|
end
|
69
81
|
end
|