Beispiel #1
0
    def ready(self):
        super(ConverterApp, self).ready()

        Package(label='Pillow',
                license_text='''
The Python Imaging Library (PIL) is

    Copyright (c) 1997-2011 by Secret Labs AB
    Copyright (c) 1995-2011 by Fredrik Lundh

By obtaining, using, and/or copying this software and/or its associated documentation, you agree that you have read, understood, and will comply with the following terms and conditions:

Permission to use, copy, modify, and distribute this software and its associated documentation for any purpose and without fee is hereby granted, provided that the above copyright notice appears in all copies, and that both that copyright notice and this permission notice appear in supporting documentation, and that the name of Secret Labs AB or the author not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission.

SECRET LABS AB AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL SECRET LABS AB OR THE AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
        ''')

        SourceColumn(source=Transformation,
                     label=_('Order'),
                     attribute='order')
        SourceColumn(source=Transformation,
                     label=_('Transformation'),
                     func=lambda context: unicode(context['object']))
        SourceColumn(source=Transformation,
                     label=_('Arguments'),
                     attribute='arguments')

        menu_object.bind_links(links=(link_transformation_edit,
                                      link_transformation_delete),
                               sources=(Transformation, ))
        menu_sidebar.bind_links(links=(link_transformation_create, ),
                                sources=(Transformation, ))
        menu_sidebar.bind_links(links=(link_transformation_create, ),
                                sources=('converter:transformation_create',
                                         'converter:transformation_list'))
Beispiel #2
0
    def ready(self, *args, **kwargs):
        super(MIMETypesApp, self).ready(*args, **kwargs)

        Package(label='python-magic', license_text='''
The MIT License (MIT)

Copyright (c) 2001-2014 Adam Hupp

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
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.
        ''')
Beispiel #3
0
    def ready(self):
        super(RESTAPIApp, self).ready()

        settings.STRONGHOLD_PUBLIC_URLS += (r'^/%s/.+$' % self.app_url, )

        APIEndPoint(app=self, name='rest', version_string='1')

        Package(label='Django REST framework',
                license_text='''
Copyright (c) 2011-2015, Tom Christie All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        ''')

        Package(label='django-rest-swagger',
                license_text='''
Copyright (c) 2013, Marc Gibbons
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this
   list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
   this list of conditions and the following disclaimer in the documentation
   and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        ''')

        menu_tools.bind_links(links=(link_api, link_api_documentation))
Beispiel #4
0
    def ready(self):
        super(StatisticsApp, self).ready()

        Package(label='Chart.js', license_text='''
Copyright (c) 2013-2015 Nick Downie

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 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.
        ''')

        SourceColumn(
            source=Statistic,
            # Translators: Schedule here is a verb, the 'schedule' at which the
            # statistic will be updated
            label=_('Schedule'),
            attribute='schedule',
        )

        app.conf.CELERY_QUEUES.extend(
            (
                Queue(
                    'statistics', Exchange('statistics'),
                    routing_key='statistics', delivery_mode=1
                ),
            )
        )

        app.conf.CELERY_ROUTES.update(
            {
                'statistics.tasks.task_execute_statistic': {
                    'queue': 'statistics'
                },
            }
        )

        menu_object.bind_links(
            links=(link_execute, link_view), sources=(Statistic,)
        )
        menu_object.bind_links(
            links=(link_namespace_details,), sources=(StatisticNamespace,)
        )
        menu_secondary.bind_links(
            links=(link_namespace_list,),
            sources=(StatisticNamespace, 'statistics:namespace_list')
        )
        menu_tools.bind_links(links=(link_statistics,))
Beispiel #5
0
    def ready(self):
        super(EventsApp, self).ready()

        APIEndPoint(app=self, version_string='1')

        Package(label='django-activity-stream', license_text='''
Copyright (c) 2010-2015, Justin Quick
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:

    * Redistributions of source code must retain the above copyright
      notice, this list of conditions and the following disclaimer.
    * Redistributions in binary form must reproduce the above
      copyright notice, this list of conditions and the following
      disclaimer in the documentation and/or other materials provided
      with the distribution.
    * Neither the name of the author nor the names of other
      contributors may be used to endorse or promote products derived
      from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        ''')

        SourceColumn(
            source=Action, label=_('Timestamp'), attribute='timestamp'
        )
        SourceColumn(source=Action, label=_('Actor'), attribute='actor')
        SourceColumn(
            source=Action, label=_('Verb'),
            func=lambda context: event_type_link(context['object'])
        )

        menu_tools.bind_links(links=(link_events_list,))
