Skip to content

This is an extension for the MagicMirror2 platform. It will display cancelled or irregular lessons from Untis.

License

Notifications You must be signed in to change notification settings

HeikoGr/MMM-Webuntis

 
 

Repository files navigation

MMM-Webuntis

This an extension for the MagicMirror². It allows to display your kids' cancelled and irregular lessons for schools using Untis software to organize school's timetables. You are able to configure access for each of your kids.

Installation

  1. Navigate into your MagicMirror²'s modules folder and execute git clone https://github.com/HeikoGr/MMM-Webuntis.
  2. Navigate into the new folder MMM-Webuntis and execute npm install to generate the node dependencies.

Update

  1. Navigate into your MMM-Webuntis folder and execute git pull.
  2. execute npm install to (re-)generate the node dependencies.

Using the module

To use this module, add it to the modules array in the config/config.js file:

modules: [
    {
        module: "MMM-Webuntis",
        position: "top_right",
        header: "Untis",
        config: { // see 'Configuration options' for more information
            students: [
                {
                    title: "1st child's name",
                    qrcode: "untis:[...] " // preferred, or:
                    // school: "your school",
                    // username: "your untis username",
                    // password: "your untis password",
                    // server: "untis server"
                },
                {
                    title: "2nd child's name",
                    qrcode: "untis:[...] " // preferred, or:
                    // school: "your school",
                    // username: "your untis username",
                    // password: "your untis password",
                    // server: "untis server"
                },
            ],
            days: 1,
            fetchInterval: 5*60*1000,
            showStartTime: false,
            showRegularLessons: false,
            showTeacher: true,
            mode: "verbose",
            shortSubject: false
        }
    }

Configuration options

The following properties can be configured:

Option Description
header (optional) Printed by MagicMirror² if set
students Array of untis login credentials objects

Possible values: array of objects with the following attributes:
title Title of the entry, e.g. kid's name
qrcode login-string from qrcode provided by webuntis. You need to login in the student account and go to -> Profile -> Data Acess to generate a qrcode. Adjust the qrcode sting to match your credentials:
'untis://setschool?url=[...]&school=[...]&user=[...]&key=[...]&schoolNumber=[...]';
school School name as in the URL after having logged in at webuntis.com. A plus sign (+) in the URL can be replaced by space.
username Username used to login at Untis
(Optional, only required if student has custom login)
password Password used to login at Untis
(Optional, only required if student has custom login)
server Server as shown in the URL after having logged in at webuntis.com, e.g. kephiso.webuntis.com
class Name of class to show
(Optional, only required if Anonymous mode is used)
useClassTimetable It seems, that some schools do not provide an individual timetable but only the class timetable. Try to set this to true if you don't receive any elements.

Default value: false
days Number of days to look ahead

Possible values: int from 1 to 10
Default value: 7
fetchInterval Defines how often the module shall retrieve data from Untis

Possible values: int in milliseconds
Default value: 5*60*1000 (5 Minutes)
showStartTime Whether time or lesson order number shall be shown

Possible values: true or false
Default value: false

The module tries to achieve the timetable of the school and currently assumes that Monday's lesson times are valid for the whole week. When set to false the module matches a start time like "07:40" to "1." for example.
showRegularLessons Whether to show also regular lessons or not

Possible values: true or false
Default value: false
showTeacher Whether to show also teachers name or not or just the initial

Possible values: true or false or "initial"
Default value: true
shortSubject Whether to show just the subject initials or full subject name

Possible values: true or false
Default value: false
mode Show each student as own table, or compact in one table.
Possible values: verbose or compact
Default value: verbose
debug Use only for debug purposes!
If set to true, the timetable from WebUntis and the parsed lessons will be printed to the MM log

Possible values: true or false
Default value: false

How it works

This module may be useful for students at schools using Untis for the organization of time tables. It uses the node.js wrapper of the WebUnits API by TheNoim and retrieves all lessons in a specified number of days time period. It displays cancelled or irregular subjects so that kids are able to prepare for the next day without pulling the information from the Untis app. The module can be configured for several students.

Dependencies

Screenshots

"mode: compact":

Screenshot

"mode: verbose":

Screenshot

Attribution

This project is based on work done by Paul-Vincent Roll in the MMM-Wunderlist module. (https://github.com/paviro/MMM-Wunderlist)

About

This is an extension for the MagicMirror2 platform. It will display cancelled or irregular lessons from Untis.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 98.0%
  • CSS 2.0%