mirror of
https://github.com/n8n-io/n8n.git
synced 2025-03-05 20:50:17 -08:00
👕 Fix some lint issues
This commit is contained in:
parent
b1035d539d
commit
b598036b3d
|
@ -1,8 +1,8 @@
|
||||||
import { ICredentialType, NodePropertyTypes } from 'n8n-workflow';
|
import { ICredentialType, NodePropertyTypes } from 'n8n-workflow';
|
||||||
|
|
||||||
export class MicrosoftSqlServer implements ICredentialType {
|
export class MicrosoftSql implements ICredentialType {
|
||||||
name = 'microsoftSqlServer';
|
name = 'microsoftSql';
|
||||||
displayName = 'Microsoft SQL Server';
|
displayName = 'Microsoft SQL';
|
||||||
properties = [
|
properties = [
|
||||||
{
|
{
|
||||||
displayName: 'Server',
|
displayName: 'Server',
|
|
@ -22,23 +22,23 @@ import {
|
||||||
extractValues,
|
extractValues,
|
||||||
} from './GenericFunctions';
|
} from './GenericFunctions';
|
||||||
|
|
||||||
export class MicrosoftSqlServer implements INodeType {
|
export class MicrosoftSql implements INodeType {
|
||||||
description: INodeTypeDescription = {
|
description: INodeTypeDescription = {
|
||||||
displayName: 'Microsoft SQL Server',
|
displayName: 'Microsoft SQL',
|
||||||
name: 'microsoftSqlServer',
|
name: 'microsoftSql',
|
||||||
icon: 'file:mssql.png',
|
icon: 'file:mssql.png',
|
||||||
group: ['input'],
|
group: ['input'],
|
||||||
version: 1,
|
version: 1,
|
||||||
description: 'Gets, add and update data in Microsoft SQL Server.',
|
description: 'Gets, add and update data in Microsoft SQL.',
|
||||||
defaults: {
|
defaults: {
|
||||||
name: 'Microsoft SQL Server',
|
name: 'Microsoft SQL',
|
||||||
color: '#1d4bab',
|
color: '#1d4bab',
|
||||||
},
|
},
|
||||||
inputs: ['main'],
|
inputs: ['main'],
|
||||||
outputs: ['main'],
|
outputs: ['main'],
|
||||||
credentials: [
|
credentials: [
|
||||||
{
|
{
|
||||||
name: 'microsoftSqlServer',
|
name: 'microsoftSql',
|
||||||
required: true,
|
required: true,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
@ -204,7 +204,7 @@ export class MicrosoftSqlServer implements INodeType {
|
||||||
};
|
};
|
||||||
|
|
||||||
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
|
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
|
||||||
const credentials = this.getCredentials('microsoftSqlServer');
|
const credentials = this.getCredentials('microsoftSql');
|
||||||
|
|
||||||
if (credentials === undefined) {
|
if (credentials === undefined) {
|
||||||
throw new Error('No credentials got returned!');
|
throw new Error('No credentials got returned!');
|
||||||
|
@ -222,7 +222,7 @@ export class MicrosoftSqlServer implements INodeType {
|
||||||
const pool = new mssql.ConnectionPool(config);
|
const pool = new mssql.ConnectionPool(config);
|
||||||
await pool.connect();
|
await pool.connect();
|
||||||
|
|
||||||
let returnItems: any = [];
|
let returnItems: INodeExecutionData[] = [];
|
||||||
|
|
||||||
const items = this.getInputData();
|
const items = this.getInputData();
|
||||||
const operation = this.getNodeParameter('operation', 0) as string;
|
const operation = this.getNodeParameter('operation', 0) as string;
|
||||||
|
@ -259,7 +259,7 @@ export class MicrosoftSqlServer implements INodeType {
|
||||||
table: string;
|
table: string;
|
||||||
columnString: string;
|
columnString: string;
|
||||||
items: IDataObject[];
|
items: IDataObject[];
|
||||||
}): Promise<any>[] => {
|
}): Array<Promise<object>> => {
|
||||||
return chunk(items, 1000).map(insertValues => {
|
return chunk(items, 1000).map(insertValues => {
|
||||||
const values = insertValues
|
const values = insertValues
|
||||||
.map((item: IDataObject) => extractValues(item))
|
.map((item: IDataObject) => extractValues(item))
|
||||||
|
@ -307,7 +307,7 @@ export class MicrosoftSqlServer implements INodeType {
|
||||||
table: string;
|
table: string;
|
||||||
columnString: string;
|
columnString: string;
|
||||||
items: IDataObject[];
|
items: IDataObject[];
|
||||||
}): Promise<any>[] => {
|
}): Array<Promise<object>> => {
|
||||||
return items.map(item => {
|
return items.map(item => {
|
||||||
const columns = columnString
|
const columns = columnString
|
||||||
.split(',')
|
.split(',')
|
Before Width: | Height: | Size: 3.4 KiB After Width: | Height: | Size: 3.4 KiB |
|
@ -96,7 +96,7 @@
|
||||||
"dist/credentials/MicrosoftExcelOAuth2Api.credentials.js",
|
"dist/credentials/MicrosoftExcelOAuth2Api.credentials.js",
|
||||||
"dist/credentials/MicrosoftOAuth2Api.credentials.js",
|
"dist/credentials/MicrosoftOAuth2Api.credentials.js",
|
||||||
"dist/credentials/MicrosoftOneDriveOAuth2Api.credentials.js",
|
"dist/credentials/MicrosoftOneDriveOAuth2Api.credentials.js",
|
||||||
"dist/credentials/MicrosoftSqlServer.credentials.js",
|
"dist/credentials/MicrosoftSql.credentials.js",
|
||||||
"dist/credentials/MoceanApi.credentials.js",
|
"dist/credentials/MoceanApi.credentials.js",
|
||||||
"dist/credentials/MondayComApi.credentials.js",
|
"dist/credentials/MondayComApi.credentials.js",
|
||||||
"dist/credentials/MongoDb.credentials.js",
|
"dist/credentials/MongoDb.credentials.js",
|
||||||
|
@ -242,7 +242,7 @@
|
||||||
"dist/nodes/MessageBird/MessageBird.node.js",
|
"dist/nodes/MessageBird/MessageBird.node.js",
|
||||||
"dist/nodes/Microsoft/Excel/MicrosoftExcel.node.js",
|
"dist/nodes/Microsoft/Excel/MicrosoftExcel.node.js",
|
||||||
"dist/nodes/Microsoft/OneDrive/MicrosoftOneDrive.node.js",
|
"dist/nodes/Microsoft/OneDrive/MicrosoftOneDrive.node.js",
|
||||||
"dist/nodes/Microsoft/SqlServer/MicrosoftSqlServer.node.js",
|
"dist/nodes/Microsoft/Sql/MicrosoftSql.node.js",
|
||||||
"dist/nodes/MoveBinaryData.node.js",
|
"dist/nodes/MoveBinaryData.node.js",
|
||||||
"dist/nodes/Mocean/Mocean.node.js",
|
"dist/nodes/Mocean/Mocean.node.js",
|
||||||
"dist/nodes/MondayCom/MondayCom.node.js",
|
"dist/nodes/MondayCom/MondayCom.node.js",
|
||||||
|
|
Loading…
Reference in a new issue