alchemy_cms 2.6.3 → 2.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.simplecov +14 -0
- data/.travis.yml +1 -1
- data/Gemfile +7 -6
- data/README.md +15 -5
- data/alchemy_cms.gemspec +3 -2
- data/app/assets/javascripts/alchemy/alchemy.base.js.coffee +9 -17
- data/app/assets/javascripts/alchemy/alchemy.dirty.js.coffee +70 -0
- data/app/assets/javascripts/alchemy/alchemy.dragndrop.js.coffee +80 -0
- data/app/assets/javascripts/alchemy/alchemy.element_editors.js.coffee +43 -19
- data/app/assets/javascripts/alchemy/alchemy.gui.js.coffee +3 -1
- data/app/assets/javascripts/alchemy/alchemy.js +4 -2
- data/app/assets/javascripts/alchemy/alchemy.onload.js.coffee +1 -1
- data/app/assets/javascripts/alchemy/alchemy.spinner.js.coffee +14 -0
- data/app/assets/javascripts/alchemy/alchemy.tinymce.js.coffee.erb +96 -0
- data/app/assets/javascripts/alchemy/alchemy.translations.js.coffee +22 -0
- data/app/assets/javascripts/alchemy/alchemy.windows.js.coffee +28 -17
- data/app/assets/stylesheets/alchemy/base.scss +6 -0
- data/app/assets/stylesheets/alchemy/elements.scss +2 -28
- data/app/assets/stylesheets/alchemy/errors.scss +1 -1
- data/app/assets/stylesheets/alchemy/menubar.css.scss +2 -0
- data/app/assets/stylesheets/alchemy/sitemap.scss +21 -34
- data/app/assets/stylesheets/alchemy/tables.scss +13 -3
- data/app/controllers/alchemy/admin/attachments_controller.rb +10 -5
- data/app/controllers/alchemy/admin/base_controller.rb +19 -0
- data/app/controllers/alchemy/admin/contents_controller.rb +1 -4
- data/app/controllers/alchemy/admin/dashboard_controller.rb +2 -1
- data/app/controllers/alchemy/admin/elements_controller.rb +1 -1
- data/app/controllers/alchemy/admin/essence_files_controller.rb +1 -1
- data/app/controllers/alchemy/admin/essence_pictures_controller.rb +70 -56
- data/app/controllers/alchemy/admin/pages_controller.rb +37 -114
- data/app/controllers/alchemy/admin/pictures_controller.rb +5 -12
- data/app/controllers/alchemy/admin/resources_controller.rb +3 -1
- data/app/controllers/alchemy/admin/trash_controller.rb +1 -1
- data/app/controllers/alchemy/attachments_controller.rb +1 -1
- data/app/controllers/alchemy/base_controller.rb +3 -15
- data/app/controllers/alchemy/messages_controller.rb +4 -10
- data/app/controllers/alchemy/pages_controller.rb +6 -6
- data/app/controllers/alchemy/passwords_controller.rb +1 -1
- data/app/controllers/alchemy/user_sessions_controller.rb +1 -1
- data/app/helpers/alchemy/admin/base_helper.rb +49 -230
- data/app/helpers/alchemy/admin/contents_helper.rb +5 -1
- data/app/helpers/alchemy/admin/elements_helper.rb +19 -47
- data/app/helpers/alchemy/admin/essences_helper.rb +59 -17
- data/app/helpers/alchemy/admin/navigation_helper.rb +204 -0
- data/app/helpers/alchemy/admin/pages_helper.rb +22 -79
- data/app/helpers/alchemy/admin/pictures_helper.rb +1 -1
- data/app/helpers/alchemy/admin/tags_helper.rb +42 -0
- data/app/helpers/alchemy/base_helper.rb +0 -11
- data/app/helpers/alchemy/elements_helper.rb +48 -25
- data/app/helpers/alchemy/essences_helper.rb +0 -20
- data/app/helpers/alchemy/pages_helper.rb +18 -14
- data/app/helpers/alchemy/url_helper.rb +1 -0
- data/app/mailers/alchemy/messages.rb +4 -6
- data/app/models/alchemy/attachment.rb +3 -0
- data/app/models/alchemy/cell.rb +33 -35
- data/app/models/alchemy/content.rb +20 -111
- data/app/models/alchemy/content/factory.rb +188 -0
- data/app/models/alchemy/element.rb +51 -200
- data/app/models/alchemy/element/definitions.rb +52 -0
- data/app/models/alchemy/element/presenters.rb +87 -0
- data/app/models/alchemy/essence_date.rb +1 -1
- data/app/models/alchemy/essence_file.rb +6 -7
- data/app/models/alchemy/essence_picture.rb +19 -4
- data/app/models/alchemy/message.rb +18 -14
- data/app/models/alchemy/page.rb +120 -214
- data/app/models/alchemy/page/elements.rb +145 -36
- data/app/models/alchemy/page/natures.rb +90 -0
- data/app/models/alchemy/page/scopes.rb +93 -0
- data/app/models/alchemy/page/users.rb +25 -0
- data/app/models/alchemy/picture.rb +15 -0
- data/app/models/alchemy/site.rb +15 -1
- data/app/models/alchemy/site/layout.rb +38 -0
- data/app/models/alchemy/user.rb +13 -3
- data/app/views/alchemy/admin/attachments/_archive_overlay.html.erb +7 -7
- data/app/views/alchemy/admin/attachments/_file_to_assign.html.erb +8 -8
- data/app/views/alchemy/admin/attachments/_tag_list.html.erb +1 -16
- data/app/views/alchemy/admin/attachments/destroy.js.erb +1 -4
- data/app/views/alchemy/admin/contents/create.js.erb +1 -1
- data/app/views/alchemy/admin/dashboard/index.html.erb +14 -13
- data/app/views/alchemy/admin/elements/_element_head.html.erb +7 -7
- data/app/views/alchemy/admin/elements/_refresh_editor.js.erb +10 -0
- data/app/views/alchemy/admin/elements/create.js.erb +44 -44
- data/app/views/alchemy/admin/elements/fold.js.erb +22 -26
- data/app/views/alchemy/admin/elements/trash.js.erb +1 -1
- data/app/views/alchemy/admin/elements/update.js.erb +22 -25
- data/app/views/alchemy/admin/essence_files/assign.js.erb +8 -3
- data/app/views/alchemy/admin/essence_pictures/crop.html.erb +14 -12
- data/app/views/alchemy/admin/essence_pictures/edit.html.erb +22 -39
- data/app/views/alchemy/admin/pages/_page.html.erb +73 -80
- data/app/views/alchemy/admin/pages/destroy.js.erb +2 -2
- data/app/views/alchemy/admin/pages/edit.html.erb +21 -18
- data/app/views/alchemy/admin/pages/fold.js.erb +1 -0
- data/app/views/alchemy/admin/pages/info.html.erb +32 -0
- data/app/views/alchemy/admin/partials/_main_navigation_entry.html.erb +11 -13
- data/app/views/alchemy/admin/partials/_remote_search_form.html.erb +20 -20
- data/app/views/alchemy/admin/partials/_sub_navigation.html.erb +8 -0
- data/app/views/alchemy/admin/partials/_toolbar_button.html.erb +25 -0
- data/app/views/alchemy/admin/partials/_upload_form.html.erb +15 -15
- data/app/views/alchemy/admin/pictures/_filter_and_size_bar.html.erb +39 -39
- data/app/views/alchemy/admin/pictures/_picture_to_assign.html.erb +10 -10
- data/app/views/alchemy/admin/pictures/_tag_list.html.erb +1 -16
- data/app/views/alchemy/admin/resources/destroy.js.erb +1 -1
- data/app/views/alchemy/base/500.html.erb +1 -1
- data/app/views/alchemy/base/permission_denied.js.erb +1 -1
- data/app/views/alchemy/base/redirect.js.erb +1 -1
- data/app/views/alchemy/essences/_essence_link_editor.html.erb +1 -1
- data/app/views/alchemy/essences/_essence_picture_editor.html.erb +1 -1
- data/app/views/alchemy/essences/_essence_richtext_editor.html.erb +1 -1
- data/app/views/alchemy/essences/_essence_text_editor.html.erb +1 -1
- data/app/views/alchemy/essences/{_essence_picture_tools.html.erb → shared/_essence_picture_tools.html.erb} +5 -5
- data/app/views/alchemy/essences/{_linkable_essence_tools.html.erb → shared/_linkable_essence_tools.html.erb} +0 -0
- data/app/views/alchemy/messages/contact_form_mail.de.text.erb +12 -0
- data/app/views/alchemy/messages/contact_form_mail.en.text.erb +12 -0
- data/app/views/alchemy/notifications/reset_password_instructions.de.text.erb +1 -1
- data/app/views/alchemy/notifications/reset_password_instructions.en.text.erb +2 -2
- data/app/views/alchemy/pages/sitemap.xml.erb +3 -5
- data/app/views/alchemy/user_sessions/leave.html.erb +1 -1
- data/app/views/layouts/alchemy/admin.html.erb +4 -2
- data/app/views/layouts/alchemy/sitemap.xml.erb +1 -1
- data/bin/alchemy +7 -13
- data/config/alchemy/config.yml +1 -0
- data/config/authorization_rules.rb +2 -3
- data/config/initializers/dragonfly.rb +2 -0
- data/config/locales/alchemy.de.yml +8 -9
- data/config/locales/alchemy.en.yml +7 -4
- data/config/routes.rb +3 -0
- data/db/migrate/{20130214233001_alchemy_two_point_five.rb → 20130827094554_alchemy_two_point_six.rb} +29 -6
- data/lib/alchemy/auth/engine.rb +9 -0
- data/lib/alchemy/capistrano.rb +37 -12
- data/lib/alchemy/config.rb +48 -35
- data/lib/alchemy/engine.rb +35 -6
- data/lib/alchemy/essence.rb +25 -29
- data/lib/alchemy/ferret/search.rb +86 -0
- data/lib/alchemy/{scoped_pagination_url_helper.rb → kaminari/scoped_pagination_url_helper.rb} +0 -0
- data/lib/alchemy/logger.rb +3 -4
- data/lib/alchemy/page_layout.rb +124 -55
- data/lib/alchemy/resource.rb +0 -10
- data/lib/alchemy/resources_helper.rb +0 -5
- data/lib/alchemy/seeder.rb +1 -32
- data/lib/alchemy/shell.rb +6 -1
- data/lib/alchemy/tinymce.rb +41 -32
- data/lib/alchemy/upgrader.rb +3 -1
- data/lib/alchemy/upgrader/two_point_five.rb +15 -8
- data/lib/alchemy/upgrader/two_point_one.rb +10 -10
- data/lib/alchemy/upgrader/two_point_two.rb +96 -51
- data/lib/alchemy/version.rb +1 -1
- data/lib/alchemy_cms.rb +5 -46
- data/lib/rails/generators/alchemy/deploy_script/templates/deploy.rb.tt +1 -1
- data/lib/rails/generators/alchemy/devise/devise_generator.rb +9 -4
- data/lib/rails/generators/alchemy/essence/essence_generator.rb +7 -6
- data/lib/rails/generators/alchemy/essence/templates/editor.html.erb +1 -1
- data/lib/rails/generators/alchemy/scaffold/files/_standard.html.erb +1 -0
- data/lib/rails/generators/alchemy/scaffold/scaffold_generator.rb +1 -0
- data/lib/rails/generators/alchemy/site_layouts/site_layouts_generator.rb +23 -0
- data/lib/rails/generators/alchemy/site_layouts/templates/layout.html.erb +1 -0
- data/lib/rails/generators/alchemy/site_layouts/templates/layout.html.haml +1 -0
- data/lib/rails/generators/alchemy/site_layouts/templates/layout.html.slim +1 -0
- data/lib/rails/templates/alchemy.rb +2 -2
- data/lib/tasks/alchemy/db.rake +3 -1
- data/lib/tasks/alchemy/tidy.rake +82 -0
- data/lib/tasks/alchemy/upgrade.rake +2 -1
- data/spec/controllers/admin/attachments_controller_spec.rb +124 -0
- data/spec/controllers/admin/base_controller_spec.rb +35 -0
- data/spec/controllers/admin/clipboard_controller_spec.rb +1 -1
- data/spec/controllers/admin/contents_controller_spec.rb +17 -26
- data/spec/controllers/admin/dashboard_controller_spec.rb +121 -0
- data/spec/controllers/admin/elements_controller_spec.rb +1 -1
- data/spec/controllers/admin/essence_files_controller_spec.rb +67 -0
- data/spec/controllers/admin/essence_pictures_controller_spec.rb +161 -0
- data/spec/controllers/admin/languages_controller_spec.rb +1 -1
- data/spec/controllers/admin/layoutpages_controller_spec.rb +28 -0
- data/spec/controllers/admin/pages_controller_spec.rb +164 -118
- data/spec/controllers/admin/pictures_controller_spec.rb +89 -0
- data/spec/controllers/admin/trash_controller_spec.rb +21 -31
- data/spec/controllers/admin/users_controller_spec.rb +114 -85
- data/spec/controllers/attachments_controller_spec.rb +6 -2
- data/spec/controllers/base_controller_spec.rb +22 -0
- data/spec/controllers/elements_controller_spec.rb +1 -1
- data/spec/controllers/messages_controller_spec.rb +200 -0
- data/spec/controllers/pictures_controller_spec.rb +1 -1
- data/spec/controllers/user_sessions_controller_spec.rb +7 -6
- data/spec/controllers/users_controller_spec.rb +2 -2
- data/spec/dummy/config/alchemy/cells.yml +2 -0
- data/spec/dummy/config/application.rb +19 -8
- data/spec/dummy/db/migrate/{20130214233001_alchemy_two_point_five.rb → 20130827094554_alchemy_two_point_six.rb} +29 -6
- data/spec/dummy/db/schema.rb +1 -1
- data/spec/fast_specs.rb +15 -0
- data/spec/helpers/admin/base_helper_spec.rb +53 -34
- data/spec/helpers/admin/contents_helper_spec.rb +15 -7
- data/spec/helpers/admin/elements_helper_spec.rb +79 -34
- data/spec/helpers/admin/essences_helper_spec.rb +45 -31
- data/spec/helpers/admin/navigation_helper_spec.rb +204 -0
- data/spec/helpers/admin/pages_helper_spec.rb +25 -15
- data/spec/helpers/admin/tags_helper_spec.rb +62 -2
- data/spec/helpers/elements_helper_spec.rb +202 -138
- data/spec/helpers/pages_helper_spec.rb +48 -0
- data/spec/helpers/url_helper_spec.rb +7 -0
- data/spec/libraries/config_spec.rb +110 -3
- data/spec/libraries/essence_spec.rb +29 -9
- data/spec/libraries/page_layout_spec.rb +134 -0
- data/spec/libraries/resource_spec.rb +3 -16
- data/spec/libraries/resources_helper_spec.rb +4 -8
- data/spec/libraries/shell_spec.rb +1 -0
- data/spec/libraries/tinymce_spec.rb +61 -0
- data/spec/mailers/messages_spec.rb +23 -0
- data/spec/models/attachment_spec.rb +45 -0
- data/spec/models/cell_spec.rb +62 -9
- data/spec/models/content_spec.rb +110 -28
- data/spec/models/element_spec.rb +275 -253
- data/spec/models/essence_date_spec.rb +25 -0
- data/spec/models/essence_file_spec.rb +23 -0
- data/spec/models/essence_html_spec.rb +13 -0
- data/spec/models/essence_picture_spec.rb +16 -0
- data/spec/models/essence_text_spec.rb +29 -0
- data/spec/models/language_spec.rb +34 -0
- data/spec/models/message_spec.rb +43 -0
- data/spec/models/page_spec.rb +726 -567
- data/spec/models/picture_spec.rb +98 -0
- data/spec/models/site_spec.rb +60 -2
- data/spec/models/tag_spec.rb +31 -0
- data/spec/models/user_spec.rb +4 -4
- data/spec/spec_helper.rb +49 -58
- data/spec/support/alchemy/controller_helpers.rb +35 -0
- data/spec/support/alchemy/{specs_helpers.rb → integration_helpers.rb} +4 -8
- data/spec/{factories.rb → support/factories.rb} +11 -1
- data/vendor/assets/javascripts/jquery_plugins/jquery.ui.nestedSortable.js +2 -8
- metadata +166 -106
- data/Guardfile +0 -16
- data/app/assets/javascripts/alchemy/alchemy.dirty.js +0 -93
- data/app/assets/javascripts/alchemy/alchemy.dragndrop.js +0 -122
- data/app/models/alchemy/tree_node.rb +0 -4
- data/app/views/alchemy/admin/pages/_page_infos.html.erb +0 -3
- data/app/views/alchemy/admin/partials/_sub_navigation_tab.html.erb +0 -8
- data/app/views/alchemy/messages/contact_form_mail.text.erb +0 -12
- data/config/initializers/kaminari_config.rb +0 -9
- data/db/migrate/20130221200514_migrate_attachments_to_dragonfly.rb +0 -21
- data/db/migrate/20130312205327_change_alchemy_users_role_to_roles.rb +0 -11
- data/lib/alchemy/auth_engine.rb +0 -7
- data/lib/alchemy/authentication_helpers.rb +0 -9
- data/lib/alchemy/ferret_search.rb +0 -84
- data/lib/extensions/array.rb +0 -25
- data/lib/extensions/hash.rb +0 -34
- data/spec/dummy/db/migrate/20130221200514_migrate_attachments_to_dragonfly.rb +0 -21
- data/spec/dummy/db/migrate/20130312205327_change_alchemy_users_role_to_roles.rb +0 -11
- data/spec/models/page_layout_spec.rb +0 -60
@@ -22,7 +22,7 @@
|
|
22
22
|
<%= hidden_field_tag content.form_field_name(:link_title), content.essence.link_title %>
|
23
23
|
<%= hidden_field_tag content.form_field_name(:link_class_name), content.essence.link_class_name %>
|
24
24
|
<%= hidden_field_tag content.form_field_name(:link_target), content.essence.link_target %>
|
25
|
-
<%= render 'alchemy/essences/linkable_essence_tools', :content => content %>
|
25
|
+
<%= render 'alchemy/essences/shared/linkable_essence_tools', :content => content %>
|
26
26
|
|
27
27
|
<% end %>
|
28
28
|
|
@@ -1,7 +1,7 @@
|
|
1
|
-
<% if options[:crop]
|
1
|
+
<% if options[:crop] && content.ingredient %>
|
2
2
|
<%= link_to_overlay_window(
|
3
3
|
render_icon('crop'),
|
4
|
-
alchemy.crop_admin_essence_picture_path(content.essence, :options => options),
|
4
|
+
alchemy.crop_admin_essence_picture_path(content.essence, :options => options.to_json),
|
5
5
|
{
|
6
6
|
:size => "816x754",
|
7
7
|
:title => _t('Edit Picturemask'),
|
@@ -19,9 +19,9 @@
|
|
19
19
|
render_icon('swap_picture'),
|
20
20
|
alchemy.admin_pictures_path(
|
21
21
|
:element_id => content.element,
|
22
|
-
:content_id => content,
|
22
|
+
:content_id => content.id,
|
23
23
|
:swap => true,
|
24
|
-
:options => options
|
24
|
+
:options => options.to_json
|
25
25
|
),
|
26
26
|
{
|
27
27
|
:title => (content.ingredient ? _t(:swap_image) : _t(:insert_image)),
|
@@ -50,7 +50,7 @@
|
|
50
50
|
alchemy.edit_admin_essence_picture_path(
|
51
51
|
:id => content.essence.id,
|
52
52
|
:content_id => content.id,
|
53
|
-
:options => options
|
53
|
+
:options => options.to_json
|
54
54
|
),
|
55
55
|
{
|
56
56
|
:title => _t(:edit_image_properties),
|
File without changes
|
@@ -0,0 +1,12 @@
|
|
1
|
+
<%= @message.message %>
|
2
|
+
|
3
|
+
--
|
4
|
+
|
5
|
+
Absender:
|
6
|
+
|
7
|
+
<%= Alchemy::I18n.t(@message.salutation, scope: 'contactform.labels') %> <%= @message.firstname %> <%= @message.lastname %>
|
8
|
+
<%= @message.address %>
|
9
|
+
<%= @message.zip %> <%= @message.city %>
|
10
|
+
|
11
|
+
Telefon: <%= @message.phone %>
|
12
|
+
E-Mail: <%= @message.email %>
|
@@ -0,0 +1,12 @@
|
|
1
|
+
<%= @message.message %>
|
2
|
+
|
3
|
+
--
|
4
|
+
|
5
|
+
Sender:
|
6
|
+
|
7
|
+
<%= Alchemy::I18n.t(@message.salutation, scope: 'contactform.labels') %> <%= @message.firstname %> <%= @message.lastname %>
|
8
|
+
<%= @message.address %>
|
9
|
+
<%= @message.zip %> <%= @message.city %>
|
10
|
+
|
11
|
+
Phone: <%= @message.phone %>
|
12
|
+
Email: <%= @message.email %>
|
@@ -2,7 +2,7 @@ Hallo <%= @user.fullname %>.
|
|
2
2
|
|
3
3
|
Sie haben angefordert Ihr Passwort zurückzusetzen. Dies kann durch anklicken des nachfolgenden Links bestätigt werden.
|
4
4
|
|
5
|
-
<%= alchemy.edit_password_url(@user, :
|
5
|
+
<%= alchemy.edit_password_url(@user, reset_password_token: @user.reset_password_token) %>
|
6
6
|
|
7
7
|
Wenn Sie diese Zurücksetzung nicht angefragt haben, dann können Sie diese E-Mail einfach ignorieren.
|
8
8
|
Ihr Passwort wird erst dann zurückgesetzt, wenn Sie den Link anklicken.
|
@@ -1,8 +1,8 @@
|
|
1
|
-
Hello <%= @user.
|
1
|
+
Hello <%= @user.name %>.
|
2
2
|
|
3
3
|
You has requested to change your password. Please confirm this by clicking the link below.
|
4
4
|
|
5
|
-
<%= alchemy.edit_password_url(@user, :
|
5
|
+
<%= alchemy.edit_password_url(@user, reset_password_token: @user.reset_password_token) %>
|
6
6
|
|
7
7
|
If you didn't request this, please ignore this email.
|
8
8
|
Your password won't change until you access the link above and create a new one.
|
@@ -1,8 +1,6 @@
|
|
1
1
|
<%- @pages.each do |page| -%>
|
2
2
|
<url>
|
3
|
-
<loc><%=
|
4
|
-
<lastmod><%= page.updated_at %></lastmod>
|
5
|
-
<changefreq>weekly</changefreq>
|
6
|
-
<priority>1</priority>
|
3
|
+
<loc><%= show_alchemy_page_url(page) %></loc>
|
4
|
+
<lastmod><%= page.updated_at.utc.iso8601 %></lastmod>
|
7
5
|
</url>
|
8
|
-
<%- end -%>
|
6
|
+
<%- end -%>
|
@@ -37,7 +37,9 @@
|
|
37
37
|
</div>
|
38
38
|
<div id="left_menu">
|
39
39
|
<div id="main_navi">
|
40
|
-
|
40
|
+
<% alchemy_modules.each do |alchemy_module| %>
|
41
|
+
<%= alchemy_main_navigation_entry(alchemy_module) %>
|
42
|
+
<% end %>
|
41
43
|
<%= yield(:alchemy_main_navigation) %>
|
42
44
|
</div>
|
43
45
|
<div id="logout">
|
@@ -47,7 +49,7 @@
|
|
47
49
|
alchemy.leave_admin_path, {
|
48
50
|
:size => "300x105",
|
49
51
|
:title => _t("Leave Alchemy")
|
50
|
-
}) %>
|
52
|
+
}, {'data-alchemy-hotkey' => 'alt-q'}) %>
|
51
53
|
<% else %>
|
52
54
|
<%= link_to(alchemy.root_path) do %>
|
53
55
|
<span class="module icon exit"></span>
|
data/bin/alchemy
CHANGED
@@ -1,16 +1,10 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
2
|
# encoding: UTF-8
|
3
|
+
gem 'rails', '~> 3.2.14'
|
3
4
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
RAILS_VERSION = Rails::VERSION::STRING
|
8
|
-
if RAILS_VERSION < "3.2"
|
9
|
-
raise LoadError, "Wrong rails version installed. Please run gem install rails -v'~>3.2.11'"
|
10
|
-
end
|
11
|
-
require "thor"
|
12
|
-
require File.join(File.dirname(__FILE__), '..', 'lib/alchemy/version')
|
13
|
-
end
|
5
|
+
require 'rails/version'
|
6
|
+
require "thor"
|
7
|
+
require File.expand_path('../../lib/alchemy/version', __FILE__)
|
14
8
|
|
15
9
|
class AlchemyInstaller < Thor
|
16
10
|
include Thor::Actions
|
@@ -19,16 +13,16 @@ class AlchemyInstaller < Thor
|
|
19
13
|
map "--version" => :version
|
20
14
|
desc "version", "Prints current Alchemy CMS version", :hide => true
|
21
15
|
def version
|
22
|
-
puts Alchemy
|
16
|
+
puts Alchemy.version
|
23
17
|
end
|
24
18
|
|
25
19
|
desc "new PROJECT", "Creates a new Alchemy CMS project."
|
26
20
|
method_option :database, :type => :string, :default => 'mysql', :aliases => "-d", :desc => "Type of database to use for this project. Default mysql."
|
27
21
|
def new(project)
|
28
22
|
@application = project.downcase.strip.gsub(/ /, '_')
|
29
|
-
if system("rails new #{@application} -m #{File.join(File.dirname(__FILE__), '..', 'lib', 'rails', 'templates', 'alchemy.rb')} -d #{options[:database]} -JT")
|
23
|
+
if system("rails _#{Rails::VERSION::STRING}_ new #{@application} -m #{File.join(File.dirname(__FILE__), '..', 'lib', 'rails', 'templates', 'alchemy.rb')} -d #{options[:database]} -JT")
|
30
24
|
create_database_yml if options[:database] == 'mysql'
|
31
|
-
system("cd ./#{@application} && rake alchemy:install")
|
25
|
+
system("cd ./#{@application} && bundle exec rake alchemy:install")
|
32
26
|
gitignore = <<-GIT
|
33
27
|
log/*
|
34
28
|
tmp/*
|
data/config/alchemy/config.yml
CHANGED
@@ -128,6 +128,7 @@ mailer:
|
|
128
128
|
mail_success_page: thanks
|
129
129
|
mail_from: your.mail@your-domain.com
|
130
130
|
mail_to: your.mail@your-domain.com
|
131
|
+
subject: A new contact form message
|
131
132
|
fields: [salutation, firstname, lastname, address, zip, city, phone, email, message]
|
132
133
|
validate_fields: [lastname, email]
|
133
134
|
|
@@ -25,7 +25,6 @@ authorization do
|
|
25
25
|
end
|
26
26
|
has_permission_on :alchemy_pages, :to => [:show] do
|
27
27
|
if_attribute :public => true, :restricted => true
|
28
|
-
if_attribute :public => true, :restricted => false
|
29
28
|
end
|
30
29
|
has_permission_on :alchemy_elements, :to => [:show] do
|
31
30
|
if_attribute :public => true
|
@@ -41,7 +40,7 @@ authorization do
|
|
41
40
|
includes :registered
|
42
41
|
has_permission_on :alchemy_admin_dashboard, :to => [:index]
|
43
42
|
has_permission_on :alchemy_pictures, :to => [:thumbnail]
|
44
|
-
has_permission_on :alchemy_admin_pages, :to => [:index, :fold, :edit_page_content, :link]
|
43
|
+
has_permission_on :alchemy_admin_pages, :to => [:index, :info, :fold, :edit_page_content, :link]
|
45
44
|
has_permission_on :alchemy_admin_elements, :to => [:manage_elements]
|
46
45
|
has_permission_on :alchemy_admin_pictures, :to => [:read, :archive_overlay, :info]
|
47
46
|
has_permission_on :alchemy_admin_attachments, :to => [:index, :archive_overlay, :show, :download]
|
@@ -97,7 +96,7 @@ privileges do
|
|
97
96
|
end
|
98
97
|
|
99
98
|
privilege :manage_picture_essences, :alchemy_admin_essence_pictures do
|
100
|
-
includes :manage, :
|
99
|
+
includes :manage, :assign, :crop
|
101
100
|
end
|
102
101
|
|
103
102
|
privilege :manage_file_essences, :alchemy_admin_essence_files do
|
@@ -241,7 +241,6 @@ de:
|
|
241
241
|
"New Tag Created": "Neues Tag wurde erstellt"
|
242
242
|
"No": "Nein"
|
243
243
|
"No EssenceType given": ""
|
244
|
-
"No image found. Did you saved the element?": "Es wurde kein Bild gefunden. Haben Sie das Element auch gespeichert?"
|
245
244
|
"No items in your clipboard": "Ihre Zwischenablage ist leer"
|
246
245
|
"No Tags found": "Keine Tags gefunden"
|
247
246
|
"None": "keine"
|
@@ -296,9 +295,8 @@ de:
|
|
296
295
|
"Switch to Flash® Uploader": "Auf den Flash® Uploader wechseln"
|
297
296
|
sitemap_editor_info: "Die Sitemap wird automatisch generiert"
|
298
297
|
searchresults_editor_info: "Dieses Element stellt die Suchergebnisse dar. Es Bedarf keinerlei Anpassung."
|
299
|
-
element_dirty_notice: "Dieses Element hat nicht gespeicherte Änderungen. Möchten Sie es wirklich einklappen?"
|
300
298
|
"Tags": "Tags"
|
301
|
-
"These pictures could not be deleted, because they
|
299
|
+
"These pictures could not be deleted, because they were in use": "Diese Bilder konnten nicht gelöscht werden, da sie in Benutzung sind: %{names}"
|
302
300
|
"This page is locked by %{name}": "Diese Seite wird gerade von %{name} blockiert"
|
303
301
|
"Title": "Titel"
|
304
302
|
"Trash": "Papierkorb"
|
@@ -375,9 +373,7 @@ de:
|
|
375
373
|
create_language_tree_heading: "Einen leeren Sprachbaum erstellen"
|
376
374
|
create_page: "Eine Unterseite anlegen"
|
377
375
|
create_user: "Einen Benutzer anlegen"
|
378
|
-
|
379
|
-
created_by: "Erstellt von"
|
380
|
-
currently_edited_by: "Wird momentan bearbeitet von"
|
376
|
+
currently_edited_by: "Wird bearbeitet von"
|
381
377
|
cut_element: "Element ausschneiden"
|
382
378
|
delete_file: "Datei vom Server löschen"
|
383
379
|
delete_image: "Bild löschen."
|
@@ -399,7 +395,6 @@ de:
|
|
399
395
|
edit_tag: 'Tag bearbeiten'
|
400
396
|
edit_user: "Benutzer bearbeiten"
|
401
397
|
edit_selected_pictures: "Selektierte Bilder:"
|
402
|
-
element_dirty_page_leave_warning: "Sie haben ungesicherte Elemente auf der Seite. Möchten Sie wirklich fortfahren?"
|
403
398
|
element_editor_not_found: "Bei diesem Element ist ein Fehler aufgetreten"
|
404
399
|
element_of_type: "Element"
|
405
400
|
element_saved: "Element wurde gespeichert."
|
@@ -421,6 +416,7 @@ de:
|
|
421
416
|
file: "Datei"
|
422
417
|
file_rename_error: "Datei konnte nicht umbenannt werden."
|
423
418
|
files: "Dateien"
|
419
|
+
from_at: "von %{by} am %{at}"
|
424
420
|
height: "Höhe"
|
425
421
|
hide_element_content: "Element einklappen"
|
426
422
|
dashboard: "Dashboard"
|
@@ -472,6 +468,7 @@ de:
|
|
472
468
|
name: "Name"
|
473
469
|
names: "Namen"
|
474
470
|
navigation_name: "Navigationsname"
|
471
|
+
no_image_for_cropper_found: "Es wurde kein Bild gefunden. Bitte speichern Sie zuerst das Element."
|
475
472
|
no: "Nein"
|
476
473
|
"no pages": "Keine Seiten"
|
477
474
|
"no users": "Keine Benutzer"
|
@@ -487,6 +484,7 @@ de:
|
|
487
484
|
"Page created": "Seite '%{name}' wurde erstellt."
|
488
485
|
page_for_links:
|
489
486
|
choose_page: "%{name} wählen"
|
487
|
+
page_infos: 'Seiteninformationen'
|
490
488
|
page_layout_changed_notice: "Der Seitentyp wurde verändert. Nicht mehr verwendbare Elemente wurden in den Papierkorb verschoben."
|
491
489
|
page_properties: "Seiteneigenschaften"
|
492
490
|
page_public: "öffentlich"
|
@@ -509,6 +507,8 @@ de:
|
|
509
507
|
page_title: "Titel"
|
510
508
|
page_type: "Typ"
|
511
509
|
page_visible_in_navigation: "in der Navigation sichtbar"
|
510
|
+
page_was_created: "Wurde erstellt"
|
511
|
+
page_was_updated: "Wurde bearbeitet"
|
512
512
|
pages:
|
513
513
|
update:
|
514
514
|
comma_seperated: "Durch Kommata getrennt eingeben"
|
@@ -579,8 +579,6 @@ de:
|
|
579
579
|
unlink: "Link entfernen"
|
580
580
|
unlock_page: "Seite verlassen"
|
581
581
|
unlocked_page: "Seite %{name} wurde freigegeben."
|
582
|
-
updated_at: "Bearbeitet am"
|
583
|
-
updated_by: "Bearbeitet von"
|
584
582
|
upload: "Datei hochladen"
|
585
583
|
upload_file: "Datei(en) hochladen"
|
586
584
|
upload_image: "Bild(er) hochladen"
|
@@ -645,6 +643,7 @@ de:
|
|
645
643
|
default: "%d. %b. %Y, %H:%M Uhr"
|
646
644
|
short: "%d. %B, %H:%Mh"
|
647
645
|
long: "%A, %d. %B %Y um %H:%M Uhr"
|
646
|
+
page_status: "%d.%m.%Y um %H:%M Uhr"
|
648
647
|
date: "%d.%m.%Y"
|
649
648
|
datepicker: "%d.%m.%Y"
|
650
649
|
time: "%H:%M"
|
@@ -211,7 +211,7 @@ en:
|
|
211
211
|
create_page: "Create a new subpage"
|
212
212
|
create_user: "Create a new user"
|
213
213
|
created_at: "Created at"
|
214
|
-
currently_edited_by: "This page is
|
214
|
+
currently_edited_by: "This page is locked by"
|
215
215
|
cut_element: "Cut this element."
|
216
216
|
delete_file: "Delete this file from server."
|
217
217
|
delete_image: "Remove this image"
|
@@ -232,9 +232,7 @@ en:
|
|
232
232
|
edit_selected_pictures: "Edit selected pictures"
|
233
233
|
edit_user: "Edit the user´s properties."
|
234
234
|
element_description_missing: "WARNING! Missing description. Please check your elements.yml file."
|
235
|
-
element_dirty_notice: "This element has unsaved changes. Do you really want to fold it?"
|
236
235
|
element_dirty_close_window_notice: "You have unsaved elements. Do you really want to close the elements window?"
|
237
|
-
element_dirty_page_leave_warning: "You have unsaved elements on this page. Do you really want to continue?"
|
238
236
|
element_editor_not_found: "Error within this Element"
|
239
237
|
element_of_type: "Element"
|
240
238
|
element_saved: "Saved element."
|
@@ -254,6 +252,7 @@ en:
|
|
254
252
|
female: "Female"
|
255
253
|
file: "File"
|
256
254
|
file_rename_error: "Error renaming file."
|
255
|
+
from_at: "from %{by} at %{at}"
|
257
256
|
height: "Height"
|
258
257
|
hide_element_content: "Hide this elements content."
|
259
258
|
dashboard: "Dashboard"
|
@@ -302,6 +301,7 @@ en:
|
|
302
301
|
no_default_language_found: "No default language found."
|
303
302
|
no_element_given: "No element given."
|
304
303
|
no_files_in_archive: "You do not have any files in your archive."
|
304
|
+
no_image_for_cropper_found: "No image found. Please save the element first."
|
305
305
|
no_images_in_archive: "You don't have any images in your archive."
|
306
306
|
no_more_elements_to_add: "No more elements available."
|
307
307
|
no_search_results: "Your search did not return any results."
|
@@ -332,6 +332,8 @@ en:
|
|
332
332
|
page_title: "Title"
|
333
333
|
page_type: "Type"
|
334
334
|
page_visible_in_navigation: "visible in the navigation"
|
335
|
+
page_was_created: "Was created"
|
336
|
+
page_was_updated: "Was updated"
|
335
337
|
pages:
|
336
338
|
update:
|
337
339
|
comma_seperated: "Separate by comma"
|
@@ -382,7 +384,7 @@ en:
|
|
382
384
|
successfully_added_element: "Succesfully added new element."
|
383
385
|
successfully_saved_element_position: "Element position updated succesfully."
|
384
386
|
swap_image: "Change image"
|
385
|
-
"These pictures could not be deleted, because they
|
387
|
+
"These pictures could not be deleted, because they were in use": "These pictures could not be deleted, because they were in use: %{names}"
|
386
388
|
insert_image: "Insert image"
|
387
389
|
swfupload:
|
388
390
|
cancel_uploads: "Cancel uploads"
|
@@ -435,6 +437,7 @@ en:
|
|
435
437
|
formats:
|
436
438
|
default: "%a, %d %b %Y %H:%M:%S %z"
|
437
439
|
short: "%d %b %H:%M"
|
440
|
+
page_status: "%m.%d.%Y %H:%M"
|
438
441
|
long: "%B %d, %Y %H:%M"
|
439
442
|
date: "%Y-%m-%d"
|
440
443
|
datepicker: "%Y-%m-%d"
|
data/config/routes.rb
CHANGED
@@ -2,6 +2,8 @@ Alchemy::Engine.routes.draw do
|
|
2
2
|
|
3
3
|
root :to => 'pages#show'
|
4
4
|
|
5
|
+
get '/sitemap.xml' => 'pages#sitemap', format: 'xml'
|
6
|
+
|
5
7
|
get '/admin' => redirect(
|
6
8
|
"#{Alchemy::MountPoint.get}/admin/dashboard"
|
7
9
|
)
|
@@ -86,6 +88,7 @@ Alchemy::Engine.routes.draw do
|
|
86
88
|
post :visit
|
87
89
|
get :configure
|
88
90
|
get :preview
|
91
|
+
get :info
|
89
92
|
end
|
90
93
|
end
|
91
94
|
|
data/db/migrate/{20130214233001_alchemy_two_point_five.rb → 20130827094554_alchemy_two_point_six.rb}
RENAMED
@@ -1,27 +1,30 @@
|
|
1
|
-
# This is a compressed migration for creating all Alchemy 2.
|
1
|
+
# This is a compressed migration for creating all Alchemy 2.6 tables at once.
|
2
2
|
#
|
3
3
|
# === Notice
|
4
4
|
#
|
5
5
|
# In order to upgrade from an old version of Alchemy, you have to run all migrations from
|
6
6
|
# each version you missed up to the version you want to upgrade to, before running this migration.
|
7
7
|
#
|
8
|
-
class
|
8
|
+
class AlchemyTwoPointSix < ActiveRecord::Migration
|
9
9
|
def up
|
10
10
|
# Do not run if Alchemy tables are already present
|
11
11
|
return if table_exists?(:alchemy_pages)
|
12
12
|
|
13
13
|
create_table "alchemy_attachments", :force => true do |t|
|
14
14
|
t.string "name"
|
15
|
-
t.string "
|
16
|
-
t.string "
|
17
|
-
t.integer "
|
15
|
+
t.string "file_name"
|
16
|
+
t.string "file_mime_type"
|
17
|
+
t.integer "file_size"
|
18
18
|
t.integer "creator_id"
|
19
19
|
t.integer "updater_id"
|
20
20
|
t.datetime "created_at", :null => false
|
21
21
|
t.datetime "updated_at", :null => false
|
22
22
|
t.text "cached_tag_list"
|
23
|
+
t.string "file_uid"
|
23
24
|
end
|
24
25
|
|
26
|
+
add_index "alchemy_attachments", ["file_uid"], :name => "index_alchemy_attachments_on_file_uid"
|
27
|
+
|
25
28
|
create_table "alchemy_cells", :force => true do |t|
|
26
29
|
t.integer "page_id"
|
27
30
|
t.string "name"
|
@@ -268,7 +271,7 @@ class AlchemyTwoPointFive < ActiveRecord::Migration
|
|
268
271
|
t.string "login"
|
269
272
|
t.string "email"
|
270
273
|
t.string "gender"
|
271
|
-
t.string "
|
274
|
+
t.string "roles", :default => "registered"
|
272
275
|
t.string "language"
|
273
276
|
t.string "encrypted_password", :limit => 128, :default => "", :null => false
|
274
277
|
t.string "password_salt", :limit => 128, :default => "", :null => false
|
@@ -291,6 +294,26 @@ class AlchemyTwoPointFive < ActiveRecord::Migration
|
|
291
294
|
add_index "alchemy_users", ["email"], :name => "index_alchemy_users_on_email", :unique => true
|
292
295
|
add_index "alchemy_users", ["login"], :name => "index_alchemy_users_on_login", :unique => true
|
293
296
|
add_index "alchemy_users", ["reset_password_token"], :name => "index_alchemy_users_on_reset_password_token", :unique => true
|
297
|
+
add_index "alchemy_users", ["roles"], :name => "index_alchemy_users_on_roles"
|
298
|
+
|
299
|
+
create_table "events", :force => true do |t|
|
300
|
+
t.string "name"
|
301
|
+
t.string "hidden_name"
|
302
|
+
t.datetime "starts_at"
|
303
|
+
t.datetime "ends_at"
|
304
|
+
t.text "description"
|
305
|
+
t.decimal "entrance_fee", :precision => 6, :scale => 2
|
306
|
+
t.boolean "published"
|
307
|
+
t.integer "location_id"
|
308
|
+
t.datetime "created_at", :null => false
|
309
|
+
t.datetime "updated_at", :null => false
|
310
|
+
end
|
311
|
+
|
312
|
+
create_table "locations", :force => true do |t|
|
313
|
+
t.string "name"
|
314
|
+
t.datetime "created_at", :null => false
|
315
|
+
t.datetime "updated_at", :null => false
|
316
|
+
end
|
294
317
|
|
295
318
|
create_table "taggings", :force => true do |t|
|
296
319
|
t.integer "tag_id"
|