Need a unique gift idea?
A Pastebin account makes a great Christmas gift
SHARE
TWEET

Untitled

a guest Nov 15th, 2018 119 Never
Upgrade to PRO!
ENDING IN00days00hours00mins00secs
 
  1. [admin.py]:
  2. ---------
  3. from django.contrib import admin
  4. from Biblioteca.App.gestionlibreria.models import *
  5. # Register your models here.
  6.  
  7. admin.site.register(nombre)
  8. admin.site.register(contraseƱa)
  9. admin.site.register(fechaIngreso)
  10. [models.py]:
  11. ------------
  12. from django.db import models
  13.  
  14. class Miembro(models.Model):
  15.     nombre = models.CharField(max_length=15)
  16.     contrasenha = models.CharField(max_length=8)
  17.     fechaIngreso = models.DateField()
  18.  
  19.     def formulario(self):
  20.         registro = "Username: {}, Password: {}".format(self.nombre, self.contrasenha)
  21.         return registro
  22.     def __str__(self):
  23.         return self.formulario()
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top