mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 18:46:40 -05:00
Add createAzureFunction to extension API (#19438)
This commit is contained in:
@@ -20,6 +20,9 @@ export async function activate(context: vscode.ExtensionContext): Promise<IExten
|
|||||||
addSqlBinding: async (bindingType: BindingType, filePath: string, functionName: string, objectName: string, connectionStringSetting: string): Promise<ResultStatus> => {
|
addSqlBinding: async (bindingType: BindingType, filePath: string, functionName: string, objectName: string, connectionStringSetting: string): Promise<ResultStatus> => {
|
||||||
return addSqlBinding(bindingType, filePath, functionName, objectName, connectionStringSetting);
|
return addSqlBinding(bindingType, filePath, functionName, objectName, connectionStringSetting);
|
||||||
},
|
},
|
||||||
|
createAzureFunction: async (): Promise<void> => {
|
||||||
|
return createAzureFunction();
|
||||||
|
},
|
||||||
promptForBindingType: async (funcName?: string): Promise<BindingType | undefined> => {
|
promptForBindingType: async (funcName?: string): Promise<BindingType | undefined> => {
|
||||||
return promptForBindingType(funcName);
|
return promptForBindingType(funcName);
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -28,6 +28,11 @@ declare module 'sql-bindings' {
|
|||||||
*/
|
*/
|
||||||
addSqlBinding(bindingType: BindingType, filePath: string, functionName: string, objectName: string, connectionStringSetting: string): Promise<ResultStatus>;
|
addSqlBinding(bindingType: BindingType, filePath: string, functionName: string, objectName: string, connectionStringSetting: string): Promise<ResultStatus>;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Prompts the user for information to create an Azure Function with SQL Binding
|
||||||
|
*/
|
||||||
|
createAzureFunction(): Promise<void>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Prompts the user to select type of binding and returns result or undefined if the user cancelled out of the prompt
|
* Prompts the user to select type of binding and returns result or undefined if the user cancelled out of the prompt
|
||||||
* @param funcName (Optional) Name of the function we are adding the SQL Binding to
|
* @param funcName (Optional) Name of the function we are adding the SQL Binding to
|
||||||
@@ -46,7 +51,7 @@ declare module 'sql-bindings' {
|
|||||||
/**
|
/**
|
||||||
* Prompts the user to enter connection setting and updates it from AF project
|
* Prompts the user to enter connection setting and updates it from AF project
|
||||||
* @param projectUri Azure Function project uri
|
* @param projectUri Azure Function project uri
|
||||||
* @param connectionInfo (optional) connection info from the user to update the connection string,
|
* @param connectionInfo (optional) connection info from the user to update the connection string,
|
||||||
* if left undefined we prompt the user for the connection info
|
* if left undefined we prompt the user for the connection info
|
||||||
* @returns connection string setting name to be used for the createFunction API
|
* @returns connection string setting name to be used for the createFunction API
|
||||||
*/
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user