Skip to content

Commit

Permalink
feat: add context menu in editor and explorer for executing API requests
Browse files Browse the repository at this point in the history
  • Loading branch information
Codeneos committed Dec 18, 2023
1 parent e24bdf5 commit 4edace6
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/vscode-extension/commands.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,12 @@ vlocode.execRestApi:
when: config.vlocity.salesforce.enabled
menus:
- menu: commandPalette
- menu: explorer/context
when:
- resourceExtname == .sfhttp || resourceExtname == .http || editorLangId == sfhttp
- menu: explorer/context
when:
- resourceExtname == .sfhttp || resourceExtname == .http || editorLangId == sfhttp
vlocode.retrieveMetadata:
title: 'Salesforce: Export/Retrieve metadata from Org'
group: v_salesforce
Expand Down
10 changes: 10 additions & 0 deletions packages/vscode-extension/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -775,6 +775,11 @@
"group": "v_salesforce",
"when": "config.vlocity.salesforce.enabled && resourceScheme == file && resourceExtname == .apex"
},
{
"command": "vlocode.execRestApi",
"group": "v_salesforce",
"when": "config.vlocity.salesforce.enabled && (resourceExtname == .sfhttp || resourceExtname == .http)"
},
{
"command": "vlocode.addToProfile",
"group": "v_salesforce_profile",
Expand Down Expand Up @@ -902,6 +907,11 @@
"group": "v_salesforce",
"when": "vlocode.conditionalContextMenus == false || resourcePath in vlocode.metadata"
},
{
"command": "vlocode.execRestApi",
"group": "v_salesforce",
"when": "config.vlocity.salesforce.enabled && (resourceExtname == .sfhttp || resourceExtname == .http)"
},
{
"command": "vlocode.addToProfile",
"group": "v_salesforce_profile",
Expand Down

0 comments on commit 4edace6

Please sign in to comment.