Skip to content

Commit 2a11b4c

Browse files
lmorronigonchik
authored andcommitted
adding support to pull price tables based on account id (#417)
1 parent f0a0cf0 commit 2a11b4c

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

atlassian/jira.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ def add_user_to_application(self, username, application_key):
325325
Add a user to an application
326326
:param username: The username of the user to add.
327327
:param application_key: The application key of the application
328-
:return: True if the user was added to the application, else False
328+
:return: True if the user was added to the application, else False
329329
:see: https://docs.atlassian.com/software/jira/docs/api/REST/7.5.3/#api/2/user-addUserToApplication
330330
"""
331331
params = {
@@ -1759,6 +1759,18 @@ def tempo_account_delete_account_by_id(self, account_id):
17591759
url = 'rest/tempo-accounts/1/account/{id}/'.format(id=account_id)
17601760
return self.delete(url)
17611761

1762+
def tempo_account_get_rate_table_by_account_id(self, account_id):
1763+
"""
1764+
Returns a rate table for the specified account.
1765+
:param account_id: the account id.
1766+
:return:
1767+
"""
1768+
params = {}
1769+
params['scopeType'] = "ACCOUNT"
1770+
params['scopeId'] = account_id
1771+
url = 'rest/tempo-accounts/1/ratetable'
1772+
return self.get(url, params=params)
1773+
17621774
def tempo_account_get_all_account_by_customer_id(self, customer_id):
17631775
"""
17641776
Get un-archived Accounts by customer. The Caller must have the Browse Account permission for the Account.

0 commit comments

Comments
 (0)