HTML dodany do API.
[redakcja.git] / apps / api / resources.py
1 # -*- encoding: utf-8 -*-
2
3 __author__= "Ɓukasz Rekucki"
4 __date__ = "$2009-09-25 15:53:00$"
5 __doc__ = "Module documentation."
6
7 from piston.resource import Resource
8 from api.utils import DjangoAuth
9
10
11
12
13 authdata = {'authentication': DjangoAuth()}
14
15 #
16 # Library resources
17 #
18
19 import api.handlers.library_handlers as dh
20 library_resource = Resource(dh.LibraryHandler, **authdata)
21 document_resource = Resource(dh.DocumentHandler, **authdata)
22 document_text_resource = Resource(dh.DocumentTextHandler, **authdata)
23 document_html_resource = Resource(dh.DocumentHTMLHandler, **authdata)
24 document_dc_resource = Resource(dh.DocumentDublinCoreHandler, **authdata)
25 document_merge = Resource(dh.MergeHandler, **authdata)
26
27 #
28 # Toolbar resources
29 #
30 import api.handlers.toolbar_handlers as th
31 toolbar_buttons = Resource(th.ToolbarHandler, **authdata)
32 scriptlets = Resource(th.ScriptletsHandler, **authdata)
33
34 __all__ = [
35     'library_resource',
36     'document_resource',
37     'document_text_resource',
38     'document_dc_resource',
39     'document_merge',
40     'toolbar_buttons',
41     'scriptlets'
42 ]