alchemy_cms 2.0.7 → 2.1.beta1
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +1 -4
- data/.travis.yml +1 -1
- data/Gemfile +7 -2
- data/README.md +6 -6
- data/Rakefile +26 -18
- data/alchemy_cms.gemspec +14 -14
- data/{assets/stylesheets → app/assets/images/alchemy}/Jcrop.gif +0 -0
- data/{assets/images → app/assets/images/alchemy}/ajax_loader.gif +0 -0
- data/{assets/images → app/assets/images/alchemy}/alchemy-logo.png +0 -0
- data/{assets/images → app/assets/images/alchemy}/flags.png +0 -0
- data/{assets/images → app/assets/images/alchemy}/gui/navi-tab.png +0 -0
- data/{assets/images → app/assets/images/alchemy}/gui/shading_90.png +0 -0
- data/{assets/images → app/assets/images/alchemy}/gui/toggle.png +0 -0
- data/{assets/images → app/assets/images/alchemy}/icons.png +0 -0
- data/{assets/images → app/assets/images/alchemy}/image_loader.gif +0 -0
- data/{assets/images → app/assets/images/alchemy}/jquery-sb/select_arrow.gif +0 -0
- data/{assets/images → app/assets/images/alchemy}/jquery-sb/select_arrow_bg.gif +0 -0
- data/{assets/images → app/assets/images/alchemy}/jquery-sb/select_arrow_bg_hover.gif +0 -0
- data/{assets/images → app/assets/images/alchemy}/placeholder.png +0 -0
- data/{assets/images/gui → app/assets/images/alchemy}/shading.png +0 -0
- data/{assets/images → app/assets/images/alchemy}/swfupload/browse_button.png +0 -0
- data/{assets/stylesheets/default/img → app/assets/images/alchemy}/tabs.gif +0 -0
- data/{assets/images/jquery-ui → app/assets/images/alchemy}/ui-icons_666666_256x240.png +0 -0
- data/app/assets/javascripts/alchemy/alchemy.base.js +212 -0
- data/app/assets/javascripts/alchemy/alchemy.buttons.js +36 -0
- data/app/assets/javascripts/alchemy/alchemy.dirty.js +91 -0
- data/app/assets/javascripts/alchemy/alchemy.dragndrop.js +114 -0
- data/{assets/javascripts → app/assets/javascripts/alchemy}/alchemy.element_editor_selector.js +0 -0
- data/{assets/javascripts → app/assets/javascripts/alchemy}/alchemy.growler.js +0 -0
- data/{assets/javascripts → app/assets/javascripts/alchemy}/alchemy.image_cropper.js +0 -0
- data/app/assets/javascripts/alchemy/alchemy.js +26 -0
- data/app/assets/javascripts/alchemy/alchemy.js_extensions.js +17 -0
- data/{assets/javascripts → app/assets/javascripts/alchemy}/alchemy.link_overlay.js +1 -1
- data/{assets/javascripts → app/assets/javascripts/alchemy}/alchemy.page_sorter.js +0 -0
- data/{assets/javascripts → app/assets/javascripts/alchemy}/alchemy.preview.js +0 -0
- data/app/assets/javascripts/alchemy/alchemy.windows.js +438 -0
- data/app/assets/stylesheets/alchemy/_defaults.scss +160 -0
- data/app/assets/stylesheets/alchemy/alchemy.css +9 -0
- data/{assets/stylesheets/alchemy.css → app/assets/stylesheets/alchemy/base.css.scss} +216 -353
- data/{assets/stylesheets/elements.css → app/assets/stylesheets/alchemy/elements.css.scss} +41 -70
- data/{assets/stylesheets/flags.css → app/assets/stylesheets/alchemy/flags.css.scss} +1 -1
- data/{assets/stylesheets/jquery-ui-1.8.7.alchemy.css → app/assets/stylesheets/alchemy/jquery-ui.alchemy.css} +15 -15
- data/{assets/stylesheets/jquery.Jcrop.css → app/assets/stylesheets/alchemy/jquery.Jcrop.css.scss} +3 -3
- data/{assets/stylesheets/jquery.sb.css → app/assets/stylesheets/alchemy/jquery.sb.css.scss} +19 -29
- data/{assets/stylesheets → app/assets/stylesheets/alchemy}/print.css +6 -1
- data/{assets/stylesheets → app/assets/stylesheets/alchemy}/standard_set.css +0 -0
- data/{assets/stylesheets/alchemy_tinymce_content.css → app/assets/stylesheets/alchemy/tinymce_content.css} +0 -0
- data/{assets/stylesheets/alchemy_tinymce_dialog.css → app/assets/stylesheets/alchemy/tinymce_dialog.css} +2 -2
- data/app/controllers/admin/attachments_controller.rb +2 -8
- data/app/controllers/admin/clipboard_controller.rb +2 -2
- data/app/controllers/admin/contents_controller.rb +4 -16
- data/app/controllers/admin/elements_controller.rb +2 -2
- data/app/controllers/admin/essence_audios_controller.rb +0 -3
- data/app/controllers/admin/essence_files_controller.rb +0 -11
- data/app/controllers/admin/essence_flashes_controller.rb +0 -3
- data/app/controllers/admin/essence_pictures_controller.rb +2 -7
- data/app/controllers/admin/essence_videos_controller.rb +0 -3
- data/app/controllers/admin/languages_controller.rb +4 -10
- data/app/controllers/admin/pages_controller.rb +6 -4
- data/app/controllers/admin/pictures_controller.rb +13 -18
- data/app/controllers/admin/trash_controller.rb +0 -5
- data/app/controllers/admin/users_controller.rb +2 -3
- data/app/controllers/alchemy_controller.rb +18 -30
- data/app/controllers/pages_controller.rb +21 -24
- data/app/helpers/admin/elements_helper.rb +5 -0
- data/app/helpers/admin/pages_helper.rb +36 -1
- data/app/helpers/alchemy_helper.rb +39 -17
- data/app/models/attachment.rb +2 -2
- data/app/models/essence_file.rb +1 -1
- data/app/models/page.rb +1 -1
- data/app/sweepers/pages_sweeper.rb +10 -0
- data/app/views/admin/attachments/destroy.js.erb +4 -0
- data/app/views/admin/clipboard/insert.js.erb +12 -19
- data/app/views/admin/contents/create.js.erb +1 -1
- data/app/views/admin/contents/destroy.js.erb +7 -0
- data/app/views/admin/contents/order.js.erb +6 -0
- data/app/views/admin/elements/_element.html.erb +4 -2
- data/app/views/admin/elements/create.js.erb +19 -26
- data/app/views/admin/elements/fold.js.erb +1 -1
- data/app/views/admin/elements/index.html.erb +1 -1
- data/app/views/admin/essence_files/assign.js.erb +8 -0
- data/app/views/admin/essence_pictures/save_link.js.erb +3 -0
- data/app/views/admin/index.html.erb +37 -27
- data/app/views/admin/languages/destroy.js.erb +1 -0
- data/app/views/admin/pages/_page.html.erb +1 -1
- data/app/views/admin/pages/_sitemap.html.erb +1 -1
- data/app/views/admin/pages/edit.html.erb +2 -2
- data/app/views/admin/pages/update.js.erb +1 -1
- data/app/views/admin/partials/_upload_form.html.erb +11 -11
- data/app/views/admin/pictures/archive_overlay.js.erb +1 -0
- data/app/views/admin/pictures/flush.js.erb +2 -0
- data/app/views/admin/pictures/update.js.erb +1 -0
- data/app/views/admin/trash/clear.js.erb +3 -0
- data/app/views/alchemy/error_notice.js.erb +1 -0
- data/app/views/alchemy/permission_denied.js.erb +2 -0
- data/app/views/alchemy/redirect.js.erb +1 -0
- data/app/views/alchemy/remote_errors.js.erb +3 -0
- data/app/views/alchemy/update.js.erb +5 -0
- data/app/views/essences/_essence_file_editor.html.erb +0 -1
- data/app/views/essences/_essence_file_view.html.erb +1 -5
- data/app/views/essences/_essence_picture_tools.html.erb +1 -1
- data/app/views/layouts/alchemy.html.erb +22 -9
- data/app/views/pages/show.rss.builder +1 -1
- data/config/alchemy/elements.yml +0 -5
- data/config/alchemy/page_layouts.yml +1 -1
- data/config/asset_packages.yml +17 -19
- data/config/authorization_rules.rb +1 -0
- data/config/locales/de.yml +0 -1
- data/config/routes.rb +1 -1
- data/lib/alchemy/tinymce.rb +51 -0
- data/lib/alchemy/version.rb +3 -3
- data/lib/alchemy_cms.rb +4 -2
- data/script/rails +6 -0
- data/spec/controllers/admin/clipboard_controller_spec.rb +15 -13
- data/spec/controllers/admin/contents_controller_spec.rb +4 -4
- data/spec/controllers/admin/trash_controller_spec.rb +6 -9
- data/spec/controllers/pages_controller_spec.rb +9 -8
- data/spec/dummy/Rakefile +1 -1
- data/spec/dummy/app/assets/javascripts/application.js +9 -0
- data/spec/dummy/app/assets/stylesheets/application.css +7 -0
- data/spec/dummy/app/mailers/.gitkeep +0 -0
- data/spec/dummy/app/models/.gitkeep +0 -0
- data/spec/dummy/app/views/layouts/application.html.erb +3 -3
- data/spec/dummy/config/application.rb +12 -6
- data/spec/dummy/config/database.yml +3 -0
- data/spec/dummy/config/environments/development.rb +7 -3
- data/spec/dummy/config/environments/production.rb +23 -12
- data/spec/dummy/config/environments/test.rb +5 -1
- data/spec/dummy/config/initializers/secret_token.rb +1 -1
- data/spec/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/spec/dummy/config/locales/en.yml +1 -1
- data/spec/dummy/config/routes.rb +1 -1
- data/spec/dummy/lib/assets/.gitkeep +0 -0
- data/spec/factories.rb +8 -8
- data/spec/helpers/admin/elements_helper_spec.rb +2 -2
- data/spec/helpers/contents_helper_spec.rb +1 -1
- data/spec/helpers/elements_helper_spec.rb +6 -6
- data/spec/helpers/essences_helper_spec.rb +1 -1
- data/spec/helpers/pages_helper_spec.rb +37 -37
- data/spec/integration/pages_controller_spec.rb +29 -26
- data/spec/integration/security_spec.rb +2 -1
- data/spec/models/content_spec.rb +1 -1
- data/spec/models/element_spec.rb +11 -11
- data/spec/models/language_spec.rb +5 -5
- data/spec/models/page_spec.rb +54 -54
- data/spec/models/user_spec.rb +2 -1
- data/spec/routing_spec.rb +1 -1
- data/{assets/javascripts/jquery.js → vendor/assets/javascripts/jquery-1.6.2.min.js} +0 -0
- data/{assets/javascripts/jquery-ui.js → vendor/assets/javascripts/jquery-ui-custom-1.8.16.min.js} +0 -0
- data/{assets/javascripts → vendor/assets/javascripts/jquery_plugins}/jquery.Jcrop.min.js +0 -0
- data/{assets/javascripts → vendor/assets/javascripts/jquery_plugins}/jquery.dialogextend.min.js +7 -7
- data/{assets/javascripts → vendor/assets/javascripts/jquery_plugins}/jquery.in-place-edit.js +0 -0
- data/{assets/javascripts → vendor/assets/javascripts/jquery_plugins}/jquery.sb.min.js +0 -0
- data/{assets/javascripts → vendor/assets/javascripts/jquery_plugins}/jquery.scrollTo-1.4.2-min.js +10 -10
- data/{assets/javascripts → vendor/assets/javascripts/jquery_plugins}/jquery.ui.nestedSortable.js +0 -0
- data/{assets/javascripts → vendor/assets/javascripts/jquery_plugins}/jquery.ui.tabspaging.js +0 -0
- data/{assets → vendor/assets}/javascripts/swfupload/fileprogress.js +202 -202
- data/{assets → vendor/assets}/javascripts/swfupload/handlers.js +171 -171
- data/{assets → vendor/assets}/javascripts/swfupload/queue.js +97 -97
- data/{assets → vendor/assets}/javascripts/swfupload/swfupload.js +980 -980
- data/{assets → vendor/assets}/javascripts/swfupload/swfupload.swf +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/jquery.tinymce.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/langs/de.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/langs/en.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/license.txt +504 -504
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/alchemy_link/editor_plugin.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/alchemy_link/langs/de.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/alchemy_link/langs/en.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/autoresize/editor_plugin.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/fullscreen/editor_plugin.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/fullscreen/fullscreen.htm +110 -110
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/inlinepopups/editor_plugin.js +0 -0
- data/{assets/javascripts/tiny_mce/plugins/inlinepopups/skins/alchemy/window.css → vendor/assets/javascripts/tiny_mce/plugins/inlinepopups/skins/alchemy/window.css.erb} +8 -8
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/inlinepopups/template.htm +387 -387
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/paste/editor_plugin.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/paste/js/pastetext.js +36 -36
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/paste/js/pasteword.js +51 -51
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/paste/langs/de_dlg.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/paste/langs/en_dlg.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/paste/pastetext.htm +26 -26
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/paste/pasteword.htm +21 -21
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/cell.htm +180 -180
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/css/cell.css +16 -16
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/css/row.css +25 -25
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/css/table.css +13 -13
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/editor_plugin.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/js/cell.js +319 -319
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/js/merge_cells.js +27 -27
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/js/row.js +237 -237
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/js/table.js +450 -450
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/langs/de_dlg.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/langs/en_dlg.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/merge_cells.htm +32 -32
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/row.htm +158 -158
- data/{assets → vendor/assets}/javascripts/tiny_mce/plugins/table/table.htm +188 -188
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/about.htm +52 -52
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/anchor.htm +26 -26
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/charmap.htm +51 -51
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/color_picker.htm +74 -74
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/editor_template.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/image.htm +80 -80
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/colorpicker.jpg +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/flash.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/icons.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/iframe.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/pagebreak.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/quicktime.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/realmedia.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/shockwave.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/trans.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/video.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/img/windowsmedia.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/js/about.js +73 -73
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/js/anchor.js +43 -43
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/js/charmap.js +355 -355
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/js/color_picker.js +329 -329
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/js/image.js +251 -251
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/js/link.js +153 -153
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/js/source_editor.js +56 -56
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/langs/de.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/langs/de_dlg.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/langs/en.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/langs/en_dlg.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/link.htm +57 -57
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/shortcuts.htm +47 -47
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/default/content.css +50 -50
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/default/dialog.css +117 -117
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/default/img/buttons.png +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/default/img/items.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/default/img/menu_arrow.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/default/img/menu_check.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/default/img/progress.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/default/img/tabs.gif +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/default/ui.css +214 -214
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/o2k7/content.css +48 -48
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/o2k7/dialog.css +117 -117
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/o2k7/img/button_bg.png +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/o2k7/img/button_bg_black.png +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/o2k7/img/button_bg_silver.png +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/o2k7/ui.css +217 -217
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/o2k7/ui_black.css +7 -7
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/skins/o2k7/ui_silver.css +5 -5
- data/{assets → vendor/assets}/javascripts/tiny_mce/themes/advanced/source_editor.htm +25 -25
- data/{assets → vendor/assets}/javascripts/tiny_mce/tiny_mce.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/tiny_mce_popup.js +0 -0
- data/{assets → vendor/assets}/javascripts/tiny_mce/utils/editable_selects.js +70 -70
- data/{assets → vendor/assets}/javascripts/tiny_mce/utils/form_utils.js +210 -210
- data/{assets → vendor/assets}/javascripts/tiny_mce/utils/mctabs.js +161 -161
- data/{assets → vendor/assets}/javascripts/tiny_mce/utils/validate.js +252 -252
- metadata +338 -369
- data/app/views/elements/_download_editor.html.erb +0 -1
- data/app/views/elements/_download_view.html.erb +0 -3
- data/assets/javascripts/alchemy.js +0 -903
- data/assets/javascripts/jquery.rails.js +0 -315
- data/assets/stylesheets/ie6.css +0 -18
- data/config/initializers/tinymce_hammer.rb +0 -31
data/.gitignore
CHANGED
data/.travis.yml
CHANGED
data/Gemfile
CHANGED
@@ -3,13 +3,18 @@ source "http://rubygems.org"
|
|
3
3
|
# Specify your gem's dependencies in alchemy.gemspec
|
4
4
|
gemspec
|
5
5
|
|
6
|
+
# gem 'tvdeyen-fleximage', :git => 'git@github.com:masche842/fleximage.git'
|
7
|
+
# gem 'userstamp', :git => 'git@github.com:masche842/userstamp.git'
|
8
|
+
|
9
|
+
#gem 'attachment_magic', :path => '/Users/tvd/code/ruby/gems/attachment_magic'
|
10
|
+
|
6
11
|
group :development, :test do
|
7
|
-
gem 'gettext', '>=1.
|
12
|
+
gem 'gettext', '>=1.9.3', :require => false
|
8
13
|
end
|
9
14
|
|
10
15
|
group :test do
|
11
16
|
gem 'factory_girl_rails'
|
12
|
-
gem "capybara"
|
17
|
+
gem "capybara"
|
13
18
|
gem "launchy"
|
14
19
|
gem "database_cleaner"
|
15
20
|
end
|
data/README.md
CHANGED
@@ -1,13 +1,10 @@
|
|
1
1
|
Alchemy CMS
|
2
2
|
===========
|
3
3
|
|
4
|
-
[![Build Status](https://secure.travis-ci.org/magiclabs/alchemy_cms.png)](http://travis-ci.org/magiclabs/alchemy_cms)
|
5
|
-
![Status](http://stillmaintained.com/magiclabs/alchemy_cms.png)
|
6
|
-
|
7
4
|
About
|
8
5
|
-----
|
9
6
|
|
10
|
-
|
7
|
+
**CAUTION: This branch is a pre alpha development branch. For productive environments use [master](https://github.com/magiclabs/alchemy_cms), or [next_stable](https://github.com/magiclabs/alchemy_cms/tree/next_stable) branch.**
|
11
8
|
|
12
9
|
Features
|
13
10
|
--------
|
@@ -46,12 +43,13 @@ Features
|
|
46
43
|
- Completely free:
|
47
44
|
- BSD License
|
48
45
|
- No Enterprise Licences, or Community Editions
|
49
|
-
- Hostable on any Server that supports RubyOnRails and ImageMagick ([Software Requirements](https://github.com/magiclabs/
|
46
|
+
- Hostable on any Server that supports RubyOnRails and ImageMagick ([Software Requirements](https://github.com/magiclabs/alchemy/wiki/Software-Requirements))
|
50
47
|
|
51
48
|
Rails Version
|
52
49
|
-------------
|
53
50
|
|
54
|
-
This
|
51
|
+
This branch of Alchemy runs with Rails 3.1.1 and Ruby 1.9.2.
|
52
|
+
<<<<<<< HEAD
|
55
53
|
|
56
54
|
If you are looking for a Rails 2 compatible version check the rails-2 branch.
|
57
55
|
|
@@ -61,6 +59,8 @@ Ruby Version
|
|
61
59
|
------------
|
62
60
|
|
63
61
|
Alchemy runs with REE, Ruby 1.8.7, Ruby 1.9.2 and Ruby 1.9.3.
|
62
|
+
=======
|
63
|
+
>>>>>>> 1a8411a94fbcf0ebd5a10ce774f29263b70d7665
|
64
64
|
|
65
65
|
Installation
|
66
66
|
------------
|
data/Rakefile
CHANGED
@@ -1,27 +1,20 @@
|
|
1
|
-
|
2
|
-
require 'rubygems'
|
1
|
+
#!/usr/bin/env rake
|
3
2
|
begin
|
4
|
-
require 'bundler'
|
3
|
+
require 'bundler/setup'
|
5
4
|
rescue LoadError
|
6
5
|
puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
|
7
6
|
end
|
8
7
|
|
9
|
-
|
10
|
-
require 'rdoc/task'
|
11
|
-
|
12
|
-
require '
|
13
|
-
require '
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
RSpec::Core::RakeTask.new(:spec)
|
18
|
-
|
19
|
-
task :default => :spec
|
20
|
-
|
21
|
-
Bundler::GemHelper.install_tasks
|
8
|
+
begin
|
9
|
+
require 'rdoc/task'
|
10
|
+
rescue LoadError
|
11
|
+
require 'rdoc/rdoc'
|
12
|
+
require 'rake/rdoctask'
|
13
|
+
RDoc::Task = Rake::RDocTask
|
14
|
+
end
|
22
15
|
|
23
|
-
desc 'Generate documentation for
|
24
|
-
|
16
|
+
desc 'Generate documentation for Alchemy CMS.'
|
17
|
+
RDoc::Task.new(:rdoc) do |rdoc|
|
25
18
|
rdoc.rdoc_dir = 'rdoc'
|
26
19
|
rdoc.title = 'Alchemy CMS'
|
27
20
|
rdoc.options << '--line-numbers' << '--inline-source'
|
@@ -30,3 +23,18 @@ Rake::RDocTask.new(:rdoc) do |rdoc|
|
|
30
23
|
rdoc.rdoc_files.include('lib/**/*.rb')
|
31
24
|
rdoc.rdoc_files.include('app/**/*.rb')
|
32
25
|
end
|
26
|
+
|
27
|
+
APP_RAKEFILE = File.expand_path("../spec/dummy/Rakefile", __FILE__)
|
28
|
+
|
29
|
+
# uncomment the next line if you want to see all dummy app rake tasks
|
30
|
+
# load 'rails/tasks/engine.rake'
|
31
|
+
load File.join(File.dirname(__FILE__), 'lib/tasks/gettext.rake')
|
32
|
+
|
33
|
+
require 'rspec/core'
|
34
|
+
require 'rspec/core/rake_task'
|
35
|
+
|
36
|
+
RSpec::Core::RakeTask.new(:spec)
|
37
|
+
|
38
|
+
task :default => :spec
|
39
|
+
|
40
|
+
Bundler::GemHelper.install_tasks
|
data/alchemy_cms.gemspec
CHANGED
@@ -19,30 +19,30 @@ Gem::Specification.new do |s|
|
|
19
19
|
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
|
20
20
|
s.require_paths = ["lib"]
|
21
21
|
|
22
|
-
s.add_runtime_dependency(%q<rails>, ["~> 3.
|
23
|
-
s.add_runtime_dependency(%q<authlogic
|
22
|
+
s.add_runtime_dependency(%q<rails>, ["~> 3.1"])
|
23
|
+
s.add_runtime_dependency(%q<authlogic>)
|
24
24
|
s.add_runtime_dependency(%q<awesome_nested_set>, ["~> 2.0"])
|
25
25
|
s.add_runtime_dependency(%q<declarative_authorization>, ["~> 0.5"])
|
26
|
-
s.add_runtime_dependency(%q<tvdeyen-fleximage>, ["~> 1.0.
|
26
|
+
s.add_runtime_dependency(%q<tvdeyen-fleximage>, ["~> 1.0.9"])
|
27
27
|
s.add_runtime_dependency(%q<gettext_i18n_rails>, [">= 0.3"])
|
28
28
|
s.add_runtime_dependency(%q<will_paginate>, ["~> 3.0"])
|
29
29
|
s.add_runtime_dependency(%q<acts_as_ferret>, ["~> 0.5"])
|
30
30
|
s.add_runtime_dependency(%q<acts_as_list>, ["~> 0.1"])
|
31
|
-
s.add_runtime_dependency(%q<userstamp>, ["~> 2.0.
|
31
|
+
s.add_runtime_dependency(%q<magiclabs-userstamp>, ["~> 2.0.2"])
|
32
32
|
s.add_runtime_dependency(%q<dynamic_form>, ["~> 1.1"])
|
33
|
-
s.add_runtime_dependency(%q<jquery-rails>, ["~> 1.0"])
|
34
|
-
s.add_runtime_dependency(%q<
|
35
|
-
s.add_runtime_dependency(%q<attachment_magic>, ["~> 0.1.1"])
|
33
|
+
s.add_runtime_dependency(%q<jquery-rails>, ["~> 1.0.16"])
|
34
|
+
s.add_runtime_dependency(%q<attachment_magic>, ["~> 0.2"])
|
36
35
|
|
37
|
-
|
36
|
+
s.add_development_dependency(%q<rspec-rails>, ["~> 2.7"])
|
38
37
|
s.add_development_dependency(%q<sqlite3>)
|
38
|
+
s.add_development_dependency 'sass-rails', ['~> 3.1.4']
|
39
|
+
s.add_development_dependency 'coffee-rails', ['~> 3.1.1']
|
40
|
+
s.add_development_dependency 'uglifier', ['>= 1.0.3']
|
39
41
|
|
40
|
-
if
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
s.add_development_dependency(%q<ruby-debug>)
|
45
|
-
end
|
42
|
+
if RUBY_VERSION =~ /^1.9/
|
43
|
+
s.add_development_dependency(%q<ruby-debug19>)
|
44
|
+
else
|
45
|
+
s.add_development_dependency(%q<ruby-debug>)
|
46
46
|
end
|
47
47
|
|
48
48
|
end
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -0,0 +1,212 @@
|
|
1
|
+
if (typeof(Alchemy) === 'undefined') {
|
2
|
+
var Alchemy = {};
|
3
|
+
}
|
4
|
+
|
5
|
+
(function ($) {
|
6
|
+
|
7
|
+
// Setting jQueryUIs global animation duration
|
8
|
+
$.fx.speeds._default = 400;
|
9
|
+
|
10
|
+
// The Alchemy JavaScript Object contains all Functions
|
11
|
+
$.extend(Alchemy, {
|
12
|
+
|
13
|
+
inPlaceEditor : function (options) {
|
14
|
+
var defaults = {
|
15
|
+
save_label: 'save',
|
16
|
+
cancel_label: 'cancel'
|
17
|
+
};
|
18
|
+
var settings = jQuery.extend({}, defaults, options);
|
19
|
+
var cancel_handler = function(element) {
|
20
|
+
jQuery(element).css({overflow: 'hidden'});
|
21
|
+
return true;
|
22
|
+
};
|
23
|
+
var submit_handler = function(element, id, value) {
|
24
|
+
$(element).css({overflow: 'hidden'});
|
25
|
+
id = parseInt(id.replace(/^image_picture_/, ''));
|
26
|
+
$.ajax({url:'/admin/pictures/'+id, type: 'PUT', data: {name: value}});
|
27
|
+
return false;
|
28
|
+
};
|
29
|
+
|
30
|
+
$('#alchemy .rename').click(function () {
|
31
|
+
$(this).css({overflow: 'visible'});
|
32
|
+
});
|
33
|
+
|
34
|
+
$('#alchemy .rename').inPlaceEdit({
|
35
|
+
submit : submit_handler,
|
36
|
+
cancel : cancel_handler,
|
37
|
+
html : ' \
|
38
|
+
<div class="inplace-edit"> \
|
39
|
+
<input type="text" value="" class="thin_border field" /> \
|
40
|
+
<div class="buttons"> \
|
41
|
+
<input type="button" value="'+settings.save_label+'" class="save-button button" /> \
|
42
|
+
<input type="button" value="'+settings.cancel_label+'" class="cancel-button button" /> \
|
43
|
+
</div> \
|
44
|
+
</div>'
|
45
|
+
});
|
46
|
+
|
47
|
+
},
|
48
|
+
|
49
|
+
pleaseWaitOverlay : function(show) {
|
50
|
+
if (typeof(show) == 'undefined') {
|
51
|
+
show = true;
|
52
|
+
}
|
53
|
+
var $overlay = $('#overlay');
|
54
|
+
$overlay.css("visibility", show ? 'visible': 'hidden');
|
55
|
+
},
|
56
|
+
|
57
|
+
toggleElement : function (id, url, token, text) {
|
58
|
+
var toggle = function() {
|
59
|
+
$('#element_'+id+'_folder').hide();
|
60
|
+
$('#element_'+id+'_folder_spinner').show();
|
61
|
+
$.post(url, {
|
62
|
+
authenticity_token: encodeURIComponent(token)
|
63
|
+
}, function(request) {
|
64
|
+
$('#element_'+id+'_folder').show();
|
65
|
+
$('#element_'+id+'_folder_spinner').hide();
|
66
|
+
});
|
67
|
+
}
|
68
|
+
if (Alchemy.isPageDirty()) {
|
69
|
+
Alchemy.openConfirmWindow({
|
70
|
+
title: text.title,
|
71
|
+
message: text.message,
|
72
|
+
okLabel: text.okLabel,
|
73
|
+
cancelLabel: text.cancelLabel,
|
74
|
+
okCallback: toggle
|
75
|
+
});
|
76
|
+
return false;
|
77
|
+
} else {
|
78
|
+
toggle();
|
79
|
+
}
|
80
|
+
},
|
81
|
+
|
82
|
+
ListFilter : function(selector) {
|
83
|
+
var text = $('#search_field').val().toLowerCase();
|
84
|
+
var $boxes = $(selector);
|
85
|
+
$boxes.map(function() {
|
86
|
+
$this = $(this);
|
87
|
+
$this.css({
|
88
|
+
display: $this.attr('name').toLowerCase().indexOf(text) != -1 ? '' : 'none'
|
89
|
+
});
|
90
|
+
});
|
91
|
+
},
|
92
|
+
|
93
|
+
fadeImage : function(image, spinner_selector) {
|
94
|
+
try {
|
95
|
+
$(spinner_selector).hide();
|
96
|
+
$(image).fadeIn(600);
|
97
|
+
} catch(e) {
|
98
|
+
Alchemy.debug(e);
|
99
|
+
};
|
100
|
+
},
|
101
|
+
|
102
|
+
saveElement : function(form) {
|
103
|
+
// disabled for now. I think we don't need this.
|
104
|
+
return true;
|
105
|
+
// remove this comment if you have problems with saving tinymce content
|
106
|
+
// var $rtf_contents = $(form).find('div.content_rtf_editor');
|
107
|
+
// if ($rtf_contents.size() > 0) {
|
108
|
+
// $rtf_contents.each(function() {
|
109
|
+
// var id = $(this).children('textarea.tinymce').attr('id');
|
110
|
+
// tinymce.get(id).save();
|
111
|
+
// });
|
112
|
+
// }
|
113
|
+
},
|
114
|
+
|
115
|
+
setElementSaved : function(selector) {
|
116
|
+
var $element = $(selector);
|
117
|
+
Alchemy.setElementClean(selector);
|
118
|
+
Alchemy.enableButton(selector + ' button.button');
|
119
|
+
},
|
120
|
+
|
121
|
+
resizeFrame : function() {
|
122
|
+
var options = {
|
123
|
+
top: 90,
|
124
|
+
left: 65,
|
125
|
+
right: 0
|
126
|
+
};
|
127
|
+
var $mainFrame = $('#main_content');
|
128
|
+
var $topFrame = $('#top_menu');
|
129
|
+
var view_height = $(window).height();
|
130
|
+
var view_width = $(window).width();
|
131
|
+
var mainFrameHeight = view_height - options.top;
|
132
|
+
var topFrameHeight = options.top;
|
133
|
+
var width = view_width - options.left - options.right;
|
134
|
+
if ($mainFrame.length > 0) {
|
135
|
+
$mainFrame.css({
|
136
|
+
width: width,
|
137
|
+
height: mainFrameHeight
|
138
|
+
});
|
139
|
+
}
|
140
|
+
if ($topFrame.length > 0) {
|
141
|
+
$topFrame.css({
|
142
|
+
width: width,
|
143
|
+
height: topFrameHeight
|
144
|
+
});
|
145
|
+
}
|
146
|
+
},
|
147
|
+
|
148
|
+
Tooltips : function() {
|
149
|
+
var xOffset = 10;
|
150
|
+
var yOffset = 20;
|
151
|
+
$(".tooltip").hover(function(e) {
|
152
|
+
this.original_title = this.title;
|
153
|
+
if (this.original_title == '') {
|
154
|
+
this.tooltip_content = $(this).next('.tooltip_content').html();
|
155
|
+
} else {
|
156
|
+
this.tooltip_content = this.original_title;
|
157
|
+
}
|
158
|
+
if (this.tooltip_content != null) {
|
159
|
+
this.title = "";
|
160
|
+
$("body").append("<div id='tooltip'>"+ this.tooltip_content +"</div>");
|
161
|
+
$("#tooltip")
|
162
|
+
.css("top",(e.pageY - xOffset) + "px")
|
163
|
+
.css("left",(e.pageX + yOffset) + "px")
|
164
|
+
.fadeIn(400);
|
165
|
+
}
|
166
|
+
},
|
167
|
+
function() {
|
168
|
+
this.title = this.original_title;
|
169
|
+
$("#tooltip").remove();
|
170
|
+
});
|
171
|
+
$(".tooltip").mousemove(function(e) {
|
172
|
+
$("#tooltip")
|
173
|
+
.css("top",(e.pageY - xOffset) + "px")
|
174
|
+
.css("left",(e.pageX + yOffset) + "px");
|
175
|
+
});
|
176
|
+
},
|
177
|
+
|
178
|
+
SelectBox : function(selector) {
|
179
|
+
$(selector).sb({animDuration: 0, fixedWidth: true});
|
180
|
+
},
|
181
|
+
|
182
|
+
Buttons : function(options) {
|
183
|
+
$("button, input:submit, a.button").button(options);
|
184
|
+
},
|
185
|
+
|
186
|
+
handleEssenceCheckbox: function (checkbox) {
|
187
|
+
var $checkbox = $(checkbox);
|
188
|
+
if (checkbox.checked) {
|
189
|
+
$('#' + checkbox.id + '_hidden').remove();
|
190
|
+
} else {
|
191
|
+
$checkbox.after('<input type="hidden" value="0" name="'+checkbox.name+'" id="'+checkbox.id+'_hidden">');
|
192
|
+
}
|
193
|
+
},
|
194
|
+
|
195
|
+
selectOrCreateCellTab: function (cell_name, label) {
|
196
|
+
if ($('#cell_'+cell_name).size() === 0) {
|
197
|
+
$('#cells').tabs('add', '#cell_'+cell_name, label);
|
198
|
+
$('#cell_'+cell_name).addClass('sortable_cell');
|
199
|
+
}
|
200
|
+
$('#cells').tabs('select', 'cell_'+cell_name);
|
201
|
+
},
|
202
|
+
|
203
|
+
debug : function(e) {
|
204
|
+
if (window['console']) {
|
205
|
+
console.debug(e);
|
206
|
+
console.trace();
|
207
|
+
}
|
208
|
+
}
|
209
|
+
|
210
|
+
});
|
211
|
+
|
212
|
+
})(jQuery);
|
@@ -0,0 +1,36 @@
|
|
1
|
+
if (typeof(Alchemy) === 'undefined') {
|
2
|
+
var Alchemy = {};
|
3
|
+
}
|
4
|
+
|
5
|
+
(function($) {
|
6
|
+
|
7
|
+
$.extend(Alchemy, {
|
8
|
+
|
9
|
+
ButtonObserver: function (selector) {
|
10
|
+
$(selector).click(function(event) {
|
11
|
+
Alchemy.disableButton(this);
|
12
|
+
});
|
13
|
+
},
|
14
|
+
|
15
|
+
disableButton: function (button) {
|
16
|
+
var $button = $(button), $clone = $button.clone(), width = $button.outerWidth(), text = $button.text();
|
17
|
+
$button.hide();
|
18
|
+
$button.parent().append($clone);
|
19
|
+
$clone.attr({disabled: true, href: 'javascript:void(0)'})
|
20
|
+
.addClass('disabled cloned-button')
|
21
|
+
.css({width: width})
|
22
|
+
.html('<img src="/assets/alchemy/ajax_loader.gif">')
|
23
|
+
.show();
|
24
|
+
return true;
|
25
|
+
},
|
26
|
+
|
27
|
+
enableButton: function (button) {
|
28
|
+
var $button = $(button);
|
29
|
+
$button.show();
|
30
|
+
$button.parent().find('.cloned-button').remove();
|
31
|
+
return true;
|
32
|
+
}
|
33
|
+
|
34
|
+
});
|
35
|
+
|
36
|
+
})(jQuery);
|