Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Field's value gets replaced by Model's name if the name of field is 'name' #73

Open
kaflesudip opened this issue Dec 18, 2014 · 3 comments

Comments

@kaflesudip
Copy link
Contributor

If I have a Document similar to this:

class MyDocument(Document):
    name = fields.StringField()

The value of 'name' is changed to 'MyDocument' i.e. the name of the Document itself.

@mohitm86
Copy link

I am also facing the same issue. Will be great if you guys can point me in the right direction.

@garrypolley
Copy link
Collaborator

Do you have any more details on the issue?

@mohitm86
Copy link

mohitm86 commented Sep 20, 2016

If I create a admin page for the above example

class MyDocument(Document):
name = fields.StringField()

and set name = "My name" is the form when create or updating a new MyDocument, name field is still set as MyDocument.

i.e. document.name is always MyDocument no matter what I set it to.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants