mirror of
https://github.com/daniviga/django-ram.git
synced 2025-08-04 13:17:50 +02:00
Add shop as a fixed property (#49)
* Add shop field (from properties) * Update template * Implement description in BaseModel and then consist * Make notes internal only * Fix a merge issue
This commit is contained in:
@@ -49,12 +49,16 @@ class ConsistAdmin(SortableAdminBase, admin.ModelAdmin):
|
||||
"consist_address",
|
||||
"company",
|
||||
"era",
|
||||
"description",
|
||||
"image",
|
||||
"notes",
|
||||
"tags",
|
||||
)
|
||||
},
|
||||
),
|
||||
(
|
||||
"Notes",
|
||||
{"classes": ("collapse",), "fields": ("notes",)},
|
||||
),
|
||||
(
|
||||
"Audit",
|
||||
{
|
||||
|
19
ram/consist/migrations/0015_consist_description.py
Normal file
19
ram/consist/migrations/0015_consist_description.py
Normal file
@@ -0,0 +1,19 @@
|
||||
# Generated by Django 5.1.4 on 2025-01-27 21:15
|
||||
|
||||
import tinymce.models
|
||||
from django.db import migrations
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
("consist", "0014_alter_consistitem_order"),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name="consist",
|
||||
name="description",
|
||||
field=tinymce.models.HTMLField(blank=True),
|
||||
),
|
||||
]
|
@@ -21,4 +21,5 @@ class ConsistSerializer(serializers.ModelSerializer):
|
||||
|
||||
class Meta:
|
||||
model = Consist
|
||||
fields = "__all__"
|
||||
exclude = ("notes",)
|
||||
read_only_fields = ("creation_time", "updated_time")
|
||||
|
Reference in New Issue
Block a user