@spinajs/orm-sqlite 1.0.22 → 1.2.31
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/README.md +11 -0
- package/lib/compilers.d.ts +1 -0
- package/lib/compilers.js +32 -14
- package/lib/compilers.js.map +1 -1
- package/lib/converters.d.ts +4 -7
- package/lib/converters.js +13 -17
- package/lib/converters.js.map +1 -1
- package/lib/index.js +23 -15
- package/lib/index.js.map +1 -1
- package/lib/log-common/src/index.d.ts +180 -0
- package/lib/log-common/src/index.js +49 -0
- package/lib/log-common/src/index.js.map +1 -0
- package/lib/orm-sqlite/src/compilers.d.ts +32 -0
- package/lib/orm-sqlite/src/compilers.js +215 -0
- package/lib/orm-sqlite/src/compilers.js.map +1 -0
- package/lib/orm-sqlite/src/converters.d.ts +6 -0
- package/lib/orm-sqlite/src/converters.js +25 -0
- package/lib/orm-sqlite/src/converters.js.map +1 -0
- package/lib/orm-sqlite/src/index.d.ts +22 -0
- package/lib/orm-sqlite/src/index.js +221 -0
- package/lib/orm-sqlite/src/index.js.map +1 -0
- package/lib/orm-sqlite/src/statements.d.ts +6 -0
- package/lib/orm-sqlite/src/statements.js +31 -0
- package/lib/orm-sqlite/src/statements.js.map +1 -0
- package/lib/orm-sqlite/src/types.d.ts +13 -0
- package/lib/orm-sqlite/src/types.js +3 -0
- package/lib/orm-sqlite/src/types.js.map +1 -0
- package/lib/orm-sqlite.js +7 -0
- package/lib/statements.js +3 -6
- package/lib/statements.js.map +1 -1
- package/package.json +23 -37
- package/lib/decorators.d.ts +0 -1
- package/lib/decorators.js +0 -32
- package/lib/decorators.js.map +0 -1
package/lib/statements.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"statements.js","sourceRoot":"","sources":["../src/statements.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oCAA0C;AAE1C,8CAAoD;AACpD,kDAAoD;AACpD,oDAAmD;
|
|
1
|
+
{"version":3,"file":"statements.js","sourceRoot":"","sources":["../src/statements.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,sCAAsC;AACtC,oCAA0C;AAE1C,8CAAoD;AACpD,kDAAoD;AACpD,oDAAmD;AAGnD,IAAa,oBAAoB,GAAjC,MAAa,oBAAqB,SAAQ,0BAAgB;IACxD,YAAY,KAAwB,EAAE,MAAkB,EAAE,UAAkB,EAAE,UAAkB,EAAE,KAAa,EAAE,UAAkB;QACjI,KAAK,CAAC,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,UAAU,EAAE,KAAK,EAAE,UAAU,CAAC,CAAC;QAEhE,IAAI,MAAM,KAAK,kBAAU,CAAC,KAAK,IAAI,MAAM,KAAK,kBAAU,CAAC,WAAW,EAAE;YACpE,MAAM,IAAI,yBAAY,CAAC,eAAe,MAAM,oCAAoC,CAAC,CAAC;SACnF;IACH,CAAC;CACF,CAAA;AARY,oBAAoB;IADhC,IAAA,gBAAW,GAAE;;GACD,oBAAoB,CAQhC;AARY,oDAAoB"}
|
package/package.json
CHANGED
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spinajs/orm-sqlite",
|
|
3
|
-
"version": "1.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "1.2.31",
|
|
4
|
+
"description": "framework orm sql-lite language module",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"private": false,
|
|
7
7
|
"scripts": {
|
|
8
|
+
"build": "npm run clean && npm run compile",
|
|
9
|
+
"compile": "tsc -p tsconfig.build.json",
|
|
10
|
+
"clean": "",
|
|
8
11
|
"test": "ts-mocha -p tsconfig.json test/**/*.test.ts",
|
|
9
12
|
"coverage": "nyc npm run test",
|
|
10
13
|
"build-docs": "rimraf docs && typedoc --options typedoc.json src/",
|
|
11
|
-
"build": "tsc",
|
|
12
14
|
"prepare": "npm run build",
|
|
13
|
-
"format": "prettier --write \"src/**/*.ts\"
|
|
14
|
-
"lint": "
|
|
15
|
+
"format": "prettier --write \"src/**/*.ts\"",
|
|
16
|
+
"lint": "eslint -c .eslintrc.js --ext .ts src --fix",
|
|
15
17
|
"prepublishOnly": "npm test && npm run lint",
|
|
16
18
|
"preversion": "npm run lint",
|
|
17
19
|
"version": "npm run format && git add -A src",
|
|
@@ -20,9 +22,10 @@
|
|
|
20
22
|
"files": [
|
|
21
23
|
"lib/**/*"
|
|
22
24
|
],
|
|
25
|
+
"types": "lib",
|
|
23
26
|
"repository": {
|
|
24
27
|
"type": "git",
|
|
25
|
-
"url": "git+https://github.com/spinajs/
|
|
28
|
+
"url": "git+https://github.com/spinajs/main.git"
|
|
26
29
|
},
|
|
27
30
|
"keywords": [
|
|
28
31
|
"di",
|
|
@@ -30,43 +33,26 @@
|
|
|
30
33
|
"spinajs",
|
|
31
34
|
"di"
|
|
32
35
|
],
|
|
33
|
-
"author": "SpinaJS <spinajs@coderush.pl> (https://github.com/spinajs/
|
|
36
|
+
"author": "SpinaJS <spinajs@coderush.pl> (https://github.com/spinajs/main)",
|
|
34
37
|
"license": "MIT",
|
|
35
38
|
"bugs": {
|
|
36
|
-
"url": "https://github.com/spinajs/
|
|
39
|
+
"url": "https://github.com/spinajs/main/issues"
|
|
37
40
|
},
|
|
38
|
-
"homepage": "https://github.com/spinajs/
|
|
41
|
+
"homepage": "https://github.com/spinajs/main#readme",
|
|
39
42
|
"dependencies": {
|
|
40
|
-
"@spinajs/configuration": "^1.
|
|
41
|
-
"@spinajs/di": "^1.
|
|
43
|
+
"@spinajs/configuration": "^1.2.31",
|
|
44
|
+
"@spinajs/di": "^1.2.30",
|
|
42
45
|
"@spinajs/exceptions": "^1.0.3",
|
|
43
|
-
"@spinajs/log": "^1.
|
|
44
|
-
"@spinajs/orm": "^1.
|
|
45
|
-
"@spinajs/orm-sql": "^1.
|
|
46
|
+
"@spinajs/log": "^1.2.31",
|
|
47
|
+
"@spinajs/orm": "^1.2.31",
|
|
48
|
+
"@spinajs/orm-sql": "^1.2.31",
|
|
46
49
|
"lodash": "^4.17.15",
|
|
47
|
-
"
|
|
50
|
+
"luxon": "^2.3.0",
|
|
51
|
+
"sqlite3": "^4.2.0",
|
|
52
|
+
"typescript-mix": "^3.1.3"
|
|
48
53
|
},
|
|
49
54
|
"devDependencies": {
|
|
50
|
-
"@types/
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
"@types/lodash": "^4.14.136",
|
|
54
|
-
"@types/sinon": "^7.5.1",
|
|
55
|
-
"@types/sqlite3": "^3.1.5",
|
|
56
|
-
"chai": "^4.2.0",
|
|
57
|
-
"chai-as-promised": "^7.1.1",
|
|
58
|
-
"mocha": "^6.1.4",
|
|
59
|
-
"nyc": "^14.1.1",
|
|
60
|
-
"prettier": "^1.18.2",
|
|
61
|
-
"sinon": "^8.1.1",
|
|
62
|
-
"ts-mocha": "^6.0.0",
|
|
63
|
-
"ts-node": "^8.3.0",
|
|
64
|
-
"tslint": "^5.20.1",
|
|
65
|
-
"tslint-circular-dependencies": "^0.1.0",
|
|
66
|
-
"tslint-config-prettier": "^1.18.0",
|
|
67
|
-
"tslint-config-standard": "^8.0.1",
|
|
68
|
-
"tslint-no-unused-expression-chai": "^0.1.4",
|
|
69
|
-
"typedoc": "^0.14.2",
|
|
70
|
-
"typescript": "^3.7.3"
|
|
71
|
-
}
|
|
55
|
+
"@types/sqlite3": "^3.1.5"
|
|
56
|
+
},
|
|
57
|
+
"gitHead": "dc63606c6ce0ec96d14086a1eaa3ce677151a085"
|
|
72
58
|
}
|
package/lib/decorators.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function Datetime(): any;
|
package/lib/decorators.js
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const orm_1 = require("@spinajs/orm");
|
|
4
|
-
const converters_1 = require("./converters");
|
|
5
|
-
function Datetime() {
|
|
6
|
-
return orm_1.extractDecoratorDescriptor((model, target, propertyKey) => {
|
|
7
|
-
const type = Reflect.getMetadata('design:type', target, propertyKey);
|
|
8
|
-
if (type.name !== 'Date') {
|
|
9
|
-
throw Error(`Proprety ${propertyKey} must be Date type`);
|
|
10
|
-
}
|
|
11
|
-
if (!model.Columns) {
|
|
12
|
-
model.Columns = [];
|
|
13
|
-
}
|
|
14
|
-
model.Columns.push({
|
|
15
|
-
Type: 'TEXT',
|
|
16
|
-
MaxLength: 0,
|
|
17
|
-
Comment: '',
|
|
18
|
-
DefaultValue: null,
|
|
19
|
-
NativeType: 'TEXT',
|
|
20
|
-
Unsigned: false,
|
|
21
|
-
Nullable: true,
|
|
22
|
-
PrimaryKey: false,
|
|
23
|
-
AutoIncrement: false,
|
|
24
|
-
Name: 'CreatedAt',
|
|
25
|
-
Converter: new converters_1.DateTimeConverter(),
|
|
26
|
-
Schema: 'test',
|
|
27
|
-
Unique: false,
|
|
28
|
-
});
|
|
29
|
-
}, true);
|
|
30
|
-
}
|
|
31
|
-
exports.Datetime = Datetime;
|
|
32
|
-
//# sourceMappingURL=decorators.js.map
|
package/lib/decorators.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"decorators.js","sourceRoot":"","sources":["../src/decorators.ts"],"names":[],"mappings":";;AAAA,sCAA6E;AAC7E,6CAAiD;AAEjD,SAAgB,QAAQ;IACtB,OAAO,gCAA0B,CAAC,CAAC,KAAwB,EAAE,MAAW,EAAE,WAAmB,EAAE,EAAE;QAC/F,MAAM,IAAI,GAAG,OAAO,CAAC,WAAW,CAAC,aAAa,EAAE,MAAM,EAAE,WAAW,CAAC,CAAC;QACrE,IAAI,IAAI,CAAC,IAAI,KAAK,MAAM,EAAE;YACxB,MAAM,KAAK,CAAC,aAAa,WAAW,oBAAoB,CAAC,CAAC;SAC3D;QAED,IAAI,CAAC,KAAK,CAAC,OAAO,EAAE;YAClB,KAAK,CAAC,OAAO,GAAG,EAAE,CAAC;SACpB;QAED,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC;YACjB,IAAI,EAAE,MAAM;YACZ,SAAS,EAAE,CAAC;YACZ,OAAO,EAAE,EAAE;YACX,YAAY,EAAE,IAAI;YAClB,UAAU,EAAE,MAAM;YAClB,QAAQ,EAAE,KAAK;YACf,QAAQ,EAAE,IAAI;YACd,UAAU,EAAE,KAAK;YACjB,aAAa,EAAE,KAAK;YACpB,IAAI,EAAE,WAAW;YACjB,SAAS,EAAE,IAAI,8BAAiB,EAAE;YAClC,MAAM,EAAE,MAAM;YACd,MAAM,EAAE,KAAK;SACd,CAAC,CAAC;IACL,CAAC,EAAE,IAAI,CAAC,CAAC;AACX,CAAC;AA3BD,4BA2BC"}
|