Create a "web development in Sonador" set of pages which describe design patterns, workflows, and components within the Oak-Tree platform
Design patterns:
- How are the backend components of the Oak-Tree platform and Sonador organized?
-
lib/guru
- Management endpoints
- REST endpoints
- Form driven data cleaning/validation
-
lib/secure
- security: API access credentials and tokens
-
api_request
: security applied via decorators at URL patterns
-
- How are the APIs consumed?
- Guru Client library
- Traditional REST conventions
- Management API endpoint (collection methods)
-
fetch
(classmethod
): retrieve JSON data for a collection -
fetch_modelinstance
(classmethod
): retrieve JSON data for a single member -
create
(classmethod
): create a model instance
-
- Rest API endpoint (instance methods)
-
update
: update data for single instance -
remove
: remove instance form the server
-
- Sonador IO client
-
local
: work with DICOM data from a local source (folder) -
remote
: API based data- Sonador Web Application
- Orthanc (
imaging.orthanc
)- Core/Resources: managed by uploading DICOM resources and indexing their contents
- Extension models: associated with resources and managed via standard conventions
-
sr
: structured data associated with a resource
-
- Guru Client library
Components:
-
lib/guru
-
views.py
: https://code.oak-tree.tech/django-apps/guru/-/blob/master/views.py-
GuruApiObjectManagementView
: used to list existing instances and create new instances of model data -
GuruApiRestView
: provide API access points to retrieve JSON encoded data
-
-
forms.py
: https://code.oak-tree.tech/django-apps/guru/-/blob/master/forms/init.py-
create_modelform_class
: create a form class for data validation from a model instance. Supports nested model validation. -
GuruCoreForm
: form class which supports nested model validation -
RelatedModelField
: form field providing nested model validation -
ManyToManyRelatedModelField
: form field providing support for form validation and update of many-to-many database relationships, including nested model validation
-
-
filter.py
: https://code.oak-tree.tech/django-apps/guru/-/tree/master/filter-
forms.py
: https://code.oak-tree.tech/django-apps/guru/-/blob/master/filter/forms.py-
GuruQueryParamFilterFormMixin
: mixin class which can be used to add query parameter filtering of results to a view
-
-
views.py
: https://code.oak-tree.tech/django-apps/guru/-/blob/master/filter/views.py-
GuruFilterForm
: Form which can be used to filter model results (works with a view that incorporatesGuruQueryParamFilterFormMixin
), provides properties to convert between query parameters and Queryset filter parameters.
-
-
-