Jacques Crocker
6d31e368bf
Use persisted? instead of new_record?
...
In order to be more ActiveModel compliant, lets use persisted? whereever we can. Particularly for datamapper, new_record? causes api warnings. Better to stick to the ActiveModel api I think.
2010-03-28 20:53:13 -07:00
José Valim
2a082f3e4c
Fix some unlockable bugs.
2010-03-28 23:09:28 +02:00
José Valim
033db1ca7c
Do not depend on silence_missing_strategies! anymore. This speeds up strategies matching because we don't need to check if the model duck types to the strategy and it doesn't trigger uneeded strategies.
2010-03-28 14:55:05 +02:00
José Valim
066c6e8771
Do not force halt on authenticatable. This allows other strategies (like devise_imapable or even devise_facebook_connectable) to hook into sessions controller as well.
...
Those strategies should follow the same convention, allowing them to be cascated.
2010-03-28 12:52:12 +02:00
José Valim
96c8238b02
Remove duplicated method.
2010-03-28 07:24:56 +02:00
José Valim
4b7a9204b8
More configuration to validatable.
2010-03-28 07:19:23 +02:00
José Valim
ea71be8d2a
More compatibility with Rails master.
2010-03-28 07:15:52 +02:00
Jacques Crocker
6bcf18b04f
Mongoid support cleanup
...
moving test specific == override part of the test models and not part of the Compatibility module included in all Mongoid docs. Made sure that nothing in devise itself uses this == between 2 different models, its purely for assert_equal
2010-03-27 16:16:36 -07:00
Jacques Crocker
bb504e08aa
Initial Datamapper test suite
...
Test suite runs, however there's still some failing tests. This allows us to at least have a working test suite so they can fix these datamapper spec failures individually.
2010-03-27 16:15:23 -07:00
Jacques Crocker
afe6a8c8c8
Merge branch 'master' of git://github.com/plataformatec/devise
2010-03-27 16:10:30 -07:00
José Valim
a53cc74fd9
Revert "Move password_required? to authenticatable. This allow you to reuse it when building your own validations."
...
This reverts commit 386e7be823 .
2010-03-27 12:31:38 +01:00
Jacques Crocker
fd035b841b
Additional configuration for validatable
...
Added the ability to customize password length (via Devise.password_length) and the regular expression used for validating email (via Devise.email_regex)
2010-03-26 13:52:12 -07:00
Jacques Crocker
e127463ac8
Adding Mongoid 2.0 Support, Removing MongoMapper for now
2010-03-26 13:37:38 -07:00
José Valim
bd4b29c0fd
sign_in_count shoud default to zero.
2010-03-26 12:56:24 +01:00
Carlos Antonio da Silva
6f41284714
Merge branch 'master' of github.com:plataformatec/devise
2010-03-26 08:44:42 -03:00
Carlos Antonio da Silva
a5ba2ac1a8
Use prepend_before_filter in require_no_authentication.
...
We need to be sure require_no_authentication runs before other user filters that may call some Devise helper (ie current_xxx).
Conflicts:
app/controllers/devise/passwords_controller.rb
app/controllers/devise/registrations_controller.rb
app/controllers/devise/sessions_controller.rb
app/controllers/devise/unlocks_controller.rb
lib/devise/controllers/internal_helpers.rb
test/rails_app/app/controllers/application_controller.rb
2010-03-26 08:26:51 -03:00
José Valim
386e7be823
Move password_required? to authenticatable. This allow you to reuse it when building your own validations.
2010-03-26 12:19:01 +01:00
José Valim
e136573905
Improve workflow with devise generator.
2010-03-26 10:36:15 +01:00
José Valim
ae729aedc3
Allow devise to work with association proxies.
2010-03-26 10:19:31 +01:00
José Valim
12b64c691f
Add support to multipart e-mails (just put them in your mailers folder) and headers customization by simply defining headers_for in your model.
2010-03-26 10:01:24 +01:00
José Valim
76e45ecb12
Bring unloadable back.
2010-03-23 00:39:27 +01:00
José Valim
8fbbe34bdd
Fix routes generation on Rails master.
2010-03-16 14:48:30 +01:00
José Valim
3a84fd4f3f
Ensure devise_views is always executed.
2010-03-16 02:51:59 +01:00
Ørjan Blom
f129b9ffd7
don't use a static name in a public directory, and delete after use.
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-14 15:02:54 +01:00
José Valim
185541b9e4
Use template engine as option since it's the one used by rails.
2010-03-14 09:39:59 +01:00
Fred Wu
de92be39f2
Use Ruby's tmp directory instead of a ghost directory inside the devise gem folder.
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-14 09:25:57 +01:00
Fred Wu
3f85fa88c3
Use 'rescue' to ensure the presence of Haml.
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-14 09:25:52 +01:00
Fred Wu
2ebbc30540
Made sure no deprecated HAML templates (in case any) will get copied over.
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-14 09:25:45 +01:00
Fred Wu
b8091928a0
A more user friendly way of checking the existence of Haml.
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-14 09:25:39 +01:00
Fred Wu
cbd35a846a
Added verification for HAML >= 2.3.
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-14 09:25:31 +01:00
Fred Wu
90e8253205
Added HAML as a template engine option to devise_views generator (-t or --engine). HAML files are created based on the erb files on the fly using 'html2haml' command that comes with HAML.
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-14 09:25:19 +01:00
José Valim
3f0bae1968
Allow to give :skip in devise_for to skip routes for an specific controller.
2010-03-12 09:54:57 +01:00
José Valim
59b26d8427
All tests pass using Rails master.
2010-03-11 18:39:32 +01:00
José Valim
cbc3747039
No need to check if app.routes.url_helpers exists. I.e. Devise master now *requires* Rails master (aka beta1).
2010-03-10 08:59:22 -07:00
José Valim
ed3a460bad
Allow to give a scope when copying views.
2010-03-10 16:53:09 +01:00
José Valim
ac742e3271
Clean up lockable and class methods API.
2010-03-10 16:13:54 +01:00
Fred Wu
cd17099401
Create the devise_views directory in './app/views' instead of the root.
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-10 15:29:30 +01:00
José Valim
829c85631b
Aim for Rails 3.0.0.beta1 compatibility. A few issues are still pending with Warden.
2010-03-10 15:00:12 +01:00
Ørjan Blom
1a740774e3
use Devise.encryptor setting when creating the migration
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-09 10:38:39 +01:00
Philip MacIver
bb9f594cc8
Changed the datamapper orm so that the default value is only deleted when it is nill, this is so that is a value is set to another value except nil by default through devise, that value will be maintained in datamapper
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-06 18:14:37 +01:00
Philip MacIver
d64e146ec9
Modified the datamapper orm so that it actually works with devise
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-03-06 16:18:53 +01:00
Philip MacIver
0a0d7ba577
Typo in the datamapper orm stopped it from being loaded properly
...
Signed-off-by: Carlos Antonio da Silva <carlosantoniodasilva@gmail.com >
2010-03-04 20:44:09 -03:00
José Valim
1d4f4c19c9
Release pre4 with improved controller handling.
2010-03-03 12:22:04 +01:00
José Valim
0e64bc74b7
Move trackabe logic to the model.
2010-03-03 12:03:43 +01:00
José Valim
038627574c
Keep modules definition in a different file.
2010-03-03 12:03:43 +01:00
José Valim
af39afcdf8
More refactoring.
2010-03-03 12:03:43 +01:00
José Valim
1660831002
Give more flexibility when swapping controllers.
2010-03-03 12:03:42 +01:00
Lucas Uyezu
8525b56318
SQLite requries a default value when the column is NOT NULL
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-02-25 08:33:38 +01:00
José Valim
bcb46bbccb
Do not forget frozen records.
2010-02-25 08:00:10 +01:00
José Valim
484361e815
Improve error message on undefined method devise.
2010-02-25 07:54:06 +01:00