django - How to register a visitor (guest), after submitting an order form, and immediately authorize his on site with this data? -
there django 1.11.5
override user model (client
). authorization occurs email + password, fields removed in admin panel, otherwise - standard model of user django (i use abstractuser
). also, there application (order_form
) many fields can filled in both guests , authorized site visitors.
how make sure when send form, if visitor guest (unauthorized) , not have account on site (check email), automatically registered (with email indicated in form , randomly generated password + sending letter data mail)?
also, redirect personal cabinet , authorize user, using email , generated password.
i glad help.
Comments
Post a Comment