class Code(models.Model): name = models.CharField(max_length=50, null=False) short_desc = models.CharField(max_length=100, null=False) full_desc = models.CharField(max_length=1000, null=True, blank=True) intro = models.CharField(max_length=5000, null=True, blank=True) main = models.CharField(max_length=10000, null=True, blank=True) func = models.CharField(max_length=5000, null=True, blank=True) input = models.CharField(max_length=500, null=True, blank=True) solution = models.CharField(max_length=5000, null=True, blank=True) level = models.CharField(max_length=5000, null=True, blank=True) language = models.CharField(max_length=5000, null=True, blank=True) compilation = models.CharField(max_length=5000, null=True, blank=True) tag = ListField(null=True, blank=True) topic = ListField(null=True, blank=True) sub_topic = ListField(null=True, blank=True) log_history = ListField(default=[{ 'type': 'Unknown', 'msg': 'Gods knows the event', 'ts': datetime.now().strftime('%Y-%m-%d %H:%M:%S') }], null=True, blank=True) created_at = models.DateTimeField(auto_now_add=True) updated_at = models.DateTimeField(auto_now=True) read_only = models.BooleanField(default=False)
class Subject(models.Model): name = models.CharField(max_length=100, null=False) uid = models.CharField(max_length=100, null=True) syllabus = models.CharField(max_length=1000, null=True) ref_book = models.CharField(max_length=1000, null=True) teacher = models.ManyToManyField(to=Employee) categorise = ListField(null=True, blank=True) group = ListField(null=True, blank=True) mark_division = DictField(null=True, blank=True)
class Book(models.Model): name = models.CharField(max_length=100,null=False) icbn = models.IntegerField(default=None,null=True,blank=True) pub_date = models.DateTimeField(auto_now=True,default=datetime.now()) toc = DictField(default={'house_rent':0,'food':0,'traval':0},null=True,blank=True) author = ListField(default=[1,2,3],null=True,blank=True) publication = ListField(default=[1,2,3],null=True,blank=True) log_history = ListField(default=[{'type':'Unknown', 'msg':'Gods knows the event','ts':datetime.now().strftime('%Y-%m-%d %H:%M:%S')}],null=True,blank=True); created_at = models.DateTimeField(auto_now_add=True) updated_at = models.DateTimeField(auto_now=True)
class Exam(models.Model): name = ListField(null=True, blank=True) subject = models.ForeignKey(to=Subject) date = models.DateTimeField(auto_now=True, default=datetime.now()) classRoom = models.CharField(max_length=1000, null=True) time = models.CharField(max_length=1000, null=True) teacher = models.ManyToManyField(to=Employee)
class Book(models.Model): name = models.CharField(max_length=100, null=False) author = models.CharField(max_length=100, null=False) desc = models.CharField(max_length=100, null=False) count = models.IntegerField(default=None, null=True, blank=True) price = models.IntegerField(default=None, null=True, blank=True) categories = ListField(null=True, blank=True)
class Result(models.Model): exam = models.ForeignKey(to=Exam) Student = models.ManyToManyField(to=Student) total = models.IntegerField(default=None, null=True, blank=True) percentage = models.IntegerField(default=None, null=True, blank=True) division = ListField(null=True, blank=True) comment = models.CharField(max_length=1000, null=True)
class Tickets(models.Model): uid = models.IntegerField(default=None, null=True, blank=True) summary = models.CharField(max_length=100, null=False) description = models.CharField(max_length=400, default=None, null=True, blank=True) author_name = models.CharField(max_length=400, default='guest', null=True, blank=True) author_email = models.EmailField(default=None, null=True, blank=True) created_date = models.DateTimeField(auto_now=True) modified_date = models.DateTimeField(default=datetime.now()) state = models.CharField(max_length=40, choices=TT_STATE, default='ASSIGNED', null=True, blank=True) type = models.CharField(max_length=40, choices=TT_TYPE, default='BACKEND', null=True, blank=True) sav = models.CharField(max_length=40, choices=TT_SEV, default='AVERAGE', null=True, blank=True) tags = ListField(default=[], null=True, blank=True) history = ListField(default=[], null=True, blank=True) assigned = models.CharField(max_length=40, default=None, null=True, blank=True) #comments=ListField(default=[{'author':'admin','timestamp':datetime.now(),'msg':'Thanks for your TT. We will get back to you soon'}],null=True,blank=True) comments = ListField(default=[], null=True, blank=True) def __unicode__(self): return u"TT:%s : %s" % (self.id, self.summary)
class Student(models.Model): uid = models.CharField(max_length=100, null=True) name = models.CharField(max_length=100, null=True) email = models.CharField(max_length=100, null=True) phone = models.CharField(max_length=100, null=True) address = models.CharField(max_length=500, null=True) dob = models.CharField(max_length=100, null=True) doj = models.DateTimeField(max_length=100, null=True) gender = models.CharField(max_length=100, null=True) parent = models.ForeignKey(to=Parent) myclass = models.ManyToManyField(to=MyClass) roll = models.CharField(max_length=100, null=True) section = ListField(default=[1, 2, 3], null=True, blank=True)
class Employee(models.Model): name = models.CharField(max_length=100, null=False) uid = models.CharField(max_length=100, null=False) address = models.CharField(max_length=100, null=True) age = models.IntegerField(default=None, null=True, blank=True) designation = models.CharField(max_length=100, null=True) rank = models.CharField(max_length=100, null=True) max_qualification = models.CharField(max_length=100, null=True) meretarial_status = models.CharField(max_length=100, null=True) gender = models.CharField(max_length=100, null=True) dob = models.CharField(max_length=100, null=True) doj = models.DateTimeField(max_length=100, null=True) categories = ListField(default=[1, 2, 3], null=True, blank=True)
class PayRoll(models.Model): type = ListField(null=True, blank=True) month = ListField(null=True, blank=True) year = ListField(null=True, blank=True) source = ListField(null=True, blank=True) category = ListField(null=True, blank=True) subcategory = models.CharField(max_length=200, null=False) amount = models.IntegerField(default=None, null=True, blank=True) actualamount = models.IntegerField(default=None, null=True, blank=True) breakup = DictField(null=True, blank=True) comment = models.CharField(max_length=100, null=False) log_history = ListField(default=[{ 'type': 'Unknown', 'msg': 'Gods knows the event', 'ts': datetime.now().strftime('%Y-%m-%d %H:%M:%S') }], null=True, blank=True) created_at = models.DateTimeField(auto_now_add=True) updated_at = models.DateTimeField(auto_now=True)
class Instrument(models.Model): name = models.CharField(max_length=100, null=False) details = models.CharField(max_length=100, null=False) categories = ListField(null=True, blank=True) purchage_date = models.DateTimeField(auto_now=True, default=datetime.now()) count = models.IntegerField(null=True, blank=True)
class Notice(models.Model): title = models.CharField(max_length=100, null=False) details = models.CharField(max_length=100, null=False) categories = ListField(null=True, blank=True) date = models.DateTimeField(auto_now=True, default=datetime.now())
class Discipline(models.Model): name = models.CharField(max_length=100, null=False) details = models.CharField(max_length=100, null=False) categories = ListField(null=True, blank=True)
class Fund(models.Model): name = models.CharField(max_length=100, null=False) tenant = models.CharField(max_length=100, null=False) purpose = models.CharField(max_length=100, null=False) type = ListField(null=True, blank=True) amount = models.IntegerField(default=None, null=True, blank=True)
class Setting(models.Model): name = models.CharField(max_length=100, null=False) account = models.ManyToManyField(to=Account) theme = ListField(null=True, blank=True)
class Sport(models.Model): name = models.CharField(max_length=100, null=False) position = DictField(null=True, blank=True) student = models.ManyToManyField(to=Student) categories = ListField(null=True, blank=True)