Skip to content

Commit e1e1be7

Browse files
committed
Merge branch 'dev' of github.com:TINF21CS1/python-campusnet into dev
2 parents e020ca4 + 9edc9e5 commit e1e1be7

File tree

1 file changed

+39
-2
lines changed

1 file changed

+39
-2
lines changed

Readme.md

Lines changed: 39 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,47 @@
1-
## Example usage
1+
# CampusNet Python
2+
3+
## Usage Examples
4+
5+
### Exam Script
6+
7+
The `print_exams_as_table.py` script that is included in this repository will easily retrieve all Exams for a user and print them in a pretty table. This makes a quick overview very easy.
8+
9+
```
10+
PS > python .\print_exams_as_table.py
11+
Username (mit @!): [email protected]
12+
Password:
13+
--------- ---------------------------------------- ------------------------------------------------------ ------------ -------------------------------------------- ---
14+
T3_1000 Praxisprojekt I T3_1000.1 Projektarbeit 1 (MA-TINF21CS1) SoSe 2022 Projektarbeit (1%)
15+
T3_1000 Praxisprojekt I T3_1000.2 Wissenschaftliches Arbeiten 1 (MA-TINF21CS1) SoSe 2022 Ablauf- und Reflexionsbericht (1%)
16+
T3INF1001 Mathematik I T3INF1001.1 Lineare Algebra (MA-TINF21CS1) WiSe 2021/22 Klausurarbeit (50%) 2.9
17+
T3INF1001 Mathematik I T3INF1001.2 Analysis (MA-TINF21CS1) SoSe 2022 Klausurarbeit (50%) 3.1
18+
T3INF1002 Theoretische Informatik I (MA-TINF21CS1) Modulabschlussleistungen SoSe 2022 Klausurarbeit (100%)
19+
T3INF1003 Theoretische Informatik II Modulabschlussleistungen SoSe 2022 Klausurarbeit (100%)
20+
T3INF1004 Programmieren Modulabschlussleistungen SoSe 2022 Programmentwurf (100%)
21+
T3INF1005 Schlüsselqualifikationen Modulabschlussleistungen SoSe 2022 Klausurarbeit (< 50 %) (100%)
22+
T3INF4102 Einführung in die Kryptologie Modulabschlussleistungen SoSe 2022 Klausur 75 % und Laborarbeit 25 % (100%)
23+
T3INF9000 Web and App Engineering Modulabschlussleistungen SoSe 2022 Klausur 50 % und Programmentwurf 50 % (100%)
24+
T3INF1006 Technische Informatik I Modulabschlussleistungen WiSe 2021/22 Klausurarbeit (100%) 4
25+
T3INF9001 Cyber Security Basics Modulabschlussleistungen WiSe 2021/22 Hausarbeit (100%) 2.1
26+
--------- ---------------------------------------- ------------------------------------------------------ ------------ -------------------------------------------- ---
27+
```
28+
29+
### Python Package
30+
31+
You can also use CampusNet.py as an imported Package to interact in detail with CampusNet.
232

333
```python
4-
$ python3 -i CampusNet.py
34+
$ python
35+
>>> from CampusNet import *
536
>>> s = CampusNetSession("s***REMOVED***@student.dhbw-mannheim.de", "***REMOVED***")
637
>>> s.modules
738
[Module(num='T3_1000', name='Praxisprojekt I', credits=20.0, status='', semesters=['SoSe 2022'], id='381683598069776', grade=None), Module(num='T3INF1001', name='Mathematik I', credits=8.0, status='', semesters=['SoSe 2022', 'WiSe 2021/22'], id='380685560144022', grade=None), Module(num='T3INF1002', name='Theoretische Informatik I (MA-TINF21CS1)', credits=5.0, status='', semesters=['SoSe 2022'], id='382855008624547', grade=None), Module(num='T3INF1003', name='Theoretische Informatik II', credits=5.0, status='', semesters=['SoSe 2022'], id='382214102615788', grade=None), Module(num='T3INF1004', name='Programmieren', credits=9.0, status='', semesters=['SoSe 2022'], id='379974839816701', grade=None), Module(num='T3INF1005', name='Schlüsselqualifikationen', credits=5.0, status='', semesters=['SoSe 2022'], id='379974840574866', grade=None), Module(num='T3INF4102', name='Einführung in die Kryptologie', credits=5.0, status='', semesters=['SoSe 2022'], id='382214104541196', grade=None), Module(num='T3INF9000', name='Web and App Engineering', credits=5.0, status='', semesters=['SoSe 2022'], id='379974842066225', grade=None), Module(num='T3INF1006', name='Technische Informatik I', credits=5.0, status='bestanden', semesters=['WiSe 2021/22'], id='380703425164844', grade=1.2), Module(num='T3INF9001', name='Cyber Security Basics', credits=3.0, status='bestanden', semesters=['WiSe 2021/22'], id='379974841329087', grade=1.6)]
839
>>> s.get_exams_for_module(s.modules[9])
940
[Exam(semester='WiSe 2021/22', description='Hausarbeit (100%)', grade=1.6)]
1041
```
42+
43+
## Contribution
44+
45+
This package is still work in progress. If you need data from CampusNet, that is currently not retrieved by it, please feel free to open an Issue or even PR for it.
46+
47+
We are studying at DHBW Mannheim, so this package is tested with [https://dualis.dhbw.de](https://dualis.dhbw.de). But it should also be compatible with other CampusNet instances from other universities.

0 commit comments

Comments
 (0)