wlanslovenija / django-tastypie-mongoengine

MongoEngine support for django-tastypie.
Other
73 stars 59 forks source link

Truncated EmbeddedDocumentField arguments #40

Closed leo-naeka closed 11 years ago

leo-naeka commented 11 years ago

Hi mitar,

Just to know, is there any reason why EmbeddedDocumentFields init arguments are so limited ? cf. fields.py#L79

I've just quickly tested with readonly, which I need, and it works -in my case- fine. blank should also be interesting.

mitar commented 11 years ago

I have no idea why this looked reasonable to me at that time. ;-) Maybe because you can make the same thing if all fields of an embedded document is read-only, no?

Feel free to make a pull request with fix. Please add tests. Probably we should also extend build_schema to somehow tell those attributes to the user? What do you think?