Beispiel #1
0
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls.defaults import *
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = {'authentication': auth_engine}

#infrastructure resources
typeResource = CsrfExemptResource(handler=handlers.ItemTypeHandler, **ad)
fieldResource = CsrfExemptResource(handler=handlers.ItemFieldHandler, **ad)
itemResource = CsrfExemptResource(handler=handlers.ItemHandler, **ad)
statusResource = CsrfExemptResource(handler=handlers.ItemStatusHandler, **ad)
serviceRecordResource = CsrfExemptResource(
    handler=handlers.ItemServicingHandler, **ad)
locationResource = CsrfExemptResource(handler=handlers.LocationHandler, **ad)

urlpatterns = patterns(
    '',
    #Infrastructure
    url(r'^doc$',
        documentation_view,
        kwargs={'module': handlers},
        name="api_infrastructure_doc"),
    url(r'^fields$', fieldResource, name="api_infrastructure_fields"),
Beispiel #2
0
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls import patterns, url
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = {'authentication': auth_engine}

# news resources
updateRecordsResource = CsrfExemptResource(
    handler=handlers.UpdateRecordHandler, **ad)

urlpatterns = patterns(
    '',
    # News
    url(r'^doc$',
        documentation_view,
        kwargs={'module': handlers},
        name="api_news_doc"),
    url(r'^records$', updateRecordsResource, name="api_news_update_records"),
    url(r'^record/(?P<record_id>\d+)',
        updateRecordsResource,
        name="api_news_update_records"),
)
Beispiel #3
0
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls.defaults import *
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = {'authentication': auth_engine}

#sales resources
saleStatusResource = CsrfExemptResource(handler=handlers.SaleStatusHandler,
                                        **ad)
productResource = CsrfExemptResource(handler=handlers.ProductHandler, **ad)
sourceResource = CsrfExemptResource(handler=handlers.SaleSourceHandler, **ad)
leadResource = CsrfExemptResource(handler=handlers.LeadHandler, **ad)
opportunityResource = CsrfExemptResource(handler=handlers.OpportunityHandler,
                                         **ad)
orderResource = CsrfExemptResource(handler=handlers.SaleOrderHandler, **ad)
subscriptionResource = CsrfExemptResource(handler=handlers.SubscriptionHandler,
                                          **ad)
orderedProductResource = CsrfExemptResource(
    handler=handlers.OrderedProductHandler, **ad)

urlpatterns = patterns(
    '',
    #Sales
    url(r'^doc$',
Beispiel #4
0
# encoding: utf-8
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls import patterns, url
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = {'authentication': auth_engine}

# events resources
eventResource = CsrfExemptResource(handler=handlers.EventHandler, **ad)

urlpatterns = patterns(
    '',
    # Events
    url(r'^doc$',
        documentation_view,
        kwargs={'module': handlers},
        name="api_events_doc"),
    url(r'^events$', eventResource, name="api_events"),
    url(r'^event/(?P<object_ptr>\d+)', eventResource, name="api_events"),
)
Beispiel #5
0
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls.defaults import *
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = {'authentication': auth_engine}

#documents resources
folderResource = CsrfExemptResource(handler=handlers.FolderHandler, **ad)
fileResource = CsrfExemptResource(handler=handlers.FileHandler, **ad)
documentResource = CsrfExemptResource(handler=handlers.DocumentHandler, **ad)
weblinkResource = CsrfExemptResource(handler=handlers.WebLinkHandler, **ad)

urlpatterns = patterns(
    '',
    #Documents
    url(r'^doc$',
        documentation_view,
        kwargs={'module': handlers},
        name="api_documents_doc"),
    url(r'^folders$', folderResource, name="api_documents_folders"),
    url(r'^folder/(?P<object_ptr>\d+)',
        folderResource,
        name="api_documents_folders"),
Beispiel #6
0
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls import patterns, url
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = {'authentication': auth_engine}

# knowledge resources
folderResource = CsrfExemptResource(
    handler=handlers.KnowledgeFolderHandler, **ad)
categoryResource = CsrfExemptResource(
    handler=handlers.KnowledgeCategoryHandler, **ad)
itemResource = CsrfExemptResource(handler=handlers.KnowledgeItemHandler, **ad)

urlpatterns = patterns('',
    # Knowledge
    url(r'^doc$', documentation_view, kwargs={
        'module': handlers}, name="api_knowledge_doc"),
    url(r'^folders$', folderResource,
        name='api_knowledge_folders'),
    url(r'^folder/(?P<object_ptr>\d+)',
        folderResource, name='api_knowledge_folders'),
    url(r'^categories$', categoryResource,
        name='api_knowledge_categories'),
    url(r'^category/(?P<object_ptr>\d+)',
Beispiel #7
0
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls import patterns, url
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = {'authentication': auth_engine}

# services resources
ticketStatusResource = CsrfExemptResource(
    handler=handlers.TicketStatusHandler, **ad)
serviceResource = CsrfExemptResource(handler=handlers.ServiceHandler, **ad)
slaResource = CsrfExemptResource(
    handler=handlers.ServiceLevelAgreementHandler, **ad)
agentResource = CsrfExemptResource(handler=handlers.ServiceAgentHandler, **ad)
queueResource = CsrfExemptResource(handler=handlers.TicketQueueHandler, **ad)
ticketResource = CsrfExemptResource(handler=handlers.TicketHandler, **ad)
ticketRecordResource = CsrfExemptResource(
    handler=handlers.TicketRecordHandler, **ad)

urlpatterns = patterns('',
    # Services
    url(r'^doc$', documentation_view, kwargs={
        'module': handlers}, name="api_services_doc"),
    url(r'^services$', serviceResource,
        name="api_services"),
Beispiel #8
0
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls.defaults import *
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = { 'authentication': auth_engine }

#projects resources
taskResource = CsrfExemptResource(handler = handlers.TaskHandler, **ad)
projectResource = CsrfExemptResource(handler = handlers.ProjectHandler, **ad)
statusResource = CsrfExemptResource(handler = handlers.TaskStatusHandler, **ad)
taskTimeResource = CsrfExemptResource(handler = handlers.TaskTimeHandler, **ad)
milestoneResource = CsrfExemptResource(handler = handlers.MilestoneHandler, **ad)
startTimeResource = CsrfExemptResource(handler = handlers.StartTaskTimeHandler, **ad)
stopTimeResource = CsrfExemptResource(handler = handlers.StopTaskTimeHandler, **ad)

urlpatterns = patterns('',
#Projects
    url(r'^doc$', documentation_view, kwargs={'module': handlers}, name="api_projects_doc"),
    url(r'^projects$', projectResource, name="api_projects"),
    url(r'^project/(?P<object_ptr>\d+)', projectResource, name="api_projects"),
    url(r'^status$', statusResource, name="api_projects_status"),
    url(r'^status/(?P<object_ptr>\d+)', statusResource, name="api_projects_status"),
    url(r'^milestones$', milestoneResource, name="api_projects_milestones"),
Beispiel #9
0
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls.defaults import *
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = {'authentication': auth_engine}

#messaging resources
mlistResource = CsrfExemptResource(handler=handlers.MailingListHandler, **ad)
streamResource = CsrfExemptResource(handler=handlers.MessageStreamHandler,
                                    **ad)
messageResource = CsrfExemptResource(handler=handlers.MessageHandler, **ad)

urlpatterns = patterns(
    '',
    #Messaging
    url(r'^doc$',
        documentation_view,
        kwargs={'module': handlers},
        name="api_messaging_doc"),
    url(r'^mlist$', mlistResource, name="api_messaging_mlist"),
    url(r'^mlist/(?P<object_ptr>\d+)',
        mlistResource,
        name="api_messaging_mlist"),
Beispiel #10
0
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls import patterns, url
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = {'authentication': auth_engine}

# identities resources
contactFieldResource = CsrfExemptResource(handler=handlers.ContactFieldHandler,
                                          **ad)
contactTypeResource = CsrfExemptResource(handler=handlers.ContactTypeHandler,
                                         **ad)
contactResource = CsrfExemptResource(handler=handlers.ContactHandler, **ad)

urlpatterns = patterns(
    '',
    # Identities
    url(r'^doc$',
        documentation_view,
        kwargs={'module': handlers},
        name="api_identities_doc"),
    url(r'^fields$', contactFieldResource, name="api_identities_fields"),
    url(r'^field/(?P<object_ptr>\d+)',
        contactFieldResource,
        name="api_identities_fields"),
Beispiel #11
0
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

from django.conf.urls import patterns, url

ad = {'authentication': auth_engine}

# finance resources
currencyResource = CsrfExemptResource(handler=handlers.CurrencyHandler, **ad)
taxResource = CsrfExemptResource(handler=handlers.TaxHandler, **ad)
categoryResource = CsrfExemptResource(handler=handlers.CategoryHandler, **ad)
assetResource = CsrfExemptResource(handler=handlers.AssetHandler, **ad)
accountResource = CsrfExemptResource(handler=handlers.AccountHandler, **ad)
equityResource = CsrfExemptResource(handler=handlers.EquityHandler, **ad)
liabilityResource = CsrfExemptResource(handler=handlers.LiabilityHandler, **ad)
transactionResource = CsrfExemptResource(handler=handlers.TransactionHandler,
                                         **ad)

urlpatterns = patterns(
    '',
    # Finance
    url(r'^doc$',
        documentation_view,
        kwargs={'module': handlers},
Beispiel #12
0
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license

#-*- coding: utf-8 -*-

import handlers
from django.conf.urls.defaults import *
from treeio.core.api.auth import auth_engine
from treeio.core.api.doc import documentation_view
from treeio.core.api.resource import CsrfExemptResource

ad = { 'authentication': auth_engine }

#admin resources
groupResource = CsrfExemptResource(handler = handlers.GroupHandler, **ad)
userResource = CsrfExemptResource(handler = handlers.UserHandler, **ad)
moduleResource = CsrfExemptResource(handler = handlers.ModuleHandler, **ad)
perspectiveResource = CsrfExemptResource(handler = handlers.PerspectiveHandler, **ad)
#folderResource = CsrfExemptResource(handler = handlers.PageFolderHandler, **ad)
#pageResource = CsrfExemptResource(handler = handlers.PageHandler, **ad)

urlpatterns = patterns('',
#Resources
    url(r'^doc$', documentation_view, kwargs={'module': handlers}, name="api_admin_doc"),
    url(r'^groups$', groupResource, name="api_admin_groups"),
    url(r'^group/(?P<accessentity_ptr>\d+)', groupResource, name="api_admin_groups"),
    url(r'^users$', userResource, name="api_admin_users"),
    url(r'^user/(?P<accessentity_ptr>\d+)', userResource, name="api_admin_users"),
    url(r'^modules$', moduleResource, name="api_admin_modules"),
    url(r'^module/(?P<object_ptr>\d+)', moduleResource, name="api_admin_modules"),