feat: add admin screens, permissions and navigation

Seven admin controllers in a "Studia BM" navigation group, guarded by
jz.bm.access_courses, jz.bm.access_schedule and jz.bm.access_materials,
with Polish and English labels. Date and time fields are checked by the
models before a save and answered as 422 on the field.
This commit is contained in:
Jakub Zych
2026-10-02 14:26:26 +02:00
parent 1046237771
commit 577fa14d3d
42 changed files with 1234 additions and 11 deletions

View File

@@ -0,0 +1,15 @@
columns:
title:
label: jz.bm::lang.common.title
searchable: true
type:
label: jz.bm::lang.materials.type
course:
label: jz.bm::lang.common.course
relation: course
select: name
published_at:
label: jz.bm::lang.materials.published_at
created_at:
label: jz.bm::lang.common.created_at
type: datetime

View File

@@ -0,0 +1,46 @@
# Attached files (system_files, field "files") have no form widget yet; see
# the TODO on materialsAdmin.AdminFieldRelations.
fields:
title:
label: jz.bm::lang.common.title
type: text
span: left
required: true
type:
label: jz.bm::lang.materials.type
type: dropdown
span: right
required: true
options:
pdf: jz.bm::lang.material_types.pdf
notatka: jz.bm::lang.material_types.notatka
link: jz.bm::lang.material_types.link
inne: jz.bm::lang.material_types.inne
course:
label: jz.bm::lang.common.course
type: relation
nameFrom: name
span: left
emptyOption: jz.bm::lang.common.none
published_at:
label: jz.bm::lang.materials.published_at
type: text
span: right
comment: jz.bm::lang.materials.published_at_comment
source:
label: jz.bm::lang.common.source
type: text
span: left
url:
label: jz.bm::lang.common.url
type: text
span: right
tags:
label: jz.bm::lang.materials.tags
type: relation
nameFrom: name
body:
label: jz.bm::lang.materials.body
type: textarea
size: giant
comment: jz.bm::lang.materials.body_comment