baja-lite 1.5.28 → 1.5.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/convert-xml.js CHANGED
@@ -1,4 +1,4 @@
1
- import LGet from 'lodash.get';
1
+ import { LGet } from 'baja-lite-field';
2
2
  export const convert = function (childrens, param, parentIds, myBatisMapper) {
3
3
  let statement = '';
4
4
  for (let i = 0, children; children = childrens[i]; i++) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "baja-lite",
3
- "version": "1.5.28",
3
+ "version": "1.5.30",
4
4
  "description": "some util for self",
5
5
  "homepage": "https://github.com/void-soul/baja-lite",
6
6
  "repository": {
@@ -38,14 +38,13 @@
38
38
  "@msgpack/msgpack": "3.1.2",
39
39
  "@types/request-promise": "4.1.51",
40
40
  "axios": "1.11.0",
41
- "baja-lite-field": "1.4.13",
41
+ "baja-lite-field": "1.4.15",
42
42
  "decimal.js": "10.6.0",
43
43
  "html-parse-stringify": "3.0.1",
44
44
  "iterare": "1.2.1",
45
- "lodash.get": "4.4.2",
46
45
  "mustache": "4.2.0",
47
46
  "pino": "9.7.0",
48
- "pino-pretty": "13.0.0",
47
+ "pino-pretty": "13.1.1",
49
48
  "reflect-metadata": "0.2.2",
50
49
  "request": "2.88.2",
51
50
  "request-promise": "4.2.6",
@@ -55,22 +54,21 @@
55
54
  },
56
55
  "devDependencies": {
57
56
  "@types/better-sqlite3": "7.6.13",
58
- "@types/lodash.get": "4.4.9",
59
57
  "@types/mustache": "4.2.6",
60
- "@types/node": "24.0.12",
58
+ "@types/node": "24.2.0",
61
59
  "@types/shelljs": "0.8.17",
62
60
  "@types/sqlstring": "2.3.2",
63
- "@typescript-eslint/eslint-plugin": "8.36.0",
64
- "@typescript-eslint/parser": "8.36.0",
61
+ "@typescript-eslint/eslint-plugin": "8.39.0",
62
+ "@typescript-eslint/parser": "8.39.0",
65
63
  "better-sqlite3": "12.2.0",
66
- "ioredis": "5.6.1",
64
+ "ioredis": "5.7.0",
67
65
  "mongodb": "6.18.0",
68
- "mysql2": "3.14.2",
66
+ "mysql2": "3.14.3",
69
67
  "pg": "8.16.3",
70
68
  "pg-pool": "3.10.1",
71
69
  "redlock": "5.0.0-beta.2",
72
70
  "shelljs": "0.10.0",
73
- "typescript": "5.8.3"
71
+ "typescript": "5.9.2"
74
72
  },
75
73
  "engines": {
76
74
  "node": ">=20"
package/sql.js CHANGED
@@ -10,10 +10,9 @@ var __metadata = (this && this.__metadata) || function (k, v) {
10
10
  var _b, _c, _d, _e;
11
11
  var _f, _g, _h, _j;
12
12
  import { decode, DecodeError, encode, ExtensionCodec } from "@msgpack/msgpack";
13
- import { _columns, _columnsNoId, _def, _deleteState, _fields, _Hump, _ids, _index, _logicIds, _stateFileName, DBType, Field } from 'baja-lite-field';
13
+ import { _columns, _columnsNoId, _def, _deleteState, _fields, _Hump, _ids, _index, _logicIds, _stateFileName, DBType, Field, LGet } from 'baja-lite-field';
14
14
  import HTML from 'html-parse-stringify';
15
15
  import * as ite from 'iterare';
16
- import LGet from 'lodash.get';
17
16
  import mustache from 'mustache';
18
17
  import pino from 'pino';
19
18
  import { formatDialect, mysql, postgresql, sqlite } from 'sql-formatter';
@@ -951,7 +950,7 @@ export class Sqlite {
951
950
  `);
952
951
  this[_daoDB].function('UUID_SHORT', { deterministic: false }, () => snowflake.generate());
953
952
  this[_daoDB].function('UUID', { deterministic: false }, () => snowflake.generate());
954
- this[_daoDB].function('TIME_TO_SEC', { deterministic: true }, (time) => time.split(':').map((v, i) => parseInt(v) * (i > 0 ? 1 : 60)).reduce((a, b) => a + b, 0));
953
+ this[_daoDB].function('TIME_TO_SEC', { deterministic: true }, (time) => time.split(':').map((v, i) => parseInt(v) * (i === 0 ? 360 : i === 1 ? 60 : 0)).reduce((a, b) => a + b, 0));
955
954
  this[_daoDB].function('IF', { deterministic: true }, (condition, v1, v2) => condition ? v1 : v2);
956
955
  this[_daoDB].function('RIGHT', { deterministic: true }, (src, p) => src.slice(p * -1));
957
956
  this[_daoDB].function('LEFT', { deterministic: true }, (str, len) => str?.substring(0, len) || null);
package/sqlite.js CHANGED
@@ -134,7 +134,7 @@ export class SqliteRemoteClass {
134
134
  `);
135
135
  this.dbList[dbName].function('UUID_SHORT', { deterministic: false }, () => snowflake.generate());
136
136
  this.dbList[dbName].function('UUID', { deterministic: false }, () => snowflake.generate());
137
- this.dbList[dbName].function('TIME_TO_SEC', { deterministic: true }, (time) => time.split(':').map((v, i) => parseInt(v) * (i > 0 ? 1 : 60)).reduce((a, b) => a + b, 0));
137
+ this.dbList[dbName].function('TIME_TO_SEC', { deterministic: true }, (time) => time.split(':').map((v, i) => parseInt(v) * (i === 0 ? 360 : i === 1 ? 60 : 0)).reduce((a, b) => a + b, 0));
138
138
  this.dbList[dbName].function('IF', { deterministic: true }, (condition, v1, v2) => condition ? v1 : v2);
139
139
  this.dbList[dbName].function('RIGHT', { deterministic: true }, (src, p) => src.slice(p * -1));
140
140
  this.dbList[dbName].function('LEFT', { deterministic: true }, (str, len) => str?.substring(0, len) || null);