Skip to main content

system.kanoa.schedule.deleteScheduleBlocks

This function requires KanoaOPS module

Description

Deletes all schedule blocks for the given parameters. Formerly called 'deleteLineScheduleInfoFromTable'.

Syntax

deleteScheduleBlocks(assetId, startDate, endDate, userId)
  • Parameters
      assetId (int) - Asset ID.
      startDate (datetime) - Start date for the deletion.
      endDate (datetime) - End date for the deletion.
      userId (int) - User ID.
  • Returns
      # of records modified.
  • Code Example

    # Example Usage:
    asset_id = 123
    start_date = ...
    end_date = ...
    user_id = 456
    records_modified = system.kanoa.schedule.deleteScheduleBlocks(asset_id, start_date, end_date, user_id)