mirror of
https://github.com/kristoferssolo/FOSSDB.git
synced 2025-10-21 17:50:35 +00:00
Moved Tag model to separete app
This commit is contained in:
parent
311780d2e2
commit
6272b312c2
@ -6,15 +6,11 @@ from hosting_platform.models import HostingPlatform
|
||||
from license.models import License
|
||||
from programming_language.models import ProgrammingLanguage
|
||||
|
||||
from tag.models import Tag
|
||||
|
||||
User = settings.AUTH_USER_MODEL
|
||||
|
||||
|
||||
class Tag(models.Model):
|
||||
name = models.CharField(max_length=100)
|
||||
description = models.TextField(null=True, blank=True)
|
||||
icon = models.ImageField(upload_to="types/icons/", null=True, blank=True)
|
||||
|
||||
|
||||
class Project(models.Model):
|
||||
uuid = models.UUIDField(primary_key=True, default=uuid.uuid4, editable=False)
|
||||
author = models.ForeignKey(User, on_delete=models.CASCADE)
|
||||
|
||||
@ -1,3 +1,5 @@
|
||||
from django.contrib import admin
|
||||
|
||||
# Register your models here.
|
||||
from .models import Tag
|
||||
|
||||
admin.site.register(Tag)
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
from django.db import models
|
||||
|
||||
# Create your models here.
|
||||
|
||||
class Tag(models.Model):
|
||||
name = models.CharField(max_length=100)
|
||||
description = models.TextField(null=True, blank=True)
|
||||
icon = models.ImageField(upload_to="types/icons/", null=True, blank=True)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user