Updates can now take raw queries

This commit is contained in:
Ross Lawley
2012-02-24 15:48:32 +00:00
parent 3300f409ba
commit 6a229cfbc5
2 changed files with 26 additions and 4 deletions

View File

@@ -1279,6 +1279,9 @@ class QuerySet(object):
mongo_update = {}
for key, value in update.items():
if key == "__raw__":
mongo_update.update(value)
continue
parts = key.split('__')
# Check for an operator and transform to mongo-style if there is
op = None