Skip to content

Commit

Permalink
add configuration types api
Browse files Browse the repository at this point in the history
  • Loading branch information
Mark Ciecior committed Sep 23, 2023
1 parent 2833ff6 commit c3086ad
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 1 deletion.
6 changes: 5 additions & 1 deletion CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,8 @@

0.6.0.3
---
- Added support for Company Teams
- Added support for Company Teams

0.6.0.4
---
- Added support for Configuration Types
39 changes: 39 additions & 0 deletions company/configuration_types_api.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
from ..cw_controller import CWController
# Class for /company/companies/types
from connectpyse.company import configuration_type


class ConfigurationTypeAPI(CWController):
def __init__(self, **kwargs):
self.module_url = 'company'
self.module = 'configurations/types'
self._class = configuration_type.ConfigurationType
super().__init__(**kwargs) # instance gets passed to parent object

def get_configuration_types(self):
return super()._get()

def create_configuration_type(self, a_configuration_type):
return super()._create(a_configuration_type)

def get_configuration_types_count(self):
return super()._get_count()

def get_configuration_type_by_id(self, configuration_type_id):
return super()._get_by_id(configuration_type_id)

def delete_configuration_type_by_id(self, configuration_type_id):
super()._delete_by_id(configuration_type_id)

def replace_configuration_type(self, configuration_type_id):
pass

def update_configuration_type(self, configuration_type_id, key, value):
return super()._update(configuration_type_id, key, value)

def update_configuration_type_multiple_keys(self, configuration_type_id, changes_dict):
return super()._update_multiple_keys(configuration_type_id, changes_dict)

def merge_configuration_type(self, a_configuration_type, target_configuration_type_id):
# return super()._merge(a_configuration_type, target_configuration_type_id)
pass

0 comments on commit c3086ad

Please sign in to comment.