mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 10:58:30 -05:00
Adding OE filtering interfaces. (#22738)
* Adding interfaces for tree filtering * fixing type * Adding enums in sqlhost * Fixing comment * Fixed filters lol * Fixing some contract definitions * Removing flag * Update src/sql/azdata.proposed.d.ts Co-authored-by: Charles Gagnon <chgagnon@microsoft.com> * Removing filters * Removing filters2 * Fixing enum * Fixing interface and enum names * Fixing interface name * Update src/sql/azdata.proposed.d.ts Co-authored-by: Charles Gagnon <chgagnon@microsoft.com> * Removing type from filter * Adding is null and is not null operators * Fixing enums * Update src/sql/azdata.proposed.d.ts Co-authored-by: Charles Gagnon <chgagnon@microsoft.com> * Update src/sql/azdata.proposed.d.ts Co-authored-by: Charles Gagnon <chgagnon@microsoft.com> * Update src/sql/azdata.proposed.d.ts Co-authored-by: Charles Gagnon <chgagnon@microsoft.com> --------- Co-authored-by: Charles Gagnon <chgagnon@microsoft.com>
This commit is contained in:
72
src/sql/azdata.proposed.d.ts
vendored
72
src/sql/azdata.proposed.d.ts
vendored
@@ -605,6 +605,11 @@ declare module 'azdata' {
|
|||||||
* Authentication token for the current session.
|
* Authentication token for the current session.
|
||||||
*/
|
*/
|
||||||
securityToken?: accounts.AccountSecurityToken | undefined;
|
securityToken?: accounts.AccountSecurityToken | undefined;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Filters to apply to the child nodes being returned
|
||||||
|
*/
|
||||||
|
filters?: NodeFilter[];
|
||||||
}
|
}
|
||||||
// End Object Explorer interfaces ----------------------------
|
// End Object Explorer interfaces ----------------------------
|
||||||
|
|
||||||
@@ -1793,6 +1798,73 @@ declare module 'azdata' {
|
|||||||
* The path of the parent node.
|
* The path of the parent node.
|
||||||
*/
|
*/
|
||||||
parentNodePath: string;
|
parentNodePath: string;
|
||||||
|
/**
|
||||||
|
* Filterable properties that this node supports
|
||||||
|
*/
|
||||||
|
filterableProperties?: NodeFilterProperty[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface NodeFilterProperty {
|
||||||
|
/**
|
||||||
|
* The name of the filter property displayed to the user
|
||||||
|
*/
|
||||||
|
displayName: string;
|
||||||
|
/**
|
||||||
|
* The type of the filter property
|
||||||
|
*/
|
||||||
|
type: NodeFilterPropertyDataType;
|
||||||
|
/**
|
||||||
|
* The description of the filter property
|
||||||
|
*/
|
||||||
|
description: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* NodeFilterChoiceProperty is used to define the choices for the filter property if the type is choice
|
||||||
|
*/
|
||||||
|
export interface NodeFilterChoiceProperty extends NodeFilterProperty {
|
||||||
|
/**
|
||||||
|
* The list of choices for the filter property if the type is choice
|
||||||
|
*/
|
||||||
|
choices: string[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface NodeFilter {
|
||||||
|
/**
|
||||||
|
* The name of the filter property
|
||||||
|
*/
|
||||||
|
name: string;
|
||||||
|
/**
|
||||||
|
* The operator of the filter property
|
||||||
|
*/
|
||||||
|
operator: NodeFilterOperator;
|
||||||
|
/**
|
||||||
|
* The applied values of the filter property
|
||||||
|
*/
|
||||||
|
value: string | string[] | number | boolean | undefined;
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum NodeFilterPropertyDataType {
|
||||||
|
String = 0,
|
||||||
|
Number = 1,
|
||||||
|
Boolean = 2,
|
||||||
|
Date = 3,
|
||||||
|
Choice = 4
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum NodeFilterOperator {
|
||||||
|
Equals = 0,
|
||||||
|
NotEquals = 1,
|
||||||
|
LessThan = 2,
|
||||||
|
LessThanOrEquals = 3,
|
||||||
|
GreaterThan = 4,
|
||||||
|
GreaterThanOrEquals = 5,
|
||||||
|
Between = 6,
|
||||||
|
NotBetween = 7,
|
||||||
|
Contains = 8,
|
||||||
|
NotContains = 9,
|
||||||
|
IsNull = 10,
|
||||||
|
IsNotNull = 11
|
||||||
}
|
}
|
||||||
|
|
||||||
export namespace window {
|
export namespace window {
|
||||||
|
|||||||
@@ -657,6 +657,8 @@ export function createAdsApiFactory(accessor: ServicesAccessor): IAdsExtensionAp
|
|||||||
FrequencyTypes: sqlExtHostTypes.FrequencyTypes,
|
FrequencyTypes: sqlExtHostTypes.FrequencyTypes,
|
||||||
FrequencySubDayTypes: sqlExtHostTypes.FrequencySubDayTypes,
|
FrequencySubDayTypes: sqlExtHostTypes.FrequencySubDayTypes,
|
||||||
FrequencyRelativeIntervals: sqlExtHostTypes.FrequencyRelativeIntervals,
|
FrequencyRelativeIntervals: sqlExtHostTypes.FrequencyRelativeIntervals,
|
||||||
|
NodeFilterPropertyDataType: sqlExtHostTypes.NodeFilterPropertyDataType,
|
||||||
|
NodeFilterOperator: sqlExtHostTypes.NodeFilterOperator,
|
||||||
window,
|
window,
|
||||||
tasks,
|
tasks,
|
||||||
dashboard,
|
dashboard,
|
||||||
|
|||||||
@@ -478,6 +478,29 @@ export enum AzureResource {
|
|||||||
Custom = 12 // Handles custom resource URIs as received from server endpoint.
|
Custom = 12 // Handles custom resource URIs as received from server endpoint.
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum NodeFilterPropertyDataType {
|
||||||
|
String = 0,
|
||||||
|
Number = 1,
|
||||||
|
Boolean = 2,
|
||||||
|
Date = 3,
|
||||||
|
Choice = 4
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum NodeFilterOperator {
|
||||||
|
Equals = 0,
|
||||||
|
NotEquals = 1,
|
||||||
|
LessThan = 2,
|
||||||
|
LessThanOrEquals = 3,
|
||||||
|
GreaterThan = 4,
|
||||||
|
GreaterThanOrEquals = 5,
|
||||||
|
Between = 6,
|
||||||
|
NotBetween = 7,
|
||||||
|
Contains = 8,
|
||||||
|
NotContains = 9,
|
||||||
|
IsNull = 10,
|
||||||
|
IsNotNull = 11
|
||||||
|
}
|
||||||
|
|
||||||
export class TreeItem extends vsExtTypes.TreeItem {
|
export class TreeItem extends vsExtTypes.TreeItem {
|
||||||
payload?: azdata.IConnectionProfile;
|
payload?: azdata.IConnectionProfile;
|
||||||
providerHandle?: string;
|
providerHandle?: string;
|
||||||
|
|||||||
Reference in New Issue
Block a user