From 379ede2617e561ffe03b4ecc6c5d783f834fe7be Mon Sep 17 00:00:00 2001 From: aranzaiger Date: Mon, 15 Jun 2015 16:32:35 +0300 Subject: [PATCH] models - added master_id --- models/Course.py | 2 ++ models/Project.py | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/models/Course.py b/models/Course.py index 7b2ac75..4b3abe5 100644 --- a/models/Course.py +++ b/models/Course.py @@ -6,6 +6,7 @@ from google.appengine.ext import db class Course(db.Model): courseName = db.StringProperty(required=True) campusName = db.StringProperty(required=True) + master_id = db.IntegerProperty(required=True) projects = db.StringListProperty(required=True,default=[]) startDate = db.DateProperty(required=True) endDate = db.DateProperty(required=True) @@ -13,6 +14,7 @@ class Course(db.Model): def to_JSON(self): data = {'courseName' : self.courseName, 'campusName' : self.campusName, + 'master_id' : self.master_id, 'projects' : self.projects, 'startDate' : { 'year': self.startDate.year, diff --git a/models/Project.py b/models/Project.py index e165c58..97db04e 100644 --- a/models/Project.py +++ b/models/Project.py @@ -5,7 +5,7 @@ from google.appengine.ext import db class Project(db.Model): projectName = db.StringProperty(required=True) - masterId = db.IntegerProperty(required=True) + master_id = db.IntegerProperty(required=True) grade = db.IntegerProperty(required=True, default=0) logo_url = db.StringProperty(required=False) gitRepository = db.StringProperty(required=True) @@ -13,7 +13,7 @@ class Project(db.Model): def to_JSON(self): data = {'projectName' : self.projectName, - 'masterId' : self.masterId, + 'master_id' : self.master_id, 'grade' : self.grade, 'logo_url' : self.logo_url, 'gitRepository' : self.gitRepository,