Beispiel #6
0
from __future__ import unicode_literals

from common.classes import Package

Package(label='Bootstrap',
        license_text='''
The MIT License (MIT)

Copyright (c) 2011-2015 Twitter, Inc

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
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.
''')

Package(label='Bootswatch',
        license_text='''
The MIT License (MIT)
Beispiel #7
0
from common.classes import Package

Package(label='python-gnupg',
        license_text='''
Copyright (c) 2008-2014 by Vinay Sajip.
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

    * Redistributions of source code must retain the above copyright notice,
      this list of conditions and the following disclaimer.
    * Redistributions in binary form must reproduce the above copyright notice,
      this list of conditions and the following disclaimer in the documentation
      and/or other materials provided with the distribution.
    * The name(s) of the copyright holder(s) may not be used to endorse or
      promote products derived from this software without specific prior
      written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) "AS IS" AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
''')
Beispiel #8
0
    def ready(self):
        super(DocumentIndexingApp, self).ready()

        Document = apps.get_model(app_label='documents', model_name='Document')

        DocumentType = apps.get_model(app_label='documents',
                                      model_name='DocumentType')

        DocumentMetadata = apps.get_model(app_label='metadata',
                                          model_name='DocumentMetadata')

        DocumentIndexInstanceNode = self.get_model('DocumentIndexInstanceNode')

        Index = self.get_model('Index')
        IndexInstance = self.get_model('IndexInstance')
        IndexInstanceNode = self.get_model('IndexInstanceNode')
        IndexTemplateNode = self.get_model('IndexTemplateNode')

        APIEndPoint(app=self, version_string='1')

        ModelPermission.register(model=Index,
                                 permissions=(
                                     permission_acl_edit,
                                     permission_acl_view,
                                     permission_document_indexing_create,
                                     permission_document_indexing_delete,
                                     permission_document_indexing_edit,
                                     permission_document_indexing_view,
                                 ))

        Package(label='Django MPTT',
                license_text='''
Django MPTT
-----------

Copyright (c) 2007, Jonathan Buchanan

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 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.
        ''')

        Package(label='djangorestframework-recursive',
                license_text='''
Copyright (c) 2015, Warren Jin <*****@*****.**>

Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.

THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
        ''')

        SourceColumn(source=Index, label=_('Label'), attribute='label')
        SourceColumn(source=Index, label=_('Slug'), attribute='slug')
        SourceColumn(
            source=Index,
            label=_('Enabled'),
            func=lambda context: two_state_template(context['object'].enabled))

        SourceColumn(source=IndexInstance,
                     label=_('Items'),
                     func=lambda context: context['object'].get_item_count(
                         user=context['request'].user))
        SourceColumn(source=IndexInstance,
                     label=_('Document types'),
                     attribute='get_document_types_names')

        SourceColumn(source=IndexTemplateNode,
                     label=_('Level'),
                     func=lambda context: node_level(context['object']))
        SourceColumn(
            source=IndexTemplateNode,
            label=_('Enabled'),
            func=lambda context: two_state_template(context['object'].enabled))
        SourceColumn(source=IndexTemplateNode,
                     label=_('Has document links?'),
                     func=lambda context: two_state_template(context['object'].
                                                             link_documents))

        SourceColumn(
            source=IndexInstanceNode,
            label=_('Node'),
            func=lambda context: index_instance_item_link(context['object']))
        SourceColumn(source=IndexInstanceNode,
                     label=_('Items'),
                     func=lambda context: context['object'].get_item_count(
                         user=context['request'].user))

        SourceColumn(source=DocumentIndexInstanceNode,
                     label=_('Node'),
                     func=lambda context: get_instance_link(
                         index_instance_node=context['object'], ))
        SourceColumn(source=DocumentIndexInstanceNode,
                     label=_('Items'),
                     func=lambda context: context['object'].get_item_count(
                         user=context['request'].user))

        app.conf.CELERY_QUEUES.append(
            Queue('indexing', Exchange('indexing'), routing_key='indexing'), )

        app.conf.CELERY_ROUTES.update({
            'document_indexing.tasks.task_delete_empty_index_nodes': {
                'queue': 'indexing'
            },
            'document_indexing.tasks.task_index_document': {
                'queue': 'indexing'
            },
            'document_indexing.tasks.task_do_rebuild_all_indexes': {
                'queue': 'tools'
            },
        })

        menu_facet.bind_links(links=(link_document_index_list, ),
                              sources=(Document, ))
        menu_object.bind_links(links=(link_index_setup_edit,
                                      link_index_setup_view,
                                      link_index_setup_document_types,
                                      link_acl_list, link_index_setup_delete),
                               sources=(Index, ))
        menu_object.bind_links(links=(link_template_node_create,
                                      link_template_node_edit,
                                      link_template_node_delete),
                               sources=(IndexTemplateNode, ))
        menu_main.bind_links(links=(link_index_main_menu, ))
        menu_secondary.bind_links(links=(link_index_setup_list,
                                         link_index_setup_create),
                                  sources=(Index, 'indexing:index_setup_list',
                                           'indexing:index_setup_create'))
        menu_setup.bind_links(links=(link_index_setup, ))
        menu_tools.bind_links(links=(link_rebuild_index_instances, ))

        post_delete.connect(document_index_delete,
                            dispatch_uid='document_index_delete',
                            sender=Document)
        post_delete.connect(document_metadata_index_post_delete,
                            dispatch_uid='document_metadata_index_post_delete',
                            sender=DocumentMetadata)
        post_document_created.connect(
            document_created_index_update,
            dispatch_uid='document_created_index_update',
            sender=Document)
        post_initial_document_type.connect(
            create_default_document_index,
            dispatch_uid='create_default_document_index',
            sender=DocumentType)
        post_save.connect(document_metadata_index_update,
                          dispatch_uid='document_metadata_index_update',
                          sender=DocumentMetadata)
Beispiel #9
0
    def ready(self):
        super(DjangoGPGApp, self).ready()

        Package(label='python-gnupg',
                license_text='''
