Revision 9123ecac
Added by Jérôme Schneider over 12 years ago
calebasse/api.py | ||
---|---|---|
1 | 1 |
|
2 | 2 |
from tastypie.authorization import DjangoAuthorization |
3 | 3 |
from tastypie.resources import ModelResource |
4 |
from calebasse.actes.models import Act |
|
4 | 5 |
from calebasse.agenda.models import Event |
5 | 6 |
from calebasse.dossiers.models import PatientRecord, PatientAddress |
6 | 7 |
|
... | ... | |
23 | 24 |
resource_name = 'patientaddress' |
24 | 25 |
authorization = DjangoAuthorization() |
25 | 26 |
|
27 |
class ActRessource(ModelResource): |
|
28 |
class Meta: |
|
29 |
queryset = Act.objects.all() |
|
30 |
resource_name = 'act' |
|
31 |
authorization = DjangoAuthorization() |
|
32 |
|
|
26 | 33 |
patientaddress_ressource = PatientAddressRessource() |
27 | 34 |
event_resource = EventResource() |
28 | 35 |
patientrecord_resource = PatientRecordRessource() |
36 |
act_ressource = ActRessource() |
|
29 | 37 |
|
Also available in: Unified diff
agenda / api: act validation manage billable and lost