mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-27 17:23:21 -05:00
Edit Agent Alert updates (#1872)
* Set database name and severity when editing alert * Add Operator and Proxy edit * Add edit job hookup * Edit WIP * Additional edit alert updates * Remove unused method
This commit is contained in:
@@ -145,11 +145,17 @@ export class EditJobAction extends Action {
|
||||
public static ID = 'jobaction.editJob';
|
||||
public static LABEL = nls.localize('jobaction.editJob', "Edit Job");
|
||||
|
||||
constructor() {
|
||||
constructor(
|
||||
@ICommandService private _commandService: ICommandService
|
||||
) {
|
||||
super(EditJobAction.ID, EditJobAction.LABEL);
|
||||
}
|
||||
|
||||
public run(actionInfo: IJobActionInfo): TPromise<boolean> {
|
||||
this._commandService.executeCommand(
|
||||
'agent.openJobDialog',
|
||||
actionInfo.ownerUri,
|
||||
actionInfo.targetObject);
|
||||
return TPromise.as(true);
|
||||
}
|
||||
}
|
||||
@@ -324,11 +330,17 @@ export class EditOperatorAction extends Action {
|
||||
public static ID = 'jobaction.editAlert';
|
||||
public static LABEL = nls.localize('jobaction.editOperator', "Edit Operator");
|
||||
|
||||
constructor() {
|
||||
constructor(
|
||||
@ICommandService private _commandService: ICommandService
|
||||
) {
|
||||
super(EditOperatorAction.ID, EditOperatorAction.LABEL);
|
||||
}
|
||||
|
||||
public run(info: any): TPromise<boolean> {
|
||||
public run(actionInfo: IJobActionInfo): TPromise<boolean> {
|
||||
this._commandService.executeCommand(
|
||||
'agent.openOperatorDialog',
|
||||
actionInfo.ownerUri,
|
||||
actionInfo.targetObject);
|
||||
return TPromise.as(true);
|
||||
}
|
||||
}
|
||||
@@ -398,11 +410,17 @@ export class EditProxyAction extends Action {
|
||||
public static ID = 'jobaction.editProxy';
|
||||
public static LABEL = nls.localize('jobaction.editProxy', "Edit Proxy");
|
||||
|
||||
constructor() {
|
||||
constructor(
|
||||
@ICommandService private _commandService: ICommandService
|
||||
) {
|
||||
super(EditProxyAction.ID, EditProxyAction.LABEL);
|
||||
}
|
||||
|
||||
public run(info: any): TPromise<boolean> {
|
||||
public run(actionInfo: IJobActionInfo): TPromise<boolean> {
|
||||
this._commandService.executeCommand(
|
||||
'agent.openProxyDialog',
|
||||
actionInfo.ownerUri,
|
||||
actionInfo.targetObject);
|
||||
return TPromise.as(true);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -844,7 +844,7 @@ export class JobsViewComponent extends JobManagementView implements OnInit {
|
||||
|
||||
public openCreateJobDialog() {
|
||||
let ownerUri: string = this._commonService.connectionManagementService.connectionInfo.ownerUri;
|
||||
this._commandService.executeCommand('agent.openCreateJobDialog', ownerUri);
|
||||
this._commandService.executeCommand('agent.openJobDialog', ownerUri);
|
||||
}
|
||||
|
||||
public refreshJobs() {
|
||||
|
||||
@@ -163,7 +163,7 @@ export class OperatorsViewComponent extends JobManagementView implements OnInit
|
||||
|
||||
public openCreateOperatorDialog() {
|
||||
let ownerUri: string = this._commonService.connectionManagementService.connectionInfo.ownerUri;
|
||||
this._commandService.executeCommand('agent.openCreateOperatorDialog', ownerUri);
|
||||
this._commandService.executeCommand('agent.openOperatorDialog', ownerUri);
|
||||
}
|
||||
|
||||
private refreshJobs() {
|
||||
|
||||
@@ -164,7 +164,7 @@ export class ProxiesViewComponent extends JobManagementView implements OnInit {
|
||||
|
||||
public openCreateProxyDialog() {
|
||||
let ownerUri: string = this._commonService.connectionManagementService.connectionInfo.ownerUri;
|
||||
this._commandService.executeCommand('agent.openCreateProxyDialog', ownerUri);
|
||||
this._commandService.executeCommand('agent.openProxyDialog', ownerUri);
|
||||
}
|
||||
|
||||
private refreshJobs() {
|
||||
|
||||
Reference in New Issue
Block a user