system.kanoa.quality.config.addAttribute
Description
Adds a new attribute in KanoaQDS.Syntax
addAttribute(attrInfo, userId)- dict attrInfo - Dictionary, e.g., {'attributeName': 'some attribute name', 'attributeDescription': 'some description', 'parentId': 6, 'enabled': True}
- int userId - User ID
- int attributeId - ID of the newly added attribute.
Code Examples
# Usage example
attribute_info = {'attributeName': 'some attribute name', 'attributeDescription': 'some description', 'parentId': 6, 'enabled': True}
new_attribute_id = system.kanoa.quality.config.addAttribute(attrInfo=attribute_info, userId=123)
if new_attribute_id is not None:
print(f"Successfully added attribute with ID: {new_attribute_id}")