system.kanoa.quality.config.updateCheck(chkItemInfo, userId)
Updates the configuration for a check item. All chkItemInfo keys are required.
Parameters
chkItemInfo Dictionary
| - attributeId | Integer | links to an attribute for data source value capture and/or tolerance checking for pass/fail |
| - calculation | String | |
| - chkItemGroupId | Integer | |
| - chkItemId | Integer | |
| - chkItemName | String | |
| - chkItemTriggerId | Integer | |
| - chkItemTypeId | Integer | |
| - chkShtId | Integer | |
| - dataTypeId | Integer | |
| - dynamic | Boolean | If true, this check will only be displayed if we find a tolerance set for it based on asset and item |
| - enabled | Boolean | |
| - engUnitId | Integer | |
| - format | String | i.e. "#,##0.0" |
| - instructions | String | |
| - measAggregate | String | |
| - measCount | Integer | |
| - persistence | Boolean | If true, this check value will be set to the value taken for the previous check. It can be modified by the check taker |
| - pickListId | Integer | |
| - pickListValues | String | |
| - required | Boolean | |
| - sortOrder | Integer | |
| - specification | String |
userId Integer
Returns
# of records modified Integer
Example
chkItemInfo = {
'chkItemId': 76,
'chkItemGroupId': 1,
'chkShtId': 2,
'dataTypeId':3,
'engUnitId':None,
'chkItemName': 'Check 1',
'chkItemTypeId':1,
'chkItemTriggerId':4,
'measCount': 1,
'measAggregate': None,
'instructions': None,
'pickListId': 4,
'pickListValues': None,
'calculation': None,
'required': True,
'enabled': True,
'dynamic': False,
'sortOrder':0,
'format': "#,##0.0",
'attributeId': None,
'specification': None,
'persistence': None
}
userId = 5
retVal = system.kanoa.quality.config.updateCheck(chkItemInfo, userId)