Persistence subsystem for the Netzke framework
Ruby
Switch branches/tags
Nothing to show
Pull request Compare This branch is 3 commits ahead, 9 commits behind mxgrn:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
app/models
config
features
generators
lib
spec
test
.gitignore
CHANGELOG.rdoc
README.rdoc
Rakefile
netzke-persistence.gemspec

README.rdoc

netzke-persistence

Enables persistence in Netzke components.

The following components currently support persistence:

  • Basepack::BorderLayoutPanel - remembers its region sizes, as well as collapsed/expanded states

In the works:

  • Basepack::Window - remembers its dimensions and position

  • Basepack::GridPanel - remembers:

    • columns sizes, order, and hidden/shown state

    • presets for advanced search

  • Basepack::TabPanel - remembers its last active tab

  • Basepack::AccordionPanel - remembers its panels states

  • Basepack::BasicApp - remembers its last loaded component

Installation

In your Gemfile:

gem 'netzke-persistence'

From your app directory run:

rails generate netzke:persistence && rake db:migrate

Usage

To enable persistence for a specific component, set its persistence configuration option to true, e.g.:

<%= netzke :my_component, :persistence => true %>

Component developers may refer to api.netzke.org/core/Netzke/State.html. For an example, see ComponentWithPersistence in test/rails_app/app/components.

Running tests

Symlink the Ext JS library into the test app, e.g. (depends on where your Ext JS is located):

ln -s ~/code/sencha/ext-3.3.0 test/rails_app/public/extjs

Run bundle install from inside the test app:

cd test/rails_app && bundle install && cd -

Running cucumber tests:

cucumber features

RSpec tests:

rspec spec

Copyright © 2008-2010 Sergei Kozlov, released under the MIT license