Skip to content
Snippets Groups Projects
Verified Commit c7969e42 authored by Nik | Klampfradler's avatar Nik | Klampfradler
Browse files

Fix determination of classes.

Seriously, Untis - XML is well-structured format with schema validation
and all this stuff, and you have no better idea than filling a free-form,
space-separated list with values containing values?
parent f6017dfa
No related branches found
No related tags found
No related merge requests found
......@@ -94,8 +94,8 @@ def untis_import_xml(request: HttpRequest, untis_xml: Union[BinaryIO, str]) -> N
subject_abbrev = get_child_node_id(lesson_node, 'lesson_subject')[3:]
teacher_short_name = get_child_node_id(
lesson_node, 'lesson_teacher')[3:]
group_short_names = [v[3:] for v in get_child_node_id(
lesson_node, 'lesson_classes').split(' ')]
group_short_names = [v for v in get_child_node_id(
lesson_node, 'lesson_classes').split('CL_') if v]
effectivebegindate = get_child_node_text(
lesson_node, 'effectivebegindate')
effectiveenddate = get_child_node_text(lesson_node, 'effectiveenddate')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment