## modify it under the terms of the GNU General Public License as ## published by the Free Software Foundation; either version 3 of the ## License, or (at your option) any later version. ## ## Indico 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 Indico. If not, see <http://www.gnu.org/licenses/>. from indico.web.flask.wrappers import IndicoBlueprint event_mgmt = IndicoBlueprint('event_mgmt', __name__, url_prefix='/event/<confId>/manage') import indico.web.flask.blueprints.event.management.main import indico.web.flask.blueprints.event.management.general import indico.web.flask.blueprints.event.management.tools import indico.web.flask.blueprints.event.management.layout import indico.web.flask.blueprints.event.management.protection import indico.web.flask.blueprints.event.management.lists import indico.web.flask.blueprints.event.management.evaluation import indico.web.flask.blueprints.event.management.rooms import indico.web.flask.blueprints.event.management.registration import indico.web.flask.blueprints.event.management.payment import indico.web.flask.blueprints.event.management.abstracts import indico.web.flask.blueprints.event.management.tracks import indico.web.flask.blueprints.event.management.schedule
# License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from MaKaC.webinterface.rh import (admins, announcement, taskManager, maintenance, domains, users, groups, templates, conferenceModif, services, api, oauth) from indico.web.flask.wrappers import IndicoBlueprint admin = IndicoBlueprint('admin', __name__, url_prefix='/admin') # General settings admin.add_url_rule('/', 'adminList', admins.RHAdminArea) admin.add_url_rule('/settings/general/news', 'adminList-switchNewsActive', admins.RHAdminSwitchNewsActive) admin.add_url_rule('/settings/general/', 'generalInfoModification', admins.RHGeneralInfoModification) admin.add_url_rule('/settings/general/', 'generalInfoModification-update', admins.RHGeneralInfoPerformModification, methods=('POST',)) # System settings admin.add_url_rule('/settings/system', 'adminSystem', admins.RHSystem) admin.add_url_rule('/settings/system/modify', 'adminSystem-modify', admins.RHSystemModify, methods=('GET', 'POST')) # Announcement admin.add_url_rule('/announcement', 'adminAnnouncement', announcement.RHAnnouncementModif) admin.add_url_rule('/announcement', 'adminAnnouncement-save', announcement.RHAnnouncementModifSave, methods=('POST',))
# # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from indico.modules.rb.controllers.admin import index as index_handler from indico.modules.rb.controllers.admin import locations as location_handlers from indico.modules.rb.controllers.admin import rooms as room_handlers from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('rooms_admin', __name__, template_folder='../templates', virtual_template_folder='rb', url_prefix='/admin/rooms') # Main settings _bp.add_url_rule('/config/', 'settings', index_handler.RHRoomBookingSettings, methods=('GET', 'POST')) # Locations _bp.add_url_rule('/locations/', 'roomBooking-admin', location_handlers.RHRoomBookingAdmin) _bp.add_url_rule('/locations/delete',
# This file is part of Indico. # Copyright (C) 2002 - 2021 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. from indico.modules.events import event_management_object_url_prefixes from indico.modules.events.management.controllers import actions, cloning, posters, program_codes, protection, settings from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('event_management', __name__, template_folder='templates', virtual_template_folder='events/management', url_prefix='/event/<int:event_id>/manage') # Settings _bp.add_url_rule('/', 'settings', settings.RHEventSettings) _bp.add_url_rule('/settings/data', 'edit_data', settings.RHEditEventData, methods=('GET', 'POST')) _bp.add_url_rule('/settings/dates', 'edit_dates', settings.RHEditEventDates, methods=('GET', 'POST')) _bp.add_url_rule('/settings/location', 'edit_location', settings.RHEditEventLocation, methods=('GET', 'POST')) _bp.add_url_rule('/settings/persons', 'edit_persons', settings.RHEditEventPersons, methods=('GET', 'POST')) _bp.add_url_rule('/settings/contact-info', 'edit_contact_info', settings.RHEditEventContactInfo, methods=('GET', 'POST')) _bp.add_url_rule('/settings/classification', 'edit_classification', settings.RHEditEventClassification, methods=('GET', 'POST')) # Actions _bp.add_url_rule('/delete', 'delete', actions.RHDeleteEvent, methods=('GET', 'POST')) _bp.add_url_rule('/change-type', 'change_type', actions.RHChangeEventType, methods=('POST',)) _bp.add_url_rule('/lock', 'lock', actions.RHLockEvent, methods=('GET', 'POST'))
# 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.events import event_object_url_prefixes from indico.modules.events.notes.controllers import RHCompileNotes, RHEditNote, RHDeleteNote, RHViewNote from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('event_notes', __name__, template_folder='templates', virtual_template_folder='events/notes', url_prefix='/event/<confId>') _bp.add_url_rule('/note/compile', 'compile', RHCompileNotes, methods=('GET', 'POST'), defaults={'object_type': 'event'}) for object_type, prefixes in event_object_url_prefixes.iteritems(): for prefix in prefixes: _bp.add_url_rule(prefix + '/note/', 'view', RHViewNote, defaults={'object_type': object_type})
from indico.modules.categories.controllers.management import (RHCreateCategory, RHDeleteCategory, RHDeleteEvents, RHDeleteSubcategories, RHManageCategoryContent, RHManageCategoryIcon, RHManageCategoryLogo, RHManageCategoryProtection, RHManageCategorySettings, RHMoveCategory, RHMoveEvents, RHMoveSubcategories, RHSortSubcategories, RHSplitCategory) from indico.web.flask.util import make_compat_redirect_func, redirect_view, url_for from indico.web.flask.wrappers import IndicoBlueprint def _redirect_event_creation(category_id, event_type): anchor = 'create-event:{}:{}'.format(event_type, category_id) return redirect(url_for('.display', category_id=category_id, _anchor=anchor)) _bp = IndicoBlueprint('categories', __name__, template_folder='templates', virtual_template_folder='categories', url_prefix='/category/<int:category_id>') # Category management _bp.add_url_rule('/manage/', 'manage_content', RHManageCategoryContent) _bp.add_url_rule('/manage/delete', 'delete', RHDeleteCategory, methods=('POST',)) _bp.add_url_rule('/manage/icon', 'manage_icon', RHManageCategoryIcon, methods=('POST', 'DELETE')) _bp.add_url_rule('/manage/logo', 'manage_logo', RHManageCategoryLogo, methods=('POST', 'DELETE')) _bp.add_url_rule('/manage/move', 'move', RHMoveCategory, methods=('POST',)) _bp.add_url_rule('/manage/protection', 'manage_protection', RHManageCategoryProtection, methods=('GET', 'POST')) _bp.add_url_rule('/manage/settings', 'manage_settings', RHManageCategorySettings, methods=('POST', 'GET')) # Event management _bp.add_url_rule('/manage/events/delete', 'delete_events', RHDeleteEvents, methods=('GET', 'POST')) _bp.add_url_rule('/manage/events/move', 'move_events', RHMoveEvents, methods=('POST',)) _bp.add_url_rule('/manage/events/split', 'split_category', RHSplitCategory, methods=('GET', 'POST'))
from indico.modules.events.sessions.controllers.display import (RHDisplaySession, RHDisplaySessionList, RHExportSessionTimetableToPDF, RHExportSessionToICAL) from indico.modules.events.sessions.controllers.management.sessions import (RHCreateSession, RHCreateSessionType, RHDeleteSessions, RHDeleteSessionType, RHEditSessionType, RHExportSessionsCSV, RHExportSessionsExcel, RHExportSessionsPDF, RHManageSessionBlock, RHManageSessionTypes, RHModifySession, RHSessionACL, RHSessionACLMessage, RHSessionBlocks, RHSessionPersonList, RHSessionProtection, RHSessionREST, RHSessionsList) from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('sessions', __name__, template_folder='templates', virtual_template_folder='events/sessions', url_prefix='/event/<confId>') _bp.add_url_rule('/manage/sessions/', 'session_list', RHSessionsList) _bp.add_url_rule('/manage/sessions/create', 'create_session', RHCreateSession, methods=('GET', 'POST')) _bp.add_url_rule('/manage/sessions/delete', 'delete_sessions', RHDeleteSessions, methods=('POST',)) _bp.add_url_rule('/manage/sessions/sessions.csv', 'export_csv', RHExportSessionsCSV, methods=('POST',)) _bp.add_url_rule('/manage/sessions/sessions.xlsx', 'export_excel', RHExportSessionsExcel, methods=('POST',)) _bp.add_url_rule('/manage/sessions/sessions.pdf', 'export_pdf', RHExportSessionsPDF, methods=('POST',)) _bp.add_url_rule('/manage/sessions/<int:session_id>', 'session_rest', RHSessionREST, methods=('PATCH', 'DELETE')) _bp.add_url_rule('/manage/sessions/<int:session_id>/blocks', 'session_blocks', RHSessionBlocks) _bp.add_url_rule('/manage/sessions/<int:session_id>/modify', 'modify_session', RHModifySession, methods=('GET', 'POST')) _bp.add_url_rule('/manage/sessions/person-list/', 'person_list', RHSessionPersonList, methods=('POST',)) _bp.add_url_rule('/manage/sessions/<int:session_id>/protection', 'session_protection', RHSessionProtection, methods=('GET', 'POST')) _bp.add_url_rule('/manage/sessions/<int:session_id>/blocks/<int:block_id>', 'manage_session_block', RHManageSessionBlock, methods=('GET', 'POST'))
RHRegistrationsExportPDFTable, RHRegistrationsExportPDFBook, RHRegistrationsExportCSV, RHRegistrationsExportExcel, RHRegistrationTogglePayment, RHRegistrationsPrintBadges, RHRegistrationApprove, RHRegistrationReject, RHRegistrationsModifyStatus, RHRegistrationsExportAttachments, RHRegistrationCheckIn, RHRegistrationBulkCheckIn) from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('event_registration', __name__, url_prefix='/event/<confId>', template_folder='templates', virtual_template_folder='events/registration', event_feature='registration') # Management _bp.add_url_rule('/manage/registration/', 'manage_regform_list', RHManageRegistrationForms) _bp.add_url_rule('/manage/registration/create', 'create_regform', RHRegistrationFormCreate, methods=('GET', 'POST')) # Single registration form management _bp.add_url_rule('/manage/registration/<int:reg_form_id>/', 'manage_regform', RHRegistrationFormManage) _bp.add_url_rule('/manage/registration/<int:reg_form_id>/edit', 'edit_regform', RHRegistrationFormEdit, methods=('GET', 'POST')) _bp.add_url_rule('/manage/registration/<int:reg_form_id>/delete', 'delete_regform', RHRegistrationFormDelete, methods=('POST',)) _bp.add_url_rule('/manage/registration/<int:reg_form_id>/open', 'open_regform', RHRegistrationFormOpen, methods=('POST',)) _bp.add_url_rule('/manage/registration/<int:reg_form_id>/close', 'close_regform', RHRegistrationFormClose, methods=('POST',))
announcement, taskManager, maintenance, domains, users, groups, templates, conferenceModif, services, api, oauth, ) from indico.web.flask.wrappers import IndicoBlueprint admin = IndicoBlueprint("admin", __name__, url_prefix="/admin") # General settings admin.add_url_rule("/", "adminList", admins.RHAdminArea) admin.add_url_rule("/settings/general/news", "adminList-switchNewsActive", admins.RHAdminSwitchNewsActive) admin.add_url_rule("/settings/general/", "generalInfoModification", admins.RHGeneralInfoModification) admin.add_url_rule( "/settings/general/", "generalInfoModification-update", admins.RHGeneralInfoPerformModification, methods=("POST",) ) # System settings admin.add_url_rule("/settings/system", "adminSystem", admins.RHSystem) admin.add_url_rule("/settings/system/modify", "adminSystem-modify", admins.RHSystemModify, methods=("GET", "POST")) # Announcement admin.add_url_rule("/announcement", "adminAnnouncement", announcement.RHAnnouncementModif)
# # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.rb.controllers.user import event from indico.web.flask.wrappers import IndicoBlueprint event_mgmt = IndicoBlueprint('event_mgmt', __name__, url_prefix='/event/<confId>/manage') # Booking and event assignment list event_mgmt.add_url_rule('/rooms/', 'rooms_booking_list', event.RHRoomBookingEventBookingList) event_mgmt.add_url_rule('/rooms/choose-event', 'rooms_choose_event', event.RHRoomBookingEventChooseEvent) # View/modify booking event_mgmt.add_url_rule('/rooms/booking/<roomLocation>/<int:resvID>/', 'rooms_booking_details', event.RHRoomBookingEventBookingDetails) event_mgmt.add_url_rule('/rooms/booking/<roomLocation>/<int:resvID>/modify', 'rooms_booking_modify', event.RHRoomBookingEventBookingModifyBooking,
# This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 3 of the # License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.bootstrap.controllers import RHBootstrap from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('bootstrap', __name__, template_folder='templates', virtual_template_folder='bootstrap') _bp.add_url_rule('/bootstrap', 'index', RHBootstrap, methods=('GET', 'POST'))
RHEditContributionType, RHCreateContributionType, RHDeleteContributionType, RHManageContributionFields, RHCreateContributionField, RHEditContributionField, RHDeleteContributionField, RHSortContributionFields, RHManageDescriptionField, RHSortSubContributions, RHContributionACL, RHContributionACLMessage) from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('contributions', __name__, template_folder='templates', virtual_template_folder='events/contributions', url_prefix='/event/<confId>') _bp.add_url_rule('/manage/contributions/', 'manage_contributions', RHContributions) _bp.add_url_rule('/manage/contributions/customize', 'customize_contrib_report', RHContributionsReportCustomize, methods=('GET', 'POST')) _bp.add_url_rule('/manage/contributions/static-url', 'generate_static_url', RHContributionsReportStaticURL, methods=('POST',)) _bp.add_url_rule('/manage/contributions/create', 'manage_create_contrib', RHCreateContribution, methods=('GET', 'POST')) _bp.add_url_rule('/manage/contributions/delete', 'manage_delete_contribs', RHDeleteContributions, methods=('POST',)) _bp.add_url_rule('/manage/contributions/person-list', 'person_list', RHContributionPersonList, methods=('POST',)) _bp.add_url_rule('/manage/contributions/material-package', 'material_package', RHContributionsMaterialPackage, methods=('POST',)) _bp.add_url_rule('/manage/contributions/contributions.csv', 'contributions_csv_export', RHContributionsExportCSV, methods=('POST',)) _bp.add_url_rule('/manage/contributions/contributions.xlsx', 'contributions_excel_export', RHContributionsExportExcel, methods=('POST',))
## License, or (at your option) any later version. ## ## Indico 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 Indico. If not, see <http://www.gnu.org/licenses/>. from MaKaC.webinterface.rh import welcome, helpDisplay, newsDisplay, payment, lang, resetTimezone, about, contact, \ JSContent, errors, materialDisplay from indico.web.flask.wrappers import IndicoBlueprint misc = IndicoBlueprint('misc', __name__) misc.add_url_rule('/', 'index', welcome.RHWelcome) misc.add_url_rule('/help', 'help', helpDisplay.RHHelp) misc.add_url_rule('/news', 'news', newsDisplay.RHNews) misc.add_url_rule('/payment', 'payment', payment.RHPaymentModule, methods=('GET', 'POST')) misc.add_url_rule('/change-language', 'changeLang', lang.RHChangeLang, methods=('GET', 'POST')) misc.add_url_rule('/change-timezone', 'resetSessionTZ', resetTimezone.RHResetTZ, methods=('GET', 'POST')) misc.add_url_rule('/about', 'about', about.RHAbout) misc.add_url_rule('/contact', 'contact', contact.RHContact) misc.add_url_rule('/vars.js', 'JSContent-getVars', JSContent.RHGetVarsJs) misc.add_url_rule('/report-error', 'errors', errors.RHErrorReporting, methods=('GET', 'POST')) misc.add_url_rule('/error-report/<report_id>/<filename>', 'error-report-download', errors.RHDownloadErrorReport) misc.add_url_rule('/conversion-finished', 'getConvertedFile', materialDisplay.RHMaterialAddConvertedFile, methods=('POST',))
from indico.modules.events.sessions.controllers.display import ( RHDisplaySession, RHDisplaySessionList, RHExportSessionTimetableToPDF, RHExportSessionToICAL) from indico.modules.events.sessions.controllers.management.sessions import ( RHCreateSession, RHCreateSessionType, RHDeleteSessions, RHDeleteSessionType, RHEditSessionType, RHExportSessionsCSV, RHExportSessionsExcel, RHExportSessionsPDF, RHManageSessionBlock, RHManageSessionTypes, RHModifySession, RHSessionACL, RHSessionACLMessage, RHSessionBlocks, RHSessionPersonList, RHSessionProtection, RHSessionREST, RHSessionsList) from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('sessions', __name__, template_folder='templates', virtual_template_folder='events/sessions', url_prefix='/event/<int:event_id>') _bp.add_url_rule('/manage/sessions/', 'session_list', RHSessionsList) _bp.add_url_rule('/manage/sessions/create', 'create_session', RHCreateSession, methods=('GET', 'POST')) _bp.add_url_rule('/manage/sessions/delete', 'delete_sessions', RHDeleteSessions, methods=('POST', )) _bp.add_url_rule('/manage/sessions/sessions.csv', 'export_csv', RHExportSessionsCSV,
# This file is part of Indico. # Copyright (C) 2002 - 2017 European Organization for Nuclear Research (CERN). # # Indico 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 3 of the # License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from indico.web.flask.wrappers import IndicoBlueprint event = IndicoBlueprint('event', __name__, url_prefix='/event/<confId>') import indico.web.flask.blueprints.event.display.main import indico.web.flask.blueprints.event.display.misc
# License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from MaKaC.webinterface.rh import (welcome, helpDisplay, newsDisplay, lang, resetTimezone, about, contact, errors, materialDisplay) from indico.web.flask.wrappers import IndicoBlueprint misc = IndicoBlueprint('misc', __name__) misc.add_url_rule('/', 'index', welcome.RHWelcome) misc.add_url_rule('/help', 'help', helpDisplay.RHHelp) misc.add_url_rule('/news', 'news', newsDisplay.RHNews) misc.add_url_rule('/change-language', 'changeLang', lang.RHChangeLang, methods=('GET', 'POST')) misc.add_url_rule('/change-timezone', 'resetSessionTZ', resetTimezone.RHResetTZ, methods=('GET', 'POST')) misc.add_url_rule('/about', 'about', about.RHAbout) misc.add_url_rule('/contact', 'contact', contact.RHContact) misc.add_url_rule('/report-error',
## published by the Free Software Foundation; either version 3 of the ## License, or (at your option) any later version. ## ## Indico 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 Indico. If not, see <http://www.gnu.org/licenses/>. from MaKaC.webinterface.rh import materialDisplay, fileAccess from indico.web.flask.wrappers import IndicoBlueprint files = IndicoBlueprint("files", __name__) # Material (event) files.add_url_rule("/event/<confId>/material/<materialId>/", "materialDisplay", materialDisplay.RHMaterialDisplay) files.add_url_rule( "/event/<confId>/contribution/<contribId>/material/<materialId>/", "materialDisplay", materialDisplay.RHMaterialDisplay, ) files.add_url_rule( "/event/<confId>/session/<sessionId>/contribution/<contribId>/material/<materialId>/", "materialDisplay", materialDisplay.RHMaterialDisplay, ) files.add_url_rule( "/event/<confId>/material/<materialId>/accesskey",
# General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.events.tracks.controllers import ( RHManageTracks, RHEditProgram, RHCreateTrack, RHEditTrack, RHSortTracks, RHDeleteTrack, RHDisplayTracks, RHTracksPDF) from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('tracks', __name__, template_folder='templates', virtual_template_folder='events/tracks', url_prefix='/event/<confId>') _bp.add_url_rule('/manage/tracks/', 'manage', RHManageTracks) _bp.add_url_rule('/manage/tracks/program', 'edit_program', RHEditProgram, methods=('GET', 'POST')) _bp.add_url_rule('/manage/tracks/create', 'create_track', RHCreateTrack, methods=('GET', 'POST')) _bp.add_url_rule('/manage/tracks/sort', 'sort_tracks', RHSortTracks,
from flask import request from indico.modules.users.api import fetch_authenticated_user from indico.modules.users.controllers import ( RHAcceptRegistrationRequest, RHAdmins, RHPersonalData, RHRegistrationRequestList, RHRejectRegistrationRequest, RHUserDashboard, RHUserEmails, RHUserEmailsDelete, RHUserEmailsSetPrimary, RHUserEmailsVerify, RHUserFavorites, RHUserFavoritesCategoryAPI, RHUserFavoritesUserRemove, RHUserFavoritesUsersAdd, RHUserPreferences, RHUsersAdmin, RHUsersAdminCreate, RHUsersAdminMerge, RHUsersAdminMergeCheck, RHUsersAdminSettings, RHUserSuggestionsRemove) from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('users', __name__, template_folder='templates', virtual_template_folder='users', url_prefix='/user') # Admins _bp.add_url_rule('!/admin/admins', 'admins', RHAdmins, methods=('GET', 'POST')) # User management _bp.add_url_rule('!/admin/users/', 'users_admin', RHUsersAdmin, methods=('GET', 'POST')) _bp.add_url_rule('!/admin/users/settings', 'users_admin_settings', RHUsersAdminSettings, methods=('GET', 'POST'))
# # Indico 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 3 of the # License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from MaKaC.webinterface.rh.fileAccess import RHFileAccess from indico.web.flask.wrappers import IndicoBlueprint files = IndicoBlueprint('files', __name__) # TODO: Remove when reviewing is rewritten. files.add_url_rule( '/event/<confId>/session/<sessionId>/contribution/<contribId>/material-old/<materialId>/<resId>.<fileExt>', 'getFile-access', RHFileAccess) files.add_url_rule('/event/<confId>/contribution/<contribId>/material-old/<materialId>/<resId>.<fileExt>', 'getFile-access', RHFileAccess) # TODO: Remove when the registration form is rewritten files.add_url_rule('/event/<confId>/registration/attachments/<registrantId>-<resId>.<fileExt>', 'getFile-access', RHFileAccess)
# This file is part of Indico. # Copyright (C) 2002 - 2017 European Organization for Nuclear Research (CERN). # # Indico 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 3 of the # License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.legal.controllers import RHDisplayLegalMessages, RHManageLegalMessages from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('legal', __name__, template_folder='templates', virtual_template_folder='legal') _bp.add_url_rule('/admin/legal', 'manage', RHManageLegalMessages, methods=('GET', 'POST')) _bp.add_url_rule('/tos', 'display_tos', RHDisplayLegalMessages)
# General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.groups.controllers import (RHGroupDelete, RHGroupDeleteMember, RHGroupDetails, RHGroupEdit, RHGroupMembers, RHGroups) from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('groups', __name__, template_folder='templates', virtual_template_folder='groups', url_prefix='/admin/groups') _bp.add_url_rule('/', 'groups', RHGroups, methods=('GET', 'POST')) _bp.add_url_rule('/<provider>/<group_id>/', 'group_details', RHGroupDetails) _bp.add_url_rule('/<provider>/<group_id>/members', 'group_members', RHGroupMembers) _bp.add_url_rule('/indico/new', 'group_add', RHGroupEdit, methods=('GET', 'POST')) _bp.add_url_rule('/<any(indico):provider>/<int:group_id>/edit', 'group_edit', RHGroupEdit, methods=('GET', 'POST'))
# This file is part of Indico. # Copyright (C) 2002 - 2020 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. from __future__ import unicode_literals from indico.modules.events.editing.controllers import frontend from indico.modules.events.editing.controllers.backend import common, editable_list, management, service, timeline from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('event_editing', __name__, url_prefix='/event/<confId>', template_folder='templates', virtual_template_folder='events/editing') # Frontend (management) _bp.add_url_rule('/manage/editing/', 'dashboard', frontend.RHEditingDashboard) _bp.add_url_rule('/manage/editing/tags', 'manage_tags', frontend.RHEditingDashboard) _bp.add_url_rule('/manage/editing/<any(paper,slides,poster):type>/', 'manage_editable_type', frontend.RHEditingDashboard) _bp.add_url_rule('/manage/editing/<any(paper,slides,poster):type>/list', 'manage_editable_type_list', frontend.RHEditingDashboard) _bp.add_url_rule('/manage/editing/<any(paper,slides,poster):type>/types', 'manage_file_types', frontend.RHEditingDashboard) _bp.add_url_rule('/manage/editing/<any(paper,slides,poster):type>/review-conditions', 'manage_review_conditions', frontend.RHEditingDashboard) # Frontend (timeline) contrib_prefix = '/contributions/<int:contrib_id>/editing/<any(paper,slides,poster):type>'
# This file is part of Indico. # Copyright (C) 2002 - 2020 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. from flask import current_app, g from indico.modules.events.papers.controllers import api, display, management, paper, templates from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('papers', __name__, url_prefix='/event/<confId>', template_folder='templates', virtual_template_folder='events/papers') # API _bp.add_url_rule('/papers/api/<int:contrib_id>', 'api_paper_details', api.RHPaperDetails) _bp.add_url_rule('/papers/api/<int:contrib_id>', 'api_reset_paper_state', api.RHResetPaperState, methods=('DELETE', )) _bp.add_url_rule('/papers/api/<int:contrib_id>/comment', 'api_create_comment', api.RHCreatePaperComment, methods=('POST', )) _bp.add_url_rule( '/papers/api/<int:contrib_id>/revision/<int:revision_id>/comment/<int:comment_id>',
# 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.events.requests.controllers import ( RHRequestsEventRequestDetails, RHRequestsEventRequestProcess, RHRequestsEventRequests, RHRequestsEventRequestWithdraw) from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('requests', __name__, template_folder='templates', virtual_template_folder='events/requests', url_prefix='/event/<confId>/manage/requests') # Event management _bp.add_url_rule('/', 'event_requests', RHRequestsEventRequests) _bp.add_url_rule('/<type>/', 'event_requests_details', RHRequestsEventRequestDetails, methods=('GET', 'POST')) _bp.add_url_rule('/<type>/withdraw', 'event_requests_withdraw', RHRequestsEventRequestWithdraw, methods=('POST', )) _bp.add_url_rule('/<type>/process', 'event_requests_process',
# 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from flask import request from indico.modules.auth.controllers import (RHLogin, RHLoginForm, RHLogout, RHRegister, RHLinkAccount, RHResetPassword, RHAccounts, RHRemoveAccount) from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('auth', __name__, template_folder='templates', virtual_template_folder='auth') _bp.add_url_rule('/login/', 'login', RHLogin, methods=('GET', 'POST')) _bp.add_url_rule('/login/<provider>/', 'login', RHLogin) _bp.add_url_rule('/login/<provider>/form', 'login_form', RHLoginForm) _bp.add_url_rule('/login/<provider>/link-account', 'link_account', RHLinkAccount, methods=('GET', 'POST')) _bp.add_url_rule('/logout/', 'logout', RHLogout, methods=('GET', 'POST')) _bp.add_url_rule('/register/', 'register', RHRegister, methods=('GET', 'POST'), defaults={'provider': None}) _bp.add_url_rule('/register/<provider>', 'register', RHRegister, methods=('GET', 'POST')) _bp.add_url_rule('/reset-password/', 'resetpass', RHResetPassword, methods=('GET', 'POST')) with _bp.add_prefixed_rules('/user/<int:user_id>', '/user'): _bp.add_url_rule('/accounts/', 'accounts', RHAccounts, methods=('GET', 'POST'))
# -*- coding: utf-8 -*- ## ## ## This file is part of Indico. ## Copyright (C) 2002 - 2014 European Organization for Nuclear Research (CERN). ## ## Indico 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 3 of the ## License, or (at your option) any later version. ## ## Indico 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 Indico. If not, see <http://www.gnu.org/licenses/>. import indico.ext.importer.handlers as handlers from indico.web.flask.wrappers import IndicoBlueprint blueprint = IndicoBlueprint('importer', __name__, url_prefix='/importer') blueprint.add_url_rule('/<path:filepath>', 'htdocs', handlers.RHImporterHtdocs)
import sentry_sdk from flask import current_app, g, jsonify, request, session from itsdangerous import BadData from sqlalchemy.exc import DatabaseError from werkzeug.exceptions import BadRequestKeyError, Forbidden, HTTPException, UnprocessableEntity from indico.core.errors import IndicoError, get_error_description from indico.core.logger import Logger from indico.modules.auth.util import redirect_to_login from indico.util.i18n import _ from indico.web.errors import render_error from indico.web.flask.wrappers import IndicoBlueprint from indico.web.util import ExpectedError errors_bp = IndicoBlueprint('errors', __name__) @errors_bp.app_errorhandler(Forbidden) def handle_forbidden(exc): if exc.response: return exc if (session.user is None and not request.is_xhr and not request.is_json and request.blueprint != 'auth' and not g.get('get_request_user_failed')): return redirect_to_login( reason=_('Please log in to access this page.')) return render_error(exc, _('Access Denied'), get_error_description(exc), exc.code)
# This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 3 of the # License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.announcement.controllers import RHAnnouncement from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('announcement', __name__, template_folder='templates', virtual_template_folder='announcement') _bp.add_url_rule('/admin/announcement', 'manage', RHAnnouncement, methods=('GET', 'POST'))
# Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. from __future__ import unicode_literals from indico.modules.events.reminders.controllers import (RHAddReminder, RHDeleteReminder, RHEditReminder, RHListReminders, RHPreviewReminder) from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('event_reminders', __name__, template_folder='templates', virtual_template_folder='events/reminders', url_prefix='/event/<confId>/manage/reminders') _bp.add_url_rule('/', 'list', RHListReminders) _bp.add_url_rule('/add', 'add', RHAddReminder, methods=('GET', 'POST')) _bp.add_url_rule('/preview', 'preview', RHPreviewReminder, methods=('POST', )) _bp.add_url_rule('/<int:reminder_id>/', 'edit', RHEditReminder, methods=('GET', 'POST')) _bp.add_url_rule('/<int:reminder_id>/delete', 'delete', RHDeleteReminder, methods=('POST', ))
## License, or (at your option) any later version. ## ## Indico 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 Indico. If not, see <http://www.gnu.org/licenses/>. from MaKaC.webinterface.rh import calendar, categoryDisplay from indico.web.flask.util import redirect_view from indico.web.flask.wrappers import IndicoBlueprint category = IndicoBlueprint('category', __name__, url_prefix='/category') # Short URLs category.add_url_rule('!/categ/<categId>', view_func=redirect_view('.categoryDisplay'), strict_slashes=False) category.add_url_rule('!/c/<categId>', view_func=redirect_view('.categoryDisplay'), strict_slashes=False) # Display category.add_url_rule('/<categId>/', 'categoryDisplay', categoryDisplay.RHCategoryDisplay) category.add_url_rule('/<categId>/events.atom', 'categoryDisplay-atom', categoryDisplay.RHCategoryToAtom) category.add_url_rule('/<categId>/events.rss', 'categoryDisplay-rss', categoryDisplay.RHCategoryToRSS) category.add_url_rule('/<categId>/events.ics', 'categoryDisplay-ical', categoryDisplay.RHCategoryToiCal) category.add_url_rule('/<categId>/icon', 'categoryDisplay-getIcon', categoryDisplay.RHCategoryGetIcon) category.add_url_rule('/<categId>/statistics', 'categoryStatistics', categoryDisplay.RHCategoryStatistics) # Overview
# License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.events import event_object_url_prefixes from indico.modules.events.notes.controllers import RHCompileNotes, RHEditNote, RHDeleteNote, RHViewNote from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('event_notes', __name__, template_folder='templates', virtual_template_folder='events/notes', url_prefix='/event/<confId>') _bp.add_url_rule('/note/compile', 'compile', RHCompileNotes, methods=('GET', 'POST'), defaults={'object_type': 'event'}) for object_type, prefixes in event_object_url_prefixes.iteritems(): for prefix in prefixes: _bp.add_url_rule(prefix + '/note/', 'view', RHViewNote, defaults={'object_type': object_type}) _bp.add_url_rule(prefix + '/note/edit', 'edit', RHEditNote, methods=('GET', 'POST'), defaults={'object_type': object_type}) _bp.add_url_rule(prefix + '/note/delete', 'delete', RHDeleteNote, methods=('POST',), defaults={'object_type': object_type})
# You should have received a copy of the GNU General Public License # along with Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from flask import request from indico.modules.auth.controllers import (RHLogin, RHLoginForm, RHLogout, RHRegister, RHLinkAccount, RHResetPassword, RHAccounts, RHRemoveAccount) from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint auth_blueprint = _bp = IndicoBlueprint('auth', __name__, template_folder='templates') _bp.add_url_rule('/login/', 'login', RHLogin, methods=('GET', 'POST')) _bp.add_url_rule('/login/<provider>/', 'login', RHLogin) _bp.add_url_rule('/login/<provider>/form', 'login_form', RHLoginForm) _bp.add_url_rule('/login/<provider>/link-account', 'link_account', RHLinkAccount, methods=('GET', 'POST')) _bp.add_url_rule('/logout/', 'logout', RHLogout, methods=('GET', 'POST')) _bp.add_url_rule('/register/', 'register', RHRegister, methods=('GET', 'POST'),
# Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. from __future__ import unicode_literals from flask import jsonify, redirect from indico.modules.rb.controllers.backend import admin, blockings, bookings, locations, misc, rooms from indico.modules.rb.controllers.frontend import RHRoomBooking from indico.modules.rb.event import controllers as event from indico.web.flask.util import url_for from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('rb', __name__, template_folder='../rb/templates', virtual_template_folder='rb', url_prefix='/rooms') # Frontend _bp.add_url_rule('/', 'roombooking', RHRoomBooking) _bp.add_url_rule('/<path:path>', 'roombooking', RHRoomBooking) _bp.add_url_rule('/rooms-sprite-<version>.jpg', 'sprite', misc.RHRoomsSprite) _bp.add_url_rule('/rooms-sprite.jpg', 'sprite', misc.RHRoomsSprite) _bp.add_url_rule('/rooms/<int:room_id>.jpg', 'room_photo', rooms.RHRoomPhoto) # General backend _bp.add_url_rule('/api/<path:path>', '404', lambda path: (jsonify(), 404)) _bp.add_url_rule('/api/config', 'config', misc.RHConfig) _bp.add_url_rule('/api/stats', 'stats', misc.RHStats) _bp.add_url_rule('/api/map-areas', 'map_areas', misc.RHMapAreas) _bp.add_url_rule('/api/equipment', 'equipment_types', misc.RHEquipmentTypes) _bp.add_url_rule('/api/locations', 'locations', locations.RHLocations)
from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint from indico.modules.events.layout.compat import compat_page, compat_image from indico.modules.events.layout.controllers.images import RHImageDelete, RHImageDisplay, RHImageUpload, RHImages from indico.modules.events.layout.controllers.layout import ( RHLayoutEdit, RHLayoutCSSUpload, RHLayoutCSSDelete, RHLayoutLogoUpload, RHLayoutLogoDelete, RHLogoDisplay, RHLayoutCSSSaveTheme, RHLayoutCSSDisplay, RHLayoutCSSPreview) from indico.modules.events.layout.controllers.menu import ( RHMenuAddEntry, RHMenuDeleteEntry, RHMenuEdit, RHMenuToggleCustom, RHMenuEntryToggleEnabled, RHMenuEntryToggleDefault, RHMenuEntryEdit, RHMenuEntryPosition, RHPageDisplay) _bp = IndicoBlueprint('event_layout', __name__, template_folder='templates', virtual_template_folder='events/layout', url_prefix='/event/<confId>/manage/layout') _bp.add_url_rule('/', 'index', RHLayoutEdit, methods=('GET', 'POST')) _bp.add_url_rule('/menu/', 'menu', RHMenuEdit) _bp.add_url_rule('/menu/toggle-customize', 'menu_toggle_custom', RHMenuToggleCustom, methods=('POST', )) _bp.add_url_rule('/menu/<int:menu_entry_id>/', 'menu_entry_edit', RHMenuEntryEdit, methods=( 'GET', 'POST',
# This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 3 of the # License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.events.static.controllers import RHStaticSiteBuild, RHStaticSiteDownload, RHStaticSiteList from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('static_site', __name__, template_folder='templates', virtual_template_folder='events/static', url_prefix='/event/<confId>/manage/tools/static-site') # Event management _bp.add_url_rule('/', 'list', RHStaticSiteList) _bp.add_url_rule('/<int:id>.zip', 'download', RHStaticSiteDownload) _bp.add_url_rule('/build', 'build', RHStaticSiteBuild, methods=('POST',))
# LICENSE file for more details. from __future__ import unicode_literals from indico.modules.events.agreements.controllers import ( RHAgreementForm, RHAgreementManager, RHAgreementManagerDetails, RHAgreementManagerDetailsDownloadAgreement, RHAgreementManagerDetailsRemind, RHAgreementManagerDetailsRemindAll, RHAgreementManagerDetailsSend, RHAgreementManagerDetailsSendAll, RHAgreementManagerDetailsSubmitAnswer, RHAgreementManagerDetailsToggleNotifications) from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('agreements', __name__, template_folder='templates', virtual_template_folder='events/agreements', url_prefix='/event/<confId>') # Event management _bp.add_url_rule('/manage/agreements/', 'event_agreements', RHAgreementManager) _bp.add_url_rule('/manage/agreements/<definition>/', 'event_agreements_details', RHAgreementManagerDetails) _bp.add_url_rule('/manage/agreements/<definition>/toggle-notifications', 'toggle_notifications', RHAgreementManagerDetailsToggleNotifications, methods=('POST', )) _bp.add_url_rule('/manage/agreements/<definition>/send', 'event_agreements_details_send', RHAgreementManagerDetailsSend, methods=('GET', 'POST'))
# This file is part of Indico. # Copyright (C) 2002 - 2017 European Organization for Nuclear Research (CERN). # # Indico 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 3 of the # License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.networks.controllers import (RHCreateNetworkGroup, RHDeleteNetworkGroup, RHEditNetworkGroup, RHManageNetworks) from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('networks', __name__, template_folder='templates', virtual_template_folder='networks') _bp.add_url_rule('/admin/networks/', 'manage', RHManageNetworks) _bp.add_url_rule('/admin/networks/create', 'create_group', RHCreateNetworkGroup, methods=('GET', 'POST')) _bp.add_url_rule('/admin/networks/<int:network_group_id>/', 'edit_group', RHEditNetworkGroup, methods=('GET', 'POST')) _bp.add_url_rule('/admin/networks/<int:network_group_id>/delete', 'delete_group', RHDeleteNetworkGroup, methods=('GET', 'POST'))
RHLegacyTimetableScheduleContribution, RHLegacyTimetableReschedule, RHLegacyTimetableFitBlock, RHLegacyTimetableEditEntry, RHLegacyTimetableEditEntryTime, RHLegacyTimetableMoveEntry, RHLegacyTimetableEditEntryDateTime, RHLegacyTimetableShiftEntries, RHLegacyTimetableSwapEntries, RHLegacyTimetableEditSession, RHLegacyTimetableBreakREST) from indico.modules.events.timetable.controllers.manage import (RHManageTimetable, RHManageSessionTimetable, RHTimetableREST, RHManageTimetableEntryInfo) from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('timetable', __name__, template_folder='templates', virtual_template_folder='events/timetable', url_prefix='/event/<confId>') # Management _bp.add_url_rule('/manage/timetable/', 'management', RHManageTimetable) _bp.add_url_rule('/manage/timetable/', 'timetable_rest', RHTimetableREST, methods=('POST',)) _bp.add_url_rule('/manage/timetable/<int:entry_id>', 'timetable_rest', RHTimetableREST, methods=('PATCH', 'DELETE')) _bp.add_url_rule('/manage/timetable/session/<int:session_id>/', 'manage_session', RHManageSessionTimetable) # Timetable legacy operations _bp.add_url_rule('/manage/timetable/add-session', 'add_session', RHLegacyTimetableAddSession, methods=('GET', 'POST')) _bp.add_url_rule('/manage/timetable/break/<int:break_id>', 'legacy_break_rest', RHLegacyTimetableBreakREST, methods=('PATCH',)) with _bp.add_prefixed_rules('/manage/timetable/session/<int:session_id>', '/manage/timetable'): _bp.add_url_rule('/', 'session_rest', RHLegacyTimetableEditSession, methods=('PATCH',)) _bp.add_url_rule('/entry/<int:entry_id>/info', 'entry_info_manage', RHManageTimetableEntryInfo)
# You should have received a copy of the GNU General Public License # along with Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.events import event_management_object_url_prefixes from indico.modules.events.management.controllers import ( RHDeleteEvent, RHLockEvent, RHUnlockEvent, RHShowNonInheriting, RHEventProtection, RHMoveEvent, RHEventACL, RHEventACLMessage, RHManageReferences, RHManageEventLocation, RHManageEventPersonLinks, RHManageEventKeywords) from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('event_management', __name__, template_folder='templates', virtual_template_folder='events/management', url_prefix='/event/<confId>/manage') _bp.add_url_rule('/delete', 'delete', RHDeleteEvent, methods=('GET', 'POST')) _bp.add_url_rule('/lock', 'lock', RHLockEvent, methods=('GET', 'POST')) _bp.add_url_rule('/unlock', 'unlock', RHUnlockEvent, methods=('POST', )) _bp.add_url_rule('/protection', 'protection', RHEventProtection, methods=('GET', 'POST')) _bp.add_url_rule('/protection/acl', 'acl', RHEventACL) _bp.add_url_rule('/protection/acl-message', 'acl_message', RHEventACLMessage) _bp.add_url_rule('/move', 'move', RHMoveEvent, methods=('POST', )) _bp.add_url_rule('/external-ids', 'manage_event_references',
RHMoveSubcategories, RHRemoveCategoryRoleMember, RHSortSubcategories, RHSplitCategory) from indico.modules.users import User from indico.web.flask.util import make_compat_redirect_func, redirect_view, url_for from indico.web.flask.wrappers import IndicoBlueprint def _redirect_event_creation(category_id, event_type): anchor = f'create-event:{event_type}:{category_id}' return redirect( url_for('.display', category_id=category_id, _anchor=anchor)) _bp = IndicoBlueprint('categories', __name__, template_folder='templates', virtual_template_folder='categories', url_prefix='/category/<int:category_id>') # Category management _bp.add_url_rule('/manage/', 'manage_content', RHManageCategoryContent) _bp.add_url_rule('/manage/delete', 'delete', RHDeleteCategory, methods=('POST', )) _bp.add_url_rule('/manage/icon', 'manage_icon', RHManageCategoryIcon, methods=('POST', 'DELETE')) _bp.add_url_rule('/manage/logo', 'manage_logo',
# 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from flask import current_app, g from indico.modules.events.papers.controllers import display, management, paper, templates from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('papers', __name__, url_prefix='/event/<confId>', template_folder='templates', virtual_template_folder='events/papers') # Display pages _bp.add_url_rule('/papers/', 'call_for_papers', display.RHCallForPapers) _bp.add_url_rule('/papers/select-contribution', 'select_contribution', display.RHSelectContribution) _bp.add_url_rule('/papers/<int:contrib_id>/', 'paper_timeline', display.RHPaperTimeline) _bp.add_url_rule('/papers/<int:contrib_id>/files/<int:file_id>-<filename>', 'download_file', display.RHDownloadPaperFile) _bp.add_url_rule('/papers/templates/<int:template_id>-<filename>', 'download_template', templates.RHDownloadPaperTemplate) _bp.add_url_rule('/contributions/<int:contrib_id>/paper/submit', 'submit_revision', display.RHSubmitPaper, methods=('GET', 'POST')) # Paper reviews/judgments _bp.add_url_rule('/papers/<int:contrib_id>/review/type/<review_type>', 'submit_review', display.RHSubmitPaperReview, methods=('GET', 'POST'))
## published by the Free Software Foundation; either version 3 of the ## License, or (at your option) any later version. ## ## Indico 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 Indico. If not, see <http://www.gnu.org/licenses/>. from MaKaC.webinterface.rh import categoryMod from indico.web.flask.wrappers import IndicoBlueprint category_mgmt = IndicoBlueprint('category_mgmt', __name__, url_prefix='/category/<categId>/manage') # Creation category_mgmt.add_url_rule('!/category/<categId>/create/subcategory', 'categoryCreation', categoryMod.RHCategoryCreation, methods=('GET', 'POST')) category_mgmt.add_url_rule('!/category/<categId>/create/subcategory/save', 'categoryCreation-create', categoryMod.RHCategoryPerformCreation, methods=('POST', )) # Event creation is in event.creation # General settings category_mgmt.add_url_rule('/', 'categoryModification',
# General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.events import event_management_object_url_prefixes from indico.modules.events.management.controllers import RHDeleteEvent, RHLockEvent, RHUnlockEvent, RHShowNonInheriting from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint( "event_management", __name__, template_folder="templates", virtual_template_folder="events/management", url_prefix="/event/<confId>/manage", ) _bp.add_url_rule("/delete", "delete", RHDeleteEvent, methods=("GET", "POST")) _bp.add_url_rule("/lock", "lock", RHLockEvent, methods=("GET", "POST")) _bp.add_url_rule("/unlock", "unlock", RHUnlockEvent, methods=("POST",)) for object_type, prefixes in event_management_object_url_prefixes.iteritems(): if object_type == "subcontribution": continue for prefix in prefixes: prefix = "!/event/<confId>" + prefix _bp.add_url_rule( prefix + "/show-non-inheriting",
RHDeleteCategoryAttachment) from indico.modules.attachments.controllers.management.event import (RHManageEventAttachments, RHAddEventAttachmentFiles, RHAddEventAttachmentLink, RHEditEventAttachment, RHCreateEventFolder, RHEditEventFolder, RHDeleteEventFolder, RHDeleteEventAttachment, RHPackageEventAttachmentsManagement) from indico.modules.events import event_management_object_url_prefixes, event_object_url_prefixes from indico.util.caching import memoize from indico.web.flask.util import make_view_func, make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('attachments', __name__, template_folder='templates', virtual_template_folder='attachments') @memoize def _dispatch(event_rh, category_rh): event_view = make_view_func(event_rh) categ_view = make_view_func(category_rh) def view_func(**kwargs): return categ_view(**kwargs) if kwargs['object_type'] == 'category' else event_view(**kwargs) return view_func # Management items = itertools.chain(event_management_object_url_prefixes.iteritems(), [('category', ['/manage'])])
# This file is part of Indico. # Copyright (C) 2002 - 2015 European Organization for Nuclear Research (CERN). # # Indico 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 3 of the # License, or (at your option) any later version. # # Indico 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 Indico; if not, see <http://www.gnu.org/licenses/>. from indico.core.plugins.controllers import RHPlugins, RHPluginDetails from indico.web.flask.wrappers import IndicoBlueprint plugins_blueprint = _bp = IndicoBlueprint('plugins', __name__, url_prefix='/admin/plugins', template_folder='templates') _bp.add_url_rule('/', 'index', RHPlugins) _bp.add_url_rule('/<plugin>/', 'details', RHPluginDetails, methods=('GET', 'POST'))
# This file is part of Indico. # Copyright (C) 2002 - 2021 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. from indico.modules.events.roles.controllers import (RHAddEventRole, RHAddEventRoleMembers, RHDeleteEventRole, RHEditEventRole, RHEventRoleMembersImportCSV, RHEventRoles, RHRemoveEventRoleMember) from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('event_roles', __name__, template_folder='templates', virtual_template_folder='events/roles', url_prefix='/event/<confId>/manage/roles') _bp.add_url_rule('/', 'manage', RHEventRoles) _bp.add_url_rule('/create', 'add_role', RHAddEventRole, methods=('GET', 'POST')) _bp.add_url_rule('/<int:role_id>/edit', 'edit_role', RHEditEventRole, methods=('GET', 'POST')) _bp.add_url_rule('/<int:role_id>', 'delete_role', RHDeleteEventRole, methods=('DELETE',)) _bp.add_url_rule('/<int:role_id>/members', 'add_role_members', RHAddEventRoleMembers, methods=('POST',)) _bp.add_url_rule('/<int:role_id>/members/<int:user_id>', 'remove_role_member', RHRemoveEventRoleMember, methods=('DELETE',)) _bp.add_url_rule('/<int:role_id>/members/import', 'add_members_import_csv', RHEventRoleMembersImportCSV, methods=('GET', 'POST'))
# General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.vc.controllers import ( RHVCManageEvent, RHVCManageEventSelectService, RHVCManageEventCreate, RHVCManageEventModify, RHVCManageEventRefresh, RHVCManageEventRemove, RHVCEventPage, RHVCManageSearch, RHVCManageAttach, RHVCRoomList) from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('vc', __name__, template_folder='templates', virtual_template_folder='vc') # Global management _bp.add_url_rule('/service/videoconference', 'vc_room_list', RHVCRoomList) # Event management _bp.add_url_rule('/event/<confId>/manage/videoconference/', 'manage_vc_rooms', RHVCManageEvent) _bp.add_url_rule('/event/<confId>/manage/videoconference/select', 'manage_vc_rooms_select', RHVCManageEventSelectService, methods=('GET', 'POST')) _bp.add_url_rule('/event/<confId>/manage/videoconference/<service>/create', 'manage_vc_rooms_create', RHVCManageEventCreate,
## published by the Free Software Foundation; either version 3 of the ## License, or (at your option) any later version. ## ## Indico 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 Indico. If not, see <http://www.gnu.org/licenses/>. from MaKaC.webinterface.rh import categoryMod from indico.web.flask.wrappers import IndicoBlueprint category_mgmt = IndicoBlueprint('category_mgmt', __name__, url_prefix='/category/<categId>/manage') # Creation category_mgmt.add_url_rule('!/category/<categId>/create/subcategory', 'categoryCreation', categoryMod.RHCategoryCreation, methods=('GET', 'POST')) category_mgmt.add_url_rule('!/category/<categId>/create/subcategory/save', 'categoryCreation-create', categoryMod.RHCategoryPerformCreation, methods=('POST',)) # Event creation is in event.creation # General settings category_mgmt.add_url_rule('/', 'categoryModification', categoryMod.RHCategoryModification) category_mgmt.add_url_rule('/data', 'categoryDataModification', categoryMod.RHCategoryDataModif, methods=('GET', 'POST')) category_mgmt.add_url_rule('/data/save', 'categoryDataModification-modify', categoryMod.RHCategoryPerformModification, methods=('POST',))
# 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 Indico; if not, see <http://www.gnu.org/licenses/>. from __future__ import unicode_literals from indico.modules.events.tracks.controllers import (RHCreateTrack, RHDeleteTrack, RHDisplayTracks, RHEditProgram, RHEditTrack, RHManageTracks, RHSortTracks, RHTracksPDF) from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('tracks', __name__, template_folder='templates', virtual_template_folder='events/tracks', url_prefix='/event/<confId>') _bp.add_url_rule('/manage/tracks/', 'manage', RHManageTracks) _bp.add_url_rule('/manage/tracks/program', 'edit_program', RHEditProgram, methods=('GET', 'POST')) _bp.add_url_rule('/manage/tracks/create', 'create_track', RHCreateTrack, methods=('GET', 'POST')) _bp.add_url_rule('/manage/tracks/sort', 'sort_tracks', RHSortTracks, methods=('POST',)) _bp.add_url_rule('/manage/tracks/<int:track_id>', 'edit_track', RHEditTrack, methods=('GET', 'POST')) _bp.add_url_rule('/manage/tracks/<int:track_id>', 'delete_track', RHDeleteTrack, methods=('DELETE',)) _bp.add_url_rule('/program', 'program', RHDisplayTracks) _bp.add_url_rule('/program.pdf', 'program_pdf', RHTracksPDF) _compat_bp = IndicoBlueprint('compat_tracks', __name__, url_prefix='/event/<int:confId>') _compat_bp.add_url_rule('/manage/program/tracks/<int:track_id>/contributions/', 'track_contribs', make_compat_redirect_func('contributions', 'contribution_list',
# 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 Indico; if not, see <http://www.gnu.org/licenses/>. from indico.modules.rb.controllers.admin import ( index as index_handler, locations as location_handlers, mappers as mapper_handlers, rooms as room_handlers ) from indico.web.flask.wrappers import IndicoBlueprint rooms_admin = IndicoBlueprint('rooms_admin', __name__, url_prefix='/admin/rooms') # Main settings rooms_admin.add_url_rule('/config/', 'settings', index_handler.RHRoomBookingSettings, methods=('GET', 'POST')) # Locations rooms_admin.add_url_rule('/locations/', 'roomBooking-admin', location_handlers.RHRoomBookingAdmin) rooms_admin.add_url_rule('/locations/delete',
## published by the Free Software Foundation; either version 3 of the ## License, or (at your option) any later version. ## ## Indico 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 Indico. If not, see <http://www.gnu.org/licenses/>. from MaKaC.webinterface.rh import roomBookingPluginAdmin, roomBooking, roomMappers from indico.web.flask.wrappers import IndicoBlueprint rooms_admin = IndicoBlueprint('rooms_admin', __name__, url_prefix='/admin/rooms') # Main settings rooms_admin.add_url_rule('/config/', 'roomBookingPluginAdmin', roomBookingPluginAdmin.RHRoomBookingPluginAdmin) rooms_admin.add_url_rule('/config/toggle', 'roomBookingPluginAdmin-switchRoomBookingModuleActive', roomBookingPluginAdmin.RHSwitchRoomBookingModuleActive) rooms_admin.add_url_rule('/config/save-db', 'roomBookingPluginAdmin-zodbSave', roomBookingPluginAdmin.RHZODBSave, methods=('POST',)) # Locations rooms_admin.add_url_rule('/locations/', 'roomBooking-admin', roomBooking.RHRoomBookingAdmin) rooms_admin.add_url_rule('/locations/delete', 'roomBooking-deleteLocation', roomBooking.RHRoomBookingDeleteLocation, methods=('POST',)) rooms_admin.add_url_rule('/locations/add', 'roomBooking-saveLocation', roomBooking.RHRoomBookingSaveLocation, methods=('POST',))
from indico.modules.events.layout.compat import compat_image, compat_page from indico.modules.events.layout.controllers.images import RHImageDelete, RHImageDisplay, RHImages, RHImageUpload from indico.modules.events.layout.controllers.layout import (RHLayoutCSSDelete, RHLayoutCSSDisplay, RHLayoutCSSPreview, RHLayoutCSSSaveTheme, RHLayoutCSSUpload, RHLayoutEdit, RHLayoutLogoDelete, RHLayoutLogoUpload, RHLayoutTimetableThemeForm, RHLogoDisplay) from indico.modules.events.layout.controllers.menu import (RHMenuAddEntry, RHMenuDeleteEntry, RHMenuEdit, RHMenuEntryEdit, RHMenuEntryPosition, RHMenuEntryToggleDefault, RHMenuEntryToggleEnabled, RHMenuToggleCustom, RHPageDisplay) from indico.web.flask.util import make_compat_redirect_func from indico.web.flask.wrappers import IndicoBlueprint _bp = IndicoBlueprint('event_layout', __name__, template_folder='templates', virtual_template_folder='events/layout', url_prefix='/event/<confId>/manage/layout') _bp.add_url_rule('/', 'index', RHLayoutEdit, methods=('GET', 'POST')) _bp.add_url_rule('/timetable-theme-form', 'timetable_theme_form', RHLayoutTimetableThemeForm) _bp.add_url_rule('/menu/', 'menu', RHMenuEdit) _bp.add_url_rule('/menu/toggle-customize', 'menu_toggle_custom', RHMenuToggleCustom, methods=('POST',)) _bp.add_url_rule('/menu/<int:menu_entry_id>/', 'menu_entry_edit', RHMenuEntryEdit, methods=('GET', 'POST')) _bp.add_url_rule('/menu/<int:menu_entry_id>/position', 'menu_entry_position', RHMenuEntryPosition, methods=('POST',)) _bp.add_url_rule('/menu/<int:menu_entry_id>/toggle-enabled', 'menu_entry_toggle_enabled', RHMenuEntryToggleEnabled, methods=('POST',)) _bp.add_url_rule('/menu/<int:menu_entry_id>/toggle-default', 'menu_entry_toggle_default', RHMenuEntryToggleDefault, methods=('POST',)) _bp.add_url_rule('/menu/<int:menu_entry_id>/delete', 'menu_delete_entry', RHMenuDeleteEntry, methods=('DELETE',)) _bp.add_url_rule('/menu/add', 'menu_add_entry', RHMenuAddEntry, methods=('GET', 'POST')) _bp.add_url_rule('/theme/save', 'css_save_theme', RHLayoutCSSSaveTheme, methods=('POST',)) _bp.add_url_rule('/theme/preview', 'css_preview', RHLayoutCSSPreview)
## ## Indico 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 Indico. If not, see <http://www.gnu.org/licenses/>. from MaKaC.services.interface.rpc.json import process as jsonrpc_handler from indico.web.flask.wrappers import IndicoBlueprint from indico.web.http_api.handlers import handler as api_handler api = IndicoBlueprint('api', __name__) api.add_url_rule('/services/json-rpc', view_func=jsonrpc_handler, endpoint='jsonrpc', methods=('POST',)) api.add_url_rule('/api/<path:path>', view_func=api_handler, endpoint='httpapi', defaults={'prefix': 'api'}, methods=('POST', )) api.add_url_rule('/export/<path:path>', view_func=api_handler, endpoint='httpapi',