Class General

A plugin that contains "general" methods for a Cityworks install

Hierarchy

  • General

Methods

  • Add Holidays

    Returns

    Returns Promise object that represents a

    Parameters

    • holiday: Date

      The holiday's date

    • description: string

      The holiday's name/description

    Returns Promise<unknown>

  • Find out if the current user is watching a particular activity (case, task, null [as a string])

    Returns

    Returns Promise object that represents a boolean indicating the currently authenticated user is watching the provided activity

    Parameters

    • activityType: any

      which activity type the following ID will be for.

    • activityId: number

      activity Case or CaseTask (task instance) ID to check

    Returns Promise<unknown>

  • Delete Holidays

    Returns

    Returns Promise object that represents a

    Parameters

    • holidays: Date[]

      List of datetimes which should have holidays deleted

    Returns Promise<unknown>

  • Get CwMetatData by Type and CwSid

    Returns

    Returns Promise object that represents a

    Parameters

    • ids: number[]
    • table: string

    Returns Promise<unknown>

  • Get recent history for authenticated user

    Returns

    Returns Promise object that represents a collection of RecentActivity objects

    Returns Promise<unknown>

  • Get Holidays

    Returns

    Returns Promise object that represents a list of the holiday(s) found

    Parameters

    • startDate: Date

      Date to search for Holidays, including this date.

    • Optional endDate: Date

      If not specified, Holidays on startDate are returned. If specified, Holidays on startDate up to, but not including endDate are returned.

    Returns Promise<unknown>

  • Get cost summary for WorkOrder entities

    Returns

    Returns Promise object that represents a

    Parameters

    • object_ids: number[]

    Returns Promise<unknown>

  • Get notifications for currently authenticated user

    Returns

    Returns Promise object that represents a collection of available notifications

    Returns Promise<unknown>

  • Get cost summary for WorkOrder entities selected through a search definition

    Returns

    Returns Promise object that represents a

    Parameters

    • search_id: number

    Returns Promise<unknown>