Skip to content
This repository has been archived by the owner on Nov 16, 2023. It is now read-only.

Commit

Permalink
Update version to 0.2.19 (#122)
Browse files Browse the repository at this point in the history
  • Loading branch information
joechung-msft authored Oct 18, 2019
1 parent 847a7ea commit 359d186
Show file tree
Hide file tree
Showing 9 changed files with 73 additions and 30 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ All notable changes to the "vscode-logicapps" extension will be documented in th

## [Unreleased]

## [0.2.19] - 2019-10-17
### Changed
- Update designer version to 1.41014.1.3

## [0.2.18] - 2019-10-10
### Changed
- Update designer version to 1.41007.1.1
Expand Down
38 changes: 19 additions & 19 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "vscode-logicapps",
"displayName": "Azure Logic Apps",
"description": "%extension.description%",
"version": "0.2.18",
"version": "0.2.19",
"publisher": "ms-azuretools",
"icon": "resources/azLogicApps.png",
"aiKey": "b6385546-3be0-489c-a298-baccd6c152fb",
Expand Down Expand Up @@ -720,10 +720,10 @@
"eslint-utils": "^1.4.2",
"querystringify": ">=2.0.0",
"ts-loader": "^6.2.0",
"typescript": "^3.6.3",
"vsce": "^1.67.1",
"typescript": "^3.6.4",
"vsce": "^1.68.0",
"vscode": "^1.1.36",
"webpack": "^4.41.0",
"webpack": "^4.41.1",
"webpack-cli": "^3.3.9"
},
"dependencies": {
Expand Down
16 changes: 15 additions & 1 deletion src/commands/logic-app/openInDesigner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ export async function openInDesigner(tree: AzureTreeDataProvider, node?: IAzureN
const { subscriptionId, treeItem } = node as IAzureNode<LogicAppTreeItem>;
const callbacks = await treeItem.getCallbacks();
const definition = await treeItem.getData(/* refresh */ true);
const parameters = treeItem.getParameters();
const references = await treeItem.getReferences();
const { id: workflowId, integrationAccountId, label: workflowName, location, resourceGroupName, sku } = treeItem;
const title = `${workflowName} ${readOnlySuffix}`;
Expand All @@ -28,5 +29,18 @@ export async function openInDesigner(tree: AzureTreeDataProvider, node?: IAzureN
enableScripts: true
};
const panel = vscode.window.createWebviewPanel("readonlyDesigner", title, vscode.ViewColumn.Beside, options);
panel.webview.html = getWebviewContentForDesigner({ authorization, callbacks, definition, integrationAccountId, location, references, resourceGroupName, sku, subscriptionId, title, workflowId });
panel.webview.html = getWebviewContentForDesigner({
authorization,
callbacks,
definition,
integrationAccountId,
location,
parameters,
references,
resourceGroupName,
sku,
subscriptionId,
title,
workflowId
});
}
16 changes: 15 additions & 1 deletion src/commands/logic-app/openVersionInDesigner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export async function openVersionInDesigner(tree: AzureTreeDataProvider, node?:
const { subscriptionId, treeItem } = node as IAzureNode<LogicAppVersionTreeItem>;
const callbacks = {};
const definition = await treeItem.getData();
const parameters = treeItem.getParameters();
const references = await treeItem.getReferences();
const { id: workflowId, integrationAccountId, label: workflowVersionName, location, resourceGroupName, sku } = treeItem;
const title = `${workflowVersionName} ${readOnlySuffix}`;
Expand All @@ -29,5 +30,18 @@ export async function openVersionInDesigner(tree: AzureTreeDataProvider, node?:
enableScripts: true
};
const panel = vscode.window.createWebviewPanel("readonlyDesigner", title, vscode.ViewColumn.Beside, options);
panel.webview.html = getWebviewContentForDesigner({ authorization, callbacks, definition, integrationAccountId, location, references, resourceGroupName, sku, subscriptionId, title, workflowId });
panel.webview.html = getWebviewContentForDesigner({
authorization,
callbacks,
definition,
integrationAccountId,
location,
parameters,
references,
resourceGroupName,
sku,
subscriptionId,
title,
workflowId
});
}
2 changes: 1 addition & 1 deletion src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*--------------------------------------------------------------------------------------------*/

export class Constants {
public static DesignerVersion = "1.41007.1.1.191004-1614";
public static DesignerVersion = "1.41014.1.3.191014-2002";

public static SubscriptionContextValue = "azureextensionui.azureSubscription";

Expand Down
4 changes: 4 additions & 0 deletions src/tree/logic-app/LogicAppTreeItem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,10 @@ export class LogicAppTreeItem implements IAzureParentTreeItem {
return JSON.stringify(this.workflow.definition, null, 4);
}

public getParameters(): Record<string, any> | undefined {
return this.workflow.parameters;
}

public async getReferences(): Promise<ConnectionReferences> {
return getConnectionReferencesForLogicApp(this.client.credentials, this.client.subscriptionId, this.resourceGroupName, this.workflowName, this.client.apiVersion);
}
Expand Down
4 changes: 4 additions & 0 deletions src/tree/logic-app/LogicAppVersionTreeItem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,10 @@ export class LogicAppVersionTreeItem implements IAzureTreeItem {
return JSON.stringify(this.workflowVersion.definition, null, 4);
}

public getParameters(): Record<string, any> | undefined {
return this.workflow.parameters;
}

public async getReferences(): Promise<ConnectionReferences> {
return getConnectionReferencesForLogicAppVersion(this.client.credentials, this.client.subscriptionId, this.resourceGroupName, this.workflowName, this.workflowVersion.name!, this.client.apiVersion);
}
Expand Down
11 changes: 7 additions & 4 deletions src/utils/logic-app/designerUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ interface IGetWebviewContentOptions {
definition: string;
integrationAccountId?: string;
location: string;
parameters: Record<string, any> | undefined;
references: ConnectionReferences;
resourceGroupName: string;
sku?: Sku;
Expand All @@ -24,7 +25,7 @@ interface IGetWebviewContentOptions {

const version = Constants.DesignerVersion;

export function getWebviewContentForDesigner({ authorization, callbacks, definition, integrationAccountId, location, references, resourceGroupName, sku, subscriptionId, title, workflowId }: IGetWebviewContentOptions): string {
export function getWebviewContentForDesigner({ authorization, callbacks, definition, integrationAccountId, location, parameters, references, resourceGroupName, sku, subscriptionId, title, workflowId }: IGetWebviewContentOptions): string {
sku = sku || { name: "Consumption" };

return `<!DOCTYPE html>
Expand Down Expand Up @@ -554,11 +555,12 @@ export function getWebviewContentForDesigner({ authorization, callbacks, definit
}
function loadDefinition(logicApp, callbacks, options) {
const { definition, references, sku } = logicApp;
const { connectionReferences, definition, parameters, sku } = logicApp;
const loadOptions = { ...options };
const workflow = {
connectionReferences,
definition,
references,
parameters,
properties: {
callbacks,
sku
Expand Down Expand Up @@ -621,8 +623,9 @@ export function getWebviewContentForDesigner({ authorization, callbacks, definit
};
const logicApp = {
connectionReferences: ${JSON.stringify(references)},
definition: ${definition},
references: ${JSON.stringify(references)},
parameters: ${JSON.stringify(parameters)},
sku: ${JSON.stringify(sku)}
};
Expand Down

0 comments on commit 359d186

Please sign in to comment.