Copyright (c) 2008-2014 by Vinay Sajip.
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

    * Redistributions of source code must retain the above copyright notice,
      this list of conditions and the following disclaimer.
    * Redistributions in binary form must reproduce the above copyright notice,
      this list of conditions and the following disclaimer in the documentation
      and/or other materials provided with the distribution.
    * The name(s) of the copyright holder(s) may not be used to endorse or
      promote products derived from this software without specific prior
      written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) "AS IS" AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        ''')

        SourceColumn(source=Key, label=_('ID'), attribute='key_id')
        SourceColumn(source=Key,
                     label=_('Owner'),
                     func=lambda context: ', '.join(context['object'].uids))

        SourceColumn(source=KeyStub,
                     label=_('ID'),
                     func=lambda context: '...{0}'.format(context['object'].
                                                          key_id[-16:]))
        SourceColumn(source=KeyStub, label=_('Type'), attribute='key_type')
        SourceColumn(source=KeyStub,
                     label=_('Creation date'),
                     func=lambda context: datetime.fromtimestamp(
                         int(context['object'].date)))
        SourceColumn(source=KeyStub,
                     label=_('Expiration date'),
                     func=lambda context: datetime.fromtimestamp(
                         int(context['object'].expires))
                     if context['object'].expires else _('No expiration'))
        SourceColumn(source=KeyStub, label=_('Length'), attribute='length')
        SourceColumn(source=KeyStub,
                     label=_('Identities'),
                     func=lambda context: ', '.join(context['object'].uids))

        menu_object.bind_links(links=(link_key_delete, ), sources=(Key, ))
        menu_object.bind_links(links=(link_key_receive, ), sources=(KeyStub, ))
        menu_setup.bind_links(links=(link_key_setup, ))
        menu_sidebar.bind_links(links=(link_public_keys, link_key_query),
                                sources=(
                                    'django_gpg:key_delete',
                                    'django_gpg:key_public_list',
                                    'django_gpg:key_query',
                                    'django_gpg:key_query_results',
                                ))
Beispiel #10
0
from __future__ import unicode_literals

from common.classes import Package

Package(label='Pillow',
        license_text='''
The Python Imaging Library (PIL) is

    Copyright (c) 1997-2011 by Secret Labs AB
    Copyright (c) 1995-2011 by Fredrik Lundh

By obtaining, using, and/or copying this software and/or its associated documentation, you agree that you have read, understood, and will comply with the following terms and conditions:

Permission to use, copy, modify, and distribute this software and its associated documentation for any purpose and without fee is hereby granted, provided that the above copyright notice appears in all copies, and that both that copyright notice and this permission notice appear in supporting documentation, and that the name of Secret Labs AB or the author not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission.

SECRET LABS AB AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL SECRET LABS AB OR THE AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
''')
Beispiel #11
0
from __future__ import absolute_import, unicode_literals

from common.classes import Package

Package(label='Django MPTT', license_text='''
Django MPTT
-----------

Copyright (c) 2007, Jonathan Buchanan

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 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.
''')

Package(label='djangorestframework-recursive', license_text='''
Copyright (c) 2015, Warren Jin <*****@*****.**>