@@ -205,7 +205,7 @@ def add_to_groups(self, groups=None, all_groups=False, group_type=None):
205205 Add user to some (typically PLC) groups. Note that, if you add to no groups, the effect
206206 is simply to do an "add to organization Everybody group", so we let that be done.
207207 :param groups: list of group names the user should be added to
208- :param all_groups: a boolean meaning remove from all (don't specify groups or group_type in this case)
208+ :param all_groups: a boolean meaning add to all (don't specify groups or group_type in this case)
209209 :param group_type: the type of group (defaults to "product")
210210 :return: the User, so you can do User(...).add_to_groups(...).add_role(...)
211211 """
@@ -252,8 +252,8 @@ def remove_from_groups(self, groups=None, all_groups=False, group_type=None):
252252 def add_role (self , groups = None , role_type = RoleTypes .admin ):
253253 """
254254 Make user have a role (typically PLC admin) with respect to some PLC groups.
255- :param groups: list of group names the user should be an admin for
256- :param role_type: the type of role (defaults to "admin")
255+ :param groups: list of group names the user should have this role for
256+ :param role_type: the role (defaults to "admin")
257257 :return: the User, so you can do User(...).add_role(...).add_to_groups(...)
258258 """
259259 if not groups :
@@ -268,7 +268,7 @@ def add_role(self, groups=None, role_type=RoleTypes.admin):
268268 def remove_role (self , groups = None , role_type = RoleTypes .admin ):
269269 """
270270 Remove user from a role (typically admin) of some groups.
271- :param groups: list of group names the user should NOT be an admin for
271+ :param groups: list of group names the user should NOT have this role for
272272 :param role_type: the type of role (defaults to "admin")
273273 :return: the User, so you can do User(...).remove_role(...).remove_from_groups(...)
274274 """
@@ -288,9 +288,7 @@ def remove_from_organization(self, delete_account=False):
288288 :param delete_account: Whether to delete the account after removing from the organization (default false)
289289 :return: None, because you cannot follow this command with another.
290290 """
291- self .append (removeFromOrg = {})
292- if delete_account :
293- self .delete_account ()
291+ self .append (removeFromOrg = {"deleteAccount" : True if delete_account else False })
294292 return None
295293
296294 def delete_account (self ):
@@ -356,9 +354,9 @@ def __init__(self, group_name=None, **kwargs):
356354
357355 def add_to_products (self , products = None , all_products = False ):
358356 """
359- Add user product to some PLC products .
357+ Add user group to some product license configuration groups (PLCs), or all of them .
360358 :param products: list of product names the user should be added to
361- :param all_products: a boolean meaning remove from all (don't specify products in this case)
359+ :param all_products: a boolean meaning add to all (don't specify products in this case)
362360 :return: the Group, so you can do Group(...).add_to_products(...).add_users(...)
363361 """
364362 if all_products :
@@ -373,7 +371,7 @@ def add_to_products(self, products=None, all_products=False):
373371
374372 def remove_from_products (self , products = None , all_products = False ):
375373 """
376- Remove user group from some PLC products , or all of them.
374+ Remove user group from some product license configuration groups (PLCs) , or all of them.
377375 :param products: list of product names the user group should be removed from
378376 :param all_products: a boolean meaning remove from all (don't specify products in this case)
379377 :return: the Group, so you can do Group(...).remove_from_products(...).add_users(...)
0 commit comments