finishing the design of the admin page
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 2s

This commit is contained in:
2026-08-07 17:17:26 +01:00
parent 8af967b4d3
commit e66c7034f0
4 changed files with 43 additions and 3 deletions
+17 -2
View File
@@ -72,5 +72,20 @@ class streamingAdmin(ImportExportModelAdmin):
@admin.register(StreamingRedirectData)
class StreamingRedirectAdmin(ImportExportModelAdmin):
list_display = ['name','season_to_watch','episode_to_watch','addedDate','url_example','addedDate','alias']
fields = ['name','season_to_watch','episode_to_watch','url_example','prefix','infix','suffix','alias','seasonInformation']
list_display = ['name','season_to_watch','episode_to_watch','randomViewing','url_example','addedDate','alias']
#fields = ['name','season_to_watch','episode_to_watch','url_example','prefix','infix','suffix','alias','randomViewing','seasonInformation']
fieldsets = (
(
'Serie', {
'fields': ('name', 'season_to_watch', 'episode_to_watch','randomViewing')
}),
(
'url', {
'fields': (('prefix','infix','suffix'),'url_example')
}),
(
'Information', {
"classes": ["collapse"],
'fields': ('seasonInformation','alias')
}),
)
@@ -0,0 +1,23 @@
# Generated by Django 4.2.30 on 2026-08-07 15:59
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('streaming', '0007_rename_streamingdata_streamingsitetestingdata_and_more'),
]
operations = [
migrations.AddField(
model_name='streamingredirectdata',
name='randomViewing',
field=models.BooleanField(default=False),
),
migrations.AlterField(
model_name='streamingredirectdata',
name='seasonInformation',
field=models.JSONField(blank=True, default=dict),
),
]
+1
View File
@@ -27,6 +27,7 @@ class StreamingRedirectData(models.Model):
addedDate = models.DateField('Published', blank=True, null=True, auto_now_add=True)
alias = models.CharField(max_length=1000, null=True,blank=True)
seasonInformation = models.JSONField(default=dict, blank=True)
randomViewing = models.BooleanField(default=False)
def sanitize(self, name):
return name.replace(" ", "")
+1
View File
@@ -36,3 +36,4 @@ def test_website(url_website,bool_proxy=False):
print(f"{type(err).__name__} was raised: {err}")
status = "exception not targeted"
return status