# Copyright (C) 2017 Bjoern Pedersen.
#
# 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.core.plugins import IndicoPluginBlueprint

from indico_checkin_webhook.controllers import RHCheckinWebhookManageEvent

blueprint = IndicoPluginBlueprint('checkin_webhook',
                                  'checkin_webhook',
                                  url_prefix='/event/<confId>')

# Event management
blueprint.add_url_rule('/manage/checkinwebhook/',
                       'configure',
                       RHCheckinWebhookManageEvent,
                       methods=('GET', 'POST'))
Example #2
0
# This file is part of Indico.
# Copyright (C) 2002 - 2018 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.core.plugins import IndicoPluginBlueprint

from indico_livesync.controllers import RHAddAgent, RHDeleteAgent, RHEditAgent


blueprint = IndicoPluginBlueprint('livesync', 'indico_livesync', url_prefix='/admin/plugins/livesync')

blueprint.add_url_rule('/agents/create/<backend>', 'add_agent', RHAddAgent, methods=('GET', 'POST'))
blueprint.add_url_rule('/agents/<int:agent_id>', 'edit_agent', RHEditAgent, methods=('GET', 'POST'))
blueprint.add_url_rule('/agents/<int:agent_id>', 'delete_agent', RHDeleteAgent, methods=('DELETE',))
Example #3
0
# 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.core.plugins import IndicoPluginBlueprint

from indico_search.controllers import RHSearch, RHSearchCategoryTitles


blueprint = IndicoPluginBlueprint('search', 'indico_search')

blueprint.add_url_rule('/search', 'search', RHSearch, methods=('GET', 'POST'))
blueprint.add_url_rule('/category/<categId>/search', 'search', RHSearch, methods=('GET', 'POST'))
blueprint.add_url_rule('/event/<confId>/search', 'search', RHSearch, methods=('GET', 'POST'))

blueprint.add_url_rule('/category/search-titles', 'category_names', RHSearchCategoryTitles)
Example #4
0
# This file is part of Indico.
# Copyright (C) 2002 - 2018 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.core.plugins import IndicoPluginBlueprint

from indico_payment_paypal.controllers import RHPaypalCancel, RHPaypalIPN, RHPaypalSuccess


blueprint = IndicoPluginBlueprint('payment_paypal', __name__,
                                  url_prefix='/event/<confId>/registrations/<int:reg_form_id>/payment/response/paypal')

blueprint.add_url_rule('/cancel', 'cancel', RHPaypalCancel, methods=('GET', 'POST'))
blueprint.add_url_rule('/success', 'success', RHPaypalSuccess, methods=('GET', 'POST'))
# Used by PayPal to send an asynchronous notification for the transaction (pending, successful, etc)
blueprint.add_url_rule('/ipn', 'notify', RHPaypalIPN, methods=('POST',))
Example #5
0
        yield examples

    def _extend_shell_context(self, sender, add_to_context, add_to_context_multi, **kwargs):
        add_to_context('bar', name='foo', doc='foobar from example plugin', color='magenta!')
        from flask import render_template, render_template_string
        add_to_context(render_template, color='magenta!')
        add_to_context(render_template_string, color='magenta!')

    def register_assets(self):
        self.register_js_bundle('example_js', 'js/example.js')
        self.register_js_bundle('global_js', 'js/global.js')
        self.register_css_bundle('example_css', 'css/example.scss')
        self.register_css_bundle('global_css', 'css/global.scss')


blueprint = IndicoPluginBlueprint('example', __name__)


class WPExample(WPDecorated):
    def _getBody(self, params):
        locale = get_current_locale()
        params['language'] = IndicoLocale.parse('en').languages[locale.language]
        params['python_msg_core_i18n'] = core_gettext('Hello world!')
        params['python_msg_plugin_i18n'] = _('Hello world!')
        return render_plugin_template('example:example.html', **params)


class RHExample(RH):
    def _process(self):
        return WPExample(self, foo=u'bar').display()
# This file is part of the CERN Indico plugins.
# Copyright (C) 2014 - 2019 CERN
#
# The CERN Indico plugins are free software; you can redistribute
# them and/or modify them under the terms of the MIT License; see
# the LICENSE file for more details.

from __future__ import unicode_literals

from indico.core.plugins import IndicoPluginBlueprint

