Skip to main content

system.kanoa.dashboard.updateUserDashboardField

This function is part of the kanoaCore module

Description

Updates the field with the passed value for the userDashboardId

Syntax

updateUserDashboardField(userDashboardId, field, value, userId)
  • Parameters
      serDashboardId (int)
      field (str): Name of the column to change
      value (object): new value for this field
      userId (int): used for the createdBy field
  • Returns
      retVal (int): # of records modified
      msg (string): error message, None if successful
  • Code Examples

    # Example usage
    retVal, msg = system.kanoa.dashboard.updateUserDashboardField(7, 'isDefault', True, userId)
    if msg: system.perspective.sendMessage('showFailerToast', msg)
    else: system.perspective.sendMessage('showSuccessfulToast', 'User Dashboard field has been updated')