Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • Database

Implements

  • IDatabase

Index

Constructors

constructor

  • new Database(serverName?: string, databaseName?: string): Database
  • Parameters

    • Optional serverName: string
    • Optional databaseName: string

    Returns Database

Methods

getAccessLevel

  • Gets the access level of current user

    Returns ACCESSLEVEL

    • Access Level enumeration

getCurrentDoc

  • Returns the current document opened in the page

    Returns Document

    A document object

getDb

  • getDb(serverName?: string, databaseName?: string): Database
  • Parameters

    • Optional serverName: string
    • Optional databaseName: string

    Returns Database

getDocByUnid

  • Returns a document with the provided unique ID

    Parameters

    • unid: string

      The universal ID of the document. Example: D7D294D720E4DEEC492585E3001D0371

    Returns Document

getView

  • getView(vwName: string): View
  • Returns a view object

    Parameters

    • vwName: string

      The name of the view or the alias. Example vwAllDocument or (vwAllUsers) for hidden views

    Returns View

    A View object

hasAccessPrivilege

  • Checks if the current user has a certain access privilege. Only one privilege is checked at a time

    Parameters

    Returns boolean

    • True if the user has the specified access privilege

hasRole

  • hasRole(roleName: string): boolean
  • Checks if the current user has a particular role assigned

    Parameters

    • roleName: string

      The database role name in square brackets, example: [Admin]

    Returns boolean

    • True if the user has the specified role, false otherwise

Generated using TypeDoc