system.kanoa.quality.sheet.getSheets(paramsDict)
Returns check sheets filtered by passed in paramter keys. Keys are optional.
Store chkShtVersionGroupId, not the Master ID
A check sheet's masterChkShtId moves to the newly released version each time a revision is released, so a view or dashboard that stores it stops matching after the next release. Store chkShtVersionGroupId instead: every version of a check sheet shares it, and it never changes. To get the current master from it:
released = system.kanoa.quality.sheet.getSheets({'chkShtVersionGroupId': groupId, 'chkShtVersionStateName': 'Released'})
masterChkShtId = released.getValueAt(0, 'masterChkShtId') if released.rowCount else None
Parameters
paramsDict Dictionary
| - auto | Boolean | Filter check sheets by auto or manual |
| - chkShtId | Integer | This is the id of this check sheet |
| - chkShtName | String | |
| - chkShtTypeId | Integer | filter by type of check sheet. Type refers to grouping of check sheets in folders. |
| - chkShtTypeName | String | |
| - chkShtVersionGroupId | Integer | This is a stable Id that links different versions of the same check sheet together. This id never changes |
| - chkShtVersionStateId | Integer | |
| - chkShtVersionStateName | String | |
| - chkShtVersionStateNameList | List of Strings | |
| - enabled | Boolean | |
| - masterChkShtId | Integer | This is a variable Id that links different versions of the same check sheet together, stating the 'released' version chkShtId for this group |
| - masterOnly | Boolean | |
| - path | String |
Returns
data pyDataset
Example
paramsDict = {'enabled': True}
chkShtData = system.kanoa.quality.sheet.getSheets(paramsDict)
# The released version of a check sheet, by its stable chkShtVersionGroupId
paramsDict = {'chkShtVersionGroupId': 12, 'chkShtVersionStateName': 'Released'}
chkShtData = system.kanoa.quality.sheet.getSheets(paramsDict)
masterChkShtId = chkShtData.getValueAt(0, 'masterChkShtId') if chkShtData.getRowCount() else None
masterChkShtId moves to the new release each time a revision is released; chkShtVersionGroupId never changes. See Check Sheet Version Control for how versions work.