Use Alchemys element-essences-system in any model you like!
-
Setup your Rails app
-
Install and configure Alchemy CMS
-
add alchemy_contentable to Gemfile
-
create a model or extend it with (at least) this fields:
- name:string - public:boolean - locked:boolean - locked_by:boolean - page_layout or - name:string - add t.contentable to migration
-
add t.stampable to migration
-
setup routes for your model:
resources :elements collection do post :order post :flush post :copy_language_tree get :switch_language get :create_language get :link get :sort end member do post :unlock post :publish post :fold post :visit get :configure get :preview end
-
include AlchemyContentable::ModelMixin in your model
-
include AlchemyContentable::ControllerMixin in the model’s controller
-
include AlchemyContentable::AdminControllerMixin in the model’s admin-controller and inherit from Alchemy::Admin::ResourcesController there
-
inherit your models controller from Alchemy::BaseController
-
set up authorization to manage, edit_content and update_content
-
(optional) mount your controller as a module in alchemy
-
no multilingual contents (yet)
-
problems with authorization, commented many filters out
-
no clipboard
-
no tests, but rspec setup already…