locomotive_cms 0.0.4 → 1.0.0.beta
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +15 -13
- data/README.textile +5 -4
- data/app/controllers/admin/api_contents_controller.rb +10 -1
- data/app/controllers/admin/base_controller.rb +2 -2
- data/app/controllers/admin/cross_domain_sessions_controller.rb +7 -4
- data/app/controllers/admin/current_sites_controller.rb +2 -0
- data/app/controllers/admin/imports_controller.rb +13 -19
- data/app/controllers/admin/installation_controller.rb +79 -0
- data/app/controllers/admin/pages_controller.rb +1 -1
- data/app/controllers/admin/passwords_controller.rb +2 -2
- data/app/controllers/admin/sessions_controller.rb +2 -2
- data/app/controllers/admin/sites_controller.rb +2 -0
- data/app/controllers/admin/theme_assets_controller.rb +1 -1
- data/app/controllers/application_controller.rb +1 -1
- data/app/helpers/admin/assets_helper.rb +0 -6
- data/app/helpers/admin/{login_helper.rb → box_helper.rb} +7 -3
- data/app/helpers/admin/custom_fields_helper.rb +2 -2
- data/app/models/asset_collection.rb +15 -3
- data/app/models/content_instance.rb +19 -0
- data/app/models/content_type.rb +21 -3
- data/app/models/extensions/page/tree.rb +63 -7
- data/app/models/page.rb +2 -0
- data/app/models/site.rb +15 -3
- data/app/uploaders/asset_uploader.rb +1 -1
- data/app/uploaders/theme_asset_uploader.rb +12 -1
- data/app/uploaders/theme_uploader.rb +19 -0
- data/app/views/admin/asset_collections/edit.html.haml +2 -2
- data/app/views/admin/asset_collections/new.html.haml +1 -1
- data/app/views/admin/assets/_form.html.haml +2 -2
- data/app/views/admin/content_types/_form.html.haml +2 -2
- data/app/views/admin/content_types/new.html.haml +1 -1
- data/app/views/admin/contents/_form.html.haml +2 -2
- data/app/views/admin/contents/index.html.haml +1 -1
- data/app/views/admin/cross_domain_sessions/new.html.haml +1 -1
- data/app/views/admin/current_sites/_form.html.haml +3 -3
- data/app/views/admin/current_sites/edit.html.haml +1 -1
- data/app/views/admin/errors/no_page.html.haml +1 -0
- data/app/views/admin/errors/no_site.html.haml +1 -0
- data/app/views/admin/imports/new.html.haml +11 -0
- data/app/views/admin/imports/show.html.haml +1 -1
- data/app/views/admin/installation/step_1.html.haml +24 -0
- data/app/views/admin/installation/step_2.html.haml +26 -0
- data/app/views/admin/installation/step_3.html.haml +23 -0
- data/app/views/{layouts/admin → admin/layouts}/application.html.haml +0 -0
- data/app/views/admin/layouts/box.html.haml +21 -0
- data/app/views/admin/layouts/error.html.haml +1 -0
- data/app/views/admin/my_accounts/edit.html.haml +1 -1
- data/app/views/admin/pages/_form.html.haml +2 -3
- data/app/views/admin/pages/_page.html.haml +4 -2
- data/app/views/admin/pages/index.html.haml +1 -1
- data/app/views/admin/passwords/edit.html.haml +2 -2
- data/app/views/admin/passwords/new.html.haml +2 -2
- data/app/views/admin/sessions/new.html.haml +2 -2
- data/app/views/admin/shared/_head.html.haml +4 -5
- data/app/views/admin/shared/menu/_contents.html.haml +1 -1
- data/app/views/admin/sites/_form.html.haml +3 -3
- data/app/views/admin/snippets/_form.html.haml +2 -2
- data/app/views/admin/theme_assets/_form.html.haml +2 -2
- data/app/views/admin/theme_assets/index.html.haml +1 -1
- data/config/application.rb +1 -3
- data/config/assets.yml +96 -0
- data/config/environments/development.rb +1 -6
- data/config/environments/production.rb +1 -1
- data/config/environments/test.rb +1 -5
- data/config/initializers/carrierwave.rb +17 -0
- data/config/initializers/locomotive.rb +14 -0
- data/config/locales/admin_ui_en.yml +33 -1
- data/config/locales/admin_ui_fr.yml +34 -1
- data/config/locales/default_en.yml +1 -0
- data/config/locales/default_fr.yml +1 -0
- data/config/locales/flash.en.yml +1 -0
- data/config/locales/flash.fr.yml +1 -0
- data/config/mongoid.yml +13 -5
- data/config/routes.rb +6 -1
- data/lib/generators/locomotive/install/install_generator.rb +18 -10
- data/lib/generators/locomotive/install/templates/README +23 -13
- data/lib/generators/locomotive/install/templates/locomotive.rb +15 -1
- data/lib/locomotive/carrierwave.rb +1 -0
- data/lib/locomotive/configuration.rb +3 -1
- data/lib/locomotive/custom_fields.rb +0 -1
- data/lib/locomotive/delayed_job.rb +1 -2
- data/lib/locomotive/engine.rb +24 -7
- data/lib/locomotive/heroku.rb +1 -0
- data/lib/locomotive/httparty/webservice.rb +12 -1
- data/lib/locomotive/import.rb +2 -0
- data/lib/locomotive/import/asset_collections.rb +40 -8
- data/lib/locomotive/import/assets.rb +20 -12
- data/lib/locomotive/import/base.rb +46 -0
- data/lib/locomotive/import/content_types.rb +51 -15
- data/lib/locomotive/import/job.rb +106 -11
- data/lib/locomotive/import/logger.rb +13 -0
- data/lib/locomotive/import/pages.rb +79 -26
- data/lib/locomotive/import/site.rb +3 -5
- data/lib/locomotive/import/snippets.rb +6 -8
- data/lib/locomotive/inherited_resources.rb +1 -0
- data/lib/locomotive/liquid/drops/asset_collections.rb +4 -4
- data/lib/locomotive/liquid/drops/contents.rb +21 -16
- data/lib/locomotive/liquid/drops/page.rb +4 -0
- data/lib/locomotive/liquid/filters/html.rb +15 -29
- data/lib/locomotive/liquid/tags/consume.rb +1 -1
- data/lib/locomotive/liquid/tags/nav.rb +48 -17
- data/lib/locomotive/liquid/tags/paginate.rb +3 -3
- data/lib/locomotive/middlewares/fonts.rb +3 -11
- data/lib/locomotive/misc_form_builder.rb +2 -7
- data/lib/locomotive/railties/tasks.rake +16 -0
- data/lib/locomotive/regexps.rb +1 -1
- data/lib/locomotive/render.rb +9 -3
- data/lib/locomotive/routing/site_dispatcher.rb +10 -6
- data/lib/locomotive/version.rb +1 -1
- data/public/images/admin/box/buttons/right_bg.png +0 -0
- data/public/javascripts/admin/aloha/VERSION.txt +1 -1
- data/public/javascripts/admin/aloha/aloha-nodeps.js +140 -101
- data/public/javascripts/admin/aloha/aloha.js +193 -105
- data/public/javascripts/admin/aloha/css/aloha.css +65 -4
- data/public/javascripts/admin/aloha/deps/prettyPhoto/resources/css/prettyPhoto.css +2 -2
- data/public/javascripts/admin/aloha/i18n/de.dict +2 -0
- data/public/javascripts/admin/aloha/i18n/en.dict +2 -0
- data/public/javascripts/admin/aloha/i18n/pl.dict +5 -0
- data/public/javascripts/admin/aloha/images/base.png +0 -0
- data/public/javascripts/admin/aloha/images/base_big.png +0 -0
- data/public/javascripts/admin/aloha/images/base_multi.png +0 -0
- data/public/javascripts/admin/aloha/images/fade_in.png +0 -0
- data/public/javascripts/admin/aloha/images/fade_out.png +0 -0
- data/public/javascripts/admin/aloha/images/gentics_logo.png +0 -0
- data/public/javascripts/admin/aloha/images/grabhandle.png +0 -0
- data/public/javascripts/admin/aloha/images/maximize.png +0 -0
- data/public/javascripts/admin/aloha/images/pin.png +0 -0
- data/public/javascripts/admin/aloha/images/removeformat.png +0 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/examples/triSports.css +86 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/examples/triSports.html +44 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/i18n/de.dict +4 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/i18n/en.dict +4 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/i18n/fr.dict +4 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/plugin.js +1 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/product.js +1 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/2xu-wetsuit.jpg +0 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/asics-noosa.jpg +0 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/fivefingers-kso.jpg +0 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/kuota-kueen-k.jpg +0 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/mizuno-wave-musha2.jpg +0 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/product.css +69 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/product_button.gif +0 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/simplon-mrt.jpg +0 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/trek-fuel-ex.jpg +0 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/trisports.jpg +0 -0
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.plugins.Product/resources/zoggs-predator.jpg +0 -0
- data/public/javascripts/admin/aloha/plugins/{com.example.aloha.DummySave → com.example.aloha.plugins.Save}/i18n/de.dict +0 -0
- data/public/javascripts/admin/aloha/plugins/{com.example.aloha.DummySave → com.example.aloha.plugins.Save}/i18n/en.dict +0 -0
- data/public/javascripts/admin/aloha/plugins/{com.example.aloha.DummySave → com.example.aloha.plugins.Save}/i18n/fi.dict +0 -0
- data/public/javascripts/admin/aloha/plugins/{com.example.aloha.DummySave → com.example.aloha.plugins.Save}/i18n/fr.dict +0 -0
- data/public/javascripts/admin/aloha/plugins/{com.example.aloha.DummySave → com.example.aloha.plugins.Save}/i18n/it.dict +0 -0
- data/public/javascripts/admin/aloha/plugins/{com.example.aloha.DummySave → com.example.aloha.plugins.Save}/plugin.js +0 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Abbr/examples/AlohaAbbr.css +48 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Abbr/examples/AlohaAbbr.html +69 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Abbr/i18n/de.dict +4 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Abbr/i18n/en.dict +4 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Abbr/plugin.js +7 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Format/i18n/pl.dict +30 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Format/plugin.js +1 -1
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.HighlightEditables/plugin.js +1 -1
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Link/LinkList.js +7 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Link/delicious.js +7 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Link/i18n/pl.dict +4 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Link/plugin.js +1 -1
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.LinkChecker/css/LinkChecker.css +14 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.LinkChecker/examples/AlohaLinkChecker.css +49 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.LinkChecker/examples/AlohaLinkChecker.html +82 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.LinkChecker/i18n/en.dict +27 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.LinkChecker/plugin.js +7 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.LinkChecker/proxy.php +235 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.List/plugin.js +1 -1
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Paste/plugin.js +7 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Paste/wordpastehandler.js +7 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.TOC/i18n/de.dict +1 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.TOC/i18n/en.dict +1 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.TOC/plugin.js +1 -1
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Table/i18n/de.dict +2 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Table/i18n/en.dict +2 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Table/i18n/pl.dict +12 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Table/plugin.js +1 -1
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Table/resources/table.css +28 -110
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Table/resources/wai_green.png +0 -0
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Table/resources/wai_red.png +0 -0
- data/public/javascripts/admin/asset_collections.js +11 -7
- data/public/javascripts/admin/contents.js +3 -1
- data/public/javascripts/admin/site.js +9 -3
- data/public/javascripts/admin/snippets.js +1 -1
- data/public/javascripts/admin/utils.js +5 -3
- data/public/stylesheets/admin/application.css +1 -1
- data/public/stylesheets/admin/box.css +5 -5
- data/public/stylesheets/admin/buttons.css +0 -5
- data/public/stylesheets/admin/formtastic_changes.css +5 -12
- data/public/stylesheets/admin/inline_editor.css +22 -5
- data/public/stylesheets/admin/installation.css +50 -0
- data/public/stylesheets/admin/layout.css +9 -4
- data/public/stylesheets/admin/safari.css +15 -0
- metadata +188 -131
- data/app/controllers/home_controller.rb +0 -7
- data/app/views/admin/snippets/index.html.haml +0 -15
- data/app/views/home/show.html.haml +0 -4
- data/app/views/layouts/admin/box.html.haml +0 -19
- data/app/views/layouts/application.html.haml +0 -7
- data/lib/generators/locomotive/copy_assets/copy_assets_generator.rb +0 -14
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.DummyDC/i18n/de.dict +0 -2
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.DummyDC/i18n/en.dict +0 -2
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.DummyDC/i18n/eo.dict +0 -2
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.DummyDC/i18n/fi.dict +0 -2
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.DummyDC/i18n/fr.dict +0 -2
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.DummyDC/i18n/it.dict +0 -2
- data/public/javascripts/admin/aloha/plugins/com.example.aloha.DummyDC/plugin.js +0 -7
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.GCN/i18n/de.dict +0 -20
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.GCN/i18n/en.dict +0 -20
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.GCN/i18n/eo.dict +0 -16
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.GCN/i18n/fi.dict +0 -20
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.GCN/i18n/fr.dict +0 -16
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.GCN/i18n/it.dict +0 -20
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.GCN/plugin.js +0 -7
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Link/css/jquery.autocomplete.css +0 -48
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Link/deps/jquery.autocomplete.js +0 -1
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Link/ressource.js +0 -7
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Link/ressourcedummy.js +0 -7
- data/public/javascripts/admin/aloha/plugins/com.gentics.aloha.plugins.Link/ressourceregistry.js +0 -7
- data/public/javascripts/admin/aloha/plugins/eu.iksproject.plugins.Loader/plugin.js +0 -1
- data/public/javascripts/admin/aloha/plugins/eu.iksproject.plugins.Person/i18n/en.dict +0 -2
- data/public/javascripts/admin/aloha/plugins/eu.iksproject.plugins.Person/i18n/fi.dict +0 -2
- data/public/javascripts/admin/aloha/plugins/eu.iksproject.plugins.Person/i18n/fr.dict +0 -2
- data/public/javascripts/admin/aloha/plugins/eu.iksproject.plugins.Person/person.css +0 -3
- data/public/javascripts/admin/aloha/plugins/eu.iksproject.plugins.Person/plugin.js +0 -1
- data/public/javascripts/admin/aloha/plugins/simpletable/plugin.js.deactivated +0 -2330
@@ -0,0 +1,26 @@
|
|
1
|
+
- content_for :head_title do
|
2
|
+
= t('admin.installation.common.title')
|
3
|
+
|
4
|
+
- title t('.title')
|
5
|
+
|
6
|
+
- content_for :head do
|
7
|
+
= include_stylesheets :installation
|
8
|
+
|
9
|
+
- if @step_done.blank?
|
10
|
+
= semantic_form_for(@account, :url => admin_installation_step_url(2)) do |f|
|
11
|
+
.inner
|
12
|
+
= f.inputs do
|
13
|
+
= f.input :name, :label => t('.name'), :required => false
|
14
|
+
= f.input :email, :label => t('.email'), :required => false
|
15
|
+
= f.input :password, :label => t('.password'), :required => false
|
16
|
+
= f.input :password_confirmation, :label => t('.password_confirmation'), :required => false
|
17
|
+
|
18
|
+
.footer
|
19
|
+
= box_button_tag t('.next')
|
20
|
+
- else
|
21
|
+
.inner
|
22
|
+
%p.done
|
23
|
+
!= @step_done
|
24
|
+
|
25
|
+
.footer
|
26
|
+
= next_installation_step_link(3)
|
@@ -0,0 +1,23 @@
|
|
1
|
+
- content_for :head_title do
|
2
|
+
= t('admin.installation.common.title')
|
3
|
+
|
4
|
+
- title t('.title')
|
5
|
+
|
6
|
+
- content_for :head do
|
7
|
+
= include_stylesheets :installation
|
8
|
+
|
9
|
+
= semantic_form_for(@site, :url => admin_installation_step_url(3), :html => { :multipart => true }) do |f|
|
10
|
+
.inner
|
11
|
+
%p.explanations
|
12
|
+
!= t('.explanations')
|
13
|
+
|
14
|
+
= f.inputs do
|
15
|
+
= f.input :name, :required => false
|
16
|
+
= f.input :subdomain, :required => false
|
17
|
+
|
18
|
+
%li{ :class => 'string optional', :id => 'zipfile_input' }
|
19
|
+
%label{ :for => 'zipfile' }= t('formtastic.labels.import.new.source')
|
20
|
+
= file_field_tag 'zipfile'
|
21
|
+
|
22
|
+
.footer
|
23
|
+
= box_button_tag t('.next')
|
File without changes
|
@@ -0,0 +1,21 @@
|
|
1
|
+
!!! XML
|
2
|
+
!!!
|
3
|
+
%html{ :xmlns => 'http://www.w3.org/1999/xhtml' }
|
4
|
+
%head
|
5
|
+
%title= yield(:head_title) || escape_once("#{Locomotive.config.name} — #{current_site.name}")
|
6
|
+
|
7
|
+
= include_javascripts :box
|
8
|
+
= include_stylesheets :box, :media => 'screen'
|
9
|
+
|
10
|
+
/ [if IE]
|
11
|
+
= include_stylesheets :ie, :media => 'screen'
|
12
|
+
|
13
|
+
= yield :head
|
14
|
+
|
15
|
+
%body{ :class => controller.controller_name }
|
16
|
+
#wrapper
|
17
|
+
#light.container
|
18
|
+
#panel.container
|
19
|
+
%h1!= title
|
20
|
+
|
21
|
+
= yield
|
@@ -0,0 +1 @@
|
|
1
|
+
= yield
|
@@ -1,7 +1,7 @@
|
|
1
1
|
- title link_to(@account.name.blank? ? @account.name_was : @account.name, '#', :rel => 'my_account_name', :title => t('.ask_for_name'), :class => 'editable')
|
2
2
|
|
3
3
|
- content_for :head do
|
4
|
-
=
|
4
|
+
= include_javascripts :account
|
5
5
|
|
6
6
|
- content_for :submenu do
|
7
7
|
= render 'admin/shared/menu/settings'
|
@@ -1,7 +1,6 @@
|
|
1
1
|
- content_for :head do
|
2
|
-
=
|
3
|
-
=
|
4
|
-
= image_picker_include_tags
|
2
|
+
= include_javascripts :image_picker, :edit_page
|
3
|
+
= include_stylesheets :editable_elements, :fancybox
|
5
4
|
|
6
5
|
= f.foldable_inputs :name => :information do
|
7
6
|
|
@@ -1,5 +1,7 @@
|
|
1
1
|
%li{ :id => "item-#{page.id}", :class => "#{'not-found' if page.not_found? } #{'templatized' if page.templatized?}"}
|
2
|
-
-
|
2
|
+
- with_children = !page.children.empty?
|
3
|
+
|
4
|
+
- if not page.index? and with_children
|
3
5
|
= image_tag 'admin/list/icons/node_closed.png', :class => 'toggler'
|
4
6
|
%em
|
5
7
|
%strong= link_to truncate(page.title, :length => 80), edit_admin_page_url(page)
|
@@ -11,6 +13,6 @@
|
|
11
13
|
- if not page.index? and not page.not_found?
|
12
14
|
= link_to image_tag('admin/list/icons/trash.png'), admin_page_url(page), :class => 'remove', :confirm => t('admin.messages.confirm'), :method => :delete
|
13
15
|
|
14
|
-
- if
|
16
|
+
- if with_children
|
15
17
|
%ul{ :id => "folder-#{page._id}", :class => "folder depth-#{(page.depth || 0) + 1}", :data_url => sort_admin_page_url(page), :style => "display: #{cookies["folder-#{page._id}"] || 'block'}" }
|
16
18
|
= render page.children
|
@@ -5,7 +5,7 @@
|
|
5
5
|
= f.hidden_field :reset_password_token
|
6
6
|
|
7
7
|
.inner
|
8
|
-
=
|
8
|
+
= box_flash_message
|
9
9
|
|
10
10
|
= f.inputs do
|
11
11
|
= f.input :password, :label => t('.password'), :required => false
|
@@ -15,4 +15,4 @@
|
|
15
15
|
= link_to preserve(t('.link')), new_admin_session_path
|
16
16
|
|
17
17
|
.footer
|
18
|
-
=
|
18
|
+
= box_button_tag t('admin.buttons.change_password')
|
@@ -5,7 +5,7 @@
|
|
5
5
|
= f.hidden_field :reset_password_token
|
6
6
|
|
7
7
|
.inner
|
8
|
-
=
|
8
|
+
= box_flash_message
|
9
9
|
|
10
10
|
= f.inputs do
|
11
11
|
= f.input :email, :label => t('.email'), :required => false
|
@@ -14,4 +14,4 @@
|
|
14
14
|
= link_to preserve(t('.link')), new_admin_session_path
|
15
15
|
|
16
16
|
.footer
|
17
|
-
=
|
17
|
+
= box_button_tag t('admin.buttons.send_password')
|
@@ -4,7 +4,7 @@
|
|
4
4
|
= f.hidden_field :remember_me, :value => 'true'
|
5
5
|
|
6
6
|
.inner
|
7
|
-
=
|
7
|
+
= box_flash_message
|
8
8
|
|
9
9
|
= f.inputs do
|
10
10
|
= f.input :email, :label => t('.email'), :required => false
|
@@ -14,4 +14,4 @@
|
|
14
14
|
= link_to t('.link'), new_admin_password_path
|
15
15
|
|
16
16
|
.footer
|
17
|
-
=
|
17
|
+
= box_button_tag t('admin.buttons.login')
|
@@ -4,13 +4,12 @@
|
|
4
4
|
|
5
5
|
%meta{ :name => 'locale', :content => I18n.locale }
|
6
6
|
|
7
|
-
=
|
8
|
-
/ [if IE]
|
9
|
-
= stylesheet_link_tag 'admin/blueprint/ie', :media => 'screen'
|
7
|
+
= include_javascripts :common
|
10
8
|
|
11
|
-
=
|
9
|
+
= include_stylesheets :common, :media => 'screen'
|
12
10
|
|
13
|
-
|
11
|
+
/ [if IE]
|
12
|
+
= include_stylesheets :ie, :media => 'screen'
|
14
13
|
|
15
14
|
%script{ :type => 'text/javascript' }
|
16
15
|
= find_and_preserve(growl_message)
|
@@ -5,7 +5,7 @@
|
|
5
5
|
.inner
|
6
6
|
%h2!= t('admin.pages.index.lastest_items')
|
7
7
|
%ul
|
8
|
-
- current_site.pages.latest_updated.each do |page|
|
8
|
+
- current_site.pages.latest_updated.minimal_attributes.each do |page|
|
9
9
|
%li
|
10
10
|
= link_to truncate(page.title, :length => 25), edit_admin_page_url(page)
|
11
11
|
%span= time_ago_in_words(page.updated_at)
|
@@ -1,5 +1,5 @@
|
|
1
1
|
- content_for :head do
|
2
|
-
=
|
2
|
+
= include_javascripts :site
|
3
3
|
|
4
4
|
= f.foldable_inputs :name => :information, :style => "#{'display: none' unless @site.new_record?}" do
|
5
5
|
= f.input :name, :required => false
|
@@ -18,7 +18,7 @@
|
|
18
18
|
%li{ :class => "item added #{'last' if index == @site.domains.size - 1}"}
|
19
19
|
%em
|
20
20
|
http://
|
21
|
-
= text_field_tag 'site[domains][]', name
|
21
|
+
= text_field_tag 'site[domains][]', name, :class => 'string label void domain'
|
22
22
|
|
23
23
|
= error_on_domain(@site, name)
|
24
24
|
%span.actions
|
@@ -27,7 +27,7 @@
|
|
27
27
|
%li.item.template
|
28
28
|
%em
|
29
29
|
http://
|
30
|
-
= text_field_tag 'label', t('formtastic.hints.site.domain_name'), :class => 'string label void'
|
30
|
+
= text_field_tag 'label', t('formtastic.hints.site.domain_name'), :class => 'string label void domain'
|
31
31
|
|
32
32
|
%span.actions
|
33
33
|
= link_to image_tag('admin/form/icons/trash.png'), '#', :class => 'remove first', :confirm => t('admin.messages.confirm')
|
@@ -1,6 +1,6 @@
|
|
1
1
|
- content_for :head do
|
2
|
-
=
|
3
|
-
=
|
2
|
+
= include_javascripts :image_picker, :snippets
|
3
|
+
= include_stylesheets :fancybox
|
4
4
|
|
5
5
|
= f.inputs :name => :information do
|
6
6
|
= f.input :name
|
@@ -1,6 +1,6 @@
|
|
1
1
|
- content_for :head do
|
2
|
-
=
|
3
|
-
=
|
2
|
+
= include_javascripts :image_picker, :theme_assets
|
3
|
+
= include_stylesheets :fancybox
|
4
4
|
|
5
5
|
= f.hidden_field :performing_plain_text
|
6
6
|
|
data/config/application.rb
CHANGED
@@ -1,7 +1,5 @@
|
|
1
1
|
require File.expand_path('../boot', __FILE__)
|
2
2
|
|
3
|
-
# require 'rails/all'
|
4
|
-
|
5
3
|
require "action_controller/railtie"
|
6
4
|
require "action_mailer/railtie"
|
7
5
|
require "active_resource/railtie"
|
@@ -47,6 +45,6 @@ module Locomotive
|
|
47
45
|
# Configure sensitive parameters which will be filtered from the log file.
|
48
46
|
config.filter_parameters << :password
|
49
47
|
|
50
|
-
config.middleware.insert_after ::
|
48
|
+
config.middleware.insert_after Rack::Lock, '::Locomotive::Middlewares::Fonts', :path => %r{^/fonts}
|
51
49
|
end
|
52
50
|
end
|
data/config/assets.yml
ADDED
@@ -0,0 +1,96 @@
|
|
1
|
+
embed_assets: off
|
2
|
+
|
3
|
+
s3_bucket: <%= ENV['S3_BUCKET'] %>
|
4
|
+
s3_access_key_id: <%= ENV['S3_KEY_ID'] %>
|
5
|
+
s3_secret_access_key: <%= ENV['S3_SECRET_KEY'] %>
|
6
|
+
|
7
|
+
javascripts:
|
8
|
+
box:
|
9
|
+
- public/javascripts/admin/jquery.js
|
10
|
+
common:
|
11
|
+
- public/javascripts/admin/jquery.js
|
12
|
+
- public/javascripts/admin/jquery.ui.js
|
13
|
+
- public/javascripts/admin/rails.js
|
14
|
+
- public/javascripts/admin/utils.js
|
15
|
+
- public/javascripts/admin/plugins/subscribe.js
|
16
|
+
- public/javascripts/admin/plugins/shortcut.js
|
17
|
+
- public/javascripts/admin/plugins/toggle.js
|
18
|
+
- public/javascripts/admin/plugins/growl.js
|
19
|
+
- public/javascripts/admin/plugins/cookie.js
|
20
|
+
- public/javascripts/admin/plugins/selectmenu.js
|
21
|
+
- public/javascripts/admin/locales/datepicker_fr.js
|
22
|
+
- public/javascripts/admin/application.js
|
23
|
+
custom_fields:
|
24
|
+
- public/javascripts/admin/plugins/fancybox.js
|
25
|
+
- public/javascripts/admin/custom_fields.js
|
26
|
+
edit_custom_fields:
|
27
|
+
- public/javascripts/admin/plugins/tiny_mce/tinymce.js
|
28
|
+
- public/javascripts/admin/plugins/json2.js
|
29
|
+
- public/javascripts/admin/plugins/fancybox.js
|
30
|
+
- public/javascripts/admin/custom_fields/category.js
|
31
|
+
asset_collections:
|
32
|
+
- public/javascripts/admin/plugins/fancybox.js
|
33
|
+
- public/javascripts/admin/custom_fields.js
|
34
|
+
- public/javascripts/admin/asset_collections.js
|
35
|
+
assets:
|
36
|
+
- public/javascripts/admin/assets.js
|
37
|
+
contents:
|
38
|
+
- public/javascripts/admin/plugins/tiny_mce/tinymce.js
|
39
|
+
- public/javascripts/admin/contents.js
|
40
|
+
content_types:
|
41
|
+
- public/javascripts/admin/content_types.js
|
42
|
+
site:
|
43
|
+
- public/javascripts/admin/site.js
|
44
|
+
import:
|
45
|
+
- public/javascripts/admin/plugins/json2.js
|
46
|
+
- public/javascripts/admin/plugins/smartupdater.js
|
47
|
+
- public/javascripts/admin/import.js
|
48
|
+
account:
|
49
|
+
- public/javascripts/admin/account.js
|
50
|
+
pages:
|
51
|
+
- public/javascripts/admin/pages.js
|
52
|
+
edit_page:
|
53
|
+
- public/javascripts/admin/plugins/tiny_mce/tinymce.js
|
54
|
+
- public/javascripts/admin/editable_elements.js
|
55
|
+
- public/javascripts/admin/pages.js
|
56
|
+
image_picker:
|
57
|
+
- public/javascripts/admin/plugins/json2.js
|
58
|
+
- public/javascripts/admin/plugins/scrollTo.js
|
59
|
+
- public/javascripts/admin/plugins/codemirror/codemirror.js
|
60
|
+
- public/javascripts/admin/plugins/fancybox.js
|
61
|
+
- public/javascripts/admin/plugins/plupload/plupload.full.js
|
62
|
+
- public/javascripts/admin/plugins/imagepicker.js
|
63
|
+
snippets:
|
64
|
+
- public/javascripts/admin/snippets.js
|
65
|
+
theme_assets:
|
66
|
+
- public/javascripts/admin/theme_assets.js
|
67
|
+
|
68
|
+
stylesheets:
|
69
|
+
ie:
|
70
|
+
- public/stylesheets/admin/blueprint/ie.css
|
71
|
+
box:
|
72
|
+
- public/stylesheets/admin/blueprint/screen.css
|
73
|
+
- public/stylesheets/admin/box.css
|
74
|
+
- public/stylesheets/admin/safari.css
|
75
|
+
common:
|
76
|
+
- public/stylesheets/admin/blueprint/screen.css
|
77
|
+
- public/stylesheets/admin/layout.css
|
78
|
+
- public/stylesheets/admin/jquery/ui.css
|
79
|
+
- public/stylesheets/admin/plugins/toggle.css
|
80
|
+
- public/stylesheets/admin/plugins/selectmenu.css
|
81
|
+
- public/stylesheets/admin/menu.css
|
82
|
+
- public/stylesheets/admin/buttons.css
|
83
|
+
- public/stylesheets/admin/formtastic.css
|
84
|
+
- public/stylesheets/admin/formtastic_changes.css
|
85
|
+
- public/stylesheets/admin/application.css
|
86
|
+
- public/stylesheets/admin/safari.css
|
87
|
+
fancybox:
|
88
|
+
- public/stylesheets/admin/plugins/fancybox.css
|
89
|
+
- public/stylesheets/admin/fancybox_changes.css
|
90
|
+
custom_fields:
|
91
|
+
- public/stylesheets/admin/plugins/fancybox.css
|
92
|
+
- public/stylesheets/admin/box.css
|
93
|
+
installation:
|
94
|
+
- public/stylesheets/admin/installation.css
|
95
|
+
editable_elements:
|
96
|
+
- public/stylesheets/admin/editable_elements.css
|
data/config/environments/test.rb
CHANGED
@@ -0,0 +1,17 @@
|
|
1
|
+
CarrierWave.configure do |config|
|
2
|
+
|
3
|
+
case Rails.env.to_sym
|
4
|
+
|
5
|
+
when :development
|
6
|
+
config.storage = :file
|
7
|
+
config.root = File.join(Rails.root, 'public')
|
8
|
+
|
9
|
+
when :production
|
10
|
+
config.storage = :s3
|
11
|
+
config.s3_access_key_id = ENV['S3_KEY_ID']
|
12
|
+
config.s3_secret_access_key = ENV['S3_SECRET_KEY']
|
13
|
+
config.s3_bucket = ENV['S3_BUCKET']
|
14
|
+
# config.s3_cname = 'ENV['S3_CNAME']
|
15
|
+
end
|
16
|
+
|
17
|
+
end
|
@@ -4,6 +4,12 @@ Locomotive.configure do |config|
|
|
4
4
|
# if not defined, locomotive will use example.com as main domain name. Remove prefix www from your domain name.
|
5
5
|
# Ex:
|
6
6
|
# config.default_domain = Rails.env.production? ? 'mydomain.com' : 'example.com'
|
7
|
+
#
|
8
|
+
# If you use locomotive for a single site in Heroku, use "heroku.com" as default domain name.
|
9
|
+
# Your heroku app name (<app_name>.heroku.name) will be used as the sub domain name in Locomotive
|
10
|
+
# during the installation wizzard.
|
11
|
+
# Ex:
|
12
|
+
# config.default_domain = Rails.env.production? ? 'heroku.com' : 'example.com'
|
7
13
|
config.default_domain = 'example.com'
|
8
14
|
|
9
15
|
# configure how many items we display in sub menu in the "Contents" section.
|
@@ -25,4 +31,12 @@ Locomotive.configure do |config|
|
|
25
31
|
# Ex:
|
26
32
|
# config.heroku = { :name => '<my heroku app name>', :login => 'john@doe.net', :password => 'easy' }
|
27
33
|
config.heroku = false
|
34
|
+
|
35
|
+
# Locomotive uses the DelayedJob gem for the theme import module.
|
36
|
+
# In case you want to deploy to Heroku, you will have to pay for an extra dyno.
|
37
|
+
# If you do not mind about importing theme without DelayedJob, disable it.
|
38
|
+
config.delayed_job = false
|
39
|
+
|
40
|
+
# default locale (for now, only en and fr are supported)
|
41
|
+
config.default_locale = :en
|
28
42
|
end
|
@@ -174,7 +174,7 @@ en:
|
|
174
174
|
help: "You have the choice to either upload any file or to copy/paste a stylesheet or a javascript in plain text."
|
175
175
|
edit:
|
176
176
|
title: "Editing %{file}"
|
177
|
-
help: "This asset is accessible from the following url: <
|
177
|
+
help: "This asset is accessible from the following url: <a href='%{url}'>%{url}</a>"
|
178
178
|
form:
|
179
179
|
picker_link: Insert a file into the code
|
180
180
|
choose_file: Choose file
|
@@ -220,6 +220,7 @@ en:
|
|
220
220
|
new_item: new item
|
221
221
|
form:
|
222
222
|
order_by:
|
223
|
+
created_at: 'By "created at" date'
|
223
224
|
updated_at: 'By "updated at" date'
|
224
225
|
position_in_list: Manually
|
225
226
|
|
@@ -266,6 +267,33 @@ en:
|
|
266
267
|
success: "Your site was successfully updated."
|
267
268
|
failure: "The import did not work."
|
268
269
|
|
270
|
+
installation:
|
271
|
+
common:
|
272
|
+
title: First Locomotive Installation
|
273
|
+
next: Next
|
274
|
+
step_1:
|
275
|
+
title: Step 1/3
|
276
|
+
explanations: Here is the first step of the Locomotive installation. Please read carefully what is written below.
|
277
|
+
database:
|
278
|
+
label: "Database name: <em>%{name}</em>"
|
279
|
+
notes: "All the mongodb connection settings can be found in the <b>config/mongoid.yml</b> file of your application."
|
280
|
+
default_domain:
|
281
|
+
label: "Default domain name: <em>%{name}</em>"
|
282
|
+
notes: "Basically, Locomotive is a multi websites platform. Each site instance has a default entry, also called subdomain and based on the default domain name. Obviously, you are free to map other domains to your site instance working like aliases. <br/>The default domain name value can be found in the <b>config/initializers/locomotive.rb</b> file."
|
283
|
+
step_2:
|
284
|
+
title: "Step 2/3 — Create account"
|
285
|
+
name: Account name
|
286
|
+
email: Email
|
287
|
+
password: Password
|
288
|
+
password_confirmation: Password confirmation
|
289
|
+
done: "You have already added an account:<br/><strong>%{name}</strong>, <em>%{email}</em>"
|
290
|
+
next: Create account
|
291
|
+
step_3:
|
292
|
+
title: "Step 3/3 — Create first site"
|
293
|
+
explanations: "This is the last step of the installation. You can upload a theme as a zip file. We have free available themes <a href=\"http://www.locomotivecms.com/support/themes\">here</a>."
|
294
|
+
next: Create site
|
295
|
+
|
296
|
+
|
269
297
|
formtastic:
|
270
298
|
titles:
|
271
299
|
information: General information
|
@@ -298,6 +326,8 @@ en:
|
|
298
326
|
import:
|
299
327
|
new:
|
300
328
|
source: File
|
329
|
+
samples: Copy samples
|
330
|
+
reset: Reset site
|
301
331
|
|
302
332
|
hints:
|
303
333
|
page:
|
@@ -320,4 +350,6 @@ en:
|
|
320
350
|
hint: "Text displayed in the model form just below the field"
|
321
351
|
import:
|
322
352
|
source: "A zipfile containing a database.yml along with assets and templates"
|
353
|
+
samples: "If enabled, the import process will also copy contents and assets"
|
354
|
+
reset: "If enabled, all the data of your site will be destroyed before importing the new site"
|
323
355
|
|