from django.db import models

class Profile(models.Model):
    first_name = models.CharField(max_length=200)
    last_name = models.CharField(max_length=200, blank=True, null=True)
    address = models.TextField(max_length=1000, blank=True, null=True)

    def remove(self):
        return '<input type="button" value="Delete" onclick="location.href=\'%s/delete/\'" />' % (self.pk)

    remove.short_description = ''
    remove.allow_tags = True
    
    class Admin:
        list_display = ('first_name', 'last_name','address', 'remove')
        
    def __str__(self):
        return "%s %s" % (self.first_name, self.last_name)