from indico_livesync_cern.controllers import RHCategoriesJSON

blueprint = IndicoPluginBlueprint('livesync_cern', __name__)

blueprint.add_url_rule('/livesync/cernsearch/categories.json',
                       'categories_json', RHCategoriesJSON)
Example #7
0
        if not self.settings.get('enabled_for_events') or not site_id_events:
            return {}
        params = {'site_id_events': site_id_events}
        if request.blueprint in ('event', 'events', 'contributions') and 'confId' in request.view_args:
            if not unicode(request.view_args['confId']).isdigit():
                return {}
            params['event_id'] = request.view_args['confId']
            contrib_id = request.view_args.get('contrib_id')
            if contrib_id is not None and unicode(contrib_id).isdigit():
                contribution = Contribution.find_first(event_id=params['event_id'], id=contrib_id)
                if contribution:
                    cid = (contribution.legacy_mapping.legacy_contribution_id if contribution.legacy_mapping
                           else contribution.id)
                    params['contrib_id'] = '{}t{}'.format(contribution.event_id, cid)
        return params

    def _get_tracking_url(self):
        url = self.settings.get('server_url')
        url = url if url.endswith('/') else url + '/'
        url = urlparse.urlparse(url)
        return url.netloc + url.path


blueprint = IndicoPluginBlueprint('piwik', __name__, url_prefix='/event/<confId>/manage/statistics')
blueprint.add_url_rule('/', 'view', RHStatistics)
blueprint.add_url_rule('/material', 'material', RHApiMaterial, methods=('GET', 'POST'))
blueprint.add_url_rule('/data/downloads', 'data_downloads', RHApiDownloads, methods=('GET', 'POST'))
blueprint.add_url_rule('/data/visits', 'data_visits', RHApiEventVisitsPerDay, methods=('GET', 'POST'))
blueprint.add_url_rule('/graph/countries', 'graph_countries', RHApiEventGraphCountries, methods=('GET', 'POST'))
blueprint.add_url_rule('/graph/devices', 'graph_devices', RHApiEventGraphDevices, methods=('GET', 'POST'))
# This file is part of the Indico plugins.
# Copyright (C) 2002 - 2019 CERN
#
# The Indico plugins are free software; you can redistribute
# them and/or modify them under the terms of the MIT License;
# see the LICENSE file for more details.

from __future__ import unicode_literals

from indico.core.plugins import IndicoPluginBlueprint

from indico_livesync.controllers import RHAddAgent, RHDeleteAgent, RHEditAgent


blueprint = IndicoPluginBlueprint('livesync', 'indico_livesync', url_prefix='/admin/plugins/livesync')

blueprint.add_url_rule('/agents/create/<backend>', 'add_agent', RHAddAgent, methods=('GET', 'POST'))
blueprint.add_url_rule('/agents/<int:agent_id>', 'edit_agent', RHEditAgent, methods=('GET', 'POST'))
blueprint.add_url_rule('/agents/<int:agent_id>', 'delete_agent', RHDeleteAgent, methods=('DELETE',))
Example #9
0
# This file is part of the CERN Indico plugins.
# Copyright (C) 2014 - 2021 CERN
#
# The CERN Indico plugins are free software; you can redistribute
# them and/or modify them under the terms of the MIT License; see
# the LICENSE file for more details.

from indico.core.plugins import IndicoPluginBlueprint

from indico_conversion.conversion import RHConversionCheck, RHConversionFinished


blueprint = IndicoPluginBlueprint('conversion', __name__)
blueprint.add_url_rule('/conversion/finished', 'callback', RHConversionFinished, methods=('POST',))
blueprint.add_url_rule('/conversion/check', 'check', RHConversionCheck)
Example #10
0
                    event_id=params['event_id'], id=contrib_id)
                if contribution:
                    cid = (contribution.legacy_mapping.legacy_contribution_id
                           if contribution.legacy_mapping else contribution.id)
                    params['contrib_id'] = '{}t{}'.format(
                        contribution.event_id, cid)
        return params

    def _get_tracking_url(self):
        url = self.settings.get('server_url')
        url = url if url.endswith('/') else url + '/'
        url = urlparse.urlparse(url)
        return url.netloc + url.path


blueprint = IndicoPluginBlueprint(
    'piwik', __name__, url_prefix='/event/<confId>/manage/statistics')
