다음을 통해 공유


DashboardRestClient class

VSS REST api에 대한 요청을 만드는 데 사용해야 하는 기본 클래스(파생)입니다.

Extends

생성자

DashboardRestClient(IVssRestClientOptions)

속성

RESOURCE_AREA_ID

메서드

createDashboard(Dashboard, TeamContext)

제공된 대시보드를 만듭니다.

createWidget(Widget, TeamContext, string)

지정된 대시보드에 위젯을 만듭니다.

deleteDashboard(TeamContext, string)

ID가 지정된 대시보드를 삭제합니다. 이렇게 하면 이 대시보드와 연결된 위젯도 삭제됩니다.

deleteWidget(TeamContext, string, string)

지정된 위젯을 삭제합니다.

getDashboard(TeamContext, string)

ID로 대시보드를 가져옵니다.

getDashboardsByProject(TeamContext)

프로젝트 아래의 대시보드 목록을 가져옵니다.

getWidget(TeamContext, string, string)

지정된 위젯의 현재 상태를 가져옵니다.

getWidgetMetadata(string, string)

지정된 기여 ID를 충족하는 위젯 메타데이터를 가져옵니다.

getWidgetTypes(WidgetScope, string)

isVisibleFromCatalog == false로 표시된 위젯을 포함하여 사용 가능한 모든 위젯 메타데이터를 알파벳 순서로 가져옵니다.

replaceDashboard(Dashboard, TeamContext, string)

지정된 대시보드에 대한 구성을 바꿉니다. Dashboard의 위젯 목록을 대체합니다(속성이 제공된 경우에만).

replaceDashboards(DashboardGroup, TeamContext)

제공된 그룹에서 대시보드의 이름과 위치를 업데이트하고 생략된 대시보드를 제거합니다. 대시보드 콘텐츠를 수정하지 않습니다.

replaceWidget(Widget, TeamContext, string, string)

지정된 위젯의 상태를 재정의합니다.

updateWidget(Widget, TeamContext, string, string)

지정된 위젯의 부분 업데이트를 수행합니다.

생성자 세부 정보

DashboardRestClient(IVssRestClientOptions)

new DashboardRestClient(options: IVssRestClientOptions)

매개 변수

속성 세부 정보

RESOURCE_AREA_ID

static RESOURCE_AREA_ID: string

속성 값

string

메서드 세부 정보

createDashboard(Dashboard, TeamContext)

제공된 대시보드를 만듭니다.

function createDashboard(dashboard: Dashboard, teamContext: TeamContext): Promise<Dashboard>

매개 변수

dashboard
Dashboard

대시보드의 초기 상태

teamContext
TeamContext

작업에 대한 팀 컨텍스트

반환

Promise<Dashboard>

createWidget(Widget, TeamContext, string)

지정된 대시보드에 위젯을 만듭니다.

function createWidget(widget: Widget, teamContext: TeamContext, dashboardId: string): Promise<Widget>

매개 변수

widget
Widget

추가할 위젯의 상태

teamContext
TeamContext

작업에 대한 팀 컨텍스트

dashboardId

string

위젯이 추가될 대시보드의 ID입니다.

반환

Promise<Widget>

deleteDashboard(TeamContext, string)

ID가 지정된 대시보드를 삭제합니다. 이렇게 하면 이 대시보드와 연결된 위젯도 삭제됩니다.

function deleteDashboard(teamContext: TeamContext, dashboardId: string): Promise<void>

매개 변수

teamContext
TeamContext

작업에 대한 팀 컨텍스트

dashboardId

string

삭제할 대시보드의 ID입니다.

반환

Promise<void>

deleteWidget(TeamContext, string, string)

지정된 위젯을 삭제합니다.

function deleteWidget(teamContext: TeamContext, dashboardId: string, widgetId: string): Promise<Dashboard>

매개 변수

teamContext
TeamContext

작업에 대한 팀 컨텍스트

dashboardId

string

위젯이 포함된 대시보드의 ID입니다.

widgetId

string

업데이트할 위젯의 ID입니다.

반환

Promise<Dashboard>

getDashboard(TeamContext, string)

