From c416758e827a8d247df07274682a6d60db71cb14 Mon Sep 17 00:00:00 2001 From: Emanuele Date: Fri, 18 Oct 2024 11:57:01 +0200 Subject: [PATCH] Registered model to admin and made changes --- techdb/catops/admin.py | 2 ++ .../catops/migrations/0002_rename_parts_part.py | 17 +++++++++++++++++ techdb/catops/models.py | 2 +- 3 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 techdb/catops/migrations/0002_rename_parts_part.py diff --git a/techdb/catops/admin.py b/techdb/catops/admin.py index 8c38f3f..ee5f15f 100644 --- a/techdb/catops/admin.py +++ b/techdb/catops/admin.py @@ -1,3 +1,5 @@ from django.contrib import admin +from .models import Part # Register your models here. +admin.site.register(Part) diff --git a/techdb/catops/migrations/0002_rename_parts_part.py b/techdb/catops/migrations/0002_rename_parts_part.py new file mode 100644 index 0000000..976ba8c --- /dev/null +++ b/techdb/catops/migrations/0002_rename_parts_part.py @@ -0,0 +1,17 @@ +# Generated by Django 5.1.2 on 2024-10-18 09:55 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('catops', '0001_initial'), + ] + + operations = [ + migrations.RenameModel( + old_name='Parts', + new_name='Part', + ), + ] diff --git a/techdb/catops/models.py b/techdb/catops/models.py index cc669a9..7816c42 100644 --- a/techdb/catops/models.py +++ b/techdb/catops/models.py @@ -3,6 +3,6 @@ from django.db import models # Create your models here. # These models represent the actual data structure organization of the storage. -class Parts(models.Model): +class Part(models.Model): id = models.UUIDField(primary_key=True)