alchemy_cms 2.5.3.1 → 2.6.0.rc5
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +1 -1
- data/.travis.yml +5 -13
- data/Gemfile +6 -3
- data/README.md +3 -2
- data/alchemy_cms.gemspec +22 -22
- data/app/assets/fonts/alchemy-icons.eot +0 -0
- data/app/assets/fonts/alchemy-icons.svg +54 -0
- data/app/assets/fonts/alchemy-icons.ttf +0 -0
- data/app/assets/fonts/alchemy-icons.woff +0 -0
- data/app/assets/images/alchemy/icons.png +0 -0
- data/app/assets/javascripts/alchemy/alchemy.base.js.coffee +151 -0
- data/app/assets/javascripts/alchemy/alchemy.buttons.js.coffee +3 -2
- data/app/assets/javascripts/alchemy/alchemy.datepicker.js.coffee +31 -0
- data/app/assets/javascripts/alchemy/alchemy.dragndrop.js +1 -1
- data/app/assets/javascripts/alchemy/alchemy.element_editors.js.coffee +98 -0
- data/app/assets/javascripts/alchemy/alchemy.elements_window.js.coffee +23 -24
- data/app/assets/javascripts/alchemy/alchemy.growler.js.coffee +27 -0
- data/app/assets/javascripts/alchemy/alchemy.gui.js.coffee +11 -8
- data/app/assets/javascripts/alchemy/alchemy.hotkeys.js.coffee +32 -0
- data/app/assets/javascripts/alchemy/alchemy.image_cropper.js.coffee +46 -0
- data/app/assets/javascripts/alchemy/alchemy.js +8 -2
- data/app/assets/javascripts/alchemy/alchemy.link_overlay.js.coffee +5 -4
- data/app/assets/javascripts/alchemy/alchemy.list_filter.js.coffee +49 -0
- data/app/assets/javascripts/alchemy/alchemy.onload.js.coffee +3 -0
- data/app/assets/javascripts/alchemy/alchemy.preview_window.js.coffee +71 -0
- data/app/assets/javascripts/alchemy/alchemy.sitemap.js.coffee +61 -0
- data/app/assets/javascripts/alchemy/alchemy.spinner.js.coffee +35 -0
- data/app/assets/javascripts/alchemy/alchemy.string_extension.js.coffee +11 -0
- data/app/assets/javascripts/alchemy/alchemy.windows.js.coffee +278 -0
- data/app/assets/stylesheets/alchemy/admin.css.scss +2 -0
- data/app/assets/stylesheets/alchemy/archive.scss +109 -65
- data/app/assets/stylesheets/alchemy/base.scss +16 -188
- data/app/assets/stylesheets/alchemy/dashboard.scss +2 -2
- data/app/assets/stylesheets/alchemy/defaults.scss +2 -1
- data/app/assets/stylesheets/alchemy/elements.scss +58 -94
- data/app/assets/stylesheets/alchemy/errors.scss +2 -2
- data/app/assets/stylesheets/alchemy/{mixins.scss → extends.scss} +104 -80
- data/app/assets/stylesheets/alchemy/flash.scss +4 -6
- data/app/assets/stylesheets/alchemy/fonts.scss +46 -0
- data/app/assets/stylesheets/alchemy/form_elements.scss +46 -45
- data/app/assets/stylesheets/alchemy/frame.scss +20 -15
- data/app/assets/stylesheets/alchemy/icons.scss +22 -9
- data/app/assets/stylesheets/alchemy/jquery-ui.scss +476 -399
- data/app/assets/stylesheets/alchemy/login.scss +1 -1
- data/app/assets/stylesheets/alchemy/menubar.css.scss +1 -1
- data/app/assets/stylesheets/alchemy/notices.scss +5 -5
- data/app/assets/stylesheets/alchemy/pagination.scss +25 -13
- data/app/assets/stylesheets/alchemy/search.scss +29 -17
- data/app/assets/stylesheets/alchemy/sitemap.scss +41 -36
- data/app/assets/stylesheets/alchemy/tables.scss +102 -50
- data/app/assets/stylesheets/alchemy/tinymce_dialog.css.scss +18 -16
- data/app/assets/stylesheets/alchemy/toolbar.scss +84 -24
- data/app/assets/stylesheets/alchemy/upload.scss +14 -9
- data/app/assets/stylesheets/alchemy/variables.scss +1 -0
- data/app/assets/stylesheets/tiny_mce/plugins/inlinepopups/skins/alchemy/window.css.scss +18 -21
- data/app/controllers/alchemy/admin/attachments_controller.rb +29 -39
- data/app/controllers/alchemy/admin/base_controller.rb +3 -9
- data/app/controllers/alchemy/admin/clipboard_controller.rb +1 -1
- data/app/controllers/alchemy/admin/contents_controller.rb +1 -1
- data/app/controllers/alchemy/admin/dashboard_controller.rb +1 -1
- data/app/controllers/alchemy/admin/elements_controller.rb +3 -3
- data/app/controllers/alchemy/admin/essence_files_controller.rb +1 -1
- data/app/controllers/alchemy/admin/essence_pictures_controller.rb +5 -5
- data/app/controllers/alchemy/admin/languages_controller.rb +1 -1
- data/app/controllers/alchemy/admin/pages_controller.rb +18 -16
- data/app/controllers/alchemy/admin/pictures_controller.rb +11 -10
- data/app/controllers/alchemy/admin/resources_controller.rb +87 -14
- data/app/controllers/alchemy/admin/tags_controller.rb +3 -3
- data/app/controllers/alchemy/admin/trash_controller.rb +3 -3
- data/app/controllers/alchemy/admin/users_controller.rb +6 -11
- data/app/controllers/alchemy/attachments_controller.rb +8 -9
- data/app/controllers/alchemy/base_controller.rb +17 -10
- data/app/controllers/alchemy/pages_controller.rb +7 -19
- data/app/controllers/alchemy/passwords_controller.rb +15 -3
- data/app/controllers/alchemy/user_sessions_controller.rb +5 -4
- data/app/controllers/alchemy/users_controller.rb +1 -1
- data/app/helpers/alchemy/admin/attachments_helper.rb +2 -2
- data/app/helpers/alchemy/admin/base_helper.rb +62 -90
- data/app/helpers/alchemy/admin/elements_helper.rb +13 -5
- data/app/helpers/alchemy/admin/essences_helper.rb +3 -5
- data/app/helpers/alchemy/admin/pages_helper.rb +6 -3
- data/app/helpers/alchemy/admin/tags_helper.rb +60 -0
- data/app/helpers/alchemy/base_helper.rb +16 -20
- data/app/helpers/alchemy/elements_helper.rb +7 -11
- data/app/helpers/alchemy/essences_helper.rb +2 -2
- data/app/helpers/alchemy/pages_helper.rb +31 -69
- data/app/helpers/alchemy/url_helper.rb +11 -3
- data/app/models/alchemy/attachment.rb +73 -45
- data/app/models/alchemy/cell.rb +1 -1
- data/app/models/alchemy/content.rb +20 -9
- data/app/models/alchemy/element.rb +9 -7
- data/app/models/alchemy/page.rb +15 -248
- data/app/models/alchemy/page/cells.rb +71 -0
- data/app/models/alchemy/page/elements.rb +147 -0
- data/app/models/alchemy/page/naming.rb +90 -0
- data/app/models/alchemy/picture.rb +18 -13
- data/app/models/alchemy/tag.rb +1 -1
- data/app/models/alchemy/user.rb +38 -6
- data/app/views/alchemy/admin/attachments/_archive_overlay.html.erb +14 -7
- data/app/views/alchemy/admin/attachments/_attachment.html.erb +17 -12
- data/app/views/alchemy/admin/attachments/_file_to_assign.html.erb +3 -8
- data/app/views/alchemy/admin/attachments/_files_list.html.erb +20 -12
- data/app/views/alchemy/admin/attachments/_overlay_file_list.html.erb +11 -0
- data/app/views/alchemy/admin/attachments/_tag_list.html.erb +31 -0
- data/app/views/alchemy/admin/attachments/archive_overlay.js.erb +4 -0
- data/app/views/alchemy/admin/attachments/edit.html.erb +8 -7
- data/app/views/alchemy/admin/attachments/index.html.erb +19 -12
- data/app/views/alchemy/admin/attachments/new.html.erb +2 -2
- data/app/views/alchemy/admin/attachments/show.html.erb +3 -0
- data/app/views/alchemy/admin/contents/_missing.html.erb +4 -4
- data/app/views/alchemy/admin/contents/create.js.erb +1 -1
- data/app/views/alchemy/admin/contents/new.html.erb +6 -3
- data/app/views/alchemy/admin/dashboard/_locked_pages.html.erb +1 -1
- data/app/views/alchemy/admin/dashboard/_users.html.erb +1 -1
- data/app/views/alchemy/admin/dashboard/index.html.erb +3 -3
- data/app/views/alchemy/admin/dashboard/info.html.erb +16 -13
- data/app/views/alchemy/admin/elements/_add_picture.html.erb +1 -1
- data/app/views/alchemy/admin/elements/_element_foot.html.erb +4 -4
- data/app/views/alchemy/admin/elements/_element_head.html.erb +1 -7
- data/app/views/alchemy/admin/elements/_elements_select.html.erb +2 -2
- data/app/views/alchemy/admin/elements/_new_element_form.html.erb +4 -4
- data/app/views/alchemy/admin/elements/_picture_gallery_editor.html.erb +1 -1
- data/app/views/alchemy/admin/elements/create.js.erb +2 -2
- data/app/views/alchemy/admin/elements/fold.js.erb +3 -6
- data/app/views/alchemy/admin/elements/new.html.erb +1 -1
- data/app/views/alchemy/admin/elements/order.js.erb +1 -1
- data/app/views/alchemy/admin/elements/trash.js.erb +1 -1
- data/app/views/alchemy/admin/elements/update.js.erb +2 -2
- data/app/views/alchemy/admin/essence_files/edit.html.erb +4 -4
- data/app/views/alchemy/admin/essence_pictures/crop.html.erb +17 -18
- data/app/views/alchemy/admin/essence_pictures/edit.html.erb +2 -2
- data/app/views/alchemy/admin/essence_pictures/update.js.erb +1 -0
- data/app/views/alchemy/admin/languages/_form.html.erb +12 -10
- data/app/views/alchemy/admin/languages/_language.html.erb +2 -1
- data/app/views/alchemy/admin/languages/_table.html.erb +3 -3
- data/app/views/alchemy/admin/languages/index.html.erb +15 -15
- data/app/views/alchemy/admin/layoutpages/_layoutpage.html.erb +6 -6
- data/app/views/alchemy/admin/layoutpages/index.html.erb +41 -40
- data/app/views/alchemy/admin/pages/_contactform_links.html.erb +4 -4
- data/app/views/alchemy/admin/pages/_create_language_form.html.erb +6 -6
- data/app/views/alchemy/admin/pages/_external_link.html.erb +2 -2
- data/app/views/alchemy/admin/pages/_file_link.html.erb +3 -3
- data/app/views/alchemy/admin/pages/_internal_link.html.erb +1 -1
- data/app/views/alchemy/admin/pages/_new_page_form.html.erb +1 -1
- data/app/views/alchemy/admin/pages/_page.html.erb +13 -13
- data/app/views/alchemy/admin/pages/_page_for_links.html.erb +2 -4
- data/app/views/alchemy/admin/pages/_sitemap.html.erb +5 -0
- data/app/views/alchemy/admin/pages/configure.html.erb +7 -7
- data/app/views/alchemy/admin/pages/configure_external.html.erb +4 -4
- data/app/views/alchemy/admin/pages/edit.html.erb +23 -30
- data/app/views/alchemy/admin/pages/index.html.erb +34 -23
- data/app/views/alchemy/admin/pages/new.html.erb +1 -1
- data/app/views/alchemy/admin/pages/sort.js.erb +1 -1
- data/app/views/alchemy/admin/partials/_flash_upload.html.erb +2 -3
- data/app/views/alchemy/admin/partials/_remote_search_form.html.erb +2 -2
- data/app/views/alchemy/admin/partials/_search_form.html.erb +3 -3
- data/app/views/alchemy/admin/partials/_upload_form.html.erb +2 -2
- data/app/views/alchemy/admin/pictures/_archive.html.erb +7 -7
- data/app/views/alchemy/admin/pictures/_archive_overlay.html.erb +1 -1
- data/app/views/alchemy/admin/pictures/_filter_and_size_bar.html.erb +6 -6
- data/app/views/alchemy/admin/pictures/_filter_bar.html.erb +4 -4
- data/app/views/alchemy/admin/pictures/_overlay_picture_list.html.erb +1 -1
- data/app/views/alchemy/admin/pictures/_picture.html.erb +3 -8
- data/app/views/alchemy/admin/pictures/_picture_to_assign.html.erb +9 -14
- data/app/views/alchemy/admin/pictures/_tag_list.html.erb +27 -25
- data/app/views/alchemy/admin/pictures/archive_overlay.js.erb +3 -1
- data/app/views/alchemy/admin/pictures/index.html.erb +49 -42
- data/app/views/alchemy/admin/pictures/new.html.erb +2 -2
- data/app/views/alchemy/admin/pictures/show.html.erb +11 -0
- data/app/views/alchemy/admin/resources/_boolean.html.erb +2 -2
- data/app/views/alchemy/admin/resources/_datetime.html.erb +2 -2
- data/app/views/alchemy/admin/resources/_form.html.erb +9 -8
- data/app/views/alchemy/admin/resources/_resource.html.erb +15 -21
- data/app/views/alchemy/admin/resources/_string.html.erb +2 -2
- data/app/views/alchemy/admin/resources/_table.html.erb +11 -13
- data/app/views/alchemy/admin/resources/_text.html.erb +2 -2
- data/app/views/alchemy/admin/resources/index.csv.erb +13 -0
- data/app/views/alchemy/admin/resources/index.html.erb +24 -15
- data/app/views/alchemy/admin/sites/index.html.erb +23 -0
- data/app/views/alchemy/admin/tags/_radio_tag.html.erb +1 -1
- data/app/views/alchemy/admin/tags/_tag.html.erb +2 -1
- data/app/views/alchemy/admin/tags/edit.html.erb +1 -1
- data/app/views/alchemy/admin/tags/index.html.erb +16 -11
- data/app/views/alchemy/admin/tags/new.html.erb +3 -3
- data/app/views/alchemy/admin/trash/clear.js.coffee +1 -1
- data/app/views/alchemy/admin/users/_table.html.erb +12 -5
- data/app/views/alchemy/admin/users/_user.html.erb +16 -16
- data/app/views/alchemy/admin/users/index.html.erb +28 -16
- data/app/views/alchemy/breadcrumb/_page.html.erb +15 -0
- data/app/views/alchemy/breadcrumb/_spacer.html.erb +1 -0
- data/app/views/alchemy/elements/_editor_not_found.html.erb +1 -1
- data/app/views/alchemy/essences/_essence_file_editor.html.erb +16 -16
- data/app/views/alchemy/essences/_essence_file_view.html.erb +8 -9
- data/app/views/alchemy/essences/_essence_picture_editor.html.erb +3 -6
- data/app/views/alchemy/essences/_essence_picture_tools.html.erb +9 -8
- data/app/views/alchemy/essences/_essence_richtext_editor.html.erb +0 -5
- data/app/views/alchemy/essences/_linkable_essence_tools.html.erb +2 -2
- data/app/views/alchemy/navigation/_link.html.erb +7 -7
- data/app/views/alchemy/navigation/_renderer.html.erb +29 -36
- data/app/views/alchemy/notifications/admin_user_created.de.text.erb +5 -1
- data/app/views/alchemy/notifications/admin_user_created.en.text.erb +5 -1
- data/app/views/alchemy/notifications/registered_user_created.de.text.erb +13 -0
- data/app/views/alchemy/notifications/registered_user_created.en.text.erb +13 -0
- data/app/views/alchemy/search/_result.html.erb +4 -6
- data/app/views/alchemy/search/_results.html.erb +4 -5
- data/app/views/alchemy/user_sessions/leave.html.erb +1 -1
- data/app/views/alchemy/user_sessions/new.html.erb +2 -2
- data/app/views/kaminari/_first_page.html.erb +11 -0
- data/app/views/kaminari/_gap.html.erb +1 -1
- data/app/views/kaminari/_last_page.html.erb +11 -0
- data/app/views/kaminari/_next_page.html.erb +2 -2
- data/app/views/kaminari/_page.html.erb +1 -1
- data/app/views/kaminari/_paginator.html.erb +2 -0
- data/app/views/kaminari/_prev_page.html.erb +2 -2
- data/app/views/layouts/alchemy/admin.html.erb +4 -5
- data/config/alchemy/config.yml +8 -12
- data/config/authorization_rules.rb +4 -3
- data/config/initializers/dragonfly.rb +20 -12
- data/config/locales/alchemy.de.yml +20 -15
- data/config/locales/alchemy.en.yml +15 -10
- data/config/locales/devise.de.yml +1 -0
- data/config/routes.rb +3 -3
- data/{spec/dummy/db/migrate/20121118000000_alchemy_two_point_four.rb → db/migrate/20130214233001_alchemy_two_point_five.rb} +50 -36
- data/db/migrate/20130221200514_migrate_attachments_to_dragonfly.rb +21 -0
- data/db/migrate/20130312205327_change_alchemy_users_role_to_roles.rb +11 -0
- data/lib/alchemy/capistrano.rb +10 -8
- data/lib/alchemy/errors.rb +7 -0
- data/lib/alchemy/filetypes.rb +33 -0
- data/lib/alchemy/i18n.rb +9 -1
- data/lib/alchemy/name_conversions.rb +28 -0
- data/lib/alchemy/page_layout.rb +5 -3
- data/lib/alchemy/resource.rb +132 -29
- data/lib/alchemy/resources_helper.rb +81 -12
- data/lib/alchemy/upgrader.rb +14 -276
- data/lib/alchemy/version.rb +1 -1
- data/lib/alchemy_cms.rb +17 -2
- data/lib/rails/generators/alchemy/deploy_script/templates/deploy.rb.tt +1 -1
- data/lib/rails/generators/alchemy/scaffold/scaffold_generator.rb +1 -1
- data/lib/tasks/alchemy/convert.rake +39 -0
- data/lib/tasks/alchemy/install.rake +4 -6
- data/lib/tasks/alchemy/upgrade.rake +18 -1
- data/spec/controllers/admin/clipboard_controller_spec.rb +4 -4
- data/spec/controllers/admin/elements_controller_spec.rb +23 -23
- data/spec/controllers/admin/pages_controller_spec.rb +15 -0
- data/spec/controllers/admin/resources_controller_spec.rb +1 -11
- data/spec/controllers/admin/trash_controller_spec.rb +9 -9
- data/spec/controllers/attachments_controller_spec.rb +3 -3
- data/spec/controllers/elements_controller_spec.rb +2 -2
- data/spec/controllers/pages_controller_spec.rb +160 -129
- data/spec/controllers/pictures_controller_spec.rb +2 -2
- data/spec/controllers/user_sessions_controller_spec.rb +3 -3
- data/spec/controllers/users_controller_spec.rb +2 -2
- data/spec/dummy/app/models/event.rb +2 -2
- data/spec/dummy/app/models/location.rb +4 -0
- data/spec/dummy/app/views/layouts/application.html.erb +6 -42
- data/spec/dummy/config/routes.rb +1 -1
- data/spec/dummy/db/migrate/20121026104128_create_events.rb +0 -1
- data/{db/migrate/20121118000000_alchemy_two_point_four.rb → spec/dummy/db/migrate/20130214233001_alchemy_two_point_five.rb} +50 -36
- data/spec/dummy/db/migrate/20130221200514_migrate_attachments_to_dragonfly.rb +21 -0
- data/spec/dummy/db/migrate/20130312205327_change_alchemy_users_role_to_roles.rb +11 -0
- data/spec/dummy/db/migrate/20130328101418_create_locations.rb +9 -0
- data/spec/dummy/db/schema.rb +15 -6
- data/spec/factories.rb +4 -4
- data/spec/{integration → features}/admin/link_overlay_spec.rb +0 -0
- data/spec/{integration → features}/admin/modules_integration_spec.rb +1 -1
- data/spec/{integration → features}/admin/pages_controller_spec.rb +9 -4
- data/spec/{integration → features}/admin/picture_library_integration_spec.rb +5 -5
- data/spec/{integration → features}/admin/resources_integration_spec.rb +1 -1
- data/spec/{integration → features}/navigation_spec.rb +0 -0
- data/spec/{integration → features}/pages_controller_spec.rb +42 -112
- data/spec/{integration → features}/picture_security_spec.rb +2 -2
- data/spec/{integration → features}/security_spec.rb +7 -7
- data/spec/{integration → features}/translation_integration_spec.rb +0 -0
- data/spec/helpers/admin/base_helper_spec.rb +0 -50
- data/spec/helpers/admin/tags_helper_spec.rb +53 -0
- data/spec/helpers/base_helper_spec.rb +19 -3
- data/spec/helpers/pages_helper_spec.rb +92 -44
- data/spec/{url_helpers_spec.rb → helpers/picture_url_helpers_spec.rb} +7 -7
- data/spec/helpers/url_helper_spec.rb +92 -72
- data/spec/{config_spec.rb → libraries/config_spec.rb} +0 -0
- data/spec/libraries/resource_spec.rb +215 -76
- data/spec/libraries/resources_helper_spec.rb +70 -28
- data/spec/models/attachment_spec.rb +75 -9
- data/spec/models/clipboard_spec.rb +1 -1
- data/spec/models/element_spec.rb +7 -0
- data/spec/models/page_spec.rb +144 -25
- data/spec/models/picture_spec.rb +5 -5
- data/spec/models/resource_spec.rb +47 -10
- data/spec/models/user_spec.rb +115 -3
- data/spec/{routing_spec.rb → routing/routing_spec.rb} +8 -20
- data/spec/spec_helper.rb +5 -6
- data/spec/support/alchemy/specs_helpers.rb +1 -1
- data/spec/support/ci/install_phantomjs +1 -1
- data/spec/support/image with spaces.png +0 -0
- data/vendor/assets/javascripts/jquery_plugins/jquery.Jcrop.min.js +18 -18
- data/vendor/assets/javascripts/jquery_plugins/{jquery.dialogextend.1_0_1.js → jquery.dialogextend.js} +25 -17
- data/vendor/assets/javascripts/jquery_plugins/jquery.scrollTo.min.js +7 -0
- data/vendor/assets/javascripts/jquery_plugins/jquery.ui.tabspaging.js +7 -7
- data/vendor/assets/javascripts/keymage.min.js +6 -0
- data/vendor/assets/javascripts/spin.min.js +1 -0
- metadata +122 -124
- data/app/assets/images/alchemy/ajax_loader.gif +0 -0
- data/app/assets/images/alchemy/gui/toggle.png +0 -0
- data/app/assets/images/alchemy/image_loader.gif +0 -0
- data/app/assets/images/alchemy/shading.png +0 -0
- data/app/assets/images/alchemy/tabs.gif +0 -0
- data/app/assets/javascripts/alchemy/alchemy.base.js +0 -172
- data/app/assets/javascripts/alchemy/alchemy.datepicker.js +0 -47
- data/app/assets/javascripts/alchemy/alchemy.element_editor_selector.js +0 -91
- data/app/assets/javascripts/alchemy/alchemy.growler.js +0 -46
- data/app/assets/javascripts/alchemy/alchemy.image_cropper.js +0 -60
- data/app/assets/javascripts/alchemy/alchemy.js_extensions.js +0 -15
- data/app/assets/javascripts/alchemy/alchemy.preview_window.js +0 -97
- data/app/assets/javascripts/alchemy/alchemy.windows.js +0 -321
- data/app/models/alchemy/clipboard_spec.rb +0 -0
- data/app/views/alchemy/admin/pictures/show_in_window.html.erb +0 -8
- data/app/views/alchemy/notifications/registered_user_created.text.erb +0 -11
- data/db/migrate/20121121162313_switch_from_fleximage_to_dragonfly.rb +0 -21
- data/db/migrate/20121205155004_create_alchemy_sites.rb +0 -14
- data/db/migrate/20121211163003_add_public_to_alchemy_sites.rb +0 -6
- data/db/migrate/20121220102223_add_aliases_to_site.rb +0 -6
- data/db/migrate/20130110212411_create_alchemy_legacy_page_urls.rb +0 -11
- data/db/migrate/20130121092645_migrate_to_devise.rb +0 -24
- data/spec/alchemy_spec.rb +0 -7
- data/spec/dummy/db/migrate/20121121162313_switch_from_fleximage_to_dragonfly.rb +0 -21
- data/spec/dummy/db/migrate/20121205155004_create_alchemy_sites.rb +0 -14
- data/spec/dummy/db/migrate/20121211163003_add_public_to_alchemy_sites.rb +0 -6
- data/spec/dummy/db/migrate/20121220102223_add_aliases_to_site.rb +0 -6
- data/spec/dummy/db/migrate/20130110212411_create_alchemy_legacy_page_urls.rb +0 -11
- data/spec/dummy/db/migrate/20130121092645_migrate_to_devise.rb +0 -24
- data/vendor/assets/javascripts/jquery_plugins/jquery.scrollTo-1.4.2-min.js +0 -11
@@ -1,3 +1,5 @@
|
|
1
1
|
jQuery('#alchemy_window_body').replaceWith('<%= escape_javascript(render(:partial => "archive_overlay")) %>');
|
2
2
|
Alchemy.SelectBox('#filter_bar');
|
3
|
-
Alchemy.overlayObserver('#alchemy_window_body');
|
3
|
+
Alchemy.overlayObserver('#alchemy_window_body');
|
4
|
+
Alchemy.ImageLoader('#assign_image_list');
|
5
|
+
Alchemy.ListFilter('#alchemy_window_body');
|
@@ -1,87 +1,95 @@
|
|
1
1
|
<% content_for(:toolbar) do %>
|
2
|
-
<div
|
2
|
+
<div class="toolbar_buttons">
|
3
3
|
<%= toolbar_button(
|
4
|
-
:
|
5
|
-
:
|
6
|
-
:
|
7
|
-
:
|
8
|
-
|
9
|
-
:
|
4
|
+
icon: 'upload',
|
5
|
+
label: _t(:upload_image),
|
6
|
+
url: alchemy.new_admin_picture_path(size: @size),
|
7
|
+
hotkey: 'alt-n',
|
8
|
+
overlay_options: {
|
9
|
+
title: _t(:upload_image),
|
10
|
+
size: '540x590'
|
10
11
|
},
|
11
|
-
:
|
12
|
-
:
|
13
|
-
:
|
12
|
+
class: 'icon_button',
|
13
|
+
title: _t(:upload_image),
|
14
|
+
if_permitted_to: [:new, :alchemy_admin_pictures]
|
14
15
|
) %>
|
15
16
|
<div class="toolbar_spacer"></div>
|
16
17
|
<div class="button_with_label">
|
17
18
|
<%= link_to(
|
18
19
|
render_icon('zoom-out'),
|
19
20
|
alchemy.admin_pictures_path({
|
20
|
-
:
|
21
|
-
:
|
21
|
+
size: "small",
|
22
|
+
query: params[:query]
|
22
23
|
}),
|
23
|
-
:
|
24
|
-
:
|
24
|
+
title: _t(:small_thumbnails),
|
25
|
+
class: "icon_button please_wait"
|
25
26
|
) %>
|
26
27
|
<%= link_to(
|
27
28
|
render_icon('zoom-equal'),
|
28
29
|
alchemy.admin_pictures_path({
|
29
|
-
:
|
30
|
-
:
|
30
|
+
size: "medium",
|
31
|
+
query: params[:query]
|
31
32
|
}),
|
32
|
-
:
|
33
|
-
:
|
33
|
+
title: _t(:medium_thumbnails),
|
34
|
+
class: "icon_button please_wait"
|
34
35
|
) %>
|
35
36
|
<%= link_to(
|
36
37
|
render_icon('zoom-in'),
|
37
38
|
alchemy.admin_pictures_path({
|
38
|
-
:
|
39
|
-
:
|
39
|
+
size: "large",
|
40
|
+
query: params[:query]
|
40
41
|
}),
|
41
|
-
:
|
42
|
-
:
|
42
|
+
title: _t(:big_thumbnails),
|
43
|
+
class: "icon_button please_wait"
|
43
44
|
) %>
|
44
45
|
<label><%= _t('Image size') %></label>
|
45
|
-
<%= hidden_field_tag('size', @size, :
|
46
|
+
<%= hidden_field_tag('size', @size, id: 'overlay_thumbnails_size') %>
|
46
47
|
</div>
|
47
48
|
|
48
49
|
<% permitted_to?(:flush, :alchemy_admin_pictures) do %>
|
49
50
|
<div class="toolbar_spacer"></div>
|
50
51
|
<%= toolbar_button(
|
51
|
-
:
|
52
|
-
:
|
53
|
-
:
|
54
|
-
:
|
55
|
-
:
|
56
|
-
:
|
52
|
+
icon: 'flush',
|
53
|
+
url: alchemy.flush_admin_pictures_path,
|
54
|
+
overlay: false,
|
55
|
+
link_options: {
|
56
|
+
remote: true,
|
57
|
+
method: :post
|
57
58
|
},
|
58
|
-
:
|
59
|
-
:
|
60
|
-
:
|
61
|
-
:
|
59
|
+
label: _t('Flush picture cache'),
|
60
|
+
class: 'icon_button please_wait',
|
61
|
+
title: _t('Flush picture cache'),
|
62
|
+
skip_permission_check: true
|
62
63
|
) %>
|
63
64
|
<% end %>
|
64
65
|
<div class="toolbar_spacer"></div>
|
65
66
|
<div class="button_with_label">
|
66
|
-
<%= link_to
|
67
|
+
<%= link_to(
|
68
|
+
render_icon('select_all'),
|
69
|
+
'',
|
70
|
+
id: 'select_all_pictures',
|
71
|
+
class: 'icon_button',
|
72
|
+
'data-alchemy-hotkey' => 'alt-a'
|
73
|
+
) %>
|
67
74
|
<label><%= _t("Select all") %></label>
|
68
75
|
</div>
|
69
76
|
</div>
|
70
77
|
|
71
|
-
<%= render :
|
78
|
+
<%= render partial: 'alchemy/admin/partials/search_form' %>
|
72
79
|
<% end %>
|
73
80
|
|
74
81
|
<div id="picture_archive">
|
82
|
+
<h1>
|
83
|
+
<%= @pictures.total_count %>
|
84
|
+
<%= Alchemy::Picture.model_name.human(count: @pictures.total_count) %>
|
85
|
+
</h1>
|
75
86
|
<%= render 'archive' %>
|
76
87
|
</div>
|
77
88
|
|
78
|
-
|
89
|
+
<% content_for :javascripts do %>
|
79
90
|
<script type="text/javascript" charset="utf-8">
|
80
|
-
|
81
|
-
jQuery(document).ready(function($) {
|
82
|
-
|
91
|
+
$(function() {
|
83
92
|
Alchemy.pictureSelector();
|
84
|
-
|
85
93
|
$('#select_all_pictures').on('click', function(e) {
|
86
94
|
$('.picture_tool.select :checkbox').prop('checked', true).change();
|
87
95
|
e.preventDefault;
|
@@ -89,6 +97,5 @@
|
|
89
97
|
});
|
90
98
|
|
91
99
|
});
|
92
|
-
|
93
100
|
</script>
|
94
|
-
|
101
|
+
<% end %>
|
@@ -3,9 +3,9 @@
|
|
3
3
|
:partial => "alchemy/admin/partials/upload_form",
|
4
4
|
:locals => {
|
5
5
|
:file_types => configuration(:uploader)['allowed_filetypes']['pictures'],
|
6
|
-
:file_types_description => _t(
|
6
|
+
:file_types_description => _t(:images),
|
7
7
|
:model_name => 'picture',
|
8
|
-
:item_type => _t(
|
8
|
+
:item_type => _t(:images)
|
9
9
|
}
|
10
10
|
) %>
|
11
11
|
<%= f.submit :upload, :style => 'display: none' %>
|
@@ -1,2 +1,2 @@
|
|
1
|
-
<td class="label"><%= f.
|
2
|
-
<td class="input"><%= f.
|
1
|
+
<td class="label"><%= f.label attribute[:name] %></td>
|
2
|
+
<td class="input"><%= f.text_field attribute[:name], :type => :date -%></td>
|
@@ -1,4 +1,4 @@
|
|
1
|
-
<%= form_for resource_instance_variable, :
|
1
|
+
<%= form_for resource_instance_variable, url: resource_path(resource_instance_variable), remote: true do |f| %>
|
2
2
|
<div id="errors">
|
3
3
|
<ul>
|
4
4
|
<% resource_instance_variable.errors.full_messages.each do |error| %>
|
@@ -9,13 +9,14 @@
|
|
9
9
|
<table>
|
10
10
|
<% resource_handler.attributes.each do |attribute| %>
|
11
11
|
<tr>
|
12
|
-
<%
|
13
|
-
|
12
|
+
<% if relation = attribute[:relation] %>
|
13
|
+
<td class="label"><%= f.label attribute[:name] %></td>
|
14
14
|
<td class="select">
|
15
|
-
<%= f.
|
16
|
-
|
17
|
-
|
18
|
-
{
|
15
|
+
<%= f.select(
|
16
|
+
attribute[:name],
|
17
|
+
options_for_resource_relation_select(relation),
|
18
|
+
{include_blank: _t(:blank, scope: 'resources.relation_select')},
|
19
|
+
{class: "alchemy_selectbox"}
|
19
20
|
) %>
|
20
21
|
</td>
|
21
22
|
<% else %>
|
@@ -29,7 +30,7 @@
|
|
29
30
|
<% end %>
|
30
31
|
<tr>
|
31
32
|
<td class="submit" colspan="2">
|
32
|
-
<%= f.button _t(
|
33
|
+
<%= f.button _t(:save), class: 'button' %>
|
33
34
|
</td>
|
34
35
|
</tr>
|
35
36
|
</table>
|
@@ -1,31 +1,25 @@
|
|
1
1
|
<tr class="<%= cycle('even', 'odd') %>">
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
2
|
+
<% resource_handler.attributes.each do |attribute| %>
|
3
|
+
<td class="<%= attribute[:type] %> <%= attribute[:name] %>">
|
4
|
+
<% if attribute[:type] == :boolean %>
|
5
|
+
<%= render_icon render_attribute(resource, attribute) %>
|
6
|
+
<% else %>
|
7
|
+
<%= render_attribute(resource, attribute) %>
|
8
|
+
<% end %>
|
7
9
|
</td>
|
8
|
-
|
9
|
-
|
10
|
-
<td class="right"><%= render_attribute(resource, attribute[:name]) -%></td>
|
11
|
-
<%- else -%>
|
12
|
-
<td>
|
13
|
-
<%= render_attribute(resource, attribute[:name]) %>
|
14
|
-
</td>
|
15
|
-
<%- end -%>
|
16
|
-
<%- end -%>
|
10
|
+
<% end %>
|
17
11
|
<td class="tools">
|
18
|
-
|
12
|
+
<% permitted_to?(:destroy, resource_permission_scope) do %>
|
19
13
|
<%= link_to_confirmation_window(
|
20
14
|
'',
|
21
15
|
_t("Are you sure?"),
|
22
16
|
resource_path(resource),
|
23
17
|
:title => _t("Delete"),
|
24
18
|
:class => "icon destroy",
|
25
|
-
:id => "delete_#{resource_handler.
|
26
|
-
)
|
27
|
-
|
28
|
-
|
19
|
+
:id => "delete_#{resource_handler.resource_name}_#{resource.id}"
|
20
|
+
) %>
|
21
|
+
<% end %>
|
22
|
+
<% permitted_to?(:edit, resource_permission_scope) do %>
|
29
23
|
<%= link_to_overlay_window(
|
30
24
|
'',
|
31
25
|
edit_resource_path(resource),
|
@@ -37,7 +31,7 @@
|
|
37
31
|
:class => "icon edit",
|
38
32
|
:title => _t("Edit")
|
39
33
|
}
|
40
|
-
)
|
41
|
-
|
34
|
+
) %>
|
35
|
+
<% end %>
|
42
36
|
</td>
|
43
37
|
</tr>
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<td class="label"><%= f.
|
1
|
+
<td class="label"><%= f.label attribute[:name] %></td>
|
2
2
|
<td class="input">
|
3
|
-
<%= f.
|
3
|
+
<%= f.text_field attribute[:name], :class => 'thin_border' %>
|
4
4
|
<%= resource_help_text attribute %>
|
5
5
|
</td>
|
@@ -1,23 +1,21 @@
|
|
1
|
-
|
1
|
+
<% if resources_instance_variable.any? %>
|
2
2
|
<table class="list" id="<%= resource_handler.resources_name %>_list">
|
3
3
|
<tr>
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
<%- end -%>
|
12
|
-
<%= resource_handler.model.human_attribute_name(attribute[:name]) %>
|
4
|
+
<% resource_handler.attributes.each do |attribute| %>
|
5
|
+
<th class="<%= attribute[:type] %> <%= attribute[:name] %>">
|
6
|
+
<%= sortable_column(
|
7
|
+
resource_handler.model.human_attribute_name(attribute[:name]),
|
8
|
+
:column => sortable_resource_header_column(attribute),
|
9
|
+
:route_proxy => resource_url_proxy
|
10
|
+
) %>
|
13
11
|
</th>
|
14
|
-
|
12
|
+
<% end %>
|
15
13
|
<th class="tools"></th>
|
16
14
|
</tr>
|
17
15
|
<%= render_resources %>
|
18
16
|
</table>
|
19
|
-
|
17
|
+
<% elsif params[:query] %>
|
20
18
|
<p><%= _t('Nothing found') %></p>
|
21
|
-
|
19
|
+
<% end %>
|
22
20
|
|
23
21
|
<%= render 'alchemy/admin/partials/pagination_links', :items => resources_instance_variable, :scope => resource_url_proxy %>
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<td class="label"><%= f.
|
1
|
+
<td class="label"><%= f.label attribute[:name] %></td>
|
2
2
|
<td class="input">
|
3
|
-
<%= f.
|
3
|
+
<%= f.text_area attribute[:name], :rows => 4 %>
|
4
4
|
<%= resource_help_text attribute %>
|
5
5
|
</td>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<% csv = CSV.generate(:col_sep => ";", :row_sep => "\r\n") do |row| %>
|
2
|
+
<% row << resource_handler.attributes.collect { |a| resource_handler.model.human_attribute_name(a[:name]) } %>
|
3
|
+
<% resources_instance_variable.each do |resource| %>
|
4
|
+
<% row << resource_handler.attributes.map { |a|
|
5
|
+
if a[:type] == :boolean
|
6
|
+
resource.send(a[:name]) ? 'x' : ''
|
7
|
+
else
|
8
|
+
render_attribute(resource, a).to_s.strip
|
9
|
+
end
|
10
|
+
} %>
|
11
|
+
<% end %>
|
12
|
+
<% end %>
|
13
|
+
<%= csv.html_safe %>
|
@@ -1,23 +1,32 @@
|
|
1
|
-
|
1
|
+
<% label_title = _t("Create #{resource_name}", default: _t('Create')) %>
|
2
2
|
|
3
|
-
|
4
|
-
:
|
3
|
+
<% toolbar(
|
4
|
+
buttons: [
|
5
5
|
{
|
6
|
-
:
|
7
|
-
:
|
8
|
-
:
|
9
|
-
:
|
10
|
-
:
|
11
|
-
|
12
|
-
:
|
6
|
+
icon: 'create',
|
7
|
+
label: label_title,
|
8
|
+
url: new_resource_path,
|
9
|
+
title: label_title,
|
10
|
+
hotkey: 'alt-n',
|
11
|
+
overlay_options: {
|
12
|
+
title: label_title,
|
13
|
+
size: resource_window_size
|
13
14
|
},
|
14
|
-
:
|
15
|
+
if_permitted_to: [:new, resource_permission_scope]
|
16
|
+
},
|
17
|
+
{
|
18
|
+
icon: 'download',
|
19
|
+
url: resource_url_proxy.url_for(action: 'index', format: 'csv', query: params[:query], sort: params[:sort]),
|
20
|
+
label: _t(:download_csv),
|
21
|
+
title: _t(:download_csv),
|
22
|
+
overlay: false,
|
23
|
+
loading_indicator: false,
|
24
|
+
if_permitted_to: [:index, resource_permission_scope]
|
15
25
|
}
|
16
|
-
]
|
17
|
-
|
18
|
-
:search_url => resources_path
|
19
|
-
) -%>
|
26
|
+
]
|
27
|
+
) %>
|
20
28
|
|
21
29
|
<div id="archive_all">
|
30
|
+
<%= resources_header %>
|
22
31
|
<%= render 'table' %>
|
23
32
|
</div>
|
@@ -0,0 +1,23 @@
|
|
1
|
+
<% label_title = _t("Create #{resource_name}", default: _t('Create')) %>
|
2
|
+
|
3
|
+
<% toolbar(
|
4
|
+
buttons: [
|
5
|
+
{
|
6
|
+
icon: 'create',
|
7
|
+
label: label_title,
|
8
|
+
url: new_resource_path,
|
9
|
+
title: label_title,
|
10
|
+
hotkey: 'alt-n',
|
11
|
+
overlay_options: {
|
12
|
+
title: label_title,
|
13
|
+
size: resource_window_size
|
14
|
+
},
|
15
|
+
if_permitted_to: [:new, resource_permission_scope]
|
16
|
+
}
|
17
|
+
]
|
18
|
+
) %>
|
19
|
+
|
20
|
+
<div id="archive_all">
|
21
|
+
<%= resources_header %>
|
22
|
+
<%= render 'table' %>
|
23
|
+
</div>
|
@@ -1,4 +1,4 @@
|
|
1
|
-
<li
|
1
|
+
<li name="<%= radio_tag.name.downcase %>">
|
2
2
|
<%= radio_button_tag name + "[merge_to]", radio_tag.id, false, :id => radio_tag.name + "_tag_list" %>
|
3
3
|
<label for="<%= radio_tag.name + "_tag_list" %>">
|
4
4
|
<%= radio_tag.name %>
|
@@ -25,7 +25,7 @@
|
|
25
25
|
<label>Tags</label>
|
26
26
|
</td>
|
27
27
|
<td class="input" id="tags_tag_list">
|
28
|
-
<%= js_filter_field
|
28
|
+
<%= js_filter_field '#tag_list li' %>
|
29
29
|
<ul id="tag_list" class="tags">
|
30
30
|
<%= render :partial => "radio_tag", :collection => @tags, :locals => {:name => "tag"} %>
|
31
31
|
</ul>
|