ID로 대시보드를 가져옵니다.

function getDashboard(teamContext: TeamContext, dashboardId: string): Promise<Dashboard>

매개 변수

teamContext
TeamContext

작업에 대한 팀 컨텍스트

dashboardId

string

반환

Promise<Dashboard>

getDashboardsByProject(TeamContext)

프로젝트 아래의 대시보드 목록을 가져옵니다.

function getDashboardsByProject(teamContext: TeamContext): Promise<Dashboard[]>

매개 변수

teamContext
TeamContext

작업에 대한 팀 컨텍스트

반환

Promise<Dashboard[]>

getWidget(TeamContext, string, string)

지정된 위젯의 현재 상태를 가져옵니다.

function getWidget(teamContext: TeamContext, dashboardId: string, widgetId: string): Promise<Widget>

매개 변수

teamContext
TeamContext

작업에 대한 팀 컨텍스트

dashboardId

string

위젯이 포함된 대시보드의 ID입니다.

widgetId

string

읽을 위젯의 ID입니다.

반환

Promise<Widget>

getWidgetMetadata(string, string)

지정된 기여 ID를 충족하는 위젯 메타데이터를 가져옵니다.

function getWidgetMetadata(contributionId: string, project?: string): Promise<WidgetMetadataResponse>

매개 변수

contributionId

string

위젯에 대한 기여 ID

project

string

프로젝트 ID 또는 프로젝트 이름

반환

getWidgetTypes(WidgetScope, string)

isVisibleFromCatalog == false로 표시된 위젯을 포함하여 사용 가능한 모든 위젯 메타데이터를 알파벳 순서로 가져옵니다.

function getWidgetTypes(scope: WidgetScope, project?: string): Promise<WidgetTypesResponse>

매개 변수

scope
WidgetScope
project

string

프로젝트 ID 또는 프로젝트 이름

반환

replaceDashboard(Dashboard, TeamContext, string)

지정된 대시보드에 대한 구성을 바꿉니다. Dashboard의 위젯 목록을 대체합니다(속성이 제공된 경우에만).

function replaceDashboard(dashboard: Dashboard, teamContext: TeamContext, dashboardId: string): Promise<Dashboard>

매개 변수

dashboard
Dashboard

교체할 대시보드의 구성입니다.

teamContext
TeamContext

작업에 대한 팀 컨텍스트

dashboardId

string

교체할 대시보드의 ID입니다.

반환

Promise<Dashboard>

replaceDashboards(DashboardGroup, TeamContext)

제공된 그룹에서 대시보드의 이름과 위치를 업데이트하고 생략된 대시보드를 제거합니다. 대시보드 콘텐츠를 수정하지 않습니다.

function replaceDashboards(group: DashboardGroup, teamContext: TeamContext): Promise<DashboardGroup>

매개 변수

teamContext
TeamContext

작업에 대한 팀 컨텍스트

반환

Promise<DashboardGroup>

replaceWidget(Widget, TeamContext, string, string)

지정된 위젯의 상태를 재정의합니다.

function replaceWidget(widget: Widget, teamContext: TeamContext, dashboardId: string, widgetId: string): Promise<Widget>

매개 변수

widget
Widget

위젯에 대해 작성할 상태입니다.

teamContext
TeamContext

작업에 대한 팀 컨텍스트

dashboardId

string

위젯이 포함된 대시보드의 ID입니다.

widgetId

string

업데이트할 위젯의 ID입니다.

반환

Promise<Widget>

updateWidget(Widget, TeamContext, string, string)

지정된 위젯의 부분 업데이트를 수행합니다.

function updateWidget(widget: Widget, teamContext: TeamContext, dashboardId: string, widgetId: string): Promise<Widget>

매개 변수

widget
Widget

위젯에 대한 설명이 적용되도록 변경됩니다. null이 아닌 모든 필드가 대체됩니다.

teamContext
TeamContext

작업에 대한 팀 컨텍스트

dashboardId

string

위젯이 포함된 대시보드의 ID입니다.

widgetId

string

업데이트할 위젯의 ID입니다.

반환

Promise<Widget>