Changes in referenz entry field
All checks were successful
Build containers when image tags change / build-if-image-changed (., web, containers, main container, git.baumann.gr/adebaumann/vui) (push) Successful in 31s
Build containers when image tags change / build-if-image-changed (data-loader, loader, initContainers, init-container, git.baumann.gr/adebaumann/vui-data-loader) (push) Successful in 8s
All checks were successful
Build containers when image tags change / build-if-image-changed (., web, containers, main container, git.baumann.gr/adebaumann/vui) (push) Successful in 31s
Build containers when image tags change / build-if-image-changed (data-loader, loader, initContainers, init-container, git.baumann.gr/adebaumann/vui-data-loader) (push) Successful in 8s
This commit is contained in:
@@ -18,7 +18,7 @@ data:
|
||||
MEDIA_URL: "/media/"
|
||||
|
||||
# Application Version
|
||||
VERSION: "0.989"
|
||||
VERSION: "0.990"
|
||||
|
||||
# Database Configuration (for future use)
|
||||
# DATABASE_ENGINE: "django.db.backends.sqlite3"
|
||||
|
||||
@@ -27,7 +27,7 @@ spec:
|
||||
mountPath: /data
|
||||
containers:
|
||||
- name: web
|
||||
image: git.baumann.gr/adebaumann/vui:0.989
|
||||
image: git.baumann.gr/adebaumann/vui:0.990
|
||||
imagePullPolicy: Always
|
||||
securityContext:
|
||||
runAsUser: 99
|
||||
|
||||
@@ -2,11 +2,9 @@ from django.contrib import admin
|
||||
from django import forms
|
||||
from django.utils.safestring import mark_safe
|
||||
|
||||
from mptt.forms import TreeNodeMultipleChoiceField
|
||||
from nested_admin import NestedStackedInline, NestedModelAdmin, NestedTabularInline
|
||||
from .models import *
|
||||
from stichworte.models import Stichwort, Stichworterklaerung
|
||||
from referenzen.models import Referenz
|
||||
|
||||
|
||||
|
||||
@@ -87,8 +85,6 @@ class EinleitungInline(NestedStackedInline):
|
||||
)
|
||||
|
||||
class VorgabeForm(forms.ModelForm):
|
||||
referenzen = TreeNodeMultipleChoiceField(queryset=Referenz.objects.all(), required=False)
|
||||
|
||||
class Meta:
|
||||
model = Vorgabe
|
||||
fields = '__all__'
|
||||
|
||||
@@ -14,7 +14,7 @@ class ReferenzerklaerungInline(NestedStackedInline):
|
||||
class ReferenzAdmin(NestedModelAdmin):
|
||||
list_display = ('Path', 'vorgaben_count')
|
||||
inlines=[ReferenzerklaerungInline]
|
||||
search_fields=("name_nummer","Path")
|
||||
search_fields=("name_nummer","name_text")
|
||||
readonly_fields=("vorgaben_list",)
|
||||
fieldsets = (
|
||||
(None, {
|
||||
|
||||
@@ -13,15 +13,17 @@ class Referenz(MPTTModel):
|
||||
url = models.URLField(blank=True)
|
||||
|
||||
def Path(self):
|
||||
Temp = " → ".join([str(x) for x in self.get_ancestors(include_self=True)])+(" (%s)"%self.name_text if self.name_text else "")
|
||||
return Temp
|
||||
path = " → ".join([x.name_nummer for x in self.get_ancestors(include_self=True)])
|
||||
if self.name_text:
|
||||
path += " (%s)" % self.name_text
|
||||
return path
|
||||
|
||||
class MPTTMeta:
|
||||
parent_attr = 'oberreferenz' # optional, but safe
|
||||
order_insertion_by = ['name_nummer']
|
||||
|
||||
def __str__(self):
|
||||
return self.name_nummer
|
||||
return self.Path()
|
||||
|
||||
class Meta:
|
||||
verbose_name_plural="Referenzen"
|
||||
|
||||
17
rollen/migrations/0003_alter_rolle_options.py
Normal file
17
rollen/migrations/0003_alter_rolle_options.py
Normal file
@@ -0,0 +1,17 @@
|
||||
# Generated by Django 6.0.1 on 2026-02-12 13:27
|
||||
|
||||
from django.db import migrations
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('rollen', '0002_alter_rolle_options'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterModelOptions(
|
||||
name='rolle',
|
||||
options={'verbose_name': 'Rolle', 'verbose_name_plural': 'Rollen'},
|
||||
),
|
||||
]
|
||||
Reference in New Issue
Block a user