aboutsummaryrefslogtreecommitdiffstats
path: root/mediagoblin/submit/views.py
diff options
context:
space:
mode:
authorElrond <elrond+mediagoblin.org@samba-tng.org>2012-12-23 21:44:05 +0100
committerElrond <elrond+mediagoblin.org@samba-tng.org>2012-12-24 00:07:24 +0100
commitac8212fe657802eaf9dfd9d6c0f28f25b750399e (patch)
tree7966f1cba03949813e9045f2160f1d094e0034ab /mediagoblin/submit/views.py
parentb39d1f2351352fca21666137fa137eb64926a036 (diff)
downloadmediagoblin-ac8212fe657802eaf9dfd9d6c0f28f25b750399e.tar.lz
mediagoblin-ac8212fe657802eaf9dfd9d6c0f28f25b750399e.tar.xz
mediagoblin-ac8212fe657802eaf9dfd9d6c0f28f25b750399e.zip
Remove mongo style .id = ObjectId()
On SQL we can't generate the primary key on our own. So just remove this stuff.
Diffstat (limited to 'mediagoblin/submit/views.py')
-rw-r--r--mediagoblin/submit/views.py4
1 files changed, 0 insertions, 4 deletions
diff --git a/mediagoblin/submit/views.py b/mediagoblin/submit/views.py
index 1f0e927e..b52fca33 100644
--- a/mediagoblin/submit/views.py
+++ b/mediagoblin/submit/views.py
@@ -29,7 +29,6 @@ _log = logging.getLogger(__name__)
from werkzeug.utils import secure_filename
from werkzeug.datastructures import FileStorage
-from mediagoblin.db.util import ObjectId
from mediagoblin.tools.text import convert_to_tag_list_of_dicts
from mediagoblin.tools.translate import pass_to_ugettext as _
from mediagoblin.tools.response import render_to_response, redirect
@@ -66,7 +65,6 @@ def submit_start(request):
# create entry and save in database
entry = request.db.MediaEntry()
- entry.id = ObjectId()
entry.media_type = unicode(media_type)
entry.title = (
unicode(request.form['title'])
@@ -193,10 +191,8 @@ def add_collection(request, media=None):
if request.method == 'POST' and submit_form.validate():
try:
collection = request.db.Collection()
- collection.id = ObjectId()
collection.title = unicode(request.form['title'])
-
collection.description = unicode(request.form.get('description'))
collection.creator = request.user.id
collection.generate_slug()