Closed bcoover closed 8 years ago
If you can demonstrate that vanilla views are different to Django's implementation in this regard then we could consider this. Otherwise, not. We mirror their behavior but with a cleaner implementation and interface. Nothing more than that.
Hi, I ran into a problem in my app with vanilla views as it relates to passwords. As you know, passwords have to be hashed before saving. When using the vanilla-generated create and update views, the password was not getting saved correctly via hashing, and looking at those objects i the admin, I got the error "Invalid password format or unknown hashing algorithm" I understand that vanilla, by design, treats all fields the same, which is fine, but in special cases this may break down. For common use cases like passwords, it would be nice to have them handled automatically. I didn't find anything when Googling this in reference to django-vanilla-views, so (IMHO) I think this would be a good addition to the documentation...
FYI, in my app I am doing a couple of slightly non-standard things:
My workaround was adding this override function 'form_valid' to the create and update views to ensure that this field was treated correctly: