Commit 4cb2b3f7 authored by Franco Velasco's avatar Franco Velasco

Merge branch 'velasco/homepage' into 'master'

Created Model for Widget User, added admin handler for Model

See merge request !1
parents 3081e5c0 095018b1
File added
from django.contrib import admin
from .models import WidgetUser
# Register your models here.
class WidgetUserAdmin(admin.ModelAdmin):
model = WidgetUser
list_display = ('first_name', 'last_name',)
admin.site.register(WidgetUser, WidgetUserAdmin)
from django.db import models
# Create your models here.
class WidgetUser(models.Model):
first_name = models.CharField(max_length=50)
middle_name = models.CharField(max_length=50)
last_name = models.CharField(max_length=50)
def __str__(self):
return f"{self.last_name}, {self.first_name} {self.middle_name}"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment