Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

create models in django

from django.db import models
# Create your models here.

class Contact(models.Model):
    name = models.CharField(max_length=50)
    email = models.CharField(max_length=50)
    contact = models.CharField(max_length=50)
    content = models.TextField()
    def __str__(self):
        return self.name + ' ' + self.email
 
PREVIOUS NEXT
Tagged: #create #models #django
ADD COMMENT
Topic
Name
2+3 =