blueprint.add_url_rule('/', 'view', RHStatistics)
blueprint.add_url_rule('/material',
                       'material',
                       RHApiMaterial,
                       methods=('GET', 'POST'))
blueprint.add_url_rule('/data/downloads',
                       'data_downloads',
                       RHApiDownloads,
                       methods=('GET', 'POST'))
blueprint.add_url_rule('/data/visits',
                       'data_visits',
                       RHApiEventVisitsPerDay,
                       methods=('GET', 'POST'))
blueprint.add_url_rule('/graph/countries',
                       'graph_countries',
Example #11
0
# This file is part of the Indico plugins.
# Copyright (C) 2020 - 2022 CERN and ENEA
#
# The Indico plugins are free software; you can redistribute
# them and/or modify them under the terms of the MIT License;
# see the LICENSE file for more details.

from indico.core.plugins import IndicoPluginBlueprint

from indico_vc_zoom.controllers import RHRoomAlternativeHost, RHWebhook

blueprint = IndicoPluginBlueprint('vc_zoom', 'indico_vc_zoom')

# Room management
# using any(zoom) instead of defaults since the event vc room locator
# includes the service and normalization skips values provided in 'defaults'
blueprint.add_url_rule(
    '/event/<int:event_id>/manage/videoconference/<any(zoom):service>/<int:event_vc_room_id>/make-me-alt-host',
    'make_me_alt_host',
    RHRoomAlternativeHost,
    methods=('POST', ))
blueprint.add_url_rule('/api/plugin/zoom/webhook',
                       'webhook',
                       RHWebhook,
                       methods=('POST', ))
Example #12
0
 def get_blueprints(self):
     return IndicoPluginBlueprint('vc_dummy', __name__)
Example #13
0
# This file is part of the Indico plugins.
# Copyright (C) 2002 - 2019 CERN
#
# The Indico plugins are free software; you can redistribute
# them and/or modify them under the terms of the MIT License;
# see the LICENSE file for more details.

from __future__ import unicode_literals

from indico.core.plugins import IndicoPluginBlueprint

from indico_search.controllers import RHSearch, RHSearchCategoryTitles


blueprint = IndicoPluginBlueprint('search', 'indico_search')

blueprint.add_url_rule('/search', 'search', RHSearch)
blueprint.add_url_rule('/category/<int:category_id>/search', 'search', RHSearch)
blueprint.add_url_rule('/event/<confId>/search', 'search', RHSearch)

blueprint.add_url_rule('/category/search-titles', 'category_names', RHSearchCategoryTitles)
                print self.settings.get('dummy_message')

    def extend_shell_context(self, add_to_context):
        add_to_context('bar',
                       name='foo',
                       doc='foobar from example plugin',
                       color='magenta!')

    def register_assets(self):
        self.register_js_bundle('example_js', 'js/example.js')
        self.register_js_bundle('global_js', 'js/global.js')
        self.register_css_bundle('example_css', 'css/example.scss')
        self.register_css_bundle('global_css', 'css/global.scss')


blueprint = IndicoPluginBlueprint('example', __name__)


class WPExample(WPMainBase):
    def _getBody(self, params):
        return render_plugin_template('example.html', **params)


class RHExample(RH):
    def _process(self):
        return WPExample(self, foo=u'bar').display()


class RHTest(RH):
    def _process(self):
        return render_plugin_template('test.html')
Example #15
0
# This file is part of Indico.
# Copyright (C) 2002 - 2018 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.core.plugins import IndicoPluginBlueprint

from indico_storage_s3.controllers import RHBuckets


blueprint = IndicoPluginBlueprint('storage_s3', __name__, url_prefix='/api/plugin/s3')
blueprint.add_url_rule('/buckets', 'buckets', RHBuckets)
Example #16
0
# This file is part of the CERN Indico plugins.
# Copyright (C) 2014 - 2021 CERN
#
# The CERN Indico plugins are free software; you can redistribute
# them and/or modify them under the terms of the MIT License; see
# the LICENSE file for more details.

from indico.core.plugins import IndicoPluginBlueprint

from indico_burotel.controllers import RHBurotelStats, RHBurotelStatsCSV, RHUserExperiment


blueprint = IndicoPluginBlueprint('burotel', __name__, url_prefix='/rooms')

blueprint.add_url_rule('/api/user/experiment', 'user_experiment', RHUserExperiment, methods=('GET', 'POST'))
blueprint.add_url_rule('/api/burotel-stats', 'stats', RHBurotelStats)
blueprint.add_url_rule('/burotel-stats.csv', 'stats_csv', RHBurotelStatsCSV)


# XXX: RHLanding is not handled here on purpose!
Example #17
0
# This file is part of the CERN Indico plugins.
# Copyright (C) 2014 - 2020 CERN
#
# The CERN Indico plugins are free software; you can redistribute
# them and/or modify them under the terms of the MIT License; see
# the LICENSE file for more details.

from __future__ import unicode_literals

from indico.core.plugins import IndicoPluginBlueprint

from indico_audiovisual.controllers import RHRequestList


blueprint = IndicoPluginBlueprint('audiovisual', __name__, url_prefix='/service/audiovisual')
blueprint.add_url_rule('/', 'request_list', RHRequestList)
# This file is part of the Indico plugins.
# Copyright (C) 2002 - 2020 CERN
#
# The Indico plugins are free software; you can redistribute
# them and/or modify them under the terms of the MIT License;
# see the LICENSE file for more details.

from __future__ import unicode_literals

from indico.core.plugins import IndicoPluginBlueprint

from indico_vc_vidyo.controllers import RHVidyoRoomOwner

blueprint = IndicoPluginBlueprint('vc_vidyo', 'indico_vc_vidyo')

# Room management
# using any(vidyo) instead of defaults since the event vc room locator
# includes the service and normalization skips values provided in 'defaults'
blueprint.add_url_rule(
    '/event/<confId>/manage/videoconference/<any(vidyo):service>/<int:event_vc_room_id>/room-owner',
    'set_room_owner',
    RHVidyoRoomOwner,
    methods=('POST', ))
Example #19
0
    def get_timetable_buttons(self, *args, **kwargs):
        yield (_('Importer'), 'create-importer-dialog')

    def get_vars_js(self):
        return {'urls': {'import_data': plugin_url_rule_to_js('importer.import_data'),
                         'importers': plugin_url_rule_to_js('importer.importers'),
                         'day_end_date': plugin_url_rule_to_js('importer.day_end_date'),
                         'block_end_date': plugin_url_rule_to_js('importer.block_end_date'),
                         'add_contrib': url_rule_to_js('timetable.add_contribution'),
                         'create_subcontrib_rest': url_rule_to_js('contributions.create_subcontrib_rest'),
                         'create_contrib_reference_rest': url_rule_to_js('contributions.create_contrib_reference_rest'),
                         'create_subcontrib_reference_rest': url_rule_to_js('contributions'
                                                                            '.create_subcontrib_reference_rest'),
                         'add_link': url_rule_to_js('attachments.add_link')}}

    def register_assets(self):
        self.register_js_bundle('importer_js', 'js/importer.js')
        self.register_css_bundle('importer_css', 'css/importer.css')

    def register_importer_engine(self, importer_engine, plugin):
        self.importer_engines[importer_engine._id] = (importer_engine, plugin)


blueprint = IndicoPluginBlueprint('importer', __name__)
blueprint.add_url_rule('/importers/<importer_name>/search', 'import_data', RHImportData, methods=('POST',))
blueprint.add_url_rule('/importers/', 'importers', RHGetImporters)

blueprint.add_url_rule('/importers/<importer_name>/event/<confId>/day-end-date', 'day_end_date', RHDayEndTime)
blueprint.add_url_rule('/importers/<importer_name>/event/<confId>/entry/<entry_id>/block-end-date', 'block_end_date',
                       RHBlockEndTime)
Example #20
0
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
# Created on Mar 9, 2018
#
# @author: pedersen

from __future__ import unicode_literals

from indico.core.plugins import IndicoPluginBlueprint
from indico_mlz_export.controller import RHExportRegistrations, RHExportRegistration, RHExportRegistrationsFlat, RHExportRegistrationFlat

blueprint = IndicoPluginBlueprint('mlz_export',
                                  __name__,
                                  url_prefix='/mlz/export')
# API
blueprint.add_url_rule('/<int:event_id>/registrants/<int:registrant_id>',
                       'api_registrant',
                       RHExportRegistration,
                       methods=('GET', ))
blueprint.add_url_rule('/<int:event_id>/registrants', 'api_registrants',
                       RHExportRegistrations)
blueprint.add_url_rule('/<int:event_id>/registrants_flat/<int:registrant_id>',
                       'api_registrant_flat',
                       RHExportRegistrationFlat,
                       methods=('GET', ))
blueprint.add_url_rule('/<int:event_id>/registrants_flat',
                       'api_registrants_flat', RHExportRegistrationsFlat)
Example #21
0
from wtforms import StringField, IntegerField

from MaKaC.authentication import AuthenticatorMgr
from MaKaC.user import LoginInfo
from MaKaC.webinterface import urlHandlers
from MaKaC.webinterface.rh.base import RH
from MaKaC.webinterface.rh.login import RHSignInBase, RHSignOut
from MaKaC.webinterface.urlHandlers import SecureURLHandler
from boshclient import BOSHClient, JID
from indico.core.config import Config
from indico.core.plugins import IndicoPluginBlueprint, IndicoPlugin, plugin_engine
from flask import session, request
from indico.core import signals
from indico.web.forms.base import IndicoForm

blueprint = IndicoPluginBlueprint('indicoxmpp', __name__, url_prefix='/xmpp')


class SettingsForm(IndicoForm):
    base_host = StringField(label='XMPP Host name', description='Specify the XMPP Host name.',default="localhost")
    base_port = IntegerField(label='XMPP Port', description='Specify the XMPP Port.',default="5280")


class IndicoXMPPPlugin(IndicoPlugin):
    """Indico XMPP Plugin

    """
    configurable = True
    settings_form = SettingsForm

    def init(self):
Example #22
0
#
# 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.core.plugins import IndicoPluginBlueprint

from indico_chat.controllers.event import RHChatEventPage
from indico_chat.controllers.logs import RHChatManageEventAttachLogs, RHChatManageEventLogs, RHChatManageEventShowLogs
from indico_chat.controllers.management import (RHChatManageEvent, RHChatManageEventAttach, RHChatManageEventCreate,
                                                RHChatManageEventModify, RHChatManageEventRefresh,
                                                RHChatManageEventRemove)


blueprint = IndicoPluginBlueprint('chat', 'indico_chat', url_prefix='/event/<confId>')

# Event
blueprint.add_url_rule('/chat', 'event_page', RHChatEventPage)

# Event management
blueprint.add_url_rule('/manage/chat/', 'manage_rooms', RHChatManageEvent)
blueprint.add_url_rule('/manage/chat/<int:chatroom_id>/', 'manage_rooms_modify', RHChatManageEventModify,
                       methods=('GET', 'POST'))
blueprint.add_url_rule('/manage/chat/<int:chatroom_id>/logs/', 'manage_rooms_logs', RHChatManageEventLogs)
blueprint.add_url_rule('/manage/chat/<int:chatroom_id>/logs/show', 'manage_rooms_show_logs',
                       RHChatManageEventShowLogs)
blueprint.add_url_rule('/manage/chat/<int:chatroom_id>/logs/attach', 'manage_rooms_attach_logs',
                       RHChatManageEventAttachLogs, methods=('POST',))
blueprint.add_url_rule('/manage/chat/<int:chatroom_id>/refresh', 'manage_rooms_refresh', RHChatManageEventRefresh,
                       methods=('POST',))
Example #23
0
# 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.core.plugins import IndicoPluginBlueprint

from indico_vc_vidyo.controllers import RHVidyoRoomOwner

blueprint = IndicoPluginBlueprint('vc_vidyo', 'indico_vc_vidyo')

# Room management
# using any(vidyo) instead of defaults since the event vc room locator
# includes the service and normalization skips values provided in 'defaults'
blueprint.add_url_rule('/event/<confId>/manage/videoconference/<any(vidyo):service>/<int:event_vc_room_id>/room-owner',
                       'set_room_owner', RHVidyoRoomOwner, methods=('POST',))
Example #24
0
# This file is part of the CERN Indico plugins.
# Copyright (C) 2014 - 2021 CERN
#
# The CERN Indico plugins are free software; you can redistribute
# them and/or modify them under the terms of the MIT License; see
# the LICENSE file for more details.

from indico.core.plugins import IndicoPluginBlueprint

from indico_room_assistance.controllers import RHRequestList

blueprint = IndicoPluginBlueprint('room_assistance',
                                  __name__,
                                  url_prefix='/service/room-assistance')
blueprint.add_url_rule('/', 'request_list', RHRequestList)
Example #25
0
# This file is part of Indico.
# Copyright (C) 2002 - 2018 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.core.plugins import IndicoPluginBlueprint

from indico_search.controllers import RHSearch, RHSearchCategoryTitles


blueprint = IndicoPluginBlueprint('search', 'indico_search')

blueprint.add_url_rule('/search', 'search', RHSearch)
blueprint.add_url_rule('/category/<int:category_id>/search', 'search', RHSearch)
blueprint.add_url_rule('/event/<confId>/search', 'search', RHSearch)

blueprint.add_url_rule('/category/search-titles', 'category_names', RHSearchCategoryTitles)
Example #26
0
 def get_blueprints(self):
     return IndicoPluginBlueprint(self.name, __name__)
Example #27
0
# 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.core.plugins import IndicoPluginBlueprint

from indico_chat.controllers.event import RHChatEventPage
from indico_chat.controllers.logs import RHChatManageEventLogs, RHChatManageEventShowLogs, RHChatManageEventAttachLogs
from indico_chat.controllers.management import (RHChatManageEvent, RHChatManageEventModify, RHChatManageEventRefresh,
                                                RHChatManageEventRemove, RHChatManageEventCreate,
                                                RHChatManageEventAttach)

blueprint = IndicoPluginBlueprint('chat', 'indico_chat', url_prefix='/event/<confId>')

# Event
blueprint.add_url_rule('/chat', 'event_page', RHChatEventPage)

# Event management
blueprint.add_url_rule('/manage/chat/', 'manage_rooms', RHChatManageEvent)
blueprint.add_url_rule('/manage/chat/<int:chatroom_id>/', 'manage_rooms_modify', RHChatManageEventModify,
                       methods=('GET', 'POST'))
blueprint.add_url_rule('/manage/chat/<int:chatroom_id>/logs/', 'manage_rooms_logs', RHChatManageEventLogs)
blueprint.add_url_rule('/manage/chat/<int:chatroom_id>/logs/show', 'manage_rooms_show_logs',
                       RHChatManageEventShowLogs)
blueprint.add_url_rule('/manage/chat/<int:chatroom_id>/logs/attach', 'manage_rooms_attach_logs',
                       RHChatManageEventAttachLogs, methods=('POST',))
blueprint.add_url_rule('/manage/chat/<int:chatroom_id>/refresh', 'manage_rooms_refresh', RHChatManageEventRefresh,
                       methods=('POST',))
Example #28
0
# The CERN Indico plugins are free software; you can redistribute
# them and/or modify them under the terms of the MIT License; see
# the LICENSE file for more details.

from __future__ import unicode_literals

from flask import redirect, request
from werkzeug.exceptions import NotFound

from indico.core.plugins import IndicoPluginBlueprint
from indico.modules.events.agreements.models.agreements import Agreement
from indico.web.flask.util import url_for

from indico_audiovisual.definition import AVRequest, SpeakerReleaseAgreement

compat_blueprint = IndicoPluginBlueprint('compat_audiovisual',
                                         'indico_audiovisual')


@compat_blueprint.route('/event/<int:confId>/collaboration/agreement')
def redirect_old_agreement_url(confId):
    uuid = request.args['authKey']
    agreement = Agreement.find_first(event_id=confId, uuid=uuid)
    if agreement is None:
        raise NotFound
    return redirect(
        url_for('agreements.agreement_form',
                confId=confId,
                id=agreement.id,
                uuid=uuid))

Example #29
0
# 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 indico.core.plugins import IndicoPluginBlueprint
from indico_previewer_jupyter.controllers import RHEventPreviewIPyNB


blueprint = IndicoPluginBlueprint('previewer_jupyter', __name__)
blueprint.add_url_rule('/preview/ipynb/<int:attachment_id>', 'preview_ipynb', RHEventPreviewIPyNB)
Example #30
0
 def get_blueprints(self):
     return IndicoPluginBlueprint('search_invenio', 'indico_search_invenio')