lockbox_middleware 1.2.1 → 1.2.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/lockbox_middleware.rb +1 -1
- data/spec/lib/lockbox_middleware_spec.rb +2 -2
- data/spec/spec_helper.rb +0 -2
- metadata +36 -756
- data/.gitignore +0 -15
- data/Capfile +0 -4
- data/Gemfile +0 -11
- data/Rakefile +0 -12
- data/VERSION +0 -1
- data/app/controllers/admin/partners_controller.rb +0 -14
- data/app/controllers/admin_controller.rb +0 -8
- data/app/controllers/application_controller.rb +0 -32
- data/app/controllers/authentication_controller.rb +0 -58
- data/app/controllers/confirmation_controller.rb +0 -14
- data/app/controllers/fetch_password_controller.rb +0 -44
- data/app/controllers/home_controller.rb +0 -11
- data/app/controllers/partner_sessions_controller.rb +0 -30
- data/app/controllers/partners_controller.rb +0 -58
- data/app/helpers/admin/partners_helper.rb +0 -3
- data/app/helpers/admin_helper.rb +0 -2
- data/app/helpers/application_helper.rb +0 -20
- data/app/helpers/authentication_helper.rb +0 -2
- data/app/helpers/fetch_password_helper.rb +0 -2
- data/app/helpers/home_helper.rb +0 -2
- data/app/helpers/labeled_builder.rb +0 -76
- data/app/helpers/partners_helper.rb +0 -2
- data/app/models/partner.rb +0 -129
- data/app/models/partner_mailer.rb +0 -25
- data/app/models/partner_session.rb +0 -2
- data/app/views/admin/show.html.erb +0 -6
- data/app/views/authentication/four_two_oh.html.erb +0 -4
- data/app/views/fetch_password/index.html.erb +0 -4
- data/app/views/fetch_password/show.html.erb +0 -6
- data/app/views/home/show.html.erb +0 -20
- data/app/views/layouts/admin.html.erb +0 -42
- data/app/views/layouts/application.html.erb +0 -48
- data/app/views/partner_mailer/confirmation.text.html.erb +0 -30
- data/app/views/partner_mailer/confirmation.text.plain.erb +0 -5
- data/app/views/partner_mailer/fetch_password.text.html.erb +0 -32
- data/app/views/partner_mailer/fetch_password.text.plain.erb +0 -5
- data/app/views/partner_sessions/new.html.erb +0 -9
- data/app/views/partners/_form.html.erb +0 -7
- data/app/views/partners/edit.html.erb +0 -5
- data/app/views/partners/index.html.erb +0 -0
- data/app/views/partners/new.html.erb +0 -6
- data/app/views/partners/show.html.erb +0 -48
- data/app/views/shared/_footer.html.erb +0 -0
- data/app/views/shared/_header.html.erb +0 -3
- data/app/views/shared/_logged_in_menu.html.erb +0 -1
- data/app/views/shared/_logged_out_menu.html.erb +0 -2
- data/config/asset_packages.yml +0 -19
- data/config/boot.rb +0 -110
- data/config/database.yml.example +0 -25
- data/config/environment.rb +0 -56
- data/config/environments/development.rb +0 -22
- data/config/environments/production.rb +0 -30
- data/config/environments/test.rb +0 -35
- data/config/initializers/backtrace_silencers.rb +0 -7
- data/config/initializers/inflections.rb +0 -10
- data/config/initializers/mime_types.rb +0 -7
- data/config/initializers/new_rails_defaults.rb +0 -21
- data/config/initializers/session_store.rb +0 -15
- data/config/initializers/settings.rb +0 -1
- data/config/initializers/string.rb +0 -25
- data/config/locales/en.yml +0 -5
- data/config/lockbox.yml.example +0 -12
- data/config/routes.rb +0 -23
- data/db/migrate/20091104170848_create_partners.rb +0 -34
- data/db/migrate/20091106213802_add_index_on_api_key.rb +0 -9
- data/db/migrate/20100507193948_add_partner_slug.rb +0 -11
- data/db/seeds.rb +0 -7
- data/lib/admin_authentication.rb +0 -9
- data/lib/authentication.rb +0 -48
- data/lib/rfc822.rb +0 -18
- data/lib/tasks/jeweler.rake +0 -14
- data/lib/tasks/rspec.rake +0 -144
- data/public/404.html +0 -30
- data/public/422.html +0 -30
- data/public/500.html +0 -30
- data/public/blank.html +0 -33
- data/public/favicon.ico +0 -0
- data/public/images/active_scaffold/DO_NOT_EDIT +0 -2
- data/public/images/active_scaffold/default/add.gif +0 -0
- data/public/images/active_scaffold/default/arrow_down.gif +0 -0
- data/public/images/active_scaffold/default/arrow_up.gif +0 -0
- data/public/images/active_scaffold/default/close.gif +0 -0
- data/public/images/active_scaffold/default/cross.png +0 -0
- data/public/images/active_scaffold/default/indicator-small.gif +0 -0
- data/public/images/active_scaffold/default/indicator.gif +0 -0
- data/public/images/active_scaffold/default/magnifier.png +0 -0
- data/public/images/rails.png +0 -0
- data/public/javascripts/active_scaffold/DO_NOT_EDIT +0 -2
- data/public/javascripts/active_scaffold/default/active_scaffold.js +0 -434
- data/public/javascripts/active_scaffold/default/dhtml_history.js +0 -867
- data/public/javascripts/active_scaffold/default/form_enhancements.js +0 -117
- data/public/javascripts/active_scaffold/default/rico_corner.js +0 -370
- data/public/javascripts/application.js +0 -2
- data/public/javascripts/controls.js +0 -963
- data/public/javascripts/csshover.htc +0 -120
- data/public/javascripts/dragdrop.js +0 -973
- data/public/javascripts/effects.js +0 -1128
- data/public/javascripts/prototype.js +0 -4320
- data/public/robots.txt +0 -5
- data/public/stylesheets/active_scaffold/DO_NOT_EDIT +0 -2
- data/public/stylesheets/active_scaffold/default/stylesheet-ie.css +0 -35
- data/public/stylesheets/active_scaffold/default/stylesheet.css +0 -822
- data/public/stylesheets/application.css +0 -189
- data/public/stylesheets/ie.css +0 -11
- data/public/stylesheets/reset.css +0 -42
- data/public/stylesheets/screen.css +0 -257
- data/script/about +0 -4
- data/script/autospec +0 -6
- data/script/console +0 -3
- data/script/cucumber +0 -17
- data/script/dbconsole +0 -3
- data/script/destroy +0 -3
- data/script/generate +0 -3
- data/script/performance/benchmarker +0 -3
- data/script/performance/profiler +0 -3
- data/script/plugin +0 -3
- data/script/runner +0 -3
- data/script/server +0 -3
- data/script/spec +0 -10
- data/spec/controllers/admin/partners_controller_spec.rb +0 -55
- data/spec/controllers/admin_controller_spec.rb +0 -29
- data/spec/controllers/application_controller_spec.rb +0 -36
- data/spec/controllers/authentication_controller_spec.rb +0 -120
- data/spec/controllers/confirmation_controller_spec.rb +0 -36
- data/spec/controllers/fetch_password_controller_spec.rb +0 -155
- data/spec/controllers/home_controller_spec.rb +0 -15
- data/spec/controllers/partner_sessions_controller_spec.rb +0 -84
- data/spec/controllers/partners_controller_spec.rb +0 -132
- data/spec/factories/partners.rb +0 -14
- data/spec/models/partner_mailer_spec.rb +0 -47
- data/spec/models/partner_spec.rb +0 -155
- data/spec/rcov.opts +0 -1
- data/vendor/gems/authlogic-2.1.3/.gitignore +0 -9
- data/vendor/gems/authlogic-2.1.3/CHANGELOG.rdoc +0 -345
- data/vendor/gems/authlogic-2.1.3/LICENSE +0 -20
- data/vendor/gems/authlogic-2.1.3/README.rdoc +0 -246
- data/vendor/gems/authlogic-2.1.3/Rakefile +0 -42
- data/vendor/gems/authlogic-2.1.3/VERSION.yml +0 -5
- data/vendor/gems/authlogic-2.1.3/authlogic.gemspec +0 -217
- data/vendor/gems/authlogic-2.1.3/generators/session/session_generator.rb +0 -9
- data/vendor/gems/authlogic-2.1.3/generators/session/templates/session.rb +0 -2
- data/vendor/gems/authlogic-2.1.3/init.rb +0 -1
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/base.rb +0 -107
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/email.rb +0 -110
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/logged_in_status.rb +0 -60
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/login.rb +0 -141
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/magic_columns.rb +0 -24
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/password.rb +0 -344
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/perishable_token.rb +0 -105
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/persistence_token.rb +0 -68
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/restful_authentication.rb +0 -61
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/session_maintenance.rb +0 -139
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/single_access_token.rb +0 -65
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/acts_as_authentic/validations_scope.rb +0 -32
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/authenticates_many/association.rb +0 -42
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/authenticates_many/base.rb +0 -55
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/controller_adapters/abstract_adapter.rb +0 -67
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/controller_adapters/merb_adapter.rb +0 -30
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/controller_adapters/rails_adapter.rb +0 -48
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/controller_adapters/sinatra_adapter.rb +0 -61
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/crypto_providers/aes256.rb +0 -43
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/crypto_providers/bcrypt.rb +0 -90
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/crypto_providers/md5.rb +0 -34
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/crypto_providers/sha1.rb +0 -35
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/crypto_providers/sha256.rb +0 -50
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/crypto_providers/sha512.rb +0 -50
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/crypto_providers/wordpress.rb +0 -43
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/i18n/translator.rb +0 -15
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/i18n.rb +0 -83
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/random.rb +0 -33
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/regex.rb +0 -25
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/activation.rb +0 -58
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/active_record_trickery.rb +0 -61
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/base.rb +0 -37
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/brute_force_protection.rb +0 -96
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/callbacks.rb +0 -88
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/cookies.rb +0 -130
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/existence.rb +0 -93
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/foundation.rb +0 -63
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/http_auth.rb +0 -58
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/id.rb +0 -41
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/klass.rb +0 -78
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/magic_columns.rb +0 -95
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/magic_states.rb +0 -59
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/params.rb +0 -101
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/password.rb +0 -240
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/perishable_token.rb +0 -18
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/persistence.rb +0 -70
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/priority_record.rb +0 -34
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/scopes.rb +0 -101
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/session.rb +0 -62
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/timeout.rb +0 -82
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/unauthorized_record.rb +0 -50
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/session/validation.rb +0 -82
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/test_case/mock_controller.rb +0 -45
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/test_case/mock_cookie_jar.rb +0 -14
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/test_case/mock_logger.rb +0 -10
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/test_case/mock_request.rb +0 -19
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/test_case/rails_request_adapter.rb +0 -30
- data/vendor/gems/authlogic-2.1.3/lib/authlogic/test_case.rb +0 -120
- data/vendor/gems/authlogic-2.1.3/lib/authlogic.rb +0 -57
- data/vendor/gems/authlogic-2.1.3/rails/init.rb +0 -1
- data/vendor/gems/authlogic-2.1.3/shoulda_macros/authlogic.rb +0 -69
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/base_test.rb +0 -18
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/email_test.rb +0 -97
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/logged_in_status_test.rb +0 -36
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/login_test.rb +0 -109
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/magic_columns_test.rb +0 -27
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/password_test.rb +0 -236
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/perishable_token_test.rb +0 -90
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/persistence_token_test.rb +0 -55
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/restful_authentication_test.rb +0 -40
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/session_maintenance_test.rb +0 -84
- data/vendor/gems/authlogic-2.1.3/test/acts_as_authentic_test/single_access_test.rb +0 -44
- data/vendor/gems/authlogic-2.1.3/test/authenticates_many_test.rb +0 -16
- data/vendor/gems/authlogic-2.1.3/test/crypto_provider_test/aes256_test.rb +0 -14
- data/vendor/gems/authlogic-2.1.3/test/crypto_provider_test/bcrypt_test.rb +0 -14
- data/vendor/gems/authlogic-2.1.3/test/crypto_provider_test/sha1_test.rb +0 -23
- data/vendor/gems/authlogic-2.1.3/test/crypto_provider_test/sha256_test.rb +0 -14
- data/vendor/gems/authlogic-2.1.3/test/crypto_provider_test/sha512_test.rb +0 -14
- data/vendor/gems/authlogic-2.1.3/test/fixtures/companies.yml +0 -5
- data/vendor/gems/authlogic-2.1.3/test/fixtures/employees.yml +0 -17
- data/vendor/gems/authlogic-2.1.3/test/fixtures/projects.yml +0 -3
- data/vendor/gems/authlogic-2.1.3/test/fixtures/users.yml +0 -24
- data/vendor/gems/authlogic-2.1.3/test/i18n_test.rb +0 -33
- data/vendor/gems/authlogic-2.1.3/test/libs/affiliate.rb +0 -7
- data/vendor/gems/authlogic-2.1.3/test/libs/company.rb +0 -6
- data/vendor/gems/authlogic-2.1.3/test/libs/employee.rb +0 -7
- data/vendor/gems/authlogic-2.1.3/test/libs/employee_session.rb +0 -2
- data/vendor/gems/authlogic-2.1.3/test/libs/ldaper.rb +0 -3
- data/vendor/gems/authlogic-2.1.3/test/libs/ordered_hash.rb +0 -9
- data/vendor/gems/authlogic-2.1.3/test/libs/project.rb +0 -3
- data/vendor/gems/authlogic-2.1.3/test/libs/user.rb +0 -5
- data/vendor/gems/authlogic-2.1.3/test/libs/user_session.rb +0 -6
- data/vendor/gems/authlogic-2.1.3/test/random_test.rb +0 -49
- data/vendor/gems/authlogic-2.1.3/test/session_test/activation_test.rb +0 -43
- data/vendor/gems/authlogic-2.1.3/test/session_test/active_record_trickery_test.rb +0 -36
- data/vendor/gems/authlogic-2.1.3/test/session_test/brute_force_protection_test.rb +0 -101
- data/vendor/gems/authlogic-2.1.3/test/session_test/callbacks_test.rb +0 -6
- data/vendor/gems/authlogic-2.1.3/test/session_test/cookies_test.rb +0 -112
- data/vendor/gems/authlogic-2.1.3/test/session_test/credentials_test.rb +0 -0
- data/vendor/gems/authlogic-2.1.3/test/session_test/existence_test.rb +0 -64
- data/vendor/gems/authlogic-2.1.3/test/session_test/http_auth_test.rb +0 -28
- data/vendor/gems/authlogic-2.1.3/test/session_test/id_test.rb +0 -17
- data/vendor/gems/authlogic-2.1.3/test/session_test/klass_test.rb +0 -40
- data/vendor/gems/authlogic-2.1.3/test/session_test/magic_columns_test.rb +0 -62
- data/vendor/gems/authlogic-2.1.3/test/session_test/magic_states_test.rb +0 -60
- data/vendor/gems/authlogic-2.1.3/test/session_test/params_test.rb +0 -53
- data/vendor/gems/authlogic-2.1.3/test/session_test/password_test.rb +0 -106
- data/vendor/gems/authlogic-2.1.3/test/session_test/perishability_test.rb +0 -15
- data/vendor/gems/authlogic-2.1.3/test/session_test/persistence_test.rb +0 -21
- data/vendor/gems/authlogic-2.1.3/test/session_test/scopes_test.rb +0 -60
- data/vendor/gems/authlogic-2.1.3/test/session_test/session_test.rb +0 -59
- data/vendor/gems/authlogic-2.1.3/test/session_test/timeout_test.rb +0 -52
- data/vendor/gems/authlogic-2.1.3/test/session_test/unauthorized_record_test.rb +0 -13
- data/vendor/gems/authlogic-2.1.3/test/session_test/validation_test.rb +0 -23
- data/vendor/gems/authlogic-2.1.3/test/test_helper.rb +0 -182
- data/vendor/gems/factory_girl-1.2.3/.specification +0 -121
- data/vendor/gems/factory_girl-1.2.3/CONTRIBUTION_GUIDELINES.rdoc +0 -9
- data/vendor/gems/factory_girl-1.2.3/Changelog +0 -29
- data/vendor/gems/factory_girl-1.2.3/LICENSE +0 -19
- data/vendor/gems/factory_girl-1.2.3/README.rdoc +0 -228
- data/vendor/gems/factory_girl-1.2.3/Rakefile +0 -81
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/aliases.rb +0 -50
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/attribute/association.rb +0 -20
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/attribute/callback.rb +0 -16
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/attribute/dynamic.rb +0 -20
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/attribute/static.rb +0 -17
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/attribute.rb +0 -29
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/factory.rb +0 -395
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/proxy/attributes_for.rb +0 -21
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/proxy/build.rb +0 -30
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/proxy/create.rb +0 -12
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/proxy/stub.rb +0 -50
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/proxy.rb +0 -79
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/sequence.rb +0 -63
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/step_definitions.rb +0 -54
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/syntax/blueprint.rb +0 -42
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/syntax/generate.rb +0 -68
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/syntax/make.rb +0 -39
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/syntax/sham.rb +0 -42
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl/syntax.rb +0 -12
- data/vendor/gems/factory_girl-1.2.3/lib/factory_girl.rb +0 -35
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/aliases_spec.rb +0 -29
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/attribute/association_spec.rb +0 -29
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/attribute/callback_spec.rb +0 -23
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/attribute/dynamic_spec.rb +0 -49
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/attribute/static_spec.rb +0 -29
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/attribute_spec.rb +0 -30
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/factory_spec.rb +0 -571
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/proxy/attributes_for_spec.rb +0 -52
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/proxy/build_spec.rb +0 -81
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/proxy/create_spec.rb +0 -94
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/proxy/stub_spec.rb +0 -79
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/proxy_spec.rb +0 -84
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/sequence_spec.rb +0 -66
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/syntax/blueprint_spec.rb +0 -34
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/syntax/generate_spec.rb +0 -57
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/syntax/make_spec.rb +0 -35
- data/vendor/gems/factory_girl-1.2.3/spec/factory_girl/syntax/sham_spec.rb +0 -35
- data/vendor/gems/factory_girl-1.2.3/spec/integration_spec.rb +0 -304
- data/vendor/gems/factory_girl-1.2.3/spec/models.rb +0 -43
- data/vendor/gems/factory_girl-1.2.3/spec/spec_helper.rb +0 -18
- data/vendor/gems/paperclip-2.3.1.1/.specification +0 -161
- data/vendor/gems/paperclip-2.3.1.1/LICENSE +0 -26
- data/vendor/gems/paperclip-2.3.1.1/README.rdoc +0 -174
- data/vendor/gems/paperclip-2.3.1.1/Rakefile +0 -103
- data/vendor/gems/paperclip-2.3.1.1/generators/paperclip/USAGE +0 -5
- data/vendor/gems/paperclip-2.3.1.1/generators/paperclip/paperclip_generator.rb +0 -27
- data/vendor/gems/paperclip-2.3.1.1/generators/paperclip/templates/paperclip_migration.rb.erb +0 -19
- data/vendor/gems/paperclip-2.3.1.1/init.rb +0 -1
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/attachment.rb +0 -414
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/callback_compatability.rb +0 -33
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/geometry.rb +0 -115
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/interpolations.rb +0 -108
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/iostream.rb +0 -58
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/matchers/have_attached_file_matcher.rb +0 -49
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/matchers/validate_attachment_content_type_matcher.rb +0 -66
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/matchers/validate_attachment_presence_matcher.rb +0 -48
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/matchers/validate_attachment_size_matcher.rb +0 -83
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/matchers.rb +0 -4
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/processor.rb +0 -49
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/storage.rb +0 -243
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/thumbnail.rb +0 -73
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip/upfile.rb +0 -49
- data/vendor/gems/paperclip-2.3.1.1/lib/paperclip.rb +0 -353
- data/vendor/gems/paperclip-2.3.1.1/shoulda_macros/paperclip.rb +0 -117
- data/vendor/gems/paperclip-2.3.1.1/tasks/paperclip_tasks.rake +0 -79
- data/vendor/gems/paperclip-2.3.1.1/test/attachment_test.rb +0 -780
- data/vendor/gems/paperclip-2.3.1.1/test/database.yml +0 -4
- data/vendor/gems/paperclip-2.3.1.1/test/fixtures/12k.png +0 -0
- data/vendor/gems/paperclip-2.3.1.1/test/fixtures/50x50.png +0 -0
- data/vendor/gems/paperclip-2.3.1.1/test/fixtures/5k.png +0 -0
- data/vendor/gems/paperclip-2.3.1.1/test/fixtures/bad.png +0 -1
- data/vendor/gems/paperclip-2.3.1.1/test/fixtures/s3.yml +0 -8
- data/vendor/gems/paperclip-2.3.1.1/test/fixtures/text.txt +0 -0
- data/vendor/gems/paperclip-2.3.1.1/test/fixtures/twopage.pdf +0 -0
- data/vendor/gems/paperclip-2.3.1.1/test/geometry_test.rb +0 -177
- data/vendor/gems/paperclip-2.3.1.1/test/helper.rb +0 -108
- data/vendor/gems/paperclip-2.3.1.1/test/integration_test.rb +0 -483
- data/vendor/gems/paperclip-2.3.1.1/test/interpolations_test.rb +0 -124
- data/vendor/gems/paperclip-2.3.1.1/test/iostream_test.rb +0 -71
- data/vendor/gems/paperclip-2.3.1.1/test/matchers/have_attached_file_matcher_test.rb +0 -21
- data/vendor/gems/paperclip-2.3.1.1/test/matchers/validate_attachment_content_type_matcher_test.rb +0 -30
- data/vendor/gems/paperclip-2.3.1.1/test/matchers/validate_attachment_presence_matcher_test.rb +0 -21
- data/vendor/gems/paperclip-2.3.1.1/test/matchers/validate_attachment_size_matcher_test.rb +0 -50
- data/vendor/gems/paperclip-2.3.1.1/test/paperclip_test.rb +0 -327
- data/vendor/gems/paperclip-2.3.1.1/test/processor_test.rb +0 -10
- data/vendor/gems/paperclip-2.3.1.1/test/storage_test.rb +0 -303
- data/vendor/gems/paperclip-2.3.1.1/test/thumbnail_test.rb +0 -227
- data/vendor/gems/paperclip-2.3.1.1/test/upfile_test.rb +0 -28
- data/vendor/gems/shoulda-2.10.2/.specification +0 -224
- data/vendor/gems/shoulda-2.10.2/CONTRIBUTION_GUIDELINES.rdoc +0 -10
- data/vendor/gems/shoulda-2.10.2/MIT-LICENSE +0 -22
- data/vendor/gems/shoulda-2.10.2/README.rdoc +0 -171
- data/vendor/gems/shoulda-2.10.2/Rakefile +0 -72
- data/vendor/gems/shoulda-2.10.2/bin/convert_to_should_syntax +0 -42
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller/macros.rb +0 -240
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller/matchers/assign_to_matcher.rb +0 -109
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller/matchers/filter_param_matcher.rb +0 -57
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller/matchers/render_with_layout_matcher.rb +0 -81
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller/matchers/respond_with_content_type_matcher.rb +0 -74
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller/matchers/respond_with_matcher.rb +0 -81
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller/matchers/route_matcher.rb +0 -93
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller/matchers/set_session_matcher.rb +0 -87
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller/matchers/set_the_flash_matcher.rb +0 -85
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller/matchers.rb +0 -37
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_controller.rb +0 -26
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_mailer/assertions.rb +0 -38
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_mailer.rb +0 -10
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_view/macros.rb +0 -61
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/action_view.rb +0 -10
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/assertions.rb +0 -69
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/helpers.rb +0 -27
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/macros.rb +0 -512
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/allow_mass_assignment_of_matcher.rb +0 -83
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/allow_value_matcher.rb +0 -102
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/association_matcher.rb +0 -226
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/ensure_inclusion_of_matcher.rb +0 -87
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/ensure_length_of_matcher.rb +0 -141
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/have_db_column_matcher.rb +0 -169
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/have_db_index_matcher.rb +0 -112
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/have_named_scope_matcher.rb +0 -128
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/have_readonly_attribute_matcher.rb +0 -59
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/validate_acceptance_of_matcher.rb +0 -41
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/validate_format_of_matcher.rb +0 -67
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/validate_numericality_of_matcher.rb +0 -39
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/validate_presence_of_matcher.rb +0 -60
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/validate_uniqueness_of_matcher.rb +0 -148
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers/validation_matcher.rb +0 -57
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record/matchers.rb +0 -43
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/active_record.rb +0 -16
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/assertions.rb +0 -71
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/autoload_macros.rb +0 -46
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/context.rb +0 -402
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/helpers.rb +0 -8
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/macros.rb +0 -133
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/private_helpers.rb +0 -13
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/proc_extensions.rb +0 -14
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/rails.rb +0 -13
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/rspec.rb +0 -11
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/tasks/list_tests.rake +0 -29
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/tasks/yaml_to_shoulda.rake +0 -28
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/tasks.rb +0 -3
- data/vendor/gems/shoulda-2.10.2/lib/shoulda/test_unit.rb +0 -22
- data/vendor/gems/shoulda-2.10.2/lib/shoulda.rb +0 -9
- data/vendor/gems/shoulda-2.10.2/rails/init.rb +0 -7
- data/vendor/gems/shoulda-2.10.2/test/README +0 -36
- data/vendor/gems/shoulda-2.10.2/test/fail_macros.rb +0 -39
- data/vendor/gems/shoulda-2.10.2/test/fixtures/addresses.yml +0 -3
- data/vendor/gems/shoulda-2.10.2/test/fixtures/friendships.yml +0 -0
- data/vendor/gems/shoulda-2.10.2/test/fixtures/posts.yml +0 -5
- data/vendor/gems/shoulda-2.10.2/test/fixtures/products.yml +0 -0
- data/vendor/gems/shoulda-2.10.2/test/fixtures/taggings.yml +0 -0
- data/vendor/gems/shoulda-2.10.2/test/fixtures/tags.yml +0 -9
- data/vendor/gems/shoulda-2.10.2/test/fixtures/users.yml +0 -6
- data/vendor/gems/shoulda-2.10.2/test/functional/posts_controller_test.rb +0 -121
- data/vendor/gems/shoulda-2.10.2/test/functional/users_controller_test.rb +0 -19
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/allow_mass_assignment_of_matcher_test.rb +0 -68
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/allow_value_matcher_test.rb +0 -64
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/association_matcher_test.rb +0 -263
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/ensure_inclusion_of_matcher_test.rb +0 -80
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/ensure_length_of_matcher_test.rb +0 -158
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/have_db_column_matcher_test.rb +0 -169
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/have_db_index_matcher_test.rb +0 -91
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/have_named_scope_matcher_test.rb +0 -65
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/have_readonly_attributes_matcher_test.rb +0 -29
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/validate_acceptance_of_matcher_test.rb +0 -44
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/validate_format_of_matcher_test.rb +0 -39
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/validate_numericality_of_matcher_test.rb +0 -52
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/validate_presence_of_matcher_test.rb +0 -86
- data/vendor/gems/shoulda-2.10.2/test/matchers/active_record/validate_uniqueness_of_matcher_test.rb +0 -147
- data/vendor/gems/shoulda-2.10.2/test/matchers/controller/assign_to_matcher_test.rb +0 -35
- data/vendor/gems/shoulda-2.10.2/test/matchers/controller/filter_param_matcher_test.rb +0 -32
- data/vendor/gems/shoulda-2.10.2/test/matchers/controller/render_with_layout_matcher_test.rb +0 -33
- data/vendor/gems/shoulda-2.10.2/test/matchers/controller/respond_with_content_type_matcher_test.rb +0 -32
- data/vendor/gems/shoulda-2.10.2/test/matchers/controller/respond_with_matcher_test.rb +0 -106
- data/vendor/gems/shoulda-2.10.2/test/matchers/controller/route_matcher_test.rb +0 -58
- data/vendor/gems/shoulda-2.10.2/test/matchers/controller/set_session_matcher_test.rb +0 -38
- data/vendor/gems/shoulda-2.10.2/test/matchers/controller/set_the_flash_matcher.rb +0 -41
- data/vendor/gems/shoulda-2.10.2/test/model_builder.rb +0 -106
- data/vendor/gems/shoulda-2.10.2/test/other/autoload_macro_test.rb +0 -18
- data/vendor/gems/shoulda-2.10.2/test/other/context_test.rb +0 -189
- data/vendor/gems/shoulda-2.10.2/test/other/convert_to_should_syntax_test.rb +0 -63
- data/vendor/gems/shoulda-2.10.2/test/other/helpers_test.rb +0 -340
- data/vendor/gems/shoulda-2.10.2/test/other/private_helpers_test.rb +0 -32
- data/vendor/gems/shoulda-2.10.2/test/other/should_test.rb +0 -271
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/controllers/application_controller.rb +0 -25
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/controllers/posts_controller.rb +0 -87
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/controllers/users_controller.rb +0 -84
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/helpers/application_helper.rb +0 -3
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/helpers/posts_helper.rb +0 -2
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/helpers/users_helper.rb +0 -2
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/address.rb +0 -7
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/flea.rb +0 -3
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/friendship.rb +0 -4
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/pets/cat.rb +0 -7
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/pets/dog.rb +0 -10
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/post.rb +0 -12
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/product.rb +0 -12
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/profile.rb +0 -2
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/registration.rb +0 -2
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/tag.rb +0 -8
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/tagging.rb +0 -4
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/treat.rb +0 -3
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/models/user.rb +0 -32
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/layouts/posts.rhtml +0 -19
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/layouts/users.rhtml +0 -17
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/layouts/wide.html.erb +0 -1
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/posts/edit.rhtml +0 -27
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/posts/index.rhtml +0 -25
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/posts/new.rhtml +0 -26
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/posts/show.rhtml +0 -18
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/users/edit.rhtml +0 -22
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/users/index.rhtml +0 -22
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/users/new.rhtml +0 -21
- data/vendor/gems/shoulda-2.10.2/test/rails_root/app/views/users/show.rhtml +0 -13
- data/vendor/gems/shoulda-2.10.2/test/rails_root/config/boot.rb +0 -110
- data/vendor/gems/shoulda-2.10.2/test/rails_root/config/database.yml +0 -4
- data/vendor/gems/shoulda-2.10.2/test/rails_root/config/environment.rb +0 -18
- data/vendor/gems/shoulda-2.10.2/test/rails_root/config/environments/test.rb +0 -0
- data/vendor/gems/shoulda-2.10.2/test/rails_root/config/initializers/new_rails_defaults.rb +0 -15
- data/vendor/gems/shoulda-2.10.2/test/rails_root/config/initializers/shoulda.rb +0 -8
- data/vendor/gems/shoulda-2.10.2/test/rails_root/config/routes.rb +0 -6
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/001_create_users.rb +0 -19
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/002_create_posts.rb +0 -13
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/003_create_taggings.rb +0 -12
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/004_create_tags.rb +0 -11
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/005_create_dogs.rb +0 -12
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/006_create_addresses.rb +0 -14
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/007_create_fleas.rb +0 -11
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/008_create_dogs_fleas.rb +0 -12
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/009_create_products.rb +0 -17
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/010_create_friendships.rb +0 -14
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/011_create_treats.rb +0 -12
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/20090506203502_create_profiles.rb +0 -12
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/20090506203536_create_registrations.rb +0 -14
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/migrate/20090513104502_create_cats.rb +0 -12
- data/vendor/gems/shoulda-2.10.2/test/rails_root/db/schema.rb +0 -0
- data/vendor/gems/shoulda-2.10.2/test/rails_root/public/404.html +0 -30
- data/vendor/gems/shoulda-2.10.2/test/rails_root/public/422.html +0 -30
- data/vendor/gems/shoulda-2.10.2/test/rails_root/public/500.html +0 -30
- data/vendor/gems/shoulda-2.10.2/test/rails_root/script/console +0 -3
- data/vendor/gems/shoulda-2.10.2/test/rails_root/script/generate +0 -3
- data/vendor/gems/shoulda-2.10.2/test/rails_root/test/shoulda_macros/custom_macro.rb +0 -6
- data/vendor/gems/shoulda-2.10.2/test/rails_root/vendor/gems/gem_with_macro-0.0.1/shoulda_macros/gem_macro.rb +0 -6
- data/vendor/gems/shoulda-2.10.2/test/rails_root/vendor/plugins/plugin_with_macro/shoulda_macros/plugin_macro.rb +0 -6
- data/vendor/gems/shoulda-2.10.2/test/rspec_test.rb +0 -207
- data/vendor/gems/shoulda-2.10.2/test/test_helper.rb +0 -28
- data/vendor/gems/shoulda-2.10.2/test/unit/address_test.rb +0 -10
- data/vendor/gems/shoulda-2.10.2/test/unit/cat_test.rb +0 -7
- data/vendor/gems/shoulda-2.10.2/test/unit/dog_test.rb +0 -9
- data/vendor/gems/shoulda-2.10.2/test/unit/flea_test.rb +0 -6
- data/vendor/gems/shoulda-2.10.2/test/unit/friendship_test.rb +0 -6
- data/vendor/gems/shoulda-2.10.2/test/unit/post_test.rb +0 -19
- data/vendor/gems/shoulda-2.10.2/test/unit/product_test.rb +0 -23
- data/vendor/gems/shoulda-2.10.2/test/unit/tag_test.rb +0 -15
- data/vendor/gems/shoulda-2.10.2/test/unit/tagging_test.rb +0 -6
- data/vendor/gems/shoulda-2.10.2/test/unit/user_test.rb +0 -80
- data/vendor/plugins/active_scaffold/.autotest +0 -27
- data/vendor/plugins/active_scaffold/CHANGELOG +0 -152
- data/vendor/plugins/active_scaffold/MIT-LICENSE +0 -20
- data/vendor/plugins/active_scaffold/README +0 -31
- data/vendor/plugins/active_scaffold/Rakefile +0 -24
- data/vendor/plugins/active_scaffold/environment.rb +0 -17
- data/vendor/plugins/active_scaffold/frontends/default/images/add.gif +0 -0
- data/vendor/plugins/active_scaffold/frontends/default/images/arrow_down.gif +0 -0
- data/vendor/plugins/active_scaffold/frontends/default/images/arrow_up.gif +0 -0
- data/vendor/plugins/active_scaffold/frontends/default/images/close.gif +0 -0
- data/vendor/plugins/active_scaffold/frontends/default/images/cross.png +0 -0
- data/vendor/plugins/active_scaffold/frontends/default/images/indicator-small.gif +0 -0
- data/vendor/plugins/active_scaffold/frontends/default/images/indicator.gif +0 -0
- data/vendor/plugins/active_scaffold/frontends/default/images/magnifier.png +0 -0
- data/vendor/plugins/active_scaffold/frontends/default/javascripts/active_scaffold.js +0 -434
- data/vendor/plugins/active_scaffold/frontends/default/javascripts/dhtml_history.js +0 -867
- data/vendor/plugins/active_scaffold/frontends/default/javascripts/form_enhancements.js +0 -117
- data/vendor/plugins/active_scaffold/frontends/default/javascripts/rico_corner.js +0 -370
- data/vendor/plugins/active_scaffold/frontends/default/stylesheets/stylesheet-ie.css +0 -35
- data/vendor/plugins/active_scaffold/frontends/default/stylesheets/stylesheet.css +0 -822
- data/vendor/plugins/active_scaffold/frontends/default/views/_add_existing_form.html.erb +0 -40
- data/vendor/plugins/active_scaffold/frontends/default/views/_create_form.html.erb +0 -51
- data/vendor/plugins/active_scaffold/frontends/default/views/_create_form_on_list.html.erb +0 -38
- data/vendor/plugins/active_scaffold/frontends/default/views/_field_search.html.erb +0 -45
- data/vendor/plugins/active_scaffold/frontends/default/views/_form.html.erb +0 -18
- data/vendor/plugins/active_scaffold/frontends/default/views/_form_association.html.erb +0 -20
- data/vendor/plugins/active_scaffold/frontends/default/views/_form_association_footer.html.erb +0 -42
- data/vendor/plugins/active_scaffold/frontends/default/views/_form_attribute.html.erb +0 -12
- data/vendor/plugins/active_scaffold/frontends/default/views/_form_hidden_attribute.html.erb +0 -1
- data/vendor/plugins/active_scaffold/frontends/default/views/_form_messages.html.erb +0 -5
- data/vendor/plugins/active_scaffold/frontends/default/views/_horizontal_subform.html.erb +0 -19
- data/vendor/plugins/active_scaffold/frontends/default/views/_horizontal_subform_header.html.erb +0 -10
- data/vendor/plugins/active_scaffold/frontends/default/views/_horizontal_subform_record.html.erb +0 -29
- data/vendor/plugins/active_scaffold/frontends/default/views/_list.html.erb +0 -37
- data/vendor/plugins/active_scaffold/frontends/default/views/_list_actions.html.erb +0 -13
- data/vendor/plugins/active_scaffold/frontends/default/views/_list_calculations.html.erb +0 -22
- data/vendor/plugins/active_scaffold/frontends/default/views/_list_column_headings.html.erb +0 -32
- data/vendor/plugins/active_scaffold/frontends/default/views/_list_header.html.erb +0 -14
- data/vendor/plugins/active_scaffold/frontends/default/views/_list_inline_adapter.html.erb +0 -9
- data/vendor/plugins/active_scaffold/frontends/default/views/_list_pagination_links.html.erb +0 -30
- data/vendor/plugins/active_scaffold/frontends/default/views/_list_record.html.erb +0 -36
- data/vendor/plugins/active_scaffold/frontends/default/views/_live_search.html.erb +0 -23
- data/vendor/plugins/active_scaffold/frontends/default/views/_messages.html.erb +0 -10
- data/vendor/plugins/active_scaffold/frontends/default/views/_nested.html.erb +0 -44
- data/vendor/plugins/active_scaffold/frontends/default/views/_search.html.erb +0 -20
- data/vendor/plugins/active_scaffold/frontends/default/views/_show.html.erb +0 -8
- data/vendor/plugins/active_scaffold/frontends/default/views/_show_columns.html.erb +0 -12
- data/vendor/plugins/active_scaffold/frontends/default/views/_update_actions.html.erb +0 -9
- data/vendor/plugins/active_scaffold/frontends/default/views/_update_form.html.erb +0 -55
- data/vendor/plugins/active_scaffold/frontends/default/views/_vertical_subform.html.erb +0 -12
- data/vendor/plugins/active_scaffold/frontends/default/views/_vertical_subform_record.html.erb +0 -31
- data/vendor/plugins/active_scaffold/frontends/default/views/add_existing.js.rjs +0 -16
- data/vendor/plugins/active_scaffold/frontends/default/views/add_existing_form.html.erb +0 -5
- data/vendor/plugins/active_scaffold/frontends/default/views/create.html.erb +0 -5
- data/vendor/plugins/active_scaffold/frontends/default/views/delete.html.erb +0 -13
- data/vendor/plugins/active_scaffold/frontends/default/views/destroy.js.rjs +0 -10
- data/vendor/plugins/active_scaffold/frontends/default/views/edit_associated.js.rjs +0 -14
- data/vendor/plugins/active_scaffold/frontends/default/views/field_search.html.erb +0 -5
- data/vendor/plugins/active_scaffold/frontends/default/views/form_messages.js.rjs +0 -1
- data/vendor/plugins/active_scaffold/frontends/default/views/form_messages_on_create.js.rjs +0 -2
- data/vendor/plugins/active_scaffold/frontends/default/views/form_messages_on_update.js.rjs +0 -2
- data/vendor/plugins/active_scaffold/frontends/default/views/list.html.erb +0 -48
- data/vendor/plugins/active_scaffold/frontends/default/views/on_create.js.rjs +0 -25
- data/vendor/plugins/active_scaffold/frontends/default/views/on_update.js.rjs +0 -11
- data/vendor/plugins/active_scaffold/frontends/default/views/render_field.js.rjs +0 -9
- data/vendor/plugins/active_scaffold/frontends/default/views/search.html.erb +0 -5
- data/vendor/plugins/active_scaffold/frontends/default/views/show.html.erb +0 -5
- data/vendor/plugins/active_scaffold/frontends/default/views/update.html.erb +0 -8
- data/vendor/plugins/active_scaffold/frontends/default/views/update_column.js.rjs +0 -12
- data/vendor/plugins/active_scaffold/init.rb +0 -18
- data/vendor/plugins/active_scaffold/install.rb +0 -39
- data/vendor/plugins/active_scaffold/install_assets.rb +0 -36
- data/vendor/plugins/active_scaffold/lib/active_record_permissions.rb +0 -128
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/core.rb +0 -136
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/create.rb +0 -158
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/delete.rb +0 -72
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/field_search.rb +0 -58
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/list.rb +0 -95
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/live_search.rb +0 -57
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/nested.rb +0 -217
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/search.rb +0 -50
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/show.rb +0 -54
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/subform.rb +0 -17
- data/vendor/plugins/active_scaffold/lib/active_scaffold/actions/update.rb +0 -126
- data/vendor/plugins/active_scaffold/lib/active_scaffold/attribute_params.rb +0 -192
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/base.rb +0 -45
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/core.rb +0 -230
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/create.rb +0 -43
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/delete.rb +0 -25
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/field_search.rb +0 -53
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/form.rb +0 -49
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/list.rb +0 -134
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/live_search.rb +0 -52
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/nested.rb +0 -34
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/search.rb +0 -52
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/show.rb +0 -36
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/subform.rb +0 -36
- data/vendor/plugins/active_scaffold/lib/active_scaffold/config/update.rb +0 -32
- data/vendor/plugins/active_scaffold/lib/active_scaffold/configurable.rb +0 -29
- data/vendor/plugins/active_scaffold/lib/active_scaffold/constraints.rb +0 -181
- data/vendor/plugins/active_scaffold/lib/active_scaffold/data_structures/action_columns.rb +0 -97
- data/vendor/plugins/active_scaffold/lib/active_scaffold/data_structures/action_link.rb +0 -140
- data/vendor/plugins/active_scaffold/lib/active_scaffold/data_structures/action_links.rb +0 -47
- data/vendor/plugins/active_scaffold/lib/active_scaffold/data_structures/actions.rb +0 -45
- data/vendor/plugins/active_scaffold/lib/active_scaffold/data_structures/column.rb +0 -311
- data/vendor/plugins/active_scaffold/lib/active_scaffold/data_structures/columns.rb +0 -75
- data/vendor/plugins/active_scaffold/lib/active_scaffold/data_structures/error_message.rb +0 -24
- data/vendor/plugins/active_scaffold/lib/active_scaffold/data_structures/set.rb +0 -62
- data/vendor/plugins/active_scaffold/lib/active_scaffold/data_structures/sorting.rb +0 -159
- data/vendor/plugins/active_scaffold/lib/active_scaffold/finder.rb +0 -216
- data/vendor/plugins/active_scaffold/lib/active_scaffold/helpers/association_helpers.rb +0 -40
- data/vendor/plugins/active_scaffold/lib/active_scaffold/helpers/controller_helpers.rb +0 -41
- data/vendor/plugins/active_scaffold/lib/active_scaffold/helpers/country_helpers.rb +0 -347
- data/vendor/plugins/active_scaffold/lib/active_scaffold/helpers/form_column_helpers.rb +0 -301
- data/vendor/plugins/active_scaffold/lib/active_scaffold/helpers/id_helpers.rb +0 -129
- data/vendor/plugins/active_scaffold/lib/active_scaffold/helpers/list_column_helpers.rb +0 -234
- data/vendor/plugins/active_scaffold/lib/active_scaffold/helpers/pagination_helpers.rb +0 -39
- data/vendor/plugins/active_scaffold/lib/active_scaffold/helpers/search_column_helpers.rb +0 -172
- data/vendor/plugins/active_scaffold/lib/active_scaffold/helpers/show_column_helpers.rb +0 -46
- data/vendor/plugins/active_scaffold/lib/active_scaffold/helpers/view_helpers.rb +0 -202
- data/vendor/plugins/active_scaffold/lib/active_scaffold/locale/de.rb +0 -67
- data/vendor/plugins/active_scaffold/lib/active_scaffold/locale/en.rb +0 -67
- data/vendor/plugins/active_scaffold/lib/active_scaffold/locale/es.yml +0 -65
- data/vendor/plugins/active_scaffold/lib/active_scaffold/locale/fr.rb +0 -65
- data/vendor/plugins/active_scaffold/lib/active_scaffold/locale/hu.yml +0 -62
- data/vendor/plugins/active_scaffold/lib/active_scaffold/locale/ja.yml +0 -63
- data/vendor/plugins/active_scaffold/lib/active_scaffold/locale/ru.yml +0 -61
- data/vendor/plugins/active_scaffold/lib/active_scaffold.rb +0 -213
- data/vendor/plugins/active_scaffold/lib/bridges/bridge.rb +0 -52
- data/vendor/plugins/active_scaffold/lib/bridges/calendar_date_select/bridge.rb +0 -11
- data/vendor/plugins/active_scaffold/lib/bridges/calendar_date_select/lib/as_cds_bridge.rb +0 -86
- data/vendor/plugins/active_scaffold/lib/bridges/file_column/bridge.rb +0 -12
- data/vendor/plugins/active_scaffold/lib/bridges/file_column/lib/as_file_column_bridge.rb +0 -49
- data/vendor/plugins/active_scaffold/lib/bridges/file_column/lib/file_column_helpers.rb +0 -51
- data/vendor/plugins/active_scaffold/lib/bridges/file_column/lib/form_ui.rb +0 -32
- data/vendor/plugins/active_scaffold/lib/bridges/file_column/lib/list_ui.rb +0 -26
- data/vendor/plugins/active_scaffold/lib/bridges/file_column/test/functional/file_column_keep_test.rb +0 -43
- data/vendor/plugins/active_scaffold/lib/bridges/file_column/test/mock_model.rb +0 -9
- data/vendor/plugins/active_scaffold/lib/bridges/file_column/test/test_helper.rb +0 -15
- data/vendor/plugins/active_scaffold/lib/bridges/tiny_mce/bridge.rb +0 -5
- data/vendor/plugins/active_scaffold/lib/bridges/tiny_mce/lib/tiny_mce_bridge.rb +0 -45
- data/vendor/plugins/active_scaffold/lib/dhtml_confirm.rb +0 -54
- data/vendor/plugins/active_scaffold/lib/extensions/action_controller_rendering.rb +0 -20
- data/vendor/plugins/active_scaffold/lib/extensions/action_view_rendering.rb +0 -88
- data/vendor/plugins/active_scaffold/lib/extensions/array.rb +0 -7
- data/vendor/plugins/active_scaffold/lib/extensions/component_response_with_namespacing.rb +0 -17
- data/vendor/plugins/active_scaffold/lib/extensions/generic_view_paths.rb +0 -33
- data/vendor/plugins/active_scaffold/lib/extensions/localize.rb +0 -10
- data/vendor/plugins/active_scaffold/lib/extensions/name_option_for_datetime.rb +0 -12
- data/vendor/plugins/active_scaffold/lib/extensions/nil_id_in_url_params.rb +0 -7
- data/vendor/plugins/active_scaffold/lib/extensions/resources.rb +0 -27
- data/vendor/plugins/active_scaffold/lib/extensions/reverse_associations.rb +0 -56
- data/vendor/plugins/active_scaffold/lib/extensions/to_label.rb +0 -8
- data/vendor/plugins/active_scaffold/lib/extensions/unsaved_associated.rb +0 -61
- data/vendor/plugins/active_scaffold/lib/extensions/unsaved_record.rb +0 -20
- data/vendor/plugins/active_scaffold/lib/extensions/usa_state.rb +0 -46
- data/vendor/plugins/active_scaffold/lib/paginator.rb +0 -136
- data/vendor/plugins/active_scaffold/lib/responds_to_parent.rb +0 -68
- data/vendor/plugins/active_scaffold/public/blank.html +0 -33
- data/vendor/plugins/active_scaffold/uninstall.rb +0 -13
- data/vendor/plugins/asset_packager/CHANGELOG +0 -122
- data/vendor/plugins/asset_packager/README +0 -178
- data/vendor/plugins/asset_packager/Rakefile +0 -22
- data/vendor/plugins/asset_packager/about.yml +0 -8
- data/vendor/plugins/asset_packager/init.rb +0 -3
- data/vendor/plugins/asset_packager/install.rb +0 -1
- data/vendor/plugins/asset_packager/lib/jsmin.rb +0 -211
- data/vendor/plugins/asset_packager/lib/synthesis/asset_package.rb +0 -210
- data/vendor/plugins/asset_packager/lib/synthesis/asset_package_helper.rb +0 -39
- data/vendor/plugins/asset_packager/lib/tasks/asset_packager_tasks.rake +0 -23
- data/vendor/plugins/asset_packager/test/asset_package_helper_development_test.rb +0 -102
- data/vendor/plugins/asset_packager/test/asset_package_helper_production_test.rb +0 -142
- data/vendor/plugins/asset_packager/test/asset_packager_test.rb +0 -91
- data/vendor/plugins/asset_packager/test/asset_packages.yml +0 -20
- data/vendor/plugins/asset_packager/test/assets/javascripts/application.js +0 -2
- data/vendor/plugins/asset_packager/test/assets/javascripts/bar.js +0 -4
- data/vendor/plugins/asset_packager/test/assets/javascripts/controls.js +0 -815
- data/vendor/plugins/asset_packager/test/assets/javascripts/dragdrop.js +0 -913
- data/vendor/plugins/asset_packager/test/assets/javascripts/effects.js +0 -958
- data/vendor/plugins/asset_packager/test/assets/javascripts/foo.js +0 -4
- data/vendor/plugins/asset_packager/test/assets/javascripts/prototype.js +0 -2006
- data/vendor/plugins/asset_packager/test/assets/stylesheets/bar.css +0 -16
- data/vendor/plugins/asset_packager/test/assets/stylesheets/foo.css +0 -16
- data/vendor/plugins/asset_packager/test/assets/stylesheets/header.css +0 -16
- data/vendor/plugins/asset_packager/test/assets/stylesheets/screen.css +0 -16
- data/vendor/plugins/asset_packager/test/assets/stylesheets/subdir/bar.css +0 -16
- data/vendor/plugins/asset_packager/test/assets/stylesheets/subdir/foo.css +0 -16
- data/vendor/plugins/exception_notification/README +0 -111
- data/vendor/plugins/exception_notification/init.rb +0 -1
- data/vendor/plugins/exception_notification/lib/exception_notifiable.rb +0 -99
- data/vendor/plugins/exception_notification/lib/exception_notifier.rb +0 -66
- data/vendor/plugins/exception_notification/lib/exception_notifier_helper.rb +0 -78
- data/vendor/plugins/exception_notification/test/exception_notifier_helper_test.rb +0 -61
- data/vendor/plugins/exception_notification/test/test_helper.rb +0 -7
- data/vendor/plugins/exception_notification/views/exception_notifier/_backtrace.rhtml +0 -1
- data/vendor/plugins/exception_notification/views/exception_notifier/_environment.rhtml +0 -7
- data/vendor/plugins/exception_notification/views/exception_notifier/_inspect_model.rhtml +0 -16
- data/vendor/plugins/exception_notification/views/exception_notifier/_request.rhtml +0 -4
- data/vendor/plugins/exception_notification/views/exception_notifier/_session.rhtml +0 -2
- data/vendor/plugins/exception_notification/views/exception_notifier/_title.rhtml +0 -3
- data/vendor/plugins/exception_notification/views/exception_notifier/exception_notification.rhtml +0 -6
- data/vendor/plugins/required_attributes/MIT-LICENSE +0 -20
- data/vendor/plugins/required_attributes/README +0 -13
- data/vendor/plugins/required_attributes/Rakefile +0 -22
- data/vendor/plugins/required_attributes/init.rb +0 -1
- data/vendor/plugins/required_attributes/install.rb +0 -1
- data/vendor/plugins/required_attributes/lib/required_attributes.rb +0 -68
- data/vendor/plugins/required_attributes/required_attributes/MIT-LICENSE +0 -20
- data/vendor/plugins/required_attributes/required_attributes/README +0 -13
- data/vendor/plugins/required_attributes/required_attributes/Rakefile +0 -22
- data/vendor/plugins/required_attributes/required_attributes/init.rb +0 -1
- data/vendor/plugins/required_attributes/required_attributes/install.rb +0 -1
- data/vendor/plugins/required_attributes/required_attributes/lib/required_attributes.rb +0 -68
- data/vendor/plugins/required_attributes/required_attributes/tasks/required_attributes_tasks.rake +0 -4
- data/vendor/plugins/required_attributes/required_attributes/uninstall.rb +0 -1
- data/vendor/plugins/required_attributes/tasks/required_attributes_tasks.rake +0 -4
- data/vendor/plugins/required_attributes/uninstall.rb +0 -1
@@ -1,59 +0,0 @@
|
|
1
|
-
module Authlogic
|
2
|
-
module Session
|
3
|
-
# Authlogic tries to check the state of the record before creating the session. If your record responds to the following methods and any of them return false, validation will fail:
|
4
|
-
#
|
5
|
-
# Method name Description
|
6
|
-
# active? Is the record marked as active?
|
7
|
-
# approved? Has the record been approved?
|
8
|
-
# confirmed? Has the record been conirmed?
|
9
|
-
#
|
10
|
-
# Authlogic does nothing to define these methods for you, its up to you to define what they mean. If your object responds to these methods Authlogic will use them, otherwise they are ignored.
|
11
|
-
#
|
12
|
-
# What's neat about this is that these are checked upon any type of login. When logging in explicitly, by cookie, session, or basic http auth.
|
13
|
-
# So if you mark a user inactive in the middle of their session they wont be logged back in next time they refresh the page. Giving you complete control.
|
14
|
-
#
|
15
|
-
# Need Authlogic to check your own "state"? No problem, check out the hooks section below. Add in a before_validation to do your own checking. The sky is the limit.
|
16
|
-
module MagicStates
|
17
|
-
def self.included(klass)
|
18
|
-
klass.class_eval do
|
19
|
-
extend Config
|
20
|
-
include InstanceMethods
|
21
|
-
validate :validate_magic_states, :unless => :disable_magic_states?
|
22
|
-
end
|
23
|
-
end
|
24
|
-
|
25
|
-
# Configuration for the magic states feature.
|
26
|
-
module Config
|
27
|
-
# Set this to true if you want to disable the checking of active?, approved?, and confirmed? on your record. This is more or less of a
|
28
|
-
# convenience feature, since 99% of the time if those methods exist and return false you will not want the user logging in. You could
|
29
|
-
# easily accomplish this same thing with a before_validation method or other callbacks.
|
30
|
-
#
|
31
|
-
# * <tt>Default:</tt> false
|
32
|
-
# * <tt>Accepts:</tt> Boolean
|
33
|
-
def disable_magic_states(value = nil)
|
34
|
-
rw_config(:disable_magic_states, value, false)
|
35
|
-
end
|
36
|
-
alias_method :disable_magic_states=, :disable_magic_states
|
37
|
-
end
|
38
|
-
|
39
|
-
# The methods available for an Authlogic::Session::Base object that make up the magic states feature.
|
40
|
-
module InstanceMethods
|
41
|
-
private
|
42
|
-
def disable_magic_states?
|
43
|
-
self.class.disable_magic_states == true
|
44
|
-
end
|
45
|
-
|
46
|
-
def validate_magic_states
|
47
|
-
return true if attempted_record.nil?
|
48
|
-
[:active, :approved, :confirmed].each do |required_status|
|
49
|
-
if attempted_record.respond_to?("#{required_status}?") && !attempted_record.send("#{required_status}?")
|
50
|
-
errors.add(:base, I18n.t("error_messages.not_#{required_status}", :default => "Your account is not #{required_status}"))
|
51
|
-
return false
|
52
|
-
end
|
53
|
-
end
|
54
|
-
true
|
55
|
-
end
|
56
|
-
end
|
57
|
-
end
|
58
|
-
end
|
59
|
-
end
|
@@ -1,101 +0,0 @@
|
|
1
|
-
module Authlogic
|
2
|
-
module Session
|
3
|
-
# This module is responsible for authenticating the user via params, which ultimately allows the user to log in using a URL like the following:
|
4
|
-
#
|
5
|
-
# https://www.domain.com?user_credentials=4LiXF7FiGUppIPubBPey
|
6
|
-
#
|
7
|
-
# Notice the token in the URL, this is a single access token. A single access token is used for single access only, it is not persisted. Meaning the user
|
8
|
-
# provides it, Authlogic grants them access, and that's it. If they want access again they need to provide the token again. Authlogic will
|
9
|
-
# *NEVER* try to persist the session after authenticating through this method.
|
10
|
-
#
|
11
|
-
# For added security, this token is *ONLY* allowed for RSS and ATOM requests. You can change this with the configuration. You can also define if
|
12
|
-
# it is allowed dynamically by defining a single_access_allowed? method in your controller. For example:
|
13
|
-
#
|
14
|
-
# class UsersController < ApplicationController
|
15
|
-
# private
|
16
|
-
# def single_access_allowed?
|
17
|
-
# action_name == "index"
|
18
|
-
# end
|
19
|
-
#
|
20
|
-
# Also, by default, this token is permanent. Meaning if the user changes their password, this token will remain the same. It will only change
|
21
|
-
# when it is explicitly reset.
|
22
|
-
#
|
23
|
-
# You can modify all of this behavior with the Config sub module.
|
24
|
-
module Params
|
25
|
-
def self.included(klass)
|
26
|
-
klass.class_eval do
|
27
|
-
extend Config
|
28
|
-
include InstanceMethods
|
29
|
-
attr_accessor :single_access
|
30
|
-
persist :persist_by_params
|
31
|
-
end
|
32
|
-
end
|
33
|
-
|
34
|
-
# Configuration for the params / single access feature.
|
35
|
-
module Config
|
36
|
-
# Works exactly like cookie_key, but for params. So a user can login via params just like a cookie or a session. Your URL would look like:
|
37
|
-
#
|
38
|
-
# http://www.domain.com?user_credentials=my_single_access_key
|
39
|
-
#
|
40
|
-
# You can change the "user_credentials" key above with this configuration option. Keep in mind, just like cookie_key, if you supply an id
|
41
|
-
# the id will be appended to the front. Check out cookie_key for more details. Also checkout the "Single Access / Private Feeds Access" section in the README.
|
42
|
-
#
|
43
|
-
# * <tt>Default:</tt> cookie_key
|
44
|
-
# * <tt>Accepts:</tt> String
|
45
|
-
def params_key(value = nil)
|
46
|
-
rw_config(:params_key, value, cookie_key)
|
47
|
-
end
|
48
|
-
alias_method :params_key=, :params_key
|
49
|
-
|
50
|
-
# Authentication is allowed via a single access token, but maybe this is something you don't want for your application as a whole. Maybe this is
|
51
|
-
# something you only want for specific request types. Specify a list of allowed request types and single access authentication will only be
|
52
|
-
# allowed for the ones you specify.
|
53
|
-
#
|
54
|
-
# * <tt>Default:</tt> ["application/rss+xml", "application/atom+xml"]
|
55
|
-
# * <tt>Accepts:</tt> String of a request type, or :all or :any to allow single access authentication for any and all request types
|
56
|
-
def single_access_allowed_request_types(value = nil)
|
57
|
-
rw_config(:single_access_allowed_request_types, value, ["application/rss+xml", "application/atom+xml"])
|
58
|
-
end
|
59
|
-
alias_method :single_access_allowed_request_types=, :single_access_allowed_request_types
|
60
|
-
end
|
61
|
-
|
62
|
-
# The methods available for an Authlogic::Session::Base object that make up the params / single access feature.
|
63
|
-
module InstanceMethods
|
64
|
-
private
|
65
|
-
def persist_by_params
|
66
|
-
return false if !params_enabled?
|
67
|
-
self.unauthorized_record = search_for_record("find_by_single_access_token", params_credentials)
|
68
|
-
self.single_access = valid?
|
69
|
-
end
|
70
|
-
|
71
|
-
def params_enabled?
|
72
|
-
return false if !params_credentials || !klass.column_names.include?("single_access_token")
|
73
|
-
return controller.single_access_allowed? if controller.responds_to_single_access_allowed?
|
74
|
-
|
75
|
-
case single_access_allowed_request_types
|
76
|
-
when Array
|
77
|
-
single_access_allowed_request_types.include?(controller.request_content_type) || single_access_allowed_request_types.include?(:all)
|
78
|
-
else
|
79
|
-
[:all, :any].include?(single_access_allowed_request_types)
|
80
|
-
end
|
81
|
-
end
|
82
|
-
|
83
|
-
def params_key
|
84
|
-
build_key(self.class.params_key)
|
85
|
-
end
|
86
|
-
|
87
|
-
def single_access?
|
88
|
-
single_access == true
|
89
|
-
end
|
90
|
-
|
91
|
-
def single_access_allowed_request_types
|
92
|
-
self.class.single_access_allowed_request_types
|
93
|
-
end
|
94
|
-
|
95
|
-
def params_credentials
|
96
|
-
controller.params[params_key]
|
97
|
-
end
|
98
|
-
end
|
99
|
-
end
|
100
|
-
end
|
101
|
-
end
|
@@ -1,240 +0,0 @@
|
|
1
|
-
module Authlogic
|
2
|
-
module Session
|
3
|
-
# Handles authenticating via a traditional username and password.
|
4
|
-
module Password
|
5
|
-
def self.included(klass)
|
6
|
-
klass.class_eval do
|
7
|
-
extend Config
|
8
|
-
include InstanceMethods
|
9
|
-
validate :validate_by_password, :if => :authenticating_with_password?
|
10
|
-
|
11
|
-
class << self
|
12
|
-
attr_accessor :configured_password_methods
|
13
|
-
end
|
14
|
-
end
|
15
|
-
end
|
16
|
-
|
17
|
-
# Password configuration
|
18
|
-
module Config
|
19
|
-
# Authlogic tries to validate the credentials passed to it. One part of validation is actually finding the user and
|
20
|
-
# making sure it exists. What method it uses the do this is up to you.
|
21
|
-
#
|
22
|
-
# Let's say you have a UserSession that is authenticating a User. By default UserSession will call User.find_by_login(login).
|
23
|
-
# You can change what method UserSession calls by specifying it here. Then in your User model you can make that method do
|
24
|
-
# anything you want, giving you complete control of how users are found by the UserSession.
|
25
|
-
#
|
26
|
-
# Let's take an example: You want to allow users to login by username or email. Set this to the name of the class method
|
27
|
-
# that does this in the User model. Let's call it "find_by_username_or_email"
|
28
|
-
#
|
29
|
-
# class User < ActiveRecord::Base
|
30
|
-
# def self.find_by_username_or_email(login)
|
31
|
-
# find_by_username(login) || find_by_email(login)
|
32
|
-
# end
|
33
|
-
# end
|
34
|
-
#
|
35
|
-
# Now just specify the name of this method for this configuration option and you are all set. You can do anything you
|
36
|
-
# want here. Maybe you allow users to have multiple logins and you want to search a has_many relationship, etc. The sky is the limit.
|
37
|
-
#
|
38
|
-
# * <tt>Default:</tt> "find_by_smart_case_login_field"
|
39
|
-
# * <tt>Accepts:</tt> Symbol or String
|
40
|
-
def find_by_login_method(value = nil)
|
41
|
-
rw_config(:find_by_login_method, value, "find_by_smart_case_login_field")
|
42
|
-
end
|
43
|
-
alias_method :find_by_login_method=, :find_by_login_method
|
44
|
-
|
45
|
-
# The text used to identify credentials (username/password) combination when a bad login attempt occurs.
|
46
|
-
# When you show error messages for a bad login, it's considered good security practice to hide which field
|
47
|
-
# the user has entered incorrectly (the login field or the password field). For a full explanation, see
|
48
|
-
# http://www.gnucitizen.org/blog/username-enumeration-vulnerabilities/
|
49
|
-
#
|
50
|
-
# Example of use:
|
51
|
-
#
|
52
|
-
# class UserSession < Authlogic::Session::Base
|
53
|
-
# generalize_credentials_error_messages true
|
54
|
-
# end
|
55
|
-
#
|
56
|
-
# This would make the error message for bad logins and bad passwords look identical:
|
57
|
-
#
|
58
|
-
# Login/Password combination is not valid
|
59
|
-
#
|
60
|
-
# Alternatively you may use a custom message:
|
61
|
-
#
|
62
|
-
# class UserSession < AuthLogic::Session::Base
|
63
|
-
# generalize_credentials_error_messages "Your login information is invalid"
|
64
|
-
# end
|
65
|
-
#
|
66
|
-
# This will instead show your custom error message when the UserSession is invalid.
|
67
|
-
#
|
68
|
-
# The downside to enabling this is that is can be too vague for a user that has a hard time remembering
|
69
|
-
# their username and password combinations. It also disables the ability to to highlight the field
|
70
|
-
# with the error when you use form_for.
|
71
|
-
#
|
72
|
-
# If you are developing an app where security is an extreme priority (such as a financial application),
|
73
|
-
# then you should enable this. Otherwise, leaving this off is fine.
|
74
|
-
#
|
75
|
-
# * <tt>Default</tt> false
|
76
|
-
# * <tt>Accepts:</tt> Boolean
|
77
|
-
def generalize_credentials_error_messages(value = nil)
|
78
|
-
rw_config(:generalize_credentials_error_messages, value, false)
|
79
|
-
end
|
80
|
-
alias_method :generalize_credentials_error_messages=, :generalize_credentials_error_messages
|
81
|
-
|
82
|
-
# The name of the method you want Authlogic to create for storing the login / username. Keep in mind this is just for your
|
83
|
-
# Authlogic::Session, if you want it can be something completely different than the field in your model. So if you wanted people to
|
84
|
-
# login with a field called "login" and then find users by email this is compeltely doable. See the find_by_login_method configuration
|
85
|
-
# option for more details.
|
86
|
-
#
|
87
|
-
# * <tt>Default:</tt> klass.login_field || klass.email_field
|
88
|
-
# * <tt>Accepts:</tt> Symbol or String
|
89
|
-
def login_field(value = nil)
|
90
|
-
rw_config(:login_field, value, klass.login_field || klass.email_field)
|
91
|
-
end
|
92
|
-
alias_method :login_field=, :login_field
|
93
|
-
|
94
|
-
# Works exactly like login_field, but for the password instead. Returns :password if a login_field exists.
|
95
|
-
#
|
96
|
-
# * <tt>Default:</tt> :password
|
97
|
-
# * <tt>Accepts:</tt> Symbol or String
|
98
|
-
def password_field(value = nil)
|
99
|
-
rw_config(:password_field, value, login_field && :password)
|
100
|
-
end
|
101
|
-
alias_method :password_field=, :password_field
|
102
|
-
|
103
|
-
# The name of the method in your model used to verify the password. This should be an instance method. It should also
|
104
|
-
# be prepared to accept a raw password and a crytped password.
|
105
|
-
#
|
106
|
-
# * <tt>Default:</tt> "valid_password?"
|
107
|
-
# * <tt>Accepts:</tt> Symbol or String
|
108
|
-
def verify_password_method(value = nil)
|
109
|
-
rw_config(:verify_password_method, value, "valid_password?")
|
110
|
-
end
|
111
|
-
alias_method :verify_password_method=, :verify_password_method
|
112
|
-
end
|
113
|
-
|
114
|
-
# Password related instance methods
|
115
|
-
module InstanceMethods
|
116
|
-
def initialize(*args)
|
117
|
-
if !self.class.configured_password_methods
|
118
|
-
if login_field
|
119
|
-
self.class.send(:attr_writer, login_field) if !respond_to?("#{login_field}=")
|
120
|
-
self.class.send(:attr_reader, login_field) if !respond_to?(login_field)
|
121
|
-
end
|
122
|
-
|
123
|
-
if password_field
|
124
|
-
self.class.send(:attr_writer, password_field) if !respond_to?("#{password_field}=")
|
125
|
-
self.class.send(:define_method, password_field) {} if !respond_to?(password_field)
|
126
|
-
|
127
|
-
self.class.class_eval <<-"end_eval", __FILE__, __LINE__
|
128
|
-
private
|
129
|
-
# The password should not be accessible publicly. This way forms using form_for don't fill the password with the
|
130
|
-
# attempted password. To prevent this we just create this method that is private.
|
131
|
-
def protected_#{password_field}
|
132
|
-
@#{password_field}
|
133
|
-
end
|
134
|
-
end_eval
|
135
|
-
end
|
136
|
-
|
137
|
-
self.class.configured_password_methods = true
|
138
|
-
end
|
139
|
-
|
140
|
-
super
|
141
|
-
end
|
142
|
-
|
143
|
-
# Returns the login_field / password_field credentials combination in hash form.
|
144
|
-
def credentials
|
145
|
-
if authenticating_with_password?
|
146
|
-
details = {}
|
147
|
-
details[login_field.to_sym] = send(login_field)
|
148
|
-
details[password_field.to_sym] = "<protected>"
|
149
|
-
details
|
150
|
-
else
|
151
|
-
super
|
152
|
-
end
|
153
|
-
end
|
154
|
-
|
155
|
-
# Accepts the login_field / password_field credentials combination in hash form.
|
156
|
-
def credentials=(value)
|
157
|
-
super
|
158
|
-
values = value.is_a?(Array) ? value : [value]
|
159
|
-
if values.first.is_a?(Hash)
|
160
|
-
values.first.with_indifferent_access.slice(login_field, password_field).each do |field, value|
|
161
|
-
next if value.blank?
|
162
|
-
send("#{field}=", value)
|
163
|
-
end
|
164
|
-
end
|
165
|
-
end
|
166
|
-
|
167
|
-
def invalid_password?
|
168
|
-
invalid_password == true
|
169
|
-
end
|
170
|
-
|
171
|
-
private
|
172
|
-
def authenticating_with_password?
|
173
|
-
login_field && (!send(login_field).nil? || !send("protected_#{password_field}").nil?)
|
174
|
-
end
|
175
|
-
|
176
|
-
def validate_by_password
|
177
|
-
self.invalid_password = false
|
178
|
-
|
179
|
-
errors.add(login_field, I18n.t('error_messages.login_blank', :default => "cannot be blank")) if send(login_field).blank?
|
180
|
-
errors.add(password_field, I18n.t('error_messages.password_blank', :default => "cannot be blank")) if send("protected_#{password_field}").blank?
|
181
|
-
return if errors.count > 0
|
182
|
-
|
183
|
-
self.attempted_record = search_for_record(find_by_login_method, send(login_field))
|
184
|
-
if attempted_record.blank?
|
185
|
-
generalize_credentials_error_messages? ?
|
186
|
-
add_general_credentials_error :
|
187
|
-
errors.add(login_field, I18n.t('error_messages.login_not_found', :default => "is not valid"))
|
188
|
-
return
|
189
|
-
end
|
190
|
-
|
191
|
-
if !attempted_record.send(verify_password_method, send("protected_#{password_field}"))
|
192
|
-
self.invalid_password = true
|
193
|
-
generalize_credentials_error_messages? ?
|
194
|
-
add_general_credentials_error :
|
195
|
-
errors.add(password_field, I18n.t('error_messages.password_invalid', :default => "is not valid"))
|
196
|
-
return
|
197
|
-
end
|
198
|
-
end
|
199
|
-
|
200
|
-
def invalid_password
|
201
|
-
@invalid_password
|
202
|
-
end
|
203
|
-
|
204
|
-
def invalid_password=(value)
|
205
|
-
@invalid_password = value
|
206
|
-
end
|
207
|
-
|
208
|
-
def find_by_login_method
|
209
|
-
self.class.find_by_login_method
|
210
|
-
end
|
211
|
-
|
212
|
-
def login_field
|
213
|
-
self.class.login_field
|
214
|
-
end
|
215
|
-
|
216
|
-
def add_general_credentials_error
|
217
|
-
error_message =
|
218
|
-
if self.class.generalize_credentials_error_messages.is_a? String
|
219
|
-
self.class.generalize_credentials_error_messages
|
220
|
-
else
|
221
|
-
"#{login_field.to_s.humanize}/Password combination is not valid"
|
222
|
-
end
|
223
|
-
errors.add(:base, I18n.t('error_messages.general_credentials_error', :default => error_message))
|
224
|
-
end
|
225
|
-
|
226
|
-
def generalize_credentials_error_messages?
|
227
|
-
self.class.generalize_credentials_error_messages
|
228
|
-
end
|
229
|
-
|
230
|
-
def password_field
|
231
|
-
self.class.password_field
|
232
|
-
end
|
233
|
-
|
234
|
-
def verify_password_method
|
235
|
-
self.class.verify_password_method
|
236
|
-
end
|
237
|
-
end
|
238
|
-
end
|
239
|
-
end
|
240
|
-
end
|
@@ -1,18 +0,0 @@
|
|
1
|
-
module Authlogic
|
2
|
-
module Session
|
3
|
-
# Maintains the perishable token, which is helpful for confirming records or authorizing records to reset their password. All that this
|
4
|
-
# module does is reset it after a session have been saved, just keep it changing. The more it changes, the tighter the security.
|
5
|
-
#
|
6
|
-
# See Authlogic::ActsAsAuthentic::PerishableToken for more information.
|
7
|
-
module PerishableToken
|
8
|
-
def self.included(klass)
|
9
|
-
klass.after_save :reset_perishable_token!
|
10
|
-
end
|
11
|
-
|
12
|
-
private
|
13
|
-
def reset_perishable_token!
|
14
|
-
record.reset_perishable_token if record.respond_to?(:reset_perishable_token) && !record.disable_perishable_token_maintenance?
|
15
|
-
end
|
16
|
-
end
|
17
|
-
end
|
18
|
-
end
|
@@ -1,70 +0,0 @@
|
|
1
|
-
module Authlogic
|
2
|
-
module Session
|
3
|
-
# Responsible for allowing you to persist your sessions.
|
4
|
-
module Persistence
|
5
|
-
def self.included(klass)
|
6
|
-
klass.class_eval do
|
7
|
-
extend ClassMethods
|
8
|
-
include InstanceMethods
|
9
|
-
end
|
10
|
-
end
|
11
|
-
|
12
|
-
module ClassMethods
|
13
|
-
# This is how you persist a session. This finds the record for the current session using
|
14
|
-
# a variety of methods. It basically tries to "log in" the user without the user having
|
15
|
-
# to explicitly log in. Check out the other Authlogic::Session modules for more information.
|
16
|
-
#
|
17
|
-
# The best way to use this method is something like:
|
18
|
-
#
|
19
|
-
# helper_method :current_user_session, :current_user
|
20
|
-
#
|
21
|
-
# def current_user_session
|
22
|
-
# return @current_user_session if defined?(@current_user_session)
|
23
|
-
# @current_user_session = UserSession.find
|
24
|
-
# end
|
25
|
-
#
|
26
|
-
# def current_user
|
27
|
-
# return @current_user if defined?(@current_user)
|
28
|
-
# @current_user = current_user_session && current_user_session.user
|
29
|
-
# end
|
30
|
-
#
|
31
|
-
# Also, this method accepts a single parameter as the id, to find session that you marked with an id:
|
32
|
-
#
|
33
|
-
# UserSession.find(:secure)
|
34
|
-
#
|
35
|
-
# See the id method for more information on ids.
|
36
|
-
def find(id = nil, priority_record = nil)
|
37
|
-
session = new({:priority_record => priority_record}, id)
|
38
|
-
session.priority_record = priority_record
|
39
|
-
if session.persisting?
|
40
|
-
session
|
41
|
-
else
|
42
|
-
nil
|
43
|
-
end
|
44
|
-
end
|
45
|
-
end
|
46
|
-
|
47
|
-
module InstanceMethods
|
48
|
-
# Let's you know if the session is being persisted or not, meaning the user does not have to explicitly log in
|
49
|
-
# in order to be logged in. If the session has no associated record, it will try to find a record and persis
|
50
|
-
# the session. This is the method that the class level method find uses to ultimately persist the session.
|
51
|
-
def persisting?
|
52
|
-
return true if !record.nil?
|
53
|
-
self.attempted_record = nil
|
54
|
-
before_persisting
|
55
|
-
persist
|
56
|
-
ensure_authentication_attempted
|
57
|
-
if errors.empty? && !attempted_record.nil?
|
58
|
-
self.record = attempted_record
|
59
|
-
after_persisting
|
60
|
-
save_record
|
61
|
-
self.new_session = false
|
62
|
-
true
|
63
|
-
else
|
64
|
-
false
|
65
|
-
end
|
66
|
-
end
|
67
|
-
end
|
68
|
-
end
|
69
|
-
end
|
70
|
-
end
|
@@ -1,34 +0,0 @@
|
|
1
|
-
module Authlogic
|
2
|
-
module Session
|
3
|
-
# The point of this module is to avoid the StaleObjectError raised when lock_version is implemented in ActiveRecord.
|
4
|
-
# We accomplish this by using a "priority record". Meaning this record is used if possible, it gets priority.
|
5
|
-
# This way we don't save a record behind the scenes thus making an object being used stale.
|
6
|
-
module PriorityRecord
|
7
|
-
def self.included(klass)
|
8
|
-
klass.class_eval do
|
9
|
-
attr_accessor :priority_record
|
10
|
-
end
|
11
|
-
end
|
12
|
-
|
13
|
-
# Setting priority record if it is passed. The only way it can be passed is through an array:
|
14
|
-
#
|
15
|
-
# session.credentials = [real_user_object, priority_user_object]
|
16
|
-
def credentials=(value)
|
17
|
-
super
|
18
|
-
values = value.is_a?(Array) ? value : [value]
|
19
|
-
self.priority_record = values[1] if values[1].class < ::ActiveRecord::Base
|
20
|
-
end
|
21
|
-
|
22
|
-
private
|
23
|
-
def attempted_record=(value)
|
24
|
-
value = priority_record if value == priority_record
|
25
|
-
super
|
26
|
-
end
|
27
|
-
|
28
|
-
def save_record(alternate_record = nil)
|
29
|
-
r = alternate_record || record
|
30
|
-
super if r != priority_record
|
31
|
-
end
|
32
|
-
end
|
33
|
-
end
|
34
|
-
end
|
@@ -1,101 +0,0 @@
|
|
1
|
-
module Authlogic
|
2
|
-
module Session
|
3
|
-
# Authentication can be scoped, and it's easy, you just need to define how you want to scope everything. This should help you:
|
4
|
-
#
|
5
|
-
# 1. Want to scope by a parent object? Ex: An account has many users. Checkout Authlogic::AuthenticatesMany
|
6
|
-
# 2. Want to scope the validations in your model? Ex: 2 users can have the same login under different accounts. See Authlogic::ActsAsAuthentic::Scope
|
7
|
-
module Scopes # :nodoc:
|
8
|
-
def self.included(klass)
|
9
|
-
klass.class_eval do
|
10
|
-
extend ClassMethods
|
11
|
-
include InstanceMethods
|
12
|
-
attr_writer :scope
|
13
|
-
end
|
14
|
-
end
|
15
|
-
|
16
|
-
# = Scopes
|
17
|
-
module ClassMethods
|
18
|
-
# The current scope set, should be used in the block passed to with_scope.
|
19
|
-
def scope
|
20
|
-
Thread.current[:authlogic_scope]
|
21
|
-
end
|
22
|
-
|
23
|
-
# What with_scopes focuses on is scoping the query when finding the object and the name of the cookie / session. It works very similar to
|
24
|
-
# ActiveRecord::Base#with_scopes. It accepts a hash with any of the following options:
|
25
|
-
#
|
26
|
-
# * <tt>find_options:</tt> any options you can pass into ActiveRecord::Base.find. This is used when trying to find the record.
|
27
|
-
# * <tt>id:</tt> The id of the session, this gets merged with the real id. For information ids see the id method.
|
28
|
-
#
|
29
|
-
# Here is how you use it:
|
30
|
-
#
|
31
|
-
# UserSession.with_scope(:find_options => {:conditions => "account_id = 2"}, :id => "account_2") do
|
32
|
-
# UserSession.find
|
33
|
-
# end
|
34
|
-
#
|
35
|
-
# Eseentially what the above does is scope the searching of the object with the sql you provided. So instead of:
|
36
|
-
#
|
37
|
-
# User.find(:first, :conditions => "login = 'ben'")
|
38
|
-
#
|
39
|
-
# it would be:
|
40
|
-
#
|
41
|
-
# User.find(:first, :conditions => "login = 'ben' and account_id = 2")
|
42
|
-
#
|
43
|
-
# You will also notice the :id option. This works just like the id method. It scopes your cookies. So the name of your cookie will be:
|
44
|
-
#
|
45
|
-
# account_2_user_credentials
|
46
|
-
#
|
47
|
-
# instead of:
|
48
|
-
#
|
49
|
-
# user_credentials
|
50
|
-
#
|
51
|
-
# What is also nifty about scoping with an :id is that it merges your id's. So if you do:
|
52
|
-
#
|
53
|
-
# UserSession.with_scope(:find_options => {:conditions => "account_id = 2"}, :id => "account_2") do
|
54
|
-
# session = UserSession.new
|
55
|
-
# session.id = :secure
|
56
|
-
# end
|
57
|
-
#
|
58
|
-
# The name of your cookies will be:
|
59
|
-
#
|
60
|
-
# secure_account_2_user_credentials
|
61
|
-
def with_scope(options = {}, &block)
|
62
|
-
raise ArgumentError.new("You must provide a block") unless block_given?
|
63
|
-
self.scope = options
|
64
|
-
result = yield
|
65
|
-
self.scope = nil
|
66
|
-
result
|
67
|
-
end
|
68
|
-
|
69
|
-
private
|
70
|
-
def scope=(value)
|
71
|
-
Thread.current[:authlogic_scope] = value
|
72
|
-
end
|
73
|
-
end
|
74
|
-
|
75
|
-
module InstanceMethods
|
76
|
-
# Setting the scope if it exists upon instantiation.
|
77
|
-
def initialize(*args)
|
78
|
-
self.scope = self.class.scope
|
79
|
-
super
|
80
|
-
end
|
81
|
-
|
82
|
-
# The scope of the current object
|
83
|
-
def scope
|
84
|
-
@scope ||= {}
|
85
|
-
end
|
86
|
-
|
87
|
-
private
|
88
|
-
# Used for things like cookie_key, session_key, etc.
|
89
|
-
def build_key(last_part)
|
90
|
-
[scope[:id], super].compact.join("_")
|
91
|
-
end
|
92
|
-
|
93
|
-
def search_for_record(*args)
|
94
|
-
klass.send(:with_scope, :find => (scope[:find_options] || {})) do
|
95
|
-
klass.send(*args)
|
96
|
-
end
|
97
|
-
end
|
98
|
-
end
|
99
|
-
end
|
100
|
-
end
|
101
|
-
end
|