Error is in forms.py file.

"model = User" not profile.

Default "User" model comes with username, email filed.

Why you're creating another email field in the Profile model?

Just fetch it using {{ user.email }}


On Tue, May 25, 2021, 1:38 AM Aritra Ray <aritra...@gmail.com> wrote:

> Hi,
>
> I've been facing a problem recently in creating a Django Profile model for
> an E-commerce website.
> Error: FieldError(message) django.core.exceptions.FieldError: Unknown
> field(s) (username) specified for Profile
> Kindly help me out if possible. The screenshots have been attached below
> and the github link for the project has been provided.
>
> Link: https://github.com/First-project-01/Django-ecommerce (Check out the
> 'changes' branch)
>
> Regards,
> Aritra
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAFecadvxBCa6w02%3DZ887%2BnaEdY-R6B9%2BVVFzVW5zYvkt1gA2hg%40mail.gmail.com
> <https://groups.google.com/d/msgid/django-users/CAFecadvxBCa6w02%3DZ887%2BnaEdY-R6B9%2BVVFzVW5zYvkt1gA2hg%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAJY8mfzFT-GqqZ0YvdLKH9gKcTAv%2B1srG9973pXYfA5f_qVA7w%40mail.gmail.com.

Reply via email to