Ce serveur Gitlab sera éteint le 30 juin 2020, pensez à migrer vos projets vers les serveurs gitlab-research.centralesupelec.fr et gitlab-student.centralesupelec.fr !

admin.py 3.11 KB
Newer Older
1
# -*- mode: python; coding: utf-8 -*-
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
# Re2o est un logiciel d'administration développé initiallement au rezometz. Il
# se veut agnostique au réseau considéré, de manière à être installable en
# quelques clics.
#
# Copyright © 2017  Gabriel Détraz
# Copyright © 2017  Goulven Kermarec
# Copyright © 2017  Augustin Lemesle
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
23 24 25
"""
Classes admin pour les models de preferences
"""
26 27
from __future__ import unicode_literals

28
from django.contrib import admin
29 30
from reversion.admin import VersionAdmin

Gabriel Detraz's avatar
Gabriel Detraz committed
31 32 33 34 35 36
from .models import (
    OptionalUser,
    OptionalMachine,
    OptionalTopologie,
    GeneralOption,
    Service,
37
    MailContact,
Gabriel Detraz's avatar
Gabriel Detraz committed
38 39
    AssoOption,
    MailMessageOption,
40
    HomeOption,
41
    RadiusKey,
42 43
    SwitchManagementCred,
    Reminder
Gabriel Detraz's avatar
Gabriel Detraz committed
44
)
45

46 47

class OptionalUserAdmin(VersionAdmin):
48
    """Class admin options user"""
49 50
    pass

51

52
class OptionalTopologieAdmin(VersionAdmin):
53
    """Class admin options topologie"""
54 55
    pass

56

57
class OptionalMachineAdmin(VersionAdmin):
58
    """Class admin options machines"""
59 60
    pass

61

62
class GeneralOptionAdmin(VersionAdmin):
63
    """Class admin options générales"""
64 65
    pass

66

67
class ServiceAdmin(VersionAdmin):
68
    """Class admin gestion des services de la page d'accueil"""
69 70
    pass

71

72
class MailContactAdmin(VersionAdmin):
73
    """Admin class for contact email adresses"""
74 75 76
    pass


77
class AssoOptionAdmin(VersionAdmin):
78
    """Class admin options de l'asso"""
79
    pass
80

81

82
class MailMessageOptionAdmin(VersionAdmin):
83
    """Class admin options mail"""
84 85
    pass

86

Gabriel Detraz's avatar
Gabriel Detraz committed
87 88 89 90 91
class HomeOptionAdmin(VersionAdmin):
    """Class admin options home"""
    pass


92 93 94 95
class RadiusKeyAdmin(VersionAdmin):
    """Class radiuskey"""
    pass

96 97 98 99
class SwitchManagementCredAdmin(VersionAdmin):
    """Class managementcred for switch"""
    pass

100 101 102
class ReminderAdmin(VersionAdmin):
    """Class reminder for switch"""
    pass
103

104 105
admin.site.register(OptionalUser, OptionalUserAdmin)
admin.site.register(OptionalMachine, OptionalMachineAdmin)
106
admin.site.register(OptionalTopologie, OptionalTopologieAdmin)
107
admin.site.register(GeneralOption, GeneralOptionAdmin)
Gabriel Detraz's avatar
Gabriel Detraz committed
108
admin.site.register(HomeOption, HomeOptionAdmin)
109
admin.site.register(Service, ServiceAdmin)
110
admin.site.register(MailContact, MailContactAdmin)
111 112
admin.site.register(Reminder, ReminderAdmin)
admin.site.register(RadiusKey, RadiusKeyAdmin)
113
admin.site.register(SwitchManagementCred, SwitchManagementCredAdmin)
114
admin.site.register(AssoOption, AssoOptionAdmin)
115
admin.site.register(MailMessageOption, MailMessageOptionAdmin)