Renamed Project to cntmanage

This commit is contained in:
2025-11-18 23:28:50 +01:00
parent 9cae53a942
commit 491afb6257
77 changed files with 6 additions and 5 deletions

View File

@@ -0,0 +1,18 @@
from colorfield.fields import ColorField
from django.utils.html import format_html
from django.utils.safestring import SafeText
def course_color(color: ColorField | None) -> SafeText:
if not color:
return format_html("")
return format_html(
'<div style="background-color: {}; \
width: 20px; height: 20px; \
border-radius: 25%; \
border-color: gray; \
border-style: solid; \
border-width: 1px; \
display: inline-block; \
"></div>',
color
)