camaleon_cms 1.1.0 → 2.0.1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of camaleon_cms might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/README.md +27 -60
- data/app/apps/plugins/attack/admin_controller.rb +1 -1
- data/app/apps/plugins/attack/attack_helper.rb +4 -4
- data/app/apps/plugins/attack/config/config.json +1 -1
- data/app/apps/plugins/attack/config/custom_models.rb +1 -1
- data/app/apps/plugins/attack/views/admin/settings.html.erb +2 -2
- data/app/apps/plugins/contact_form/admin_forms_controller.rb +8 -7
- data/app/apps/plugins/contact_form/config/custom_models.rb +1 -1
- data/app/apps/plugins/contact_form/contact_form_helper.rb +4 -5
- data/app/apps/plugins/contact_form/contact_form_html_helper.rb +2 -2
- data/app/apps/plugins/contact_form/front_controller.rb +1 -1
- data/app/apps/plugins/contact_form/views/admin_forms/_form.html.erb +5 -5
- data/app/apps/plugins/contact_form/views/admin_forms/edit.html.erb +19 -35
- data/app/apps/plugins/contact_form/views/admin_forms/index.html.erb +3 -3
- data/app/apps/plugins/contact_form/views/admin_forms/responses.html.erb +6 -13
- data/app/apps/plugins/contact_form/views/forms_shorcode.html.erb +1 -1
- data/app/apps/plugins/contact_form/views/front/index.html.erb +1 -1
- data/app/apps/plugins/front_cache/admin_controller.rb +1 -1
- data/app/apps/plugins/front_cache/config/initializer.rb +1 -1
- data/app/apps/plugins/front_cache/front_cache_helper.rb +37 -42
- data/app/apps/plugins/front_cache/views/admin/settings.html.erb +3 -3
- data/app/apps/plugins/visibility_post/config/config.json +1 -1
- data/app/apps/plugins/visibility_post/visibility_post_helper.rb +21 -23
- data/app/apps/themes/camaleon_first/assets/css/main.css +1 -1
- data/app/apps/themes/camaleon_first/assets/js/main.js +1 -1
- data/app/apps/themes/camaleon_first/views/admin/settings.html.erb +1 -1
- data/app/apps/themes/default/views/admin/settings.html.erb +1 -1
- data/app/apps/themes/default/views/category.html.erb +1 -1
- data/app/apps/themes/default/views/layouts/index.html.erb +7 -7
- data/app/apps/themes/default/views/partials/_comments.html.erb +1 -1
- data/app/apps/themes/default/views/partials/_forms.html.erb +2 -2
- data/app/apps/themes/default/views/partials/_search_form.html.erb +4 -4
- data/app/apps/themes/default/views/post_tag.html.erb +1 -1
- data/app/apps/themes/default/views/post_type.html.erb +1 -1
- data/app/apps/themes/default/views/search.html.erb +1 -1
- data/app/apps/themes/new/assets/js/main.js +0 -1
- data/app/apps/themes/new/views/admin/settings.html.erb +1 -1
- data/app/apps/themes/new/views/category.html.erb +1 -1
- data/app/apps/themes/new/views/layouts/_footer.html.erb +0 -1
- data/app/apps/themes/new/views/layouts/_header.html.erb +7 -7
- data/app/apps/themes/new/views/layouts/index.html.erb +0 -1
- data/app/apps/themes/new/views/partials/_comments.html.erb +1 -1
- data/app/apps/themes/new/views/partials/_forms.html.erb +2 -2
- data/app/apps/themes/new/views/partials/_search_form.html.erb +2 -3
- data/app/apps/themes/new/views/post_tag.html.erb +1 -1
- data/app/apps/themes/new/views/post_type.html.erb +1 -1
- data/app/apps/themes/new/views/search.html.erb +1 -1
- data/app/assets/fonts/{glyphicons-halflings-regular.eot → camaleon_cms/glyphicons-halflings-regular.eot} +0 -0
- data/app/assets/fonts/{glyphicons-halflings-regular.svg → camaleon_cms/glyphicons-halflings-regular.svg} +0 -0
- data/app/assets/fonts/{glyphicons-halflings-regular.ttf → camaleon_cms/glyphicons-halflings-regular.ttf} +0 -0
- data/app/assets/fonts/{glyphicons-halflings-regular.woff → camaleon_cms/glyphicons-halflings-regular.woff} +0 -0
- data/app/assets/images/camaleon_cms/admin/admin_spinner.gif +0 -0
- data/app/assets/images/{admin → camaleon_cms/admin}/glyphicons-halflings.png +0 -0
- data/app/assets/images/{admin → camaleon_cms/admin}/intro/menus.png +0 -0
- data/app/assets/images/{admin → camaleon_cms/admin}/no_image.jpg +0 -0
- data/app/assets/images/{bg-tree.jpeg → camaleon_cms/bg-tree.jpeg} +0 -0
- data/app/assets/images/{camaleon-dark.png → camaleon_cms/camaleon-dark.png} +0 -0
- data/app/assets/images/camaleon_cms/camaleon.png +0 -0
- data/app/assets/images/{category-icon.png → camaleon_cms/category-icon.png} +0 -0
- data/app/assets/images/camaleon_cms/favicon.ico +0 -0
- data/app/assets/images/{image-not-found.png → camaleon_cms/image-not-found.png} +0 -0
- data/app/assets/images/{language → camaleon_cms/language}/de.png +0 -0
- data/app/assets/images/{language → camaleon_cms/language}/en.png +0 -0
- data/app/assets/images/{language → camaleon_cms/language}/es.png +0 -0
- data/app/assets/images/{language → camaleon_cms/language}/fr.png +0 -0
- data/app/assets/images/{language → camaleon_cms/language}/it.png +0 -0
- data/app/assets/images/{language → camaleon_cms/language}/pt.png +0 -0
- data/app/assets/images/camaleon_cms/language/pt_br.png +0 -0
- data/app/assets/images/{language → camaleon_cms/language}/zh.png +0 -0
- data/app/assets/images/{loader.gif → camaleon_cms/loader.gif} +0 -0
- data/app/assets/images/{users → camaleon_cms/users}/no-image.jpg +0 -0
- data/app/assets/javascripts/{admin/actions.js → camaleon_cms/admin/_actions.js} +3 -5
- data/app/assets/javascripts/camaleon_cms/admin/_custom_fields.js +178 -0
- data/app/assets/javascripts/{admin/data.js → camaleon_cms/admin/_data.js} +4 -9
- data/app/assets/javascripts/{admin/i18n.js → camaleon_cms/admin/_i18n.js} +10 -4
- data/app/assets/javascripts/{admin/jquery-ui.min.js → camaleon_cms/admin/_jquery-ui.min.js} +0 -0
- data/app/assets/javascripts/camaleon_cms/admin/_jquery.slugify.js +67 -0
- data/app/assets/javascripts/{admin/jquery.tagsinput.min.js → camaleon_cms/admin/_jquery.tagsinput.min.js} +0 -0
- data/app/assets/javascripts/camaleon_cms/admin/_libraries.js +339 -0
- data/app/assets/javascripts/{admin/modal.js → camaleon_cms/admin/_modal.js} +42 -25
- data/app/assets/javascripts/camaleon_cms/admin/_post.js +303 -0
- data/app/assets/javascripts/{admin/translator.js → camaleon_cms/admin/_translator.js} +4 -3
- data/app/assets/javascripts/{admin/underscore.js → camaleon_cms/admin/_underscore.js} +0 -0
- data/app/assets/javascripts/camaleon_cms/admin/admin-basic-manifest.js +3 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/admin-manifest.js +23 -18
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/bootstrap-colorpicker.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/bootstrap-datepicker.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/bootstrap-datetimepicker.min.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/bootstrap-select.js +0 -0
- data/app/assets/javascripts/camaleon_cms/admin/custom_fields_form.js +69 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/form-builder/formbuilder.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/form-builder/vendor.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/form/cropper.min.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/form/jquery.form.js +0 -0
- data/app/assets/javascripts/{admin/introjs/intro.min.js → camaleon_cms/admin/introjs/_intro.min.js} +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/jquery-sieve.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/jquery.nestable.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/jquery.validate.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin/jquery_validate}/es.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin/jquery_validate}/it.js +0 -0
- data/app/assets/javascripts/camaleon_cms/admin/jquery_validate/pt_br.js +74 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/login.js.coffee +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/login_manifest.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/lte/app.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/nav-menu.js +5 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/plugins.js +0 -0
- data/app/assets/javascripts/{admin/tageditor/jquery.caret.min.js → camaleon_cms/admin/tageditor/_jquery.caret.min.js} +0 -0
- data/app/assets/javascripts/{admin/tageditor/jquery.tag-editor.js → camaleon_cms/admin/tageditor/_jquery.tag-editor.js} +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/langs/en.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/langs/es.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/langs/it.js +0 -0
- data/app/assets/javascripts/camaleon_cms/admin/tinymce/langs/pt_br.js +219 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/langs/readme.md +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-cool.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-cry.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-embarassed.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-foot-in-mouth.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-frown.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-innocent.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-kiss.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-laughing.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-money-mouth.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-sealed.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-smile.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-surprised.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-tongue-out.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-undecided.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-wink.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/emoticons/img/smiley-yell.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/filemanager/plugin.min.js +3 -4
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/plugins/visualblocks/css/visualblocks.css +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/content.min.css.scss +2 -2
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/fonts/tinymce-small.eot +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/fonts/tinymce-small.svg +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/fonts/tinymce-small.ttf +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/fonts/tinymce-small.woff +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/fonts/tinymce.eot +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/fonts/tinymce.svg +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/fonts/tinymce.ttf +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/fonts/tinymce.woff +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/img/anchor.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/img/loader.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/img/object.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/skins/lightgray/img/trans.gif +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/themes/modern/theme.min.js +0 -0
- data/app/assets/javascripts/{admin → camaleon_cms/admin}/tinymce/tinymce.min.js +0 -0
- data/app/assets/javascripts/camaleon_cms/admin/uploader/_jquery.uploadfile.min.js +8 -0
- data/app/assets/javascripts/camaleon_cms/admin/uploader/_media_manager.js.coffee +161 -0
- data/app/assets/javascripts/camaleon_cms/admin/uploader/uploader_manifest.js +2 -0
- data/app/assets/javascripts/camaleon_cms/admin/user_profile.js +70 -0
- data/app/assets/javascripts/{bootstrap.min.js → camaleon_cms/bootstrap.min.js} +0 -0
- data/app/assets/javascripts/{gibberish-aes.js → camaleon_cms/gibberish-aes.js} +0 -0
- data/app/assets/stylesheets/camaleon_cms/admin/_custom_admin.css.scss +267 -0
- data/app/assets/stylesheets/{admin/jquery.tagsinput.css → camaleon_cms/admin/_jquery.tagsinput.css} +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/admin-basic-manifest.css +3 -3
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/admin-manifest.css +16 -8
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/bootstrap-datepicker.css.scss +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/bootstrap-datetimepicker.css.scss +1 -1
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/colorpicker.css.scss +4 -4
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/cropper/cropper.min.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/form-builder/formbuilder.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/bg.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/colorpicker/alpha.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/colorpicker/hue.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/colorpicker/saturation.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/girls-1.jpg +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/jquery/resize-icon.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/loading.gif +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/logo-small.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/logo.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/no_image.jpg +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/rormeleon-white.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/img/thumb_no_found.jpg +0 -0
- data/app/assets/stylesheets/{admin/introjs/introjs.min.css → camaleon_cms/admin/introjs/_introjs.min.css} +0 -0
- data/app/assets/stylesheets/{admin/jquery/jquery-ui.scss → camaleon_cms/admin/jquery/_jquery-ui.scss} +16 -16
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-bg_glass_75_dadada_1x400.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-icons_222222_256x240.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-icons_2e83ff_256x240.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-icons_454545_256x240.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-icons_888888_256x240.png +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/jquery/images/ui-icons_cd0a0a_256x240.png +0 -0
- data/app/assets/stylesheets/{admin/lte/admin.css.scss → camaleon_cms/admin/lte/_admin.css.scss} +4 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-black-light.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-black.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-blue-light.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-blue.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-green-light.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-green.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-purple-light.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-purple.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-red-light.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-red.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-yellow-light.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/lte/skins/skin-yellow.css +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/nav-menu.css.scss +0 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/nestable/jquery.nestable.css +0 -0
- data/app/assets/stylesheets/{admin/tageditor/jquery.tag-editor.css.scss → camaleon_cms/admin/tageditor/_jquery.tag-editor.css.scss} +0 -0
- data/app/assets/stylesheets/camaleon_cms/admin/uploader/_uploadfile.css.scss +253 -0
- data/app/assets/stylesheets/{admin → camaleon_cms/admin}/widgets.css.scss +0 -0
- data/app/assets/stylesheets/camaleon_cms/bootstrap.min.css.scss +5 -0
- data/app/controllers/{admin → camaleon_cms/admin}/appearances/nav_menus_controller.rb +14 -11
- data/app/controllers/{admin → camaleon_cms/admin}/appearances/themes_controller.rb +4 -2
- data/app/controllers/{admin → camaleon_cms/admin}/appearances/widgets/assign_controller.rb +5 -5
- data/app/controllers/{admin → camaleon_cms/admin}/appearances/widgets/main_controller.rb +8 -6
- data/app/controllers/{admin → camaleon_cms/admin}/appearances/widgets/sidebar_controller.rb +9 -9
- data/app/controllers/{admin → camaleon_cms/admin}/categories_controller.rb +18 -10
- data/app/controllers/camaleon_cms/admin/comments_controller.rb +97 -0
- data/app/controllers/{admin → camaleon_cms/admin}/installers_controller.rb +10 -10
- data/app/controllers/camaleon_cms/admin/media_controller.rb +84 -0
- data/app/controllers/{admin → camaleon_cms/admin}/plugins_controller.rb +7 -6
- data/app/controllers/{admin → camaleon_cms/admin}/post_tags_controller.rb +18 -10
- data/app/controllers/{admin → camaleon_cms/admin}/posts/drafts_controller.rb +5 -5
- data/app/controllers/{admin → camaleon_cms/admin}/posts_controller.rb +40 -23
- data/app/controllers/{admin → camaleon_cms/admin}/sessions_controller.rb +45 -35
- data/app/controllers/{admin → camaleon_cms/admin}/settings/custom_fields_controller.rb +13 -12
- data/app/controllers/{admin → camaleon_cms/admin}/settings/post_types_controller.rb +14 -13
- data/app/controllers/{admin → camaleon_cms/admin}/settings/sites_controller.rb +17 -15
- data/app/controllers/{admin → camaleon_cms/admin}/settings_controller.rb +8 -5
- data/app/controllers/{admin → camaleon_cms/admin}/user_roles_controller.rb +12 -11
- data/app/controllers/{admin → camaleon_cms/admin}/users_controller.rb +42 -48
- data/app/controllers/{admin_controller.rb → camaleon_cms/admin_controller.rb} +28 -9
- data/app/controllers/{apps → camaleon_cms/apps}/plugins_admin_controller.rb +7 -3
- data/app/controllers/camaleon_cms/apps/plugins_front_controller.rb +38 -0
- data/app/controllers/{apps → camaleon_cms/apps}/themes_admin_controller.rb +1 -1
- data/app/controllers/{apps → camaleon_cms/apps}/themes_front_controller.rb +1 -1
- data/app/controllers/camaleon_cms/camaleon_controller.rb +99 -0
- data/app/controllers/{frontend_controller.rb → camaleon_cms/frontend_controller.rb} +56 -45
- data/app/controllers/concerns/{frontend_concern.rb → camaleon_cms/frontend_concern.rb} +8 -8
- data/app/decorators/{application_decorator.rb → camaleon_cms/application_decorator.rb} +5 -17
- data/app/decorators/{category_decorator.rb → camaleon_cms/category_decorator.rb} +8 -3
- data/app/decorators/{custom_field_decorator.rb → camaleon_cms/custom_field_decorator.rb} +1 -1
- data/app/decorators/{custom_fields_concern.rb → camaleon_cms/custom_fields_concern.rb} +4 -3
- data/app/decorators/{metas_decorator_methods.rb → camaleon_cms/metas_decorator_methods.rb} +1 -1
- data/app/decorators/{nav_menu_item_decorator.rb → camaleon_cms/nav_menu_item_decorator.rb} +2 -2
- data/app/decorators/{post_comment_decorator.rb → camaleon_cms/post_comment_decorator.rb} +3 -2
- data/app/decorators/{post_decorator.rb → camaleon_cms/post_decorator.rb} +61 -14
- data/app/decorators/{post_tag_decorator.rb → camaleon_cms/post_tag_decorator.rb} +8 -3
- data/app/decorators/{post_type_decorator.rb → camaleon_cms/post_type_decorator.rb} +29 -6
- data/app/decorators/{site_decorator.rb → camaleon_cms/site_decorator.rb} +24 -22
- data/app/decorators/{term_taxonomy_decorator.rb → camaleon_cms/term_taxonomy_decorator.rb} +15 -15
- data/app/decorators/{theme_decorator.rb → camaleon_cms/theme_decorator.rb} +1 -1
- data/app/decorators/{user_decorator.rb → camaleon_cms/user_decorator.rb} +23 -11
- data/app/decorators/{widget_decorator.rb → camaleon_cms/widget_decorator.rb} +2 -2
- data/app/helpers/{admin → camaleon_cms/admin}/application_helper.rb +17 -9
- data/app/helpers/{admin → camaleon_cms/admin}/breadcrumb_helper.rb +6 -20
- data/app/helpers/{admin → camaleon_cms/admin}/category_helper.rb +6 -3
- data/app/helpers/{admin → camaleon_cms/admin}/custom_fields_helper.rb +21 -20
- data/app/helpers/{admin → camaleon_cms/admin}/menus_helper.rb +26 -36
- data/app/helpers/{admin → camaleon_cms/admin}/post_type_helper.rb +4 -4
- data/app/helpers/{camaleon_helper.rb → camaleon_cms/camaleon_helper.rb} +23 -19
- data/app/helpers/{captcha_helper.rb → camaleon_cms/captcha_helper.rb} +21 -17
- data/app/helpers/camaleon_cms/comment_helper.rb +48 -0
- data/app/helpers/{content_helper.rb → camaleon_cms/content_helper.rb} +12 -10
- data/app/helpers/{frontend → camaleon_cms/frontend}/application_helper.rb +7 -7
- data/app/helpers/{frontend → camaleon_cms/frontend}/nav_menu_helper.rb +21 -34
- data/app/helpers/{frontend → camaleon_cms/frontend}/seo_helper.rb +5 -5
- data/app/helpers/{frontend → camaleon_cms/frontend}/site_helper.rb +17 -10
- data/app/helpers/{hooks_helper.rb → camaleon_cms/hooks_helper.rb} +1 -1
- data/app/helpers/camaleon_cms/html_helper.rb +106 -0
- data/app/helpers/{plugins_helper.rb → camaleon_cms/plugins_helper.rb} +49 -64
- data/app/helpers/{session_helper.rb → camaleon_cms/session_helper.rb} +29 -26
- data/app/helpers/{short_code_helper.rb → camaleon_cms/short_code_helper.rb} +50 -16
- data/app/helpers/{site_helper.rb → camaleon_cms/site_helper.rb} +14 -19
- data/app/helpers/{theme_helper.rb → camaleon_cms/theme_helper.rb} +37 -43
- data/app/helpers/camaleon_cms/uploader_helper.rb +366 -0
- data/app/helpers/{user_roles_helper.rb → camaleon_cms/user_roles_helper.rb} +3 -3
- data/app/mailers/{html_mailer.rb → camaleon_cms/html_mailer.rb} +7 -7
- data/app/models/{ability.rb → camaleon_cms/ability.rb} +3 -3
- data/app/models/{category.rb → camaleon_cms/category.rb} +15 -12
- data/app/models/{custom_field.rb → camaleon_cms/custom_field.rb} +8 -10
- data/app/models/{custom_field_group.rb → camaleon_cms/custom_field_group.rb} +12 -11
- data/app/models/{custom_fields_relationship.rb → camaleon_cms/custom_fields_relationship.rb} +4 -4
- data/app/models/{meta.rb → camaleon_cms/meta.rb} +2 -5
- data/app/models/{nav_menu.rb → camaleon_cms/nav_menu.rb} +14 -13
- data/app/models/{nav_menu_item.rb → camaleon_cms/nav_menu_item.rb} +18 -7
- data/app/models/{plugin.rb → camaleon_cms/plugin.rb} +3 -3
- data/app/models/{post.rb → camaleon_cms/post.rb} +57 -32
- data/app/models/{post_comment.rb → camaleon_cms/post_comment.rb} +10 -9
- data/app/models/{post_default.rb → camaleon_cms/post_default.rb} +24 -19
- data/app/models/{post_relationship.rb → camaleon_cms/post_relationship.rb} +5 -5
- data/app/models/{post_tag.rb → camaleon_cms/post_tag.rb} +4 -4
- data/app/models/{post_type.rb → camaleon_cms/post_type.rb} +49 -17
- data/app/models/{site.rb → camaleon_cms/site.rb} +38 -80
- data/app/models/{term_relationship.rb → camaleon_cms/term_relationship.rb} +6 -4
- data/app/models/camaleon_cms/term_taxonomy.rb +81 -0
- data/app/models/{theme.rb → camaleon_cms/theme.rb} +3 -3
- data/app/models/{user.rb → camaleon_cms/user.rb} +23 -37
- data/app/models/{user_relationship.rb → camaleon_cms/user_relationship.rb} +4 -4
- data/app/models/camaleon_cms/user_role.rb +140 -0
- data/app/models/{widget.rb → camaleon_cms/widget.rb} +1 -1
- data/app/models/{widget → camaleon_cms/widget}/assigned.rb +4 -4
- data/app/models/{widget → camaleon_cms/widget}/main.rb +5 -5
- data/app/models/{widget → camaleon_cms/widget}/sidebar.rb +3 -3
- data/app/models/concerns/{categories_tags_for_posts.rb → camaleon_cms/categories_tags_for_posts.rb} +3 -3
- data/app/models/concerns/{custom_fields_read.rb → camaleon_cms/custom_fields_read.rb} +10 -11
- data/app/models/concerns/camaleon_cms/metas.rb +135 -0
- data/app/views/camaleon_cms/404.html.erb +4 -0
- data/app/views/camaleon_cms/500.html.erb +4 -0
- data/app/views/{_flash_messages.html.erb → camaleon_cms/_flash_messages.html.erb} +0 -0
- data/app/views/camaleon_cms/admin/appearances/nav_menus/_custom_fields.html.erb +6 -0
- data/app/views/{admin → camaleon_cms/admin}/appearances/nav_menus/_custom_menus.html.erb +2 -2
- data/app/views/{admin → camaleon_cms/admin}/appearances/nav_menus/_external_menu.html.erb +3 -3
- data/app/views/camaleon_cms/admin/appearances/nav_menus/_menu_form.html.erb +36 -0
- data/app/views/{admin → camaleon_cms/admin}/appearances/nav_menus/_menu_list.html.erb +5 -5
- data/app/views/{admin → camaleon_cms/admin}/appearances/nav_menus/index.html.erb +8 -8
- data/app/views/{admin → camaleon_cms/admin}/appearances/themes/index.html.erb +7 -6
- data/app/views/{admin → camaleon_cms/admin}/appearances/themes/preview.html.erb +0 -0
- data/app/views/{admin → camaleon_cms/admin}/appearances/themes/theme_load_data.html.erb +1 -1
- data/app/views/{admin → camaleon_cms/admin}/appearances/widgets/assign/_form.html.erb +5 -5
- data/app/views/{admin → camaleon_cms/admin}/appearances/widgets/main/_sidebar.html.erb +4 -4
- data/app/views/camaleon_cms/admin/appearances/widgets/main/form.html.erb +27 -0
- data/app/views/camaleon_cms/admin/appearances/widgets/main/index.html.erb +41 -0
- data/app/views/{admin → camaleon_cms/admin}/appearances/widgets/sidebar/form.html.erb +5 -5
- data/app/views/camaleon_cms/admin/categories/_form.html.erb +42 -0
- data/app/views/{admin/settings/post_types → camaleon_cms/admin/categories}/edit.html.erb +1 -1
- data/app/views/{admin → camaleon_cms/admin}/categories/index.html.erb +16 -26
- data/app/views/camaleon_cms/admin/comments/form.html.erb +12 -0
- data/app/views/camaleon_cms/admin/comments/form_answer.html.erb +12 -0
- data/app/views/camaleon_cms/admin/comments/index.html.erb +21 -0
- data/app/views/camaleon_cms/admin/comments/list.html.erb +36 -0
- data/app/views/{admin/dashboard/index.html.erb → camaleon_cms/admin/dashboard.html.erb} +2 -2
- data/app/views/{admin → camaleon_cms/admin}/installers/form.html.erb +6 -6
- data/app/views/camaleon_cms/admin/installers/welcome.html.erb +8 -0
- data/app/views/camaleon_cms/admin/media/_files_list.html.erb +7 -0
- data/app/views/camaleon_cms/admin/media/_render_file_item.html.erb +27 -0
- data/app/views/camaleon_cms/admin/media/_render_folder_item.html.erb +13 -0
- data/app/views/camaleon_cms/admin/media/index.html.erb +25 -0
- data/app/views/{admin → camaleon_cms/admin}/plugins/_plugins_list.html.erb +10 -10
- data/app/views/{admin → camaleon_cms/admin}/plugins/index.html.erb +10 -6
- data/app/views/{admin → camaleon_cms/admin}/post_tags/_form.html.erb +8 -14
- data/app/views/{admin → camaleon_cms/admin}/post_tags/edit.html.erb +2 -2
- data/app/views/camaleon_cms/admin/post_tags/index.html.erb +58 -0
- data/app/views/camaleon_cms/admin/posts/_filter_posts.html.erb +5 -0
- data/app/views/{admin → camaleon_cms/admin}/posts/_sidebar.html.erb +34 -36
- data/app/views/camaleon_cms/admin/posts/form.html.erb +97 -0
- data/app/views/{admin → camaleon_cms/admin}/posts/index.html.erb +34 -31
- data/app/views/{admin → camaleon_cms/admin}/posts/show.html.erb +1 -1
- data/app/views/camaleon_cms/admin/search.html.erb +68 -0
- data/app/views/camaleon_cms/admin/sessions/forgot.html.erb +44 -0
- data/app/views/camaleon_cms/admin/sessions/login.html.erb +49 -0
- data/app/views/camaleon_cms/admin/sessions/register.html.erb +63 -0
- data/app/views/camaleon_cms/admin/settings/_configuration_settings.html.erb +35 -0
- data/app/views/camaleon_cms/admin/settings/_email_settings.html.erb +33 -0
- data/app/views/camaleon_cms/admin/settings/_file_system_settings.html.erb +23 -0
- data/app/views/camaleon_cms/admin/settings/_seo_settings.html.erb +22 -0
- data/app/views/{admin/settings/custom_fields/get_items.html.erb → camaleon_cms/admin/settings/custom_fields/_get_items.html.erb} +19 -39
- data/app/views/{admin → camaleon_cms/admin}/settings/custom_fields/_meta_data.html.erb +2 -2
- data/app/views/{admin → camaleon_cms/admin}/settings/custom_fields/_render.html.erb +25 -31
- data/app/views/{admin/settings/custom_fields/fields/audio.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_audio.html.erb} +1 -1
- data/app/views/{admin/settings/custom_fields/fields/checkbox.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_checkbox.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/checkboxes.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_checkboxes.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/colorpicker.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_colorpicker.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/date.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_date.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/editor.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_editor.html.erb} +0 -1
- data/app/views/{admin/settings/custom_fields/fields/email.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_email.html.erb} +0 -0
- data/app/views/camaleon_cms/admin/settings/custom_fields/fields/_field_attrs.html.erb +8 -0
- data/app/views/{admin/settings/custom_fields/fields/file.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_file.html.erb} +1 -1
- data/app/views/{admin/settings/custom_fields/fields/image.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_image.html.erb} +1 -1
- data/app/views/{admin/settings/custom_fields/fields/numeric.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_numeric.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/phone.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_phone.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/posts.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_posts.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/radio.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_radio.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/select.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_select.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/select_eval.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_select_eval.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/text_area.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_text_area.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/text_box.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_text_box.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/url.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_url.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/users.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_users.html.erb} +0 -0
- data/app/views/{admin/settings/custom_fields/fields/video.html.erb → camaleon_cms/admin/settings/custom_fields/fields/_video.html.erb} +1 -1
- data/app/views/camaleon_cms/admin/settings/custom_fields/form.html.erb +137 -0
- data/app/views/{admin → camaleon_cms/admin}/settings/custom_fields/index.html.erb +18 -14
- data/app/views/{admin → camaleon_cms/admin}/settings/languages.html.erb +7 -7
- data/app/views/camaleon_cms/admin/settings/post_types/_form.html.erb +134 -0
- data/app/views/{admin/categories → camaleon_cms/admin/settings/post_types}/edit.html.erb +2 -2
- data/app/views/camaleon_cms/admin/settings/post_types/index.html.erb +54 -0
- data/app/views/camaleon_cms/admin/settings/shortcodes.html.erb +37 -0
- data/app/views/camaleon_cms/admin/settings/site.html.erb +112 -0
- data/app/views/{admin → camaleon_cms/admin}/settings/sites/form.html.erb +9 -9
- data/app/views/camaleon_cms/admin/settings/sites/index.html.erb +58 -0
- data/app/views/camaleon_cms/admin/user_roles/form.html.erb +160 -0
- data/app/views/camaleon_cms/admin/user_roles/index.html.erb +51 -0
- data/app/views/camaleon_cms/admin/users/form.html.erb +233 -0
- data/app/views/camaleon_cms/admin/users/index.html.erb +55 -0
- data/app/views/camaleon_cms/admin/users/profile.html.erb +1 -0
- data/app/views/{admin → camaleon_cms/admin}/users/profile/_activity.html.erb +0 -0
- data/app/views/{admin → camaleon_cms/admin}/users/profile/_settings.html.erb +0 -0
- data/app/views/camaleon_cms/default_theme/admin/settings.html.erb +1 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/category.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/category.rss.builder +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/audio.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/checkbox.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/checkboxes.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/colorpicker.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/date.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/editor.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/email.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/field_attrs.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/file.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/image.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/numeric.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/phone.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/posts.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/radio.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/select.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/select_eval.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/text_area.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/text_box.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/url.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/users.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/custom_fields/video.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/index.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/layouts/_footer.html.erb +0 -1
- data/app/views/{default_theme → camaleon_cms/default_theme}/layouts/_header.html.erb +7 -7
- data/app/views/{default_theme → camaleon_cms/default_theme}/layouts/index.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/partials/_breadcrumb.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/partials/_categories_list.html.erb +0 -0
- data/app/views/camaleon_cms/default_theme/partials/_comments.html.erb +33 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/partials/_comments_list.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/partials/_flash_messages.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/partials/_forms.html.erb +2 -2
- data/app/views/{default_theme → camaleon_cms/default_theme}/partials/_post_list_item.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/partials/_render_custom_field.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/partials/_search_form.html.erb +2 -4
- data/app/views/{default_theme → camaleon_cms/default_theme}/partials/_sidebar.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/post_tag.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/post_tag.rss.builder +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/post_type.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/post_type.rss.builder +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/profile.html.erb +0 -0
- data/app/views/camaleon_cms/default_theme/robots.text.erb +1 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/rss.rss.builder +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/search.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/single.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/single.rss.builder +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/sitemap.html.erb +0 -0
- data/app/views/{default_theme → camaleon_cms/default_theme}/sitemap.xml.builder +0 -0
- data/app/views/{html_mailer → camaleon_cms/html_mailer}/mailer.html.erb +0 -0
- data/app/views/{shortcode_templates → camaleon_cms/shortcode_templates}/widget.html.erb +1 -1
- data/app/views/layouts/camaleon_cms/admin.html.erb +49 -0
- data/app/views/layouts/camaleon_cms/admin/_ajax.html.erb +6 -0
- data/app/views/layouts/{admin → camaleon_cms/admin}/_flash_messages.html.erb +9 -0
- data/app/views/layouts/{admin → camaleon_cms/admin}/_footer.html.erb +0 -0
- data/app/views/layouts/{admin → camaleon_cms/admin}/_form_error.html.erb +1 -1
- data/app/views/layouts/{admin → camaleon_cms/admin}/_header.html.erb +11 -11
- data/app/views/layouts/camaleon_cms/admin/_sidebar.html.erb +19 -0
- data/app/views/layouts/{admin → camaleon_cms/admin}/installer.html.erb +5 -5
- data/app/views/layouts/{application.html.erb → camaleon_cms/application.html.erb} +0 -0
- data/app/views/layouts/{login.html.erb → camaleon_cms/login.html.erb} +5 -4
- data/app/views/layouts/{mailer.html.erb → camaleon_cms/mailer.html.erb} +0 -0
- data/config/initializers/action_view.rb +31 -0
- data/config/initializers/active_record_extension.rb +52 -2
- data/config/initializers/assets.rb +0 -18
- data/config/initializers/custom_initializers.rb +7 -0
- data/config/locales/camaleon_cms/admin/en.yml +648 -0
- data/config/locales/camaleon_cms/admin/es.yml +597 -0
- data/config/locales/camaleon_cms/admin/it.yml +607 -0
- data/config/locales/camaleon_cms/admin/js.yml +127 -0
- data/config/locales/camaleon_cms/admin/pt_br.yml +610 -0
- data/config/locales/camaleon_cms/common.yml +193 -0
- data/config/locales/{languages.yml → camaleon_cms/languages.yml} +0 -0
- data/config/locales/{routes.yml → camaleon_cms/routes.yml} +8 -0
- data/config/locales/{pt.yml → pt-BR.yml} +1 -1
- data/config/routes.rb +8 -24
- data/config/routes/admin.rb +114 -98
- data/config/routes/frontend.rb +39 -27
- data/config/system.json +5 -3
- data/db/migrate/20150611161134_post_table_into_utf8.rb +15 -15
- data/db/migrate/20150926095310_rename_column_posts.rb +4 -4
- data/lib/camaleon_cms/engine.rb +6 -9
- data/lib/camaleon_cms/version.rb +1 -1
- data/lib/ext/string.rb +10 -45
- data/lib/ext/translator.rb +3 -2
- data/lib/generators/camaleon_cms/gem_plugin_generator.rb +90 -83
- data/lib/generators/camaleon_cms/gem_plugin_template/app/controllers/plugins/my_plugin/admin_controller.rb +1 -1
- data/lib/generators/camaleon_cms/gem_plugin_template/app/controllers/plugins/my_plugin/front_controller.rb +1 -1
- data/lib/generators/camaleon_cms/gem_plugin_template/app/views/plugins/my_plugin/admin/index.html.erb +9 -2
- data/lib/generators/camaleon_cms/gem_theme_generator.rb +97 -0
- data/lib/generators/{ctheme_template/app/apps/themes/my_theme/assets/images → camaleon_cms/gem_theme_template/app/assets/images/themes/my_plugin}/image.png +0 -0
- data/lib/generators/{ctheme_template/app/apps/themes/my_theme/assets/js → camaleon_cms/gem_theme_template/app/assets/javascripts/themes/my_plugin}/main.js +1 -1
- data/lib/generators/{ctheme_template/app/apps/themes/my_theme/assets/css → camaleon_cms/gem_theme_template/app/assets/stylesheets/themes/my_plugin}/main.css +1 -1
- data/lib/generators/camaleon_cms/gem_theme_template/app/helpers/themes/my_plugin/main_helper.rb +26 -0
- data/lib/generators/{ctheme_template/app/apps/themes/my_theme/views → camaleon_cms/gem_theme_template/app/views/themes/my_plugin}/admin/settings.html.erb +1 -1
- data/lib/generators/{ctheme_template/app/apps/themes/my_theme/views → camaleon_cms/gem_theme_template/app/views/themes/my_plugin}/index.html.erb +0 -0
- data/lib/generators/camaleon_cms/gem_theme_template/app/views/themes/my_plugin/layouts/index.html.erb +71 -0
- data/lib/generators/{ctheme_template/app/apps/themes/my_theme/views → camaleon_cms/gem_theme_template/app/views/themes/my_plugin}/partials/readme.txt +0 -0
- data/lib/generators/camaleon_cms/gem_theme_template/config/camaleon_theme.json +14 -0
- data/lib/generators/camaleon_cms/install_template/system.json +4 -2
- data/lib/generators/camaleon_cms/theme_generator.rb +71 -0
- data/lib/generators/camaleon_cms/theme_template/app/apps/themes/my_theme/assets/css/main.css +12 -0
- data/lib/generators/camaleon_cms/theme_template/app/apps/themes/my_theme/assets/images/image.png +0 -0
- data/lib/generators/camaleon_cms/theme_template/app/apps/themes/my_theme/assets/js/main.js +14 -0
- data/lib/generators/{ctheme_template → camaleon_cms/theme_template}/app/apps/themes/my_theme/config/config.json +0 -0
- data/lib/generators/{ctheme_template → camaleon_cms/theme_template}/app/apps/themes/my_theme/main_helper.rb +0 -0
- data/lib/generators/camaleon_cms/theme_template/app/apps/themes/my_theme/views/admin/settings.html.erb +4 -0
- data/lib/generators/camaleon_cms/theme_template/app/apps/themes/my_theme/views/index.html.erb +25 -0
- data/lib/generators/{ctheme_template → camaleon_cms/theme_template}/app/apps/themes/my_theme/views/layouts/index.html.erb +8 -8
- data/lib/generators/camaleon_cms/theme_template/app/apps/themes/my_theme/views/partials/readme.txt +1 -0
- data/lib/plugin_routes.rb +59 -28
- data/lib/tasks/camaleon_cms/rspec_test.rake +16 -0
- metadata +458 -548
- data/app/apps/plugins/contact_form/views/admin_forms/manual.html.erb +0 -59
- data/app/apps/themes/new/assets/js/plugins/modal_elfinder.js +0 -29
- data/app/assets/javascripts/admin/admin-basic-manifest.js +0 -3
- data/app/assets/javascripts/admin/custom_fields.js +0 -167
- data/app/assets/javascripts/admin/elfinder-manifest.js +0 -7
- data/app/assets/javascripts/admin/elfinder/elfinder.full.js +0 -12646
- data/app/assets/javascripts/admin/elfinder/i18n/elfinder.es.js +0 -294
- data/app/assets/javascripts/admin/elfinder/i18n/elfinder.fr.js +0 -298
- data/app/assets/javascripts/admin/elfinder/i18n/elfinder.it.js +0 -366
- data/app/assets/javascripts/admin/elfinder/proxy/elFinderSupportVer1.js +0 -338
- data/app/assets/javascripts/admin/elfinder/upload_elfinder.js +0 -237
- data/app/assets/javascripts/admin/jquery.slugify.js +0 -65
- data/app/assets/javascripts/admin/libraries.js +0 -266
- data/app/assets/javascripts/admin/post.js +0 -273
- data/app/assets/javascripts/admin/widgets.js +0 -54
- data/app/assets/javascripts/elfinder_front.js +0 -85
- data/app/assets/stylesheets/admin/custom_admin.css.scss +0 -193
- data/app/assets/stylesheets/admin/elfinder-manifest.css +0 -6
- data/app/assets/stylesheets/admin/elfinder/elfinder-theme.scss +0 -191
- data/app/assets/stylesheets/admin/elfinder/elfinder.css +0 -1922
- data/app/assets/stylesheets/admin/elfinder/images/arrows-active.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/arrows-normal.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/crop.gif +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/dialogs.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/icons-big.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/icons-small.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/logo.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/progress.gif +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/quicklook-bg.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/quicklook-icons.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/resize.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/spinner-mini.gif +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/toolbar.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/app/assets/stylesheets/admin/elfinder/images/ui-icons_222222_256x240.png +0 -0
- data/app/assets/stylesheets/bootstrap.min.css.scss +0 -5
- data/app/controllers/admin/appearances_controller.rb +0 -13
- data/app/controllers/admin/comments_controller.rb +0 -113
- data/app/controllers/admin/media_controller.rb +0 -53
- data/app/controllers/api/api_controller.rb +0 -31
- data/app/controllers/api/v1/category_controller.rb +0 -15
- data/app/controllers/api/v1/contact_form_controller.rb +0 -55
- data/app/controllers/api/v1/page_controller.rb +0 -8
- data/app/controllers/api/v1/post_controller.rb +0 -8
- data/app/controllers/apps/plugins_front_controller.rb +0 -20
- data/app/controllers/camaleon_controller.rb +0 -116
- data/app/helpers/html_helper.rb +0 -118
- data/app/helpers/uploader_helper.rb +0 -214
- data/app/models/concerns/metas.rb +0 -136
- data/app/models/grid_template.rb +0 -15
- data/app/models/term_taxonomy.rb +0 -157
- data/app/models/user_role.rb +0 -139
- data/app/serializers/api/base_serializer.rb +0 -9
- data/app/serializers/api/v1/category_serializer.rb +0 -8
- data/app/views/admin/appearances/nav_menus/_custom_fields.html.erb +0 -6
- data/app/views/admin/appearances/nav_menus/_menu_form.html.erb +0 -32
- data/app/views/admin/appearances/widgets/main/form.html.erb +0 -27
- data/app/views/admin/appearances/widgets/main/index.html.erb +0 -69
- data/app/views/admin/categories/_form.html.erb +0 -42
- data/app/views/admin/comments/form.html.erb +0 -52
- data/app/views/admin/comments/index.html.erb +0 -41
- data/app/views/admin/comments/reply.html.erb +0 -196
- data/app/views/admin/installers/welcome.html.erb +0 -8
- data/app/views/admin/media/iframe.html.erb +0 -33
- data/app/views/admin/media/index.html.erb +0 -19
- data/app/views/admin/post_tags/index.html.erb +0 -74
- data/app/views/admin/posts/_filter_posts.html.erb +0 -6
- data/app/views/admin/posts/form.html.erb +0 -103
- data/app/views/admin/sessions/forgot.html.erb +0 -45
- data/app/views/admin/sessions/login.html.erb +0 -49
- data/app/views/admin/sessions/register.html.erb +0 -62
- data/app/views/admin/settings/custom_fields/fields/field_attrs.html.erb +0 -8
- data/app/views/admin/settings/custom_fields/form.html.erb +0 -248
- data/app/views/admin/settings/post_types/_form.html.erb +0 -93
- data/app/views/admin/settings/post_types/index.html.erb +0 -72
- data/app/views/admin/settings/site.html.erb +0 -188
- data/app/views/admin/settings/sites/index.html.erb +0 -55
- data/app/views/admin/taxonomy/_form.html.erb +0 -62
- data/app/views/admin/taxonomy/edit.html.erb +0 -18
- data/app/views/admin/taxonomy/index.html.erb +0 -79
- data/app/views/admin/user_roles/form.html.erb +0 -167
- data/app/views/admin/user_roles/index.html.erb +0 -48
- data/app/views/admin/users/form.html.erb +0 -306
- data/app/views/admin/users/index.html.erb +0 -53
- data/app/views/admin/users/profile.html.erb +0 -118
- data/app/views/admin/users/profile_edit.html.erb +0 -312
- data/app/views/default_theme/admin/settings.html.erb +0 -1
- data/app/views/default_theme/partials/_comments.html.erb +0 -33
- data/app/views/default_theme/robots.text.erb +0 -1
- data/app/views/layouts/admin.html.erb +0 -56
- data/app/views/layouts/admin/_ajax.html.erb +0 -2
- data/app/views/layouts/admin/_sidebar.html.erb +0 -22
- data/app/views/shortcode_templates/form.html.erb +0 -1
- data/config/initializers/cache_helper.rb +0 -17
- data/config/initializers/doorkeeper.rb +0 -128
- data/config/initializers/elfinder.rb +0 -63
- data/config/initializers/page_caching.rb +0 -42
- data/config/initializers/rufus_cron.rb +0 -33
- data/config/initializers/swagger.rb +0 -18
- data/config/locales/admin/en.yml +0 -618
- data/config/locales/admin/es.yml +0 -584
- data/config/locales/admin/it.yml +0 -605
- data/config/locales/admin/js.yml +0 -118
- data/config/locales/common.yml +0 -189
- data/config/locales/doorkeeper.en.yml +0 -123
- data/db/migrate/20150930115030_doorkeeper_configuration.rb +0 -45
- data/lib/generators/camaleon_cms/install_template/apps/plugins/readme.txt +0 -1
- data/lib/generators/camaleon_cms/install_template/apps/themes/readme.txt +0 -1
- data/lib/generators/cplugin_generator.rb +0 -82
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/admin_controller.rb +0 -8
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/assets/css/readme.txt +0 -1
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/assets/images/readme.txt +0 -1
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/assets/js/readme.txt +0 -1
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/config/config.json +0 -21
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/config/locales/readme.txt +0 -1
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/config/routes_admin.txt +0 -1
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/config/routes_front.txt +0 -1
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/front_controller.rb +0 -8
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/main_helper.rb +0 -22
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/models/my_plugin.rb +0 -7
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/views/admin/index.html.erb +0 -2
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/views/front/index.html.erb +0 -2
- data/lib/generators/cplugin_template/app/apps/plugins/my_plugin/views/layouts/readme.txt +0 -2
- data/lib/generators/ctheme_generator.rb +0 -65
- data/lib/tasks/camaleon_cms_tasks.rake +0 -23
- data/lib/tasks/precompile_overrides.rake +0 -6
@@ -6,7 +6,7 @@
|
|
6
6
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
7
7
|
See the GNU Affero General Public License (GPLv3) for more details.
|
8
8
|
=end
|
9
|
-
class TermTaxonomyDecorator < ApplicationDecorator
|
9
|
+
class CamaleonCms::TermTaxonomyDecorator < CamaleonCms::ApplicationDecorator
|
10
10
|
include CustomFieldsConcern
|
11
11
|
delegate_all
|
12
12
|
|
@@ -31,9 +31,9 @@ class TermTaxonomyDecorator < ApplicationDecorator
|
|
31
31
|
|
32
32
|
def the_status
|
33
33
|
if status.to_s.to_bool
|
34
|
-
"<span class='label label-success'> #{I18n.t('admin.button.actived')} </span>"
|
34
|
+
"<span class='label label-success'> #{I18n.t('camaleon_cms.admin.button.actived')} </span>"
|
35
35
|
else
|
36
|
-
"<span class='label label-default'> #{I18n.t('admin.button.not_actived')} </span>"
|
36
|
+
"<span class='label label-default'> #{I18n.t('camaleon_cms.admin.button.not_actived')} </span>"
|
37
37
|
end
|
38
38
|
end
|
39
39
|
|
@@ -64,14 +64,14 @@ class TermTaxonomyDecorator < ApplicationDecorator
|
|
64
64
|
def the_edit_url
|
65
65
|
link = ""
|
66
66
|
case object.class.name
|
67
|
-
when "PostType"
|
68
|
-
link = h.
|
69
|
-
when "Category"
|
70
|
-
link = h.
|
71
|
-
when "PostTag"
|
72
|
-
link = h.
|
73
|
-
when "Site"
|
74
|
-
link = h.
|
67
|
+
when "CamaleonCms::PostType"
|
68
|
+
link = h.edit_cama_admin_settings_post_type_url(object)
|
69
|
+
when "CamaleonCms::Category"
|
70
|
+
link = h.edit_cama_admin_post_type_category_url(object.post_type.id, object)
|
71
|
+
when "CamaleonCms::PostTag"
|
72
|
+
link = h.edit_cama_admin_post_type_post_tag_url(object.post_type.id, object)
|
73
|
+
when "CamaleonCms::Site"
|
74
|
+
link = h.cama_admin_settings_site_url
|
75
75
|
end
|
76
76
|
link
|
77
77
|
end
|
@@ -89,13 +89,13 @@ class TermTaxonomyDecorator < ApplicationDecorator
|
|
89
89
|
def cache_prefix(key = "")
|
90
90
|
res = ""
|
91
91
|
case object.class.name
|
92
|
-
when "PostType"
|
92
|
+
when "CamaleonCms::PostType"
|
93
93
|
res = "#{h.current_site.cache_prefix}/ptype#{object.id}#{"/#{key}" if key.present?}"
|
94
|
-
when "Category"
|
94
|
+
when "CamaleonCms::Category"
|
95
95
|
res = "#{h.current_site.cache_prefix}/pcat#{object.id}#{"/#{key}" if key.present?}"
|
96
|
-
when "PostTag"
|
96
|
+
when "CamaleonCms::PostTag"
|
97
97
|
res = "#{h.current_site.cache_prefix}/ptag#{object.id}#{"/#{key}" if key.present?}"
|
98
|
-
when "Site"
|
98
|
+
when "CamaleonCms::Site"
|
99
99
|
res = "/#{object.id}/#{I18n.locale}#{"/#{key}" if key.present?}"
|
100
100
|
end
|
101
101
|
res
|
@@ -6,7 +6,7 @@
|
|
6
6
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
7
7
|
See the GNU Affero General Public License (GPLv3) for more details.
|
8
8
|
=end
|
9
|
-
class ThemeDecorator < TermTaxonomyDecorator
|
9
|
+
class CamaleonCms::ThemeDecorator < CamaleonCms::TermTaxonomyDecorator
|
10
10
|
delegate_all
|
11
11
|
|
12
12
|
def the_id
|
@@ -6,8 +6,8 @@
|
|
6
6
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
7
7
|
See the GNU Affero General Public License (GPLv3) for more details.
|
8
8
|
=end
|
9
|
-
class UserDecorator < ApplicationDecorator
|
10
|
-
include CustomFieldsConcern
|
9
|
+
class CamaleonCms::UserDecorator < CamaleonCms::ApplicationDecorator
|
10
|
+
include CamaleonCms::CustomFieldsConcern
|
11
11
|
delegate_all
|
12
12
|
|
13
13
|
# return the identifier
|
@@ -27,22 +27,17 @@ class UserDecorator < ApplicationDecorator
|
|
27
27
|
|
28
28
|
# return the avatar for this user, default: assets/admin/img/no_image.jpg
|
29
29
|
def the_avatar
|
30
|
-
avatar_exists
|
31
|
-
if object.meta[:avatar].present? && avatar_exists
|
32
|
-
object.meta[:avatar]
|
33
|
-
else
|
34
|
-
h.asset_url("admin/img/no_image.jpg")
|
35
|
-
end
|
30
|
+
avatar_exists? ? object.get_meta("avatar") : h.asset_url("camaleon_cms/admin/img/no_image.jpg")
|
36
31
|
end
|
37
32
|
|
38
33
|
# return the slogan for this user, default: Hello World
|
39
34
|
def the_slogan
|
40
|
-
object.
|
35
|
+
object.get_meta("slogan", "Hello World")
|
41
36
|
end
|
42
37
|
|
43
38
|
# generate all seo attributes for profile page
|
44
39
|
def the_seo
|
45
|
-
h.
|
40
|
+
h.cama_build_seo({ image: (the_avatar rescue nil), title: the_name, object: self })
|
46
41
|
end
|
47
42
|
|
48
43
|
# return front url for this user
|
@@ -53,7 +48,12 @@ class UserDecorator < ApplicationDecorator
|
|
53
48
|
args[:locale] = get_locale unless args.include?(:locale)
|
54
49
|
args[:format] = "html"
|
55
50
|
as_path = args.delete(:as_path)
|
56
|
-
h.
|
51
|
+
h.cama_url_to_fixed("cama_profile_#{as_path.present? ? "path" : "url"}", args)
|
52
|
+
end
|
53
|
+
|
54
|
+
# return the url for the profile in the admin module
|
55
|
+
def the_admin_profile_url
|
56
|
+
h.cama_admin_profile_url(object.id)
|
57
57
|
end
|
58
58
|
|
59
59
|
# return all contents created by this user in current site
|
@@ -66,4 +66,16 @@ class UserDecorator < ApplicationDecorator
|
|
66
66
|
def cache_prefix(key = "")
|
67
67
|
"#{h.current_site.cache_prefix}/user#{object.id}#{"/#{key}" if key.present?}"
|
68
68
|
end
|
69
|
+
|
70
|
+
private
|
71
|
+
|
72
|
+
def avatar_exists?
|
73
|
+
# TODO change verification
|
74
|
+
# if object.get_meta('avatar').present?
|
75
|
+
# File.exist?(h.cama_url_to_file_path(object.get_meta('avatar'))) || Faraday.head(object.get_meta('avatar')).status == 200
|
76
|
+
# else
|
77
|
+
# false
|
78
|
+
# end
|
79
|
+
object.get_meta('avatar').present?
|
80
|
+
end
|
69
81
|
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
7
7
|
See the GNU Affero General Public License (GPLv3) for more details.
|
8
8
|
=end
|
9
|
-
class WidgetDecorator < Draper::Decorator
|
10
|
-
include CustomFieldsConcern
|
9
|
+
class CamaleonCms::WidgetDecorator < Draper::Decorator
|
10
|
+
include CamaleonCms::CustomFieldsConcern
|
11
11
|
delegate_all
|
12
12
|
end
|
@@ -6,11 +6,11 @@
|
|
6
6
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
7
7
|
See the GNU Affero General Public License (GPLv3) for more details.
|
8
8
|
=end
|
9
|
-
module Admin::ApplicationHelper
|
10
|
-
# include Admin::ApiHelper
|
11
|
-
include Admin::MenusHelper
|
12
|
-
include Admin::PostTypeHelper
|
13
|
-
include Admin::CategoryHelper
|
9
|
+
module CamaleonCms::Admin::ApplicationHelper
|
10
|
+
# include CamaleonCms::Admin::ApiHelper
|
11
|
+
include CamaleonCms::Admin::MenusHelper
|
12
|
+
include CamaleonCms::Admin::PostTypeHelper
|
13
|
+
include CamaleonCms::Admin::CategoryHelper
|
14
14
|
|
15
15
|
# load system notification
|
16
16
|
def admin_system_notifications(args)
|
@@ -27,15 +27,23 @@ module Admin::ApplicationHelper
|
|
27
27
|
|
28
28
|
# render pagination for current items
|
29
29
|
# items is a will pagination object
|
30
|
-
# sample: <%= raw
|
31
|
-
def
|
32
|
-
|
30
|
+
# sample: <%= raw cama_do_pagination(@posts) %>
|
31
|
+
def cama_do_pagination(items, *will_paginate_options)
|
32
|
+
will_paginate_options = will_paginate_options.extract_options!
|
33
|
+
custom_class = will_paginate_options[:panel_class]
|
34
|
+
will_paginate_options.delete(:panel_class)
|
35
|
+
"<div class='row #{custom_class} pagination_panel cama_ajax_request'>
|
33
36
|
<div class='col-md-6'>
|
34
|
-
#{will_paginate items }
|
37
|
+
#{will_paginate items, will_paginate_options }
|
35
38
|
</div>
|
36
39
|
<div class='col-md-6 text-right total-items'>
|
37
40
|
<strong>Total: #{items.total_entries} </strong>
|
38
41
|
</div>
|
39
42
|
</div>"
|
40
43
|
end
|
44
|
+
|
45
|
+
# print code with auto copy
|
46
|
+
def cama_shortcode_print(code)
|
47
|
+
"<input onmousedown=\"this.clicked = 1;\" readonly onfocus=\"if (!this.clicked) this.select(); else this.clicked = 2;\" onclick=\"if (this.clicked == 2) this.select(); this.clicked = 0;\" class='code_style' value=\"#{code}\">"
|
48
|
+
end
|
41
49
|
end
|
@@ -6,32 +6,18 @@
|
|
6
6
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
7
7
|
See the GNU Affero General Public License (GPLv3) for more details.
|
8
8
|
=end
|
9
|
-
module Admin::BreadcrumbHelper
|
10
|
-
# draw
|
11
|
-
def
|
12
|
-
res = []
|
13
|
-
@
|
14
|
-
if @_admin_breadcrumb.size == (index+1) #last menu
|
15
|
-
res << "<li class='active'>#{item[0]}</li>"
|
16
|
-
else
|
17
|
-
res << "<li><a href='#{item[1]}'>#{item[0]}</a></li>"
|
18
|
-
end
|
19
|
-
end
|
20
|
-
res.join("")
|
21
|
-
end
|
22
|
-
|
23
|
-
def admin_title_draw
|
24
|
-
res = []
|
25
|
-
@_admin_breadcrumb.each_with_index do |item, index|
|
26
|
-
res << item[0]
|
27
|
-
end
|
9
|
+
module CamaleonCms::Admin::BreadcrumbHelper
|
10
|
+
# draw the title for the admin admin panel according the breadcrumb
|
11
|
+
def cama_admin_title_draw
|
12
|
+
res = [t("camaleon_cms.admin.sidebar_top.admin_panel")]
|
13
|
+
@breadcrumbs.reverse.slice(0, 2).reverse.each{|b| res << b.name }
|
28
14
|
res.join(" » ")
|
29
15
|
end
|
30
16
|
|
31
17
|
# add breadcrumb item at the end
|
32
18
|
# label => label of the link
|
33
19
|
# url: url for the link
|
20
|
+
# DEPRECATED
|
34
21
|
def admin_breadcrumb_add(label, url = "")
|
35
|
-
@_admin_breadcrumb << [label, url]
|
36
22
|
end
|
37
23
|
end
|
@@ -7,14 +7,17 @@
|
|
7
7
|
See the GNU Affero General Public License (GPLv3) for more details.
|
8
8
|
=end
|
9
9
|
#encoding: utf-8
|
10
|
-
module Admin::CategoryHelper
|
10
|
+
module CamaleonCms::Admin::CategoryHelper
|
11
11
|
|
12
|
-
|
12
|
+
# build an array multiple with category items prefixed with - for each level
|
13
|
+
# categories: collection of categories
|
14
|
+
# level: internal iterator control
|
15
|
+
def cama_category_get_options_html(categories, level = 0)
|
13
16
|
options = []
|
14
17
|
categories.all.decorate.each do |category|
|
15
18
|
options << [("—"*level) + category.the_title, category.id] unless @category.id == category.id
|
16
19
|
children = category.children
|
17
|
-
options +=
|
20
|
+
options += cama_category_get_options_html(children, level + 1) if children.size > 0
|
18
21
|
end
|
19
22
|
options
|
20
23
|
end
|
@@ -7,13 +7,13 @@
|
|
7
7
|
See the GNU Affero General Public License (GPLv3) for more details.
|
8
8
|
=end
|
9
9
|
#encoding: utf-8
|
10
|
-
module Admin::CustomFieldsHelper
|
10
|
+
module CamaleonCms::Admin::CustomFieldsHelper
|
11
11
|
def cf_get_items
|
12
12
|
items = {}
|
13
13
|
|
14
14
|
items[:text_box] = {
|
15
15
|
key: 'text_box',
|
16
|
-
label: t('admin.custom_field.fields.text_box'),
|
16
|
+
label: t('camaleon_cms.admin.custom_field.fields.text_box'),
|
17
17
|
options: {
|
18
18
|
required: true,
|
19
19
|
multiple: true,
|
@@ -25,7 +25,7 @@ module Admin::CustomFieldsHelper
|
|
25
25
|
|
26
26
|
items[:text_area] = {
|
27
27
|
key: 'text_area',
|
28
|
-
label: t('admin.custom_field.fields.text_area'),
|
28
|
+
label: t('camaleon_cms.admin.custom_field.fields.text_area'),
|
29
29
|
options: {
|
30
30
|
required: true,
|
31
31
|
multiple: true,
|
@@ -36,12 +36,12 @@ module Admin::CustomFieldsHelper
|
|
36
36
|
}
|
37
37
|
items[:select] = {
|
38
38
|
key: 'select',
|
39
|
-
label: t('admin.custom_field.fields.select'),
|
39
|
+
label: t('camaleon_cms.admin.custom_field.fields.select'),
|
40
40
|
options: {
|
41
41
|
required: true,
|
42
42
|
multiple: false,
|
43
43
|
multiple_options: {
|
44
|
-
label: t('admin.settings.options_select'),
|
44
|
+
label: t('camaleon_cms.admin.settings.options_select'),
|
45
45
|
default: 'radio'
|
46
46
|
},
|
47
47
|
show_frontend: true
|
@@ -54,7 +54,7 @@ module Admin::CustomFieldsHelper
|
|
54
54
|
required: true,
|
55
55
|
multiple: false,
|
56
56
|
multiple_options: {
|
57
|
-
label: t('admin.settings.options_select'),
|
57
|
+
label: t('camaleon_cms.admin.settings.options_select'),
|
58
58
|
default: 'radio',
|
59
59
|
use_not_default: true
|
60
60
|
},
|
@@ -72,6 +72,7 @@ module Admin::CustomFieldsHelper
|
|
72
72
|
show_frontend: true
|
73
73
|
}
|
74
74
|
}
|
75
|
+
|
75
76
|
items[:checkboxes] = {
|
76
77
|
key: 'checkboxes',
|
77
78
|
label: 'Checkboxes',
|
@@ -101,7 +102,7 @@ module Admin::CustomFieldsHelper
|
|
101
102
|
|
102
103
|
items[:colorpicker] = {
|
103
104
|
key: 'colorpicker',
|
104
|
-
label: t('admin.custom_field.fields.colorpicker'),
|
105
|
+
label: t('camaleon_cms.admin.custom_field.fields.colorpicker'),
|
105
106
|
extra_fields:[
|
106
107
|
{
|
107
108
|
type: 'select',
|
@@ -133,7 +134,7 @@ module Admin::CustomFieldsHelper
|
|
133
134
|
|
134
135
|
items[:date] = {
|
135
136
|
key: 'date',
|
136
|
-
label: t('admin.custom_field.fields.date'),
|
137
|
+
label: t('camaleon_cms.admin.custom_field.fields.date'),
|
137
138
|
extra_fields:[
|
138
139
|
{
|
139
140
|
type: 'radio',
|
@@ -141,11 +142,11 @@ module Admin::CustomFieldsHelper
|
|
141
142
|
values: [
|
142
143
|
{
|
143
144
|
value: '0',
|
144
|
-
label: t('admin.settings.input_only_date')
|
145
|
+
label: t('camaleon_cms.admin.settings.input_only_date')
|
145
146
|
},
|
146
147
|
{
|
147
148
|
value: '1',
|
148
|
-
label: t('admin.settings.input_date_time')
|
149
|
+
label: t('camaleon_cms.admin.settings.input_date_time')
|
149
150
|
}
|
150
151
|
]
|
151
152
|
}
|
@@ -172,7 +173,7 @@ module Admin::CustomFieldsHelper
|
|
172
173
|
|
173
174
|
items[:email] = {
|
174
175
|
key: 'email',
|
175
|
-
label: t('admin.custom_field.fields.email'),
|
176
|
+
label: t('camaleon_cms.admin.custom_field.fields.email'),
|
176
177
|
options: {
|
177
178
|
required: true,
|
178
179
|
multiple: true,
|
@@ -183,7 +184,7 @@ module Admin::CustomFieldsHelper
|
|
183
184
|
|
184
185
|
items[:file] = {
|
185
186
|
key: 'file',
|
186
|
-
label: t('admin.custom_field.fields.file'),
|
187
|
+
label: t('camaleon_cms.admin.custom_field.fields.file'),
|
187
188
|
options: {
|
188
189
|
required: true,
|
189
190
|
multiple: true,
|
@@ -201,7 +202,7 @@ module Admin::CustomFieldsHelper
|
|
201
202
|
|
202
203
|
items[:image] = {
|
203
204
|
key: 'image',
|
204
|
-
label: t('admin.custom_field.fields.image'),
|
205
|
+
label: t('camaleon_cms.admin.custom_field.fields.image'),
|
205
206
|
options: {
|
206
207
|
required: true,
|
207
208
|
multiple: true,
|
@@ -212,7 +213,7 @@ module Admin::CustomFieldsHelper
|
|
212
213
|
|
213
214
|
items[:numeric] = {
|
214
215
|
key: 'numeric',
|
215
|
-
label: t('admin.custom_field.fields.numeric'),
|
216
|
+
label: t('camaleon_cms.admin.custom_field.fields.numeric'),
|
216
217
|
options: {
|
217
218
|
required: true,
|
218
219
|
multiple: true,
|
@@ -223,7 +224,7 @@ module Admin::CustomFieldsHelper
|
|
223
224
|
|
224
225
|
items[:phone] = {
|
225
226
|
key: 'phone',
|
226
|
-
label: t('admin.custom_field.fields.phone'),
|
227
|
+
label: t('camaleon_cms.admin.custom_field.fields.phone'),
|
227
228
|
options: {
|
228
229
|
required: true,
|
229
230
|
multiple: true,
|
@@ -256,7 +257,7 @@ module Admin::CustomFieldsHelper
|
|
256
257
|
|
257
258
|
items[:users] = {
|
258
259
|
key: 'users',
|
259
|
-
label: t('admin.custom_field.fields.users'),
|
260
|
+
label: t('camaleon_cms.admin.custom_field.fields.users'),
|
260
261
|
options: {
|
261
262
|
required: true,
|
262
263
|
multiple: true,
|
@@ -266,7 +267,7 @@ module Admin::CustomFieldsHelper
|
|
266
267
|
|
267
268
|
items[:posts] = {
|
268
269
|
key: 'posts',
|
269
|
-
label: t('admin.custom_field.fields.posts'),
|
270
|
+
label: t('camaleon_cms.admin.custom_field.fields.posts'),
|
270
271
|
options: {
|
271
272
|
required: true,
|
272
273
|
multiple: true,
|
@@ -286,7 +287,7 @@ module Admin::CustomFieldsHelper
|
|
286
287
|
# sample: get_select_options({})
|
287
288
|
items[:select_eval] = {
|
288
289
|
key: 'select_eval',
|
289
|
-
label: t('admin.custom_field.fields.select_eval'),
|
290
|
+
label: t('camaleon_cms.admin.custom_field.fields.select_eval'),
|
290
291
|
options: {
|
291
292
|
required: true,
|
292
293
|
multiple: false,
|
@@ -304,7 +305,7 @@ module Admin::CustomFieldsHelper
|
|
304
305
|
|
305
306
|
items[:field_attrs] = {
|
306
307
|
key: 'field_attrs',
|
307
|
-
label: t('admin.custom_field.fields.field_attrs'),
|
308
|
+
label: t('camaleon_cms.admin.custom_field.fields.field_attrs'),
|
308
309
|
options: {
|
309
310
|
required: false,
|
310
311
|
multiple: true,
|
@@ -320,7 +321,7 @@ module Admin::CustomFieldsHelper
|
|
320
321
|
# add your model class into custom fields editor
|
321
322
|
# Note: to use custom fields on your model, you need the following:
|
322
323
|
# - add: belongs_to :site (in your model) //don't forget multi site support, i.e.: you need site_id attribute in your table
|
323
|
-
# - add: include CustomFieldsRead (in your model)
|
324
|
+
# - add: include CamaleonCms::CustomFieldsRead (in your model)
|
324
325
|
# ==> With this, you can manage your model like a plugin. Check api -> custom fields section into docs)
|
325
326
|
# model_class: class name (Product)
|
326
327
|
def cf_add_model(model_class)
|
@@ -6,59 +6,59 @@
|
|
6
6
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
7
7
|
See the GNU Affero General Public License (GPLv3) for more details.
|
8
8
|
=end
|
9
|
-
module Admin::MenusHelper
|
10
|
-
include Admin::BreadcrumbHelper
|
9
|
+
module CamaleonCms::Admin::MenusHelper
|
10
|
+
include CamaleonCms::Admin::BreadcrumbHelper
|
11
11
|
|
12
12
|
def admin_menus_add_commons
|
13
|
-
admin_menu_add_menu("dashboard", {icon: "dashboard", title: t('admin.sidebar.dashboard'), url:
|
13
|
+
admin_menu_add_menu("dashboard", {icon: "dashboard", title: t('camaleon_cms.admin.sidebar.dashboard'), url: cama_admin_dashboard_path})
|
14
14
|
#if can? :manager, :content
|
15
15
|
items = []
|
16
16
|
|
17
17
|
current_site.post_types.eager_load(:metas).visible_menu.all.each do |pt|
|
18
18
|
pt = pt.decorate
|
19
19
|
items_i = []
|
20
|
-
items_i << {icon: "list", title: "#{t('admin.post_type.all')}", url:
|
21
|
-
items_i << {icon: "plus", title: "#{t('admin.post_type.add_new')} ", url:
|
20
|
+
items_i << {icon: "list", title: "#{t('camaleon_cms.admin.post_type.all')}", url: cama_admin_post_type_posts_path(pt.id)} if can? :posts, pt
|
21
|
+
items_i << {icon: "plus", title: "#{t('camaleon_cms.admin.post_type.add_new')} ", url: new_cama_admin_post_type_post_path(pt.id)} if can? :create_post, pt
|
22
22
|
if pt.manage_categories?
|
23
|
-
items_i << {icon: "folder-open", title: t('admin.post_type.categories'), url:
|
23
|
+
items_i << {icon: "folder-open", title: t('camaleon_cms.admin.post_type.categories'), url: cama_admin_post_type_categories_path(pt.id)} if can? :categories, pt
|
24
24
|
end
|
25
25
|
if pt.manage_tags?
|
26
|
-
items_i << {icon: "tags", title: t('admin.post_type.tags'), url:
|
26
|
+
items_i << {icon: "tags", title: t('camaleon_cms.admin.post_type.tags'), url: cama_admin_post_type_post_tags_path(pt.id)} if can? :post_tags, pt
|
27
27
|
end
|
28
28
|
items << {icon: "copy", title: pt.the_title, url: "", items: items_i } if items_i.present? #if can? :posts, pt
|
29
29
|
end
|
30
|
-
admin_menu_add_menu("content", {icon: "database", title: t('admin.sidebar.
|
30
|
+
admin_menu_add_menu("content", {icon: "database", title: t('camaleon_cms.admin.sidebar.contents'), url: "", items: items, datas: "data-intro='#{t("camaleon_cms.admin.intro.content")}' data-position='right' data-wait='600'"}) if items.present?
|
31
31
|
#end
|
32
32
|
|
33
|
-
admin_menu_add_menu("media", {icon: "picture-o", title: t('admin.sidebar.media'), url:
|
34
|
-
admin_menu_add_menu("comments", {icon: "comments", title: t('admin.sidebar.comments'), url:
|
33
|
+
admin_menu_add_menu("media", {icon: "picture-o", title: t('camaleon_cms.admin.sidebar.media'), url: cama_admin_media_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.media")}' data-position='right'"}) if can? :manager, :media
|
34
|
+
admin_menu_add_menu("comments", {icon: "comments", title: t('camaleon_cms.admin.sidebar.comments'), url: cama_admin_comments_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.comments")}' data-position='right'"}) if can? :manager, :comments
|
35
35
|
|
36
36
|
items = []
|
37
|
-
items << {icon: "desktop", title: t('admin.sidebar.themes'), url:
|
38
|
-
items << {icon: "archive", title: t('admin.sidebar.widgets'), url:
|
39
|
-
items << {icon: "list", title: t('admin.sidebar.menus'), url:
|
40
|
-
admin_menu_add_menu("appearance", {icon: "paint-brush", title: t('admin.sidebar.appearance'), url: "", items: items, datas: "data-intro='#{t("admin.intro.appearance")}' data-position='right' data-wait='500'"}) if items.present?
|
37
|
+
items << {icon: "desktop", title: t('camaleon_cms.admin.sidebar.themes'), url: cama_admin_appearances_themes_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.themes")}' data-position='right'"} if can? :manager, :themes
|
38
|
+
items << {icon: "archive", title: t('camaleon_cms.admin.sidebar.widgets'), url: cama_admin_appearances_widgets_main_index_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.widgets")}' data-position='right'"} if can? :manager, :widgets
|
39
|
+
items << {icon: "list", title: t('camaleon_cms.admin.sidebar.menus'), url: cama_admin_appearances_nav_menus_menu_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.menus", image: view_context.asset_path("camaleon_cms/admin/intro/menus.png"))}' data-position='right'"} if can? :manager, :nav_menu
|
40
|
+
admin_menu_add_menu("appearance", {icon: "paint-brush", title: t('camaleon_cms.admin.sidebar.appearance'), url: "", items: items, datas: "data-intro='#{t("camaleon_cms.admin.intro.appearance")}' data-position='right' data-wait='500'"}) if items.present?
|
41
41
|
|
42
42
|
|
43
|
-
admin_menu_add_menu("plugins", {icon: "plug", title: "#{t('admin.sidebar.plugins')} <small class='label label-primary'>#{PluginRoutes.all_plugins.size}</small>", url:
|
43
|
+
admin_menu_add_menu("plugins", {icon: "plug", title: "#{t('camaleon_cms.admin.sidebar.plugins')} <small class='label label-primary'>#{PluginRoutes.all_plugins.size}</small>", url: cama_admin_plugins_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.plugins")}' data-position='right'"}) if can? :manager, :plugins
|
44
44
|
|
45
45
|
if can? :manager, :users
|
46
46
|
items = []
|
47
|
-
items << {icon: "list", title: t('admin.users.all_users'), url:
|
48
|
-
items << {icon: "plus", title: t('admin.users.add_user'), url:
|
49
|
-
items << {icon: "group", title: t('admin.users.user_roles'), url:
|
50
|
-
admin_menu_add_menu("users", {icon: "users", title: t('admin.sidebar.users'), url: "", items: items, datas: "data-intro='#{t("admin.intro.users")}' data-position='right' data-wait='500'"})
|
47
|
+
items << {icon: "list", title: t('camaleon_cms.admin.users.all_users'), url: cama_admin_users_path}
|
48
|
+
items << {icon: "plus", title: t('camaleon_cms.admin.users.add_user'), url: new_cama_admin_user_path}
|
49
|
+
items << {icon: "group", title: t('camaleon_cms.admin.users.user_roles'), url: cama_admin_user_roles_path}
|
50
|
+
admin_menu_add_menu("users", {icon: "users", title: t('camaleon_cms.admin.sidebar.users'), url: "", items: items, datas: "data-intro='#{t("camaleon_cms.admin.intro.users")}' data-position='right' data-wait='500'"})
|
51
51
|
end
|
52
52
|
|
53
53
|
if can? :manager, :settings
|
54
54
|
items = []
|
55
|
-
items << {icon: "desktop", title: t('admin.sidebar.general_site'), url:
|
56
|
-
items << {icon: "cog", title: t('admin.sidebar.sites'), url:
|
57
|
-
items << {icon: "files-o", title: t('admin.sidebar.content_groups'), url:
|
58
|
-
items << {icon: "cog", title: t('admin.sidebar.custom_fields'), url:
|
59
|
-
items << {icon: "language", title: t('admin.sidebar.languages'), url:
|
60
|
-
items << {icon: "code", title: t('admin.
|
61
|
-
admin_menu_add_menu("settings", {icon: "cogs", title: t('admin.sidebar.settings'), url: "", items: items, datas: "data-intro='#{t("admin.intro.settings")}' data-position='right' data-wait='500'"})
|
55
|
+
items << {icon: "desktop", title: t('camaleon_cms.admin.sidebar.general_site'), url: cama_admin_settings_site_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.gral_site")}' data-position='right'"}
|
56
|
+
items << {icon: "cog", title: t('camaleon_cms.admin.sidebar.sites'), url: cama_admin_settings_sites_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.sites")}' data-position='right'"} if current_site.manage_sites?
|
57
|
+
items << {icon: "files-o", title: t('camaleon_cms.admin.sidebar.content_groups'), url: cama_admin_settings_post_types_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.post_type")}' data-position='right'"}
|
58
|
+
items << {icon: "cog", title: t('camaleon_cms.admin.sidebar.custom_fields'), url: cama_admin_settings_custom_fields_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.custom_fields")}' data-position='right'"}
|
59
|
+
items << {icon: "language", title: t('camaleon_cms.admin.sidebar.languages'), url: cama_admin_settings_languages_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.languages")}' data-position='right'"}
|
60
|
+
items << {icon: "code", title: t('camaleon_cms.admin.sidebar.shortcodes', default: "Shortcodes"), url: cama_admin_settings_shortcodes_path, datas: "data-intro='#{t("camaleon_cms.admin.intro.shortcodes")}' data-position='right'"}
|
61
|
+
admin_menu_add_menu("settings", {icon: "cogs", title: t('camaleon_cms.admin.sidebar.settings'), url: "", items: items, datas: "data-intro='#{t("camaleon_cms.admin.intro.settings")}' data-position='right' data-wait='500'"})
|
62
62
|
end
|
63
63
|
|
64
64
|
end
|
@@ -126,12 +126,10 @@ module Admin::MenusHelper
|
|
126
126
|
#{_admin_menu_draw(menu[:items]) if menu.has_key?(:items)}
|
127
127
|
</li>"
|
128
128
|
end
|
129
|
-
_admin_menu_draw_active
|
130
129
|
res.join
|
131
130
|
end
|
132
131
|
|
133
132
|
private
|
134
|
-
|
135
133
|
def _get_url_current
|
136
134
|
menus = @_admin_menus.map{|key, menu| menu[:key] = key; menu}
|
137
135
|
current_path = URI(site_current_url).path
|
@@ -188,12 +186,4 @@ module Admin::MenusHelper
|
|
188
186
|
res.join
|
189
187
|
end
|
190
188
|
|
191
|
-
def _admin_menu_draw_active
|
192
|
-
bread = []
|
193
|
-
@_tmp_menu_parents.uniq.each do |item|
|
194
|
-
bread << [item[:title].to_s.strip_tags, item[:url]] if item.present? && item[:key] != "dashboard"
|
195
|
-
end
|
196
|
-
@_admin_breadcrumb = [[t('admin.sidebar.dashboard'), admin_dashboard_path]] + bread + @_admin_breadcrumb
|
197
|
-
end
|
198
|
-
|
199
189
|
end
|