releaf 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/LICENSE +24 -0
- data/README.md +74 -0
- data/Rakefile +62 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-bg_glass_65_ffffff_1x400.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-bg_glass_75_dadada_1x400.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-icons_222222_256x240.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-icons_2e83ff_256x240.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-icons_454545_256x240.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-icons_888888_256x240.png +0 -0
- data/app/assets/images/releaf/3rd_party/jquery-ui-1.9.2.custom/ui-icons_cd0a0a_256x240.png +0 -0
- data/app/assets/images/releaf/3rd_party/lightbox/close.png +0 -0
- data/app/assets/images/releaf/3rd_party/lightbox/loading.gif +0 -0
- data/app/assets/images/releaf/3rd_party/lightbox/next.png +0 -0
- data/app/assets/images/releaf/3rd_party/lightbox/prev.png +0 -0
- data/app/assets/images/releaf/add.png +0 -0
- data/app/assets/images/releaf/background.jpg +0 -0
- data/app/assets/images/releaf/button/button_bgr.gif +0 -0
- data/app/assets/images/releaf/button/button_hover_bgr.png +0 -0
- data/app/assets/images/releaf/controllers/content/close.gif +0 -0
- data/app/assets/images/releaf/controllers/content/close_active.gif +0 -0
- data/app/assets/images/releaf/controllers/content/close_hover.gif +0 -0
- data/app/assets/images/releaf/controllers/content/global_fields_bgr.png +0 -0
- data/app/assets/images/releaf/controllers/content/open.gif +0 -0
- data/app/assets/images/releaf/controllers/content/open_2.gif +0 -0
- data/app/assets/images/releaf/controllers/content/open_active.gif +0 -0
- data/app/assets/images/releaf/controllers/content/open_hover.gif +0 -0
- data/app/assets/images/releaf/controllers/sessions/background.jpg +0 -0
- data/app/assets/images/releaf/controllers/sessions/logo.jpg +0 -0
- data/app/assets/images/releaf/expand_tool/close.png +0 -0
- data/app/assets/images/releaf/expand_tool/close_hover.png +0 -0
- data/app/assets/images/releaf/expand_tool/close_hover_shim.png +0 -0
- data/app/assets/images/releaf/expand_tool/close_shim.png +0 -0
- data/app/assets/images/releaf/expand_tool/loader.gif +0 -0
- data/app/assets/images/releaf/expand_tool/open.png +0 -0
- data/app/assets/images/releaf/expand_tool/open_hover.png +0 -0
- data/app/assets/images/releaf/expand_tool/open_hover_shim.png +0 -0
- data/app/assets/images/releaf/expand_tool/open_shim.png +0 -0
- data/app/assets/images/releaf/favicon.ico +0 -0
- data/app/assets/images/releaf/globalFieldContainerBgr.png +0 -0
- data/app/assets/images/releaf/icons/129.png +0 -0
- data/app/assets/images/releaf/icons/130.png +0 -0
- data/app/assets/images/releaf/icons/accept.png +0 -0
- data/app/assets/images/releaf/icons/add.png +0 -0
- data/app/assets/images/releaf/icons/arrow_down.png +0 -0
- data/app/assets/images/releaf/icons/arrow_left.png +0 -0
- data/app/assets/images/releaf/icons/arrow_refresh.png +0 -0
- data/app/assets/images/releaf/icons/arrow_up.png +0 -0
- data/app/assets/images/releaf/icons/bin_empty.png +0 -0
- data/app/assets/images/releaf/icons/bullet_black.png +0 -0
- data/app/assets/images/releaf/icons/bullet_connect.png +0 -0
- data/app/assets/images/releaf/icons/bullet_start.png +0 -0
- data/app/assets/images/releaf/icons/bullet_tick.png +0 -0
- data/app/assets/images/releaf/icons/chrome.png +0 -0
- data/app/assets/images/releaf/icons/control_play.png +0 -0
- data/app/assets/images/releaf/icons/date.png +0 -0
- data/app/assets/images/releaf/icons/delete.png +0 -0
- data/app/assets/images/releaf/icons/disk.png +0 -0
- data/app/assets/images/releaf/icons/drag-handle.png +0 -0
- data/app/assets/images/releaf/icons/error.png +0 -0
- data/app/assets/images/releaf/icons/eye.png +0 -0
- data/app/assets/images/releaf/icons/firefox.png +0 -0
- data/app/assets/images/releaf/icons/google-not-available.gif +0 -0
- data/app/assets/images/releaf/icons/google.gif +0 -0
- data/app/assets/images/releaf/icons/keyboard.png +0 -0
- data/app/assets/images/releaf/icons/left_16.png +0 -0
- data/app/assets/images/releaf/icons/link.png +0 -0
- data/app/assets/images/releaf/icons/magnifier.png +0 -0
- data/app/assets/images/releaf/icons/notAllowed.png +0 -0
- data/app/assets/images/releaf/icons/page_white_add.png +0 -0
- data/app/assets/images/releaf/icons/page_white_edit.png +0 -0
- data/app/assets/images/releaf/icons/page_white_put.png +0 -0
- data/app/assets/images/releaf/icons/page_white_text.png +0 -0
- data/app/assets/images/releaf/icons/pencil.png +0 -0
- data/app/assets/images/releaf/icons/picture.png +0 -0
- data/app/assets/images/releaf/icons/right_16.png +0 -0
- data/app/assets/images/releaf/icons/tick.png +0 -0
- data/app/assets/images/releaf/icons/warning.png +0 -0
- data/app/assets/images/releaf/icons/world_go.png +0 -0
- data/app/assets/images/releaf/icons/world_link.png +0 -0
- data/app/assets/images/releaf/input/autocompleteExpandIcon.png +0 -0
- data/app/assets/images/releaf/input/input_bgr.gif +0 -0
- data/app/assets/images/releaf/language_root.png +0 -0
- data/app/assets/images/releaf/loader.gif +0 -0
- data/app/assets/images/releaf/logout.png +0 -0
- data/app/assets/images/releaf/main_menu/active_bgr.png +0 -0
- data/app/assets/images/releaf/main_menu/bgr.png +0 -0
- data/app/assets/images/releaf/main_menu/hover_bgr.png +0 -0
- data/app/assets/images/releaf/module.png +0 -0
- data/app/assets/images/releaf/panel_layout/active_bgr.png +0 -0
- data/app/assets/images/releaf/panel_layout/secondary_panel_horizontal_bgr.png +0 -0
- data/app/assets/images/releaf/panel_layout/secondary_panel_vertical_bgr.png +0 -0
- data/app/assets/images/releaf/releaf_table/selected_bgr.png +0 -0
- data/app/assets/images/releaf/releaf_table/th_bgr.gif +0 -0
- data/app/assets/javascripts/releaf/3rd_party/jquery-cookie/README.md +73 -0
- data/app/assets/javascripts/releaf/3rd_party/jquery-cookie/jquery.cookie.js +47 -0
- data/app/assets/javascripts/releaf/3rd_party/jquery-cookie/server.js +24 -0
- data/app/assets/javascripts/releaf/3rd_party/jquery-cookie/test.html +19 -0
- data/app/assets/javascripts/releaf/3rd_party/jquery-cookie/test.js +80 -0
- data/app/assets/javascripts/releaf/3rd_party/jquery-ui-timepicker-addon.js +1882 -0
- data/app/assets/javascripts/releaf/3rd_party/lightbox.js.erb +379 -0
- data/app/assets/javascripts/releaf/application.js +14 -0
- data/app/assets/javascripts/releaf/controllers/base.js +170 -0
- data/app/assets/javascripts/releaf/controllers/releaf/content.js +90 -0
- data/app/assets/javascripts/releaf/controllers/releaf/translations.js +31 -0
- data/app/assets/javascripts/releaf/include/continuous_scroll.js +321 -0
- data/app/assets/javascripts/releaf/include/field.type_autocomplete.js +58 -0
- data/app/assets/javascripts/releaf/include/field.type_richtext.js +90 -0
- data/app/assets/javascripts/releaf/include/localization.js +12 -0
- data/app/assets/javascripts/releaf/include/nested_fields.js +71 -0
- data/app/assets/javascripts/releaf/include/sortable.js +27 -0
- data/app/assets/javascripts/releaf/lib/request_url.js +183 -0
- data/app/assets/stylesheets/releaf/3rd_party/jquery-ui-1.9.2.custom.css.erb +464 -0
- data/app/assets/stylesheets/releaf/3rd_party/jquery-ui-timepicker-addon.css +10 -0
- data/app/assets/stylesheets/releaf/3rd_party/lightbox.css.erb +157 -0
- data/app/assets/stylesheets/releaf/application.css.erb +122 -0
- data/app/assets/stylesheets/releaf/controllers/base.css.erb +205 -0
- data/app/assets/stylesheets/releaf/controllers/releaf/content.css.erb +416 -0
- data/app/assets/stylesheets/releaf/controllers/releaf/sessions.css.scss.erb +116 -0
- data/app/assets/stylesheets/releaf/controllers/releaf/translations.css.erb +205 -0
- data/app/assets/stylesheets/releaf/include/button.css.erb +176 -0
- data/app/assets/stylesheets/releaf/include/field.css.erb +257 -0
- data/app/assets/stylesheets/releaf/include/input.css.erb +40 -0
- data/app/assets/stylesheets/releaf/include/main_menu.css.erb +66 -0
- data/app/assets/stylesheets/releaf/include/pagination.css.erb +29 -0
- data/app/assets/stylesheets/releaf/include/panel_layout.css.erb +251 -0
- data/app/assets/stylesheets/releaf/include/releaf_table.css.erb +112 -0
- data/app/assets/stylesheets/releaf/include/sortable.css.erb +12 -0
- data/app/controllers/releaf/admins_controller.rb +48 -0
- data/app/controllers/releaf/application_controller.rb +11 -0
- data/app/controllers/releaf/base_application_controller.rb +15 -0
- data/app/controllers/releaf/base_controller.rb +310 -0
- data/app/controllers/releaf/content_controller.rb +166 -0
- data/app/controllers/releaf/roles_controller.rb +36 -0
- data/app/controllers/releaf/sessions_controller.rb +5 -0
- data/app/controllers/releaf/tinymce_assets_controller.rb +26 -0
- data/app/controllers/releaf/translations_controller.rb +121 -0
- data/app/helpers/releaf/admin_helper.rb +79 -0
- data/app/helpers/releaf/application_helper.rb +4 -0
- data/app/helpers/releaf/pagination_renderer.rb +44 -0
- data/app/helpers/releaf/releaf_devise_helper.rb +8 -0
- data/app/models/releaf/admin.rb +51 -0
- data/app/models/releaf/node.rb +221 -0
- data/app/models/releaf/node_base.rb +25 -0
- data/app/models/releaf/role.rb +119 -0
- data/app/models/releaf/tinymce_asset.rb +6 -0
- data/app/views/layouts/releaf/admin.html.haml +51 -0
- data/app/views/releaf/aliases/_edit.body.haml +50 -0
- data/app/views/releaf/aliases/_edit.header.haml +19 -0
- data/app/views/releaf/aliases/_index.row.haml +5 -0
- data/app/views/releaf/aliases/_secondary_panel.haml +13 -0
- data/app/views/releaf/base/_edit.body.haml +19 -0
- data/app/views/releaf/base/_edit.field.haml +96 -0
- data/app/views/releaf/base/_edit.field.type_autocomplete.haml +15 -0
- data/app/views/releaf/base/_edit.field.type_checkbox.haml +5 -0
- data/app/views/releaf/base/_edit.field.type_date.haml +8 -0
- data/app/views/releaf/base/_edit.field.type_datetime.haml +8 -0
- data/app/views/releaf/base/_edit.field.type_delete_nested.haml +3 -0
- data/app/views/releaf/base/_edit.field.type_file.haml +10 -0
- data/app/views/releaf/base/_edit.field.type_image.haml +14 -0
- data/app/views/releaf/base/_edit.field.type_link.haml +4 -0
- data/app/views/releaf/base/_edit.field.type_password.haml +4 -0
- data/app/views/releaf/base/_edit.field.type_richtext.haml +4 -0
- data/app/views/releaf/base/_edit.field.type_richtext_i18n.haml +27 -0
- data/app/views/releaf/base/_edit.field.type_select.haml +11 -0
- data/app/views/releaf/base/_edit.field.type_text.haml +4 -0
- data/app/views/releaf/base/_edit.field.type_text_i18n.haml +27 -0
- data/app/views/releaf/base/_edit.field.type_textarea.haml +4 -0
- data/app/views/releaf/base/_edit.field.type_textarea_i18n.haml +27 -0
- data/app/views/releaf/base/_edit.field.type_time.haml +8 -0
- data/app/views/releaf/base/_edit.footer.haml +14 -0
- data/app/views/releaf/base/_edit.form.haml +4 -0
- data/app/views/releaf/base/_edit.has_many_associations.haml +45 -0
- data/app/views/releaf/base/_edit.header.haml +3 -0
- data/app/views/releaf/base/_index.body.haml +6 -0
- data/app/views/releaf/base/_index.cell.haml +19 -0
- data/app/views/releaf/base/_index.footer.haml +22 -0
- data/app/views/releaf/base/_index.header.haml +4 -0
- data/app/views/releaf/base/_index.row.haml +6 -0
- data/app/views/releaf/base/_index.search.haml +5 -0
- data/app/views/releaf/base/_index.table.haml +8 -0
- data/app/views/releaf/base/_secondary_panel.haml +9 -0
- data/app/views/releaf/base/_show.body.haml +7 -0
- data/app/views/releaf/base/_show.field.haml +78 -0
- data/app/views/releaf/base/_show.field.type_html.haml +1 -0
- data/app/views/releaf/base/_show.footer.haml +16 -0
- data/app/views/releaf/base/_show.header.haml +3 -0
- data/app/views/releaf/base/confirm_destroy.haml +10 -0
- data/app/views/releaf/base/edit.haml +1 -0
- data/app/views/releaf/base/index.haml +3 -0
- data/app/views/releaf/base/new.haml +1 -0
- data/app/views/releaf/base/show.haml +3 -0
- data/app/views/releaf/content/_edit.body.haml +45 -0
- data/app/views/releaf/content/_edit.content_fields.haml +19 -0
- data/app/views/releaf/content/_edit.slug.haml +12 -0
- data/app/views/releaf/content/_get_content_form.haml +7 -0
- data/app/views/releaf/content/_secondary_panel.haml +3 -0
- data/app/views/releaf/content/_show.field.content.haml +11 -0
- data/app/views/releaf/content/_tree_level.haml +16 -0
- data/app/views/releaf/content/ajax.new.haml +3 -0
- data/app/views/releaf/content/index.haml +0 -0
- data/app/views/releaf/roles/_edit.field.admins.haml +0 -0
- data/app/views/releaf/roles/_edit.field.permissions.haml +5 -0
- data/app/views/releaf/roles/_show.field.default.haml +6 -0
- data/app/views/releaf/roles/_show.field.permissions.haml +11 -0
- data/app/views/releaf/sessions/new.html.haml +17 -0
- data/app/views/releaf/translations/_edit.body.haml +50 -0
- data/app/views/releaf/translations/_edit.header.haml +19 -0
- data/app/views/releaf/translations/_index.row.haml +5 -0
- data/app/views/releaf/translations/_secondary_panel.haml +13 -0
- data/bin/releaf +25 -0
- data/lib/generators/releaf/install_generator.rb +87 -0
- data/lib/generators/releaf/templates/config/common_fields.yml.example +17 -0
- data/lib/generators/releaf/templates/controllers/home_controller.rb +4 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-bg_glass_65_ffffff_1x400.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-bg_glass_75_dadada_1x400.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-icons_222222_256x240.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-icons_2e83ff_256x240.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-icons_454545_256x240.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-icons_888888_256x240.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/jquery_ui/smoothness/ui-icons_cd0a0a_256x240.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/lightbox/close.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/lightbox/loading.gif +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/lightbox/next.png +0 -0
- data/lib/generators/releaf/templates/images/3rd_party/lightbox/prev.png +0 -0
- data/lib/generators/releaf/templates/initializers/releaf.rb +59 -0
- data/lib/generators/releaf/templates/initializers/releaf_i18n.rb +8 -0
- data/lib/generators/releaf/templates/initializers/releaf_store_current_template.rb +25 -0
- data/lib/generators/releaf/templates/javascripts/3rd_party/jquery_ui.js +14850 -0
- data/lib/generators/releaf/templates/javascripts/3rd_party/lightbox.js.erb +379 -0
- data/lib/generators/releaf/templates/javascripts/application.js +15 -0
- data/lib/generators/releaf/templates/javascripts/lib/js_check.js +8 -0
- data/lib/generators/releaf/templates/javascripts/lib/request_url.js +169 -0
- data/lib/generators/releaf/templates/javascripts/lib/sortable.js +29 -0
- data/lib/generators/releaf/templates/migrations/create_releaf_admins.rb +53 -0
- data/lib/generators/releaf/templates/migrations/create_releaf_nodes.rb +25 -0
- data/lib/generators/releaf/templates/migrations/create_releaf_roles.rb +11 -0
- data/lib/generators/releaf/templates/migrations/create_releaf_tinymce_assets.rb +10 -0
- data/lib/generators/releaf/templates/migrations/create_releaf_translations.rb +31 -0
- data/lib/generators/releaf/templates/models/admin_ability.rb +51 -0
- data/lib/generators/releaf/templates/seeds.rb +64 -0
- data/lib/generators/releaf/templates/stylesheets/3rd_party/jquery_ui/smoothness.css.erb +1174 -0
- data/lib/generators/releaf/templates/stylesheets/3rd_party/lightbox.css.erb +157 -0
- data/lib/generators/releaf/templates/stylesheets/3rd_party/reset.css +48 -0
- data/lib/generators/releaf/templates/stylesheets/application.scss +15 -0
- data/lib/generators/releaf/templates/stylesheets/style.scss +45 -0
- data/lib/generators/releaf/templates/views/home/index.html.haml +1 -0
- data/lib/generators/releaf/templates/views/layouts/application.html.haml +26 -0
- data/lib/i18n/backend/releaf.rb +96 -0
- data/lib/i18n/backend/releaf/translation.rb +56 -0
- data/lib/i18n/backend/releaf/translation_data.rb +32 -0
- data/lib/i18n/backend/releaf/translation_group.rb +30 -0
- data/lib/i18n/releaf.rb +1 -0
- data/lib/releaf.rb +30 -0
- data/lib/releaf/engine.rb +4 -0
- data/lib/releaf/slug.rb +79 -0
- data/lib/releaf/version.rb +3 -0
- data/lib/tasks/releaf_tasks.rake +4 -0
- data/spec/dummy/README.rdoc +261 -0
- data/spec/dummy/Rakefile +7 -0
- data/spec/dummy/app/assets/images/rails.png +0 -0
- data/spec/dummy/app/assets/javascripts/application.js +15 -0
- data/spec/dummy/app/assets/stylesheets/application.css +13 -0
- data/spec/dummy/app/controllers/application_controller.rb +3 -0
- data/spec/dummy/app/helpers/application_helper.rb +2 -0
- data/spec/dummy/app/models/admin_ability.rb +51 -0
- data/spec/dummy/app/models/settings.rb +2 -0
- data/spec/dummy/app/views/layouts/application.html.haml +10 -0
- data/spec/dummy/config.ru +4 -0
- data/spec/dummy/config/application.rb +68 -0
- data/spec/dummy/config/boot.rb +6 -0
- data/spec/dummy/config/common_fields.yml.example +17 -0
- data/spec/dummy/config/database.yml +42 -0
- data/spec/dummy/config/environment.rb +5 -0
- data/spec/dummy/config/environments/development.rb +37 -0
- data/spec/dummy/config/environments/production.rb +67 -0
- data/spec/dummy/config/environments/test.rb +37 -0
- data/spec/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/dummy/config/initializers/devise.rb +232 -0
- data/spec/dummy/config/initializers/dragonfly.rb +1 -0
- data/spec/dummy/config/initializers/inflections.rb +15 -0
- data/spec/dummy/config/initializers/mime_types.rb +5 -0
- data/spec/dummy/config/initializers/releaf.rb +59 -0
- data/spec/dummy/config/initializers/releaf_i18n.rb +8 -0
- data/spec/dummy/config/initializers/releaf_store_current_template.rb +25 -0
- data/spec/dummy/config/initializers/secret_token.rb +7 -0
- data/spec/dummy/config/initializers/session_store.rb +8 -0
- data/spec/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/spec/dummy/config/locales/devise.en.yml +58 -0
- data/spec/dummy/config/locales/en.yml +5 -0
- data/spec/dummy/config/routes.rb +11 -0
- data/spec/dummy/db/migrate/20130204164516_create_settings.rb +17 -0
- data/spec/dummy/db/migrate/20130204164523_create_releaf_nodes.rb +25 -0
- data/spec/dummy/db/migrate/20130204164524_create_releaf_roles.rb +11 -0
- data/spec/dummy/db/migrate/20130204164525_create_releaf_translations.rb +31 -0
- data/spec/dummy/db/migrate/20130204164526_create_releaf_admins.rb +53 -0
- data/spec/dummy/db/schema.rb +112 -0
- data/spec/dummy/db/seeds.rb +64 -0
- data/spec/dummy/doc/README_FOR_APP +2 -0
- data/spec/dummy/log/development.log +74 -0
- data/spec/dummy/log/test.log +129 -0
- data/spec/dummy/public/404.html +26 -0
- data/spec/dummy/public/422.html +26 -0
- data/spec/dummy/public/500.html +25 -0
- data/spec/dummy/public/favicon.ico +0 -0
- data/spec/dummy/script/rails +6 -0
- data/spec/dummy/tmp/cache/9C5/660/settings%3Ai18n_updated_at +1 -0
- data/spec/factories/factories.rb +24 -0
- data/spec/features/admin_spec.rb +41 -0
- data/spec/spec_helper.rb +23 -0
- data/templates/releaf/installer.rb +196 -0
- metadata +777 -0
@@ -0,0 +1,64 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
|
3
|
+
Releaf::Role.delete_all
|
4
|
+
Releaf::Admin.delete_all
|
5
|
+
|
6
|
+
Settings.delete_all
|
7
|
+
|
8
|
+
# Role {{{
|
9
|
+
|
10
|
+
puts "Creating roles"
|
11
|
+
roles = {
|
12
|
+
default: {
|
13
|
+
name: 'default role',
|
14
|
+
default: true
|
15
|
+
},
|
16
|
+
admins: {
|
17
|
+
name: 'admins',
|
18
|
+
default: false,
|
19
|
+
admin_permission: true
|
20
|
+
}
|
21
|
+
}
|
22
|
+
|
23
|
+
roles.each_value do |value|
|
24
|
+
value[:id] = Releaf::Role.create!(value).id
|
25
|
+
end
|
26
|
+
|
27
|
+
# }}}
|
28
|
+
# Admin {{{
|
29
|
+
|
30
|
+
puts "Creating admins"
|
31
|
+
admins = {
|
32
|
+
admin: {
|
33
|
+
name: 'Admin',
|
34
|
+
surname: 'User',
|
35
|
+
password: 'password',
|
36
|
+
password_confirmation: 'password',
|
37
|
+
email: 'admin@example.com',
|
38
|
+
role_id: roles[:admins][:id],
|
39
|
+
},
|
40
|
+
janis: {
|
41
|
+
name: 'Simple',
|
42
|
+
surname: 'User',
|
43
|
+
password: 'LetMeIn',
|
44
|
+
password_confirmation: 'LetMeIn',
|
45
|
+
email: 'user@example.com',
|
46
|
+
role_id: roles[:default][:id]
|
47
|
+
}
|
48
|
+
}
|
49
|
+
|
50
|
+
admins.each_value do |value|
|
51
|
+
value[:id] = Releaf::Admin.create!(value).id
|
52
|
+
end
|
53
|
+
|
54
|
+
# }}}
|
55
|
+
# Settings {{{
|
56
|
+
|
57
|
+
puts "Creating settings"
|
58
|
+
Settings.i18n_locales = %w[en]
|
59
|
+
Settings.email_from = "do_not_reply@example.com"
|
60
|
+
|
61
|
+
# }}}
|
62
|
+
|
63
|
+
|
64
|
+
# vim: set fdm=marker:
|
@@ -0,0 +1,74 @@
|
|
1
|
+
Connecting to database specified by database.yml
|
2
|
+
Connecting to database specified by database.yml
|
3
|
+
Connecting to database specified by database.yml
|
4
|
+
Connecting to database specified by database.yml
|
5
|
+
[1m[36m (228.2ms)[0m [1mCREATE TABLE `schema_migrations` (`version` varchar(255) NOT NULL) ENGINE=InnoDB[0m
|
6
|
+
[1m[35m (428.0ms)[0m CREATE UNIQUE INDEX `unique_schema_migrations` ON `schema_migrations` (`version`)
|
7
|
+
[1m[36m (39.0ms)[0m [1mSELECT `schema_migrations`.`version` FROM `schema_migrations` [0m
|
8
|
+
Migrating to CreateSettings (20130204164516)
|
9
|
+
[1m[35m (123.7ms)[0m CREATE TABLE `settings` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `var` varchar(255) NOT NULL, `value` text, `thing_id` int(11), `thing_type` varchar(30), `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB
|
10
|
+
[1m[36m (172.7ms)[0m [1mCREATE UNIQUE INDEX `index_settings_on_thing_type_and_thing_id_and_var` ON `settings` (`thing_type`, `thing_id`, `var`)[0m
|
11
|
+
[1m[35m (1.0ms)[0m INSERT INTO `schema_migrations` (`version`) VALUES ('20130204164516')
|
12
|
+
Migrating to CreateReleafNodes (20130204164523)
|
13
|
+
[1m[36m (121.1ms)[0m [1mCREATE TABLE `releaf_nodes` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `name` varchar(255), `slug` varchar(255), `parent_id` int(11), `lft` int(11), `rgt` int(11), `content_type` varchar(255), `content_id` int(11), `data` text, `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL, `content_string` varchar(255), `position` int(11), `visible` tinyint(1) DEFAULT 1 NOT NULL, `protected` tinyint(1) DEFAULT 0 NOT NULL) ENGINE=InnoDB[0m
|
14
|
+
[1m[35m (178.6ms)[0m CREATE INDEX `index_releaf_nodes_on_parent_id` ON `releaf_nodes` (`parent_id`)
|
15
|
+
[1m[36m (145.3ms)[0m [1mCREATE INDEX `index_releaf_nodes_on_content_type_and_content_id` ON `releaf_nodes` (`content_type`, `content_id`)[0m
|
16
|
+
[1m[35m (147.1ms)[0m CREATE INDEX `index_releaf_nodes_on_lft` ON `releaf_nodes` (`lft`)
|
17
|
+
[1m[36m (148.0ms)[0m [1mCREATE INDEX `index_releaf_nodes_on_rgt` ON `releaf_nodes` (`rgt`)[0m
|
18
|
+
[1m[35m (156.3ms)[0m CREATE INDEX `index_releaf_nodes_on_slug` ON `releaf_nodes` (`slug`)
|
19
|
+
[1m[36m (2.8ms)[0m [1mINSERT INTO `schema_migrations` (`version`) VALUES ('20130204164523')[0m
|
20
|
+
Migrating to CreateReleafRoles (20130204164524)
|
21
|
+
[1m[35m (128.0ms)[0m CREATE TABLE `releaf_roles` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `name` varchar(255) NOT NULL, `permissions` text, `default` tinyint(1) DEFAULT 0 NOT NULL, `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB
|
22
|
+
[1m[36m (2.2ms)[0m [1mINSERT INTO `schema_migrations` (`version`) VALUES ('20130204164524')[0m
|
23
|
+
Migrating to CreateReleafTranslations (20130204164525)
|
24
|
+
[1m[35m (147.8ms)[0m CREATE TABLE `releaf_translation_groups` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `scope` varchar(255) NOT NULL, `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB
|
25
|
+
[1m[36m (140.7ms)[0m [1mCREATE UNIQUE INDEX `index_releaf_translation_groups_on_scope` ON `releaf_translation_groups` (`scope`)[0m
|
26
|
+
[1m[35m (131.7ms)[0m CREATE TABLE `releaf_translations` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `group_id` int(11) NOT NULL, `key` varchar(255) NOT NULL, `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB
|
27
|
+
[1m[36m (149.0ms)[0m [1mCREATE UNIQUE INDEX `index_releaf_translations_on_group_id_and_key` ON `releaf_translations` (`group_id`, `key`)[0m
|
28
|
+
[1m[35m (138.1ms)[0m CREATE INDEX `index_releaf_translations_on_group_id` ON `releaf_translations` (`group_id`)
|
29
|
+
[1m[36m (133.4ms)[0m [1mCREATE TABLE `releaf_translation_data` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `translation_id` int(11) NOT NULL, `lang` varchar(5) NOT NULL, `localization` text, `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB[0m
|
30
|
+
[1m[35m (138.5ms)[0m CREATE INDEX `index_releaf_translation_data_on_lang` ON `releaf_translation_data` (`lang`)
|
31
|
+
[1m[36m (135.2ms)[0m [1mCREATE INDEX `index_releaf_translation_data_on_translation_id` ON `releaf_translation_data` (`translation_id`)[0m
|
32
|
+
[1m[35m (132.7ms)[0m CREATE UNIQUE INDEX `index_releaf_translation_data_on_lang_and_translation_id` ON `releaf_translation_data` (`lang`, `translation_id`)
|
33
|
+
[1m[36m (1.8ms)[0m [1mINSERT INTO `schema_migrations` (`version`) VALUES ('20130204164525')[0m
|
34
|
+
Migrating to CreateReleafAdmins (20130204164526)
|
35
|
+
[1m[35m (125.1ms)[0m CREATE TABLE `releaf_admins` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `name` varchar(255) NOT NULL, `surname` varchar(255) NOT NULL, `phone` varchar(255), `avatar_uid` varchar(255), `role_id` int(11), `email` varchar(255) DEFAULT '' NOT NULL, `encrypted_password` varchar(255) DEFAULT '' NOT NULL, `reset_password_token` varchar(255), `reset_password_sent_at` datetime, `remember_created_at` datetime, `sign_in_count` int(11) DEFAULT 0, `current_sign_in_at` datetime, `last_sign_in_at` datetime, `current_sign_in_ip` varchar(255), `last_sign_in_ip` varchar(255), `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB
|
36
|
+
[1m[36m (169.1ms)[0m [1mCREATE INDEX `index_releaf_admins_on_role_id` ON `releaf_admins` (`role_id`)[0m
|
37
|
+
[1m[35m (145.9ms)[0m CREATE UNIQUE INDEX `index_releaf_admins_on_email` ON `releaf_admins` (`email`)
|
38
|
+
[1m[36m (140.5ms)[0m [1mCREATE UNIQUE INDEX `index_releaf_admins_on_reset_password_token` ON `releaf_admins` (`reset_password_token`)[0m
|
39
|
+
[1m[35m (0.9ms)[0m INSERT INTO `schema_migrations` (`version`) VALUES ('20130204164526')
|
40
|
+
[1m[36m (0.2ms)[0m [1mSELECT `schema_migrations`.`version` FROM `schema_migrations` [0m
|
41
|
+
Connecting to database specified by database.yml
|
42
|
+
[1m[36m (3.0ms)[0m [1mSELECT `schema_migrations`.`version` FROM `schema_migrations` [0m
|
43
|
+
[1m[35m (0.5ms)[0m DROP DATABASE IF EXISTS `dummy_test`
|
44
|
+
[1m[36m (0.4ms)[0m [1mCREATE DATABASE `dummy_test` DEFAULT CHARACTER SET `utf8` COLLATE `utf8_unicode_ci`[0m
|
45
|
+
[1m[35m (80.0ms)[0m CREATE TABLE `releaf_admins` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `name` varchar(255) NOT NULL, `surname` varchar(255) NOT NULL, `phone` varchar(255), `avatar_uid` varchar(255), `role_id` int(11), `email` varchar(255) DEFAULT '' NOT NULL, `encrypted_password` varchar(255) DEFAULT '' NOT NULL, `reset_password_token` varchar(255), `reset_password_sent_at` datetime, `remember_created_at` datetime, `sign_in_count` int(11) DEFAULT 0, `current_sign_in_at` datetime, `last_sign_in_at` datetime, `current_sign_in_ip` varchar(255), `last_sign_in_ip` varchar(255), `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB
|
46
|
+
[1m[36m (216.6ms)[0m [1mCREATE UNIQUE INDEX `index_releaf_admins_on_email` ON `releaf_admins` (`email`)[0m
|
47
|
+
[1m[35m (184.8ms)[0m CREATE UNIQUE INDEX `index_releaf_admins_on_reset_password_token` ON `releaf_admins` (`reset_password_token`)
|
48
|
+
[1m[36m (152.5ms)[0m [1mCREATE INDEX `index_releaf_admins_on_role_id` ON `releaf_admins` (`role_id`)[0m
|
49
|
+
[1m[35m (119.1ms)[0m CREATE TABLE `releaf_nodes` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `name` varchar(255), `slug` varchar(255), `parent_id` int(11), `lft` int(11), `rgt` int(11), `content_type` varchar(255), `content_id` int(11), `data` text, `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL, `content_string` varchar(255), `position` int(11), `visible` tinyint(1) DEFAULT 1 NOT NULL, `protected` tinyint(1) DEFAULT 0 NOT NULL) ENGINE=InnoDB
|
50
|
+
[1m[36m (170.6ms)[0m [1mCREATE INDEX `index_releaf_nodes_on_content_type_and_content_id` ON `releaf_nodes` (`content_type`, `content_id`)[0m
|
51
|
+
[1m[35m (128.7ms)[0m CREATE INDEX `index_releaf_nodes_on_lft` ON `releaf_nodes` (`lft`)
|
52
|
+
[1m[36m (247.4ms)[0m [1mCREATE INDEX `index_releaf_nodes_on_parent_id` ON `releaf_nodes` (`parent_id`)[0m
|
53
|
+
[1m[35m (354.3ms)[0m CREATE INDEX `index_releaf_nodes_on_rgt` ON `releaf_nodes` (`rgt`)
|
54
|
+
[1m[36m (595.0ms)[0m [1mCREATE INDEX `index_releaf_nodes_on_slug` ON `releaf_nodes` (`slug`)[0m
|
55
|
+
[1m[35m (213.0ms)[0m CREATE TABLE `releaf_roles` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `name` varchar(255) NOT NULL, `permissions` text, `default` tinyint(1) DEFAULT 0 NOT NULL, `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB
|
56
|
+
[1m[36m (136.7ms)[0m [1mCREATE TABLE `releaf_translation_data` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `translation_id` int(11) NOT NULL, `lang` varchar(5) NOT NULL, `localization` text, `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB[0m
|
57
|
+
[1m[35m (132.8ms)[0m CREATE UNIQUE INDEX `index_releaf_translation_data_on_lang_and_translation_id` ON `releaf_translation_data` (`lang`, `translation_id`)
|
58
|
+
[1m[36m (135.4ms)[0m [1mCREATE INDEX `index_releaf_translation_data_on_lang` ON `releaf_translation_data` (`lang`)[0m
|
59
|
+
[1m[35m (159.7ms)[0m CREATE INDEX `index_releaf_translation_data_on_translation_id` ON `releaf_translation_data` (`translation_id`)
|
60
|
+
[1m[36m (126.1ms)[0m [1mCREATE TABLE `releaf_translation_groups` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `scope` varchar(255) NOT NULL, `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB[0m
|
61
|
+
[1m[35m (154.6ms)[0m CREATE UNIQUE INDEX `index_releaf_translation_groups_on_scope` ON `releaf_translation_groups` (`scope`)
|
62
|
+
[1m[36m (125.9ms)[0m [1mCREATE TABLE `releaf_translations` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `group_id` int(11) NOT NULL, `key` varchar(255) NOT NULL, `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB[0m
|
63
|
+
[1m[35m (180.7ms)[0m CREATE UNIQUE INDEX `index_releaf_translations_on_group_id_and_key` ON `releaf_translations` (`group_id`, `key`)
|
64
|
+
[1m[36m (152.6ms)[0m [1mCREATE INDEX `index_releaf_translations_on_group_id` ON `releaf_translations` (`group_id`)[0m
|
65
|
+
[1m[35m (138.6ms)[0m CREATE TABLE `settings` (`id` int(11) DEFAULT NULL auto_increment PRIMARY KEY, `var` varchar(255) NOT NULL, `value` text, `thing_id` int(11), `thing_type` varchar(30), `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL) ENGINE=InnoDB
|
66
|
+
[1m[36m (151.2ms)[0m [1mCREATE UNIQUE INDEX `index_settings_on_thing_type_and_thing_id_and_var` ON `settings` (`thing_type`, `thing_id`, `var`)[0m
|
67
|
+
[1m[35m (137.6ms)[0m CREATE TABLE `schema_migrations` (`version` varchar(255) NOT NULL) ENGINE=InnoDB
|
68
|
+
[1m[36m (155.5ms)[0m [1mCREATE UNIQUE INDEX `unique_schema_migrations` ON `schema_migrations` (`version`)[0m
|
69
|
+
[1m[35m (0.2ms)[0m SELECT version FROM `schema_migrations`
|
70
|
+
[1m[36m (2.3ms)[0m [1mINSERT INTO `schema_migrations` (version) VALUES ('20130204164526')[0m
|
71
|
+
[1m[35m (0.8ms)[0m INSERT INTO `schema_migrations` (version) VALUES ('20130204164516')
|
72
|
+
[1m[36m (0.8ms)[0m [1mINSERT INTO `schema_migrations` (version) VALUES ('20130204164523')[0m
|
73
|
+
[1m[35m (0.8ms)[0m INSERT INTO `schema_migrations` (version) VALUES ('20130204164524')
|
74
|
+
[1m[36m (1.8ms)[0m [1mINSERT INTO `schema_migrations` (version) VALUES ('20130204164525')[0m
|
@@ -0,0 +1,129 @@
|
|
1
|
+
Connecting to database specified by database.yml
|
2
|
+
[1m[36m (3.0ms)[0m [1mSELECT lang FROM `releaf_translation_data` WHERE (lang IS NOT NULL) GROUP BY lang[0m
|
3
|
+
[1m[35mI18n::Backend::Releaf::Translation Load (2.6ms)[0m SELECT releaf_translations.*, releaf_translation_data.lang as "lang", releaf_translation_data.localization as "localization", releaf_translation_groups.scope as "scope" FROM `releaf_translations` INNER JOIN `releaf_translation_data` ON `releaf_translation_data`.`translation_id` = `releaf_translations`.`id` INNER JOIN `releaf_translation_groups` ON `releaf_translation_groups`.`id` = `releaf_translations`.`group_id` WHERE (releaf_translation_data.lang IS NOT NULL) AND (`releaf_translations`.`id` >= 0) ORDER BY `releaf_translations`.`id` ASC LIMIT 1000
|
4
|
+
[1m[36mSettings Load (0.5ms)[0m [1mSELECT `settings`.* FROM `settings` WHERE `settings`.`thing_type` IS NULL AND `settings`.`thing_id` IS NULL AND `settings`.`var` = 'i18n_updated_at' LIMIT 1[0m
|
5
|
+
[1m[35m (0.2ms)[0m BEGIN
|
6
|
+
[1m[36m (0.2ms)[0m [1mSAVEPOINT active_record_1[0m
|
7
|
+
[1m[35mReleaf::Role Exists (0.4ms)[0m SELECT 1 AS one FROM `releaf_roles` WHERE `releaf_roles`.`name` = 'role 1' LIMIT 1
|
8
|
+
[1m[36mSQL (0.3ms)[0m [1mINSERT INTO `releaf_roles` (`created_at`, `default`, `name`, `permissions`, `updated_at`) VALUES ('2013-02-04 16:45:47', 0, 'role 1', '---\n- admin\n', '2013-02-04 16:45:47')[0m
|
9
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
10
|
+
[1m[36m (0.2ms)[0m [1mSAVEPOINT active_record_1[0m
|
11
|
+
[1m[35mReleaf::Admin Exists (0.4ms)[0m SELECT 1 AS one FROM `releaf_admins` WHERE `releaf_admins`.`email` = BINARY 'person-1@example.com' LIMIT 1
|
12
|
+
[1m[36mReleaf::Admin Exists (0.2ms)[0m [1mSELECT 1 AS one FROM `releaf_admins` WHERE `releaf_admins`.`email` = 'person-1@example.com' LIMIT 1[0m
|
13
|
+
[1m[35mSQL (0.3ms)[0m INSERT INTO `releaf_admins` (`avatar_uid`, `created_at`, `current_sign_in_at`, `current_sign_in_ip`, `email`, `encrypted_password`, `last_sign_in_at`, `last_sign_in_ip`, `name`, `phone`, `remember_created_at`, `reset_password_sent_at`, `reset_password_token`, `role_id`, `sign_in_count`, `surname`, `updated_at`) VALUES (NULL, '2013-02-04 16:45:47', NULL, NULL, 'person-1@example.com', '$2a$04$pbE/3hbHRSgPEIHt6LqKy.IRJ58PwHnDM2wF8TUxYxhOyzchHY3ty', NULL, NULL, 'admin', NULL, NULL, NULL, NULL, 1, 0, 'admin', '2013-02-04 16:45:47')
|
14
|
+
[1m[36m (0.1ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
15
|
+
Started GET "/admin" for 127.0.0.1 at 2013-02-04 18:45:47 +0200
|
16
|
+
Processing by Releaf::ContentController#index as HTML
|
17
|
+
Completed 401 Unauthorized in 1ms
|
18
|
+
[1m[35mI18n::Backend::Releaf::Translation Exists (0.4ms)[0m SELECT 1 AS one FROM `releaf_translations` WHERE (releaf_translations.key IN ('devise.failure.releaf_admin.unauthenticated','devise.failure.unauthenticated','devise.unauthenticated','unauthenticated')) LIMIT 1
|
19
|
+
[1m[36mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m [1mSELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'devise.failure.releaf_admin' LIMIT 1[0m
|
20
|
+
[1m[35m (0.1ms)[0m SAVEPOINT active_record_1
|
21
|
+
[1m[36mSQL (0.4ms)[0m [1mINSERT INTO `releaf_translation_groups` (`created_at`, `scope`, `updated_at`) VALUES ('2013-02-04 16:45:47', 'devise.failure.releaf_admin', '2013-02-04 16:45:47')[0m
|
22
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
23
|
+
[1m[36mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m [1mSELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'devise.failure' LIMIT 1[0m
|
24
|
+
[1m[35m (0.1ms)[0m SAVEPOINT active_record_1
|
25
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `releaf_translation_groups` (`created_at`, `scope`, `updated_at`) VALUES ('2013-02-04 16:45:47', 'devise.failure', '2013-02-04 16:45:47')[0m
|
26
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
27
|
+
[1m[36mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m [1mSELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'devise' LIMIT 1[0m
|
28
|
+
[1m[35m (0.1ms)[0m SAVEPOINT active_record_1
|
29
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `releaf_translation_groups` (`created_at`, `scope`, `updated_at`) VALUES ('2013-02-04 16:45:47', 'devise', '2013-02-04 16:45:47')[0m
|
30
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
31
|
+
[1m[36mI18n::Backend::Releaf::Translation Load (0.3ms)[0m [1mSELECT `releaf_translations`.* FROM `releaf_translations` WHERE `releaf_translations`.`group_id` = 1 AND `releaf_translations`.`key` = 'devise.failure.releaf_admin.unauthenticated' ORDER BY releaf_translations.key LIMIT 1[0m
|
32
|
+
[1m[35m (0.1ms)[0m SAVEPOINT active_record_1
|
33
|
+
[1m[36mI18n::Backend::Releaf::Translation Exists (0.4ms)[0m [1mSELECT 1 AS one FROM `releaf_translations` WHERE (`releaf_translations`.`key` = BINARY 'devise.failure.releaf_admin.unauthenticated' AND `releaf_translations`.`group_id` = 1) LIMIT 1[0m
|
34
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO `releaf_translations` (`created_at`, `group_id`, `key`, `updated_at`) VALUES ('2013-02-04 16:45:47', 1, 'devise.failure.releaf_admin.unauthenticated', '2013-02-04 16:45:47')
|
35
|
+
[1m[36m (0.1ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
36
|
+
[1m[35mI18n::Backend::Releaf::Translation Exists (0.2ms)[0m SELECT 1 AS one FROM `releaf_translations` WHERE (releaf_translations.key IN ('devise.failure.unauthenticated','devise.unauthenticated','unauthenticated')) LIMIT 1
|
37
|
+
[1m[36mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m [1mSELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'devise.failure' LIMIT 1[0m
|
38
|
+
[1m[35mI18n::Backend::Releaf::TranslationGroup Load (0.3ms)[0m SELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'devise' LIMIT 1
|
39
|
+
[1m[36mI18n::Backend::Releaf::Translation Load (0.3ms)[0m [1mSELECT `releaf_translations`.* FROM `releaf_translations` WHERE `releaf_translations`.`group_id` = 2 AND `releaf_translations`.`key` = 'devise.failure.unauthenticated' ORDER BY releaf_translations.key LIMIT 1[0m
|
40
|
+
[1m[35m (0.1ms)[0m SAVEPOINT active_record_1
|
41
|
+
[1m[36mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m [1mSELECT 1 AS one FROM `releaf_translations` WHERE (`releaf_translations`.`key` = BINARY 'devise.failure.unauthenticated' AND `releaf_translations`.`group_id` = 2) LIMIT 1[0m
|
42
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO `releaf_translations` (`created_at`, `group_id`, `key`, `updated_at`) VALUES ('2013-02-04 16:45:47', 2, 'devise.failure.unauthenticated', '2013-02-04 16:45:47')
|
43
|
+
[1m[36m (0.1ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
44
|
+
Started GET "/admin/sign_in" for 127.0.0.1 at 2013-02-04 18:45:48 +0200
|
45
|
+
Processing by Releaf::SessionsController#new as HTML
|
46
|
+
Rendered /Users/miks/code/releaf/app/views/releaf/sessions/new.html.haml within layouts/releaf/admin (5.5ms)
|
47
|
+
Completed 200 OK in 26ms (Views: 25.2ms | ActiveRecord: 0.0ms)
|
48
|
+
Started POST "/admin/sign_in" for 127.0.0.1 at 2013-02-04 18:45:48 +0200
|
49
|
+
Processing by Releaf::SessionsController#create as HTML
|
50
|
+
Parameters: {"utf8"=>"✓", "releaf_admin"=>{"email"=>"person-1@example.com", "password"=>"[FILTERED]"}}
|
51
|
+
[1m[35mReleaf::Admin Load (0.4ms)[0m SELECT `releaf_admins`.* FROM `releaf_admins` WHERE `releaf_admins`.`email` = 'person-1@example.com' LIMIT 1
|
52
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
53
|
+
[1m[35m (0.4ms)[0m UPDATE `releaf_admins` SET `last_sign_in_at` = '2013-02-04 16:45:48', `current_sign_in_at` = '2013-02-04 16:45:48', `last_sign_in_ip` = '127.0.0.1', `current_sign_in_ip` = '127.0.0.1', `sign_in_count` = 1, `updated_at` = '2013-02-04 16:45:48' WHERE `releaf_admins`.`id` = 1
|
54
|
+
[1m[36m (0.1ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
55
|
+
[1m[35mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m SELECT 1 AS one FROM `releaf_translations` WHERE (releaf_translations.key IN ('devise.sessions.releaf_admin.signed_in','devise.sessions.signed_in','devise.signed_in','signed_in')) LIMIT 1
|
56
|
+
[1m[36mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m [1mSELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'devise.sessions.releaf_admin' LIMIT 1[0m
|
57
|
+
[1m[35m (0.1ms)[0m SAVEPOINT active_record_1
|
58
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `releaf_translation_groups` (`created_at`, `scope`, `updated_at`) VALUES ('2013-02-04 16:45:48', 'devise.sessions.releaf_admin', '2013-02-04 16:45:48')[0m
|
59
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
60
|
+
[1m[36mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m [1mSELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'devise.sessions' LIMIT 1[0m
|
61
|
+
[1m[35m (0.1ms)[0m SAVEPOINT active_record_1
|
62
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `releaf_translation_groups` (`created_at`, `scope`, `updated_at`) VALUES ('2013-02-04 16:45:48', 'devise.sessions', '2013-02-04 16:45:48')[0m
|
63
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
64
|
+
[1m[36mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m [1mSELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'devise' LIMIT 1[0m
|
65
|
+
[1m[35mI18n::Backend::Releaf::Translation Load (0.2ms)[0m SELECT `releaf_translations`.* FROM `releaf_translations` WHERE `releaf_translations`.`group_id` = 4 AND `releaf_translations`.`key` = 'devise.sessions.releaf_admin.signed_in' ORDER BY releaf_translations.key LIMIT 1
|
66
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
67
|
+
[1m[35mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m SELECT 1 AS one FROM `releaf_translations` WHERE (`releaf_translations`.`key` = BINARY 'devise.sessions.releaf_admin.signed_in' AND `releaf_translations`.`group_id` = 4) LIMIT 1
|
68
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `releaf_translations` (`created_at`, `group_id`, `key`, `updated_at`) VALUES ('2013-02-04 16:45:48', 4, 'devise.sessions.releaf_admin.signed_in', '2013-02-04 16:45:48')[0m
|
69
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
70
|
+
[1m[36mI18n::Backend::Releaf::Translation Exists (0.2ms)[0m [1mSELECT 1 AS one FROM `releaf_translations` WHERE (releaf_translations.key IN ('devise.sessions.signed_in','devise.signed_in','signed_in')) LIMIT 1[0m
|
71
|
+
[1m[35mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m SELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'devise.sessions' LIMIT 1
|
72
|
+
[1m[36mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m [1mSELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'devise' LIMIT 1[0m
|
73
|
+
[1m[35mI18n::Backend::Releaf::Translation Load (0.2ms)[0m SELECT `releaf_translations`.* FROM `releaf_translations` WHERE `releaf_translations`.`group_id` = 5 AND `releaf_translations`.`key` = 'devise.sessions.signed_in' ORDER BY releaf_translations.key LIMIT 1
|
74
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
75
|
+
[1m[35mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m SELECT 1 AS one FROM `releaf_translations` WHERE (`releaf_translations`.`key` = BINARY 'devise.sessions.signed_in' AND `releaf_translations`.`group_id` = 5) LIMIT 1
|
76
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `releaf_translations` (`created_at`, `group_id`, `key`, `updated_at`) VALUES ('2013-02-04 16:45:48', 5, 'devise.sessions.signed_in', '2013-02-04 16:45:48')[0m
|
77
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
78
|
+
Redirected to http://www.example.com/admin
|
79
|
+
Completed 302 Found in 35ms (ActiveRecord: 0.0ms)
|
80
|
+
Started GET "/admin" for 127.0.0.1 at 2013-02-04 18:45:48 +0200
|
81
|
+
Processing by Releaf::ContentController#index as HTML
|
82
|
+
[1m[36mReleaf::Admin Load (0.4ms)[0m [1mSELECT `releaf_admins`.* FROM `releaf_admins` WHERE `releaf_admins`.`id` = 1 LIMIT 1[0m
|
83
|
+
[1m[35mReleaf::Role Load (0.3ms)[0m SELECT `releaf_roles`.* FROM `releaf_roles` WHERE `releaf_roles`.`id` = 1 LIMIT 1
|
84
|
+
Rendered /Users/miks/code/releaf/app/views/releaf/content/index.haml within layouts/releaf/admin (0.7ms)
|
85
|
+
[1m[36mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m [1mSELECT 1 AS one FROM `releaf_translations` WHERE (releaf_translations.key IN ('global.logout','logout')) LIMIT 1[0m
|
86
|
+
[1m[35mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m SELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'global' LIMIT 1
|
87
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
88
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO `releaf_translation_groups` (`created_at`, `scope`, `updated_at`) VALUES ('2013-02-04 16:45:48', 'global', '2013-02-04 16:45:48')
|
89
|
+
[1m[36m (0.1ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
90
|
+
[1m[35mI18n::Backend::Releaf::Translation Load (0.2ms)[0m SELECT `releaf_translations`.* FROM `releaf_translations` WHERE `releaf_translations`.`group_id` = 6 AND `releaf_translations`.`key` = 'global.logout' ORDER BY releaf_translations.key LIMIT 1
|
91
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
92
|
+
[1m[35mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m SELECT 1 AS one FROM `releaf_translations` WHERE (`releaf_translations`.`key` = BINARY 'global.logout' AND `releaf_translations`.`group_id` = 6) LIMIT 1
|
93
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `releaf_translations` (`created_at`, `group_id`, `key`, `updated_at`) VALUES ('2013-02-04 16:45:48', 6, 'global.logout', '2013-02-04 16:45:48')[0m
|
94
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
95
|
+
[1m[36mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m [1mSELECT 1 AS one FROM `releaf_translations` WHERE (releaf_translations.key IN ('admin.main_menu.releaf/content','admin.releaf/content','releaf/content')) LIMIT 1[0m
|
96
|
+
[1m[35mI18n::Backend::Releaf::TranslationGroup Load (0.3ms)[0m SELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'admin.main_menu' LIMIT 1
|
97
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
98
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO `releaf_translation_groups` (`created_at`, `scope`, `updated_at`) VALUES ('2013-02-04 16:45:48', 'admin.main_menu', '2013-02-04 16:45:48')
|
99
|
+
[1m[36m (0.1ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
100
|
+
[1m[35mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m SELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'admin' LIMIT 1
|
101
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
102
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO `releaf_translation_groups` (`created_at`, `scope`, `updated_at`) VALUES ('2013-02-04 16:45:48', 'admin', '2013-02-04 16:45:48')
|
103
|
+
[1m[36m (0.1ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
104
|
+
[1m[35mI18n::Backend::Releaf::Translation Load (0.2ms)[0m SELECT `releaf_translations`.* FROM `releaf_translations` WHERE `releaf_translations`.`group_id` = 7 AND `releaf_translations`.`key` = 'admin.main_menu.releaf/content' ORDER BY releaf_translations.key LIMIT 1
|
105
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
106
|
+
[1m[35mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m SELECT 1 AS one FROM `releaf_translations` WHERE (`releaf_translations`.`key` = BINARY 'admin.main_menu.releaf/content' AND `releaf_translations`.`group_id` = 7) LIMIT 1
|
107
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `releaf_translations` (`created_at`, `group_id`, `key`, `updated_at`) VALUES ('2013-02-04 16:45:48', 7, 'admin.main_menu.releaf/content', '2013-02-04 16:45:48')[0m
|
108
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
109
|
+
[1m[36mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m [1mSELECT 1 AS one FROM `releaf_translations` WHERE (releaf_translations.key IN ('admin.main_menu.*permissions','admin.*permissions','*permissions')) LIMIT 1[0m
|
110
|
+
[1m[35mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m SELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'admin.main_menu' LIMIT 1
|
111
|
+
[1m[36mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m [1mSELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'admin' LIMIT 1[0m
|
112
|
+
[1m[35mI18n::Backend::Releaf::Translation Load (0.2ms)[0m SELECT `releaf_translations`.* FROM `releaf_translations` WHERE `releaf_translations`.`group_id` = 7 AND `releaf_translations`.`key` = 'admin.main_menu.*permissions' ORDER BY releaf_translations.key LIMIT 1
|
113
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
114
|
+
[1m[35mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m SELECT 1 AS one FROM `releaf_translations` WHERE (`releaf_translations`.`key` = BINARY 'admin.main_menu.*permissions' AND `releaf_translations`.`group_id` = 7) LIMIT 1
|
115
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `releaf_translations` (`created_at`, `group_id`, `key`, `updated_at`) VALUES ('2013-02-04 16:45:48', 7, 'admin.main_menu.*permissions', '2013-02-04 16:45:48')[0m
|
116
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
117
|
+
[1m[36mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m [1mSELECT 1 AS one FROM `releaf_translations` WHERE (releaf_translations.key IN ('admin.main_menu.releaf/translations','admin.releaf/translations','releaf/translations')) LIMIT 1[0m
|
118
|
+
[1m[35mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m SELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'admin.main_menu' LIMIT 1
|
119
|
+
[1m[36mI18n::Backend::Releaf::TranslationGroup Load (0.2ms)[0m [1mSELECT `releaf_translation_groups`.* FROM `releaf_translation_groups` WHERE `releaf_translation_groups`.`scope` = 'admin' LIMIT 1[0m
|
120
|
+
[1m[35mI18n::Backend::Releaf::Translation Load (0.2ms)[0m SELECT `releaf_translations`.* FROM `releaf_translations` WHERE `releaf_translations`.`group_id` = 7 AND `releaf_translations`.`key` = 'admin.main_menu.releaf/translations' ORDER BY releaf_translations.key LIMIT 1
|
121
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
122
|
+
[1m[35mI18n::Backend::Releaf::Translation Exists (0.3ms)[0m SELECT 1 AS one FROM `releaf_translations` WHERE (`releaf_translations`.`key` = BINARY 'admin.main_menu.releaf/translations' AND `releaf_translations`.`group_id` = 7) LIMIT 1
|
123
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `releaf_translations` (`created_at`, `group_id`, `key`, `updated_at`) VALUES ('2013-02-04 16:45:48', 7, 'admin.main_menu.releaf/translations', '2013-02-04 16:45:48')[0m
|
124
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
125
|
+
[1m[36mReleaf::Node Load (0.4ms)[0m [1mSELECT `releaf_nodes`.* FROM `releaf_nodes` WHERE `releaf_nodes`.`parent_id` IS NULL ORDER BY position, `releaf_nodes`.`lft`[0m
|
126
|
+
Rendered /Users/miks/code/releaf/app/views/releaf/content/_tree_level.haml (10.9ms)
|
127
|
+
Rendered /Users/miks/code/releaf/app/views/releaf/content/_secondary_panel.haml (16.6ms)
|
128
|
+
Completed 200 OK in 112ms (Views: 85.3ms | ActiveRecord: 12.3ms)
|
129
|
+
[1m[35m (1.5ms)[0m ROLLBACK
|
@@ -0,0 +1,26 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<title>The page you were looking for doesn't exist (404)</title>
|
5
|
+
<style type="text/css">
|
6
|
+
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
7
|
+
div.dialog {
|
8
|
+
width: 25em;
|
9
|
+
padding: 0 4em;
|
10
|
+
margin: 4em auto 0 auto;
|
11
|
+
border: 1px solid #ccc;
|
12
|
+
border-right-color: #999;
|
13
|
+
border-bottom-color: #999;
|
14
|
+
}
|
15
|
+
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
16
|
+
</style>
|
17
|
+
</head>
|
18
|
+
|
19
|
+
<body>
|
20
|
+
<!-- This file lives in public/404.html -->
|
21
|
+
<div class="dialog">
|
22
|
+
<h1>The page you were looking for doesn't exist.</h1>
|
23
|
+
<p>You may have mistyped the address or the page may have moved.</p>
|
24
|
+
</div>
|
25
|
+
</body>
|
26
|
+
</html>
|
@@ -0,0 +1,26 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<title>The change you wanted was rejected (422)</title>
|
5
|
+
<style type="text/css">
|
6
|
+
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
7
|
+
div.dialog {
|
8
|
+
width: 25em;
|
9
|
+
padding: 0 4em;
|
10
|
+
margin: 4em auto 0 auto;
|
11
|
+
border: 1px solid #ccc;
|
12
|
+
border-right-color: #999;
|
13
|
+
border-bottom-color: #999;
|
14
|
+
}
|
15
|
+
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
16
|
+
</style>
|
17
|
+
</head>
|
18
|
+
|
19
|
+
<body>
|
20
|
+
<!-- This file lives in public/422.html -->
|
21
|
+
<div class="dialog">
|
22
|
+
<h1>The change you wanted was rejected.</h1>
|
23
|
+
<p>Maybe you tried to change something you didn't have access to.</p>
|
24
|
+
</div>
|
25
|
+
</body>
|
26
|
+
</html>
|
@@ -0,0 +1,25 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<title>We're sorry, but something went wrong (500)</title>
|
5
|
+
<style type="text/css">
|
6
|
+
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
7
|
+
div.dialog {
|
8
|
+
width: 25em;
|
9
|
+
padding: 0 4em;
|
10
|
+
margin: 4em auto 0 auto;
|
11
|
+
border: 1px solid #ccc;
|
12
|
+
border-right-color: #999;
|
13
|
+
border-bottom-color: #999;
|
14
|
+
}
|
15
|
+
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
16
|
+
</style>
|
17
|
+
</head>
|
18
|
+
|
19
|
+
<body>
|
20
|
+
<!-- This file lives in public/500.html -->
|
21
|
+
<div class="dialog">
|
22
|
+
<h1>We're sorry, but something went wrong.</h1>
|
23
|
+
</div>
|
24
|
+
</body>
|
25
|
+
</html>
|
File without changes
|
@@ -0,0 +1,6 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
# This command will automatically be run when you run "rails" with Rails 3 gems installed from the root of your application.
|
3
|
+
|
4
|
+
APP_PATH = File.expand_path('../../config/application', __FILE__)
|
5
|
+
require File.expand_path('../../config/boot', __FILE__)
|
6
|
+
require 'rails/commands'
|
@@ -0,0 +1 @@
|
|
1
|
+
o: ActiveSupport::Cache::Entry :@compressedF:@expires_in0:@created_atf1359996345.613906:@value0
|
@@ -0,0 +1,24 @@
|
|
1
|
+
FactoryGirl.define do
|
2
|
+
sequence(:email) {|n| "person-#{n}@example.com" }
|
3
|
+
|
4
|
+
factory :admin, :class => :'Releaf::Admin' do
|
5
|
+
email
|
6
|
+
name 'admin'
|
7
|
+
surname 'admin'
|
8
|
+
password 'password'
|
9
|
+
password_confirmation 'password'
|
10
|
+
end
|
11
|
+
|
12
|
+
factory :role, :class => :'Releaf::Role' do
|
13
|
+
sequence(:name) {|n| "role #{n}"}
|
14
|
+
|
15
|
+
trait :admin do
|
16
|
+
admin_permission true
|
17
|
+
end
|
18
|
+
|
19
|
+
trait :default do
|
20
|
+
default true
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
end
|
@@ -0,0 +1,41 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
describe "home page" do
|
3
|
+
before do
|
4
|
+
module Leaf
|
5
|
+
end
|
6
|
+
@role = create(:role, :admin)
|
7
|
+
@admin = build(:admin)
|
8
|
+
@admin.role_id = @role.id
|
9
|
+
@admin.save
|
10
|
+
|
11
|
+
end
|
12
|
+
|
13
|
+
describe "login as admin procedure" do
|
14
|
+
before do
|
15
|
+
visit "/admin"
|
16
|
+
within("form.login_form") do
|
17
|
+
fill_in 'Email', :with => @admin.email
|
18
|
+
fill_in 'Password', :with => @admin.password
|
19
|
+
end
|
20
|
+
click_button 'Sign in'
|
21
|
+
end
|
22
|
+
|
23
|
+
it "admin page content" do
|
24
|
+
page.should have_content 'Logout'
|
25
|
+
page.should have_content 'Releaf/content'
|
26
|
+
page.should have_content '*permissions'
|
27
|
+
page.should have_content 'Releaf/translations'
|
28
|
+
end
|
29
|
+
|
30
|
+
it "logout sequence" do
|
31
|
+
click_link 'Logout'
|
32
|
+
|
33
|
+
page.should have_content 'Welcome to re:Leaf'
|
34
|
+
|
35
|
+
visit "/admin"
|
36
|
+
page.should have_content 'Sign in'
|
37
|
+
end
|
38
|
+
|
39
|
+
|
40
|
+
end
|
41
|
+
end
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,23 @@
|
|
1
|
+
ENV['RAILS_ENV'] ||= 'test'
|
2
|
+
require File.expand_path("../dummy/config/environment.rb", __FILE__)
|
3
|
+
require 'rspec/rails'
|
4
|
+
require 'rspec/autorun'
|
5
|
+
require 'factory_girl'
|
6
|
+
require 'capybara/rspec'
|
7
|
+
Rails.backtrace_cleaner.remove_silencers!
|
8
|
+
# Load support files
|
9
|
+
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }
|
10
|
+
RSpec.configure do |config|
|
11
|
+
config.mock_with :rspec
|
12
|
+
config.use_transactional_fixtures = true
|
13
|
+
config.infer_base_class_for_anonymous_controllers = false
|
14
|
+
config.order = "random"
|
15
|
+
|
16
|
+
# DEVISE
|
17
|
+
config.include Devise::TestHelpers, :type => :controller
|
18
|
+
|
19
|
+
# FactoryGirl
|
20
|
+
config.include FactoryGirl::Syntax::Methods
|
21
|
+
end
|
22
|
+
|
23
|
+
Dir["#{File.dirname(__FILE__)}/factories/*.rb"].each { |f| require f }
|