mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-23 11:36:01 +00:00
renamed dbgate packages, because of npmjs policy
This commit is contained in:
@@ -4,7 +4,7 @@ const sql = require('./sql');
|
||||
|
||||
const DatabaseAnalyser = require('../default/DatabaseAnalyser');
|
||||
const { filter } = require('lodash');
|
||||
const { isTypeString, isTypeNumeric } = require('@dbgate/tools');
|
||||
const { isTypeString, isTypeNumeric } = require('dbgate-tools');
|
||||
|
||||
function objectTypeToField(type) {
|
||||
switch (type.trim()) {
|
||||
@@ -187,7 +187,7 @@ class MsSqlAnalyser extends DatabaseAnalyser {
|
||||
// object not modified
|
||||
if (obj && Math.abs(new Date(modifyDate).getTime() - new Date(obj.modifyDate).getTime()) < 1000) return null;
|
||||
|
||||
/** @type {import('@dbgate/types').DatabaseModification} */
|
||||
/** @type {import('dbgate-types').DatabaseModification} */
|
||||
const action = obj
|
||||
? {
|
||||
newName: { schemaName, pureName },
|
||||
|
||||
@@ -16,7 +16,7 @@ class MsSqlDumper extends SqlDumper {
|
||||
this.putCmd('^set ^identity_insert %f %k;&n', table, allow ? 'on' : 'off');
|
||||
}
|
||||
|
||||
/** @param type {import('@dbgate/types').TransformType} */
|
||||
/** @param type {import('dbgate-types').TransformType} */
|
||||
transform(type, dumpExpr) {
|
||||
switch (type) {
|
||||
case 'GROUP:YEAR':
|
||||
|
||||
@@ -2,7 +2,7 @@ const createBulkInsertStreamBase = require('../default/createBulkInsertStreamBas
|
||||
|
||||
/**
|
||||
*
|
||||
* @param {import('@dbgate/types').EngineDriver} driver
|
||||
* @param {import('dbgate-types').EngineDriver} driver
|
||||
*/
|
||||
function createBulkInsertStream(driver, mssql, stream, pool, name, options) {
|
||||
const writable = createBulkInsertStreamBase(driver, stream, pool, name, options);
|
||||
|
||||
@@ -4,7 +4,7 @@ const MsSqlDumper = require('./MsSqlDumper');
|
||||
const createBulkInsertStream = require('./createBulkInsertStream');
|
||||
const driverBase = require('../default/driverBase');
|
||||
|
||||
/** @type {import('@dbgate/types').SqlDialect} */
|
||||
/** @type {import('dbgate-types').SqlDialect} */
|
||||
const dialect = {
|
||||
limitSelect: true,
|
||||
rangeSelect: true,
|
||||
@@ -51,7 +51,7 @@ function extractColumns(columns) {
|
||||
return [res, mapper];
|
||||
}
|
||||
|
||||
/** @type {import('@dbgate/types').EngineDriver} */
|
||||
/** @type {import('dbgate-types').EngineDriver} */
|
||||
const driver = {
|
||||
...driverBase,
|
||||
analyserClass: MsSqlAnalyser,
|
||||
|
||||
Reference in New Issue
Block a user