removed cms, updated music

This commit is contained in:
Alexander Karpov 2023-06-05 22:04:42 +03:00
parent 766b78f61d
commit 10bd668e57
5 changed files with 32 additions and 36 deletions

View File

@ -1,4 +1,4 @@
# Generated by Django 4.1.7 on 2023-03-27 21:25
# Generated by Django 4.2.1 on 2023-06-05 19:01
import akarpov.utils.files
from django.conf import settings
@ -11,8 +11,8 @@ class Migration(migrations.Migration):
initial = True
dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
("shortener", "0001_initial"),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
@ -126,22 +126,6 @@ class Migration(migrations.Migration):
"abstract": False,
},
),
migrations.CreateModel(
name="SongInQue",
fields=[
(
"id",
models.BigAutoField(
auto_created=True,
primary_key=True,
serialize=False,
verbose_name="ID",
),
),
("name", models.CharField(blank=True, max_length=250)),
("error", models.BooleanField(default=False)),
],
),
migrations.CreateModel(
name="Song",
fields=[
@ -199,6 +183,30 @@ class Migration(migrations.Migration):
"abstract": False,
},
),
migrations.CreateModel(
name="SongInQue",
fields=[
(
"id",
models.BigAutoField(
auto_created=True,
primary_key=True,
serialize=False,
verbose_name="ID",
),
),
("name", models.CharField(blank=True, max_length=250)),
("error", models.BooleanField(default=False)),
(
"song",
models.OneToOneField(
on_delete=django.db.models.deletion.CASCADE,
related_name="que",
to="music.song",
),
),
],
),
migrations.CreateModel(
name="PlaylistSong",
fields=[
@ -231,7 +239,7 @@ class Migration(migrations.Migration):
],
options={
"ordering": ["order"],
"unique_together": {("playlist", "song"), ("playlist", "order")},
"unique_together": {("playlist", "order"), ("playlist", "song")},
},
),
]

View File

@ -78,7 +78,6 @@ class Meta:
class SongInQue(models.Model):
"""It is very important for pk of SongInQue and Song to be the same"""
song = models.OneToOneField("Song", related_name="que", on_delete=models.CASCADE)
name = models.CharField(blank=True, max_length=250)
error = models.BooleanField(default=False)

View File

@ -90,7 +90,6 @@
"django.contrib.humanize", # Handy template tags
# required for jazzmin to work
"jazzmin",
"djangocms_admin_style",
"django.contrib.admin",
"django.forms",
]
@ -118,11 +117,6 @@
"django_filters",
"django_tables2",
"location_field",
# django-cms
"cms",
"menus",
"treebeard",
"sekizai",
]
HEALTH_CHECKS = [
@ -217,10 +211,6 @@
"django.contrib.messages.middleware.MessageMiddleware",
"django.middleware.common.BrokenLinkEmailsMiddleware",
"django.middleware.clickjacking.XFrameOptionsMiddleware",
"cms.middleware.language.LanguageCookieMiddleware",
"cms.middleware.user.CurrentUserMiddleware",
"cms.middleware.page.CurrentPageMiddleware",
"cms.middleware.toolbar.ToolbarMiddleware",
"django.middleware.cache.FetchFromCacheMiddleware",
]
@ -536,14 +526,14 @@
# ------------------------------------------------------------------------------
# MPD
MUSIC_MPD_HOST = env("MPD_HOST", default="")
MUSIC_MPD_PASSWORD = env("MPD_HOST", default="")
MUSIC_MPD_PASSWORD = env("MPD_PASSWORD", default="")
# SPOTIFY
MUSIC_SPOTIFY_ID = env("MPD_HOST", default="")
MUSIC_SPOTIFY_SECRET = env("MPD_HOST", default="")
MUSIC_SPOTIFY_ID = env("SPOTIFY_ID", default="")
MUSIC_SPOTIFY_SECRET = env("SPOTIFY_SECRET", default="")
# YANDEX_MUSIC
MUSIC_YANDEX_TOKEN = env("MPD_HOST", default="")
MUSIC_YANDEX_TOKEN = env("YANDEX_TOKEN", default="")
# ROBOTS
# ------------------------------------------------------------------------------

View File

@ -25,7 +25,6 @@
name="django.contrib.sitemaps.views.sitemap",
),
path("health/", include("health_check.urls")),
path("cms/", include("cms.urls")),
# Django Admin, use {% url 'admin:index' %}
path(settings.ADMIN_URL, admin.site.urls),
# User management

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.4 MiB

After

Width:  |  Height:  |  Size: 1.9 MiB