dborm-mysql 2.1.4 → 2.2.1
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/.history/base/dbUtil_20221202115852.js +478 -0
- package/.history/base/dbUtil_20230807151512.js +478 -0
- package/.history/base/dbUtil_20230807151513.js +478 -0
- package/.history/base/dbUtil_20230807151624.js +478 -0
- package/.history/base/dbUtil_20230807151706.js +478 -0
- package/.history/base/dbUtil_20230807152233.js +478 -0
- package/.history/base/dbUtil_20230807152346.js +478 -0
- package/.history/base/dbUtil_20230807152500.js +478 -0
- package/.history/base/dbUtil_20230807152501.js +478 -0
- package/.history/{package_20220831202000.json → package_20230807152934.json} +1 -1
- package/.history/{package_20221025154242.json → package_20230807152935.json} +1 -1
- package/.history/test_20210114114116.js +536 -0
- package/.history/test_20230807152745.js +537 -0
- package/.history/test_20230807152855.js +537 -0
- package/.history/test_20230807152908.js +537 -0
- package/.history/test_20230807152909.js +537 -0
- package/.history/test_20230807152948.js +536 -0
- package/.history/test_20230807153410.js +536 -0
- package/.history/test_20230807153411.js +536 -0
- package/.history/test_20230807153412.js +536 -0
- package/.history/test_20230807153423.js +536 -0
- package/base/db.js +9 -0
- package/base/dbUtil.js +14 -9
- package/base/err.js +1 -0
- package/package.json +1 -1
- package/test.js +7 -7
- package/.history/package_20221123193139.json +0 -36
package/test.js
CHANGED
|
@@ -8,11 +8,11 @@ let db2ramFieldMap = require('./config/db2ramFieldMap.json');
|
|
|
8
8
|
let textDbFieldsMap = require('./config/textDbFields.json');
|
|
9
9
|
let dbConfig = {
|
|
10
10
|
"connectionLimit": 10,
|
|
11
|
-
"database": "
|
|
12
|
-
"host": "
|
|
13
|
-
"user": "
|
|
11
|
+
"database": "test",
|
|
12
|
+
"host": "127.0.0.1",
|
|
13
|
+
"user": "*****",
|
|
14
14
|
"port": 3360,
|
|
15
|
-
"password": "
|
|
15
|
+
"password": "******",
|
|
16
16
|
"multipleStatements": true
|
|
17
17
|
};
|
|
18
18
|
|
|
@@ -167,11 +167,11 @@ describe('sampleDao', function(){
|
|
|
167
167
|
}
|
|
168
168
|
}).then(res => {
|
|
169
169
|
expect(res.count).to.be.a('number');
|
|
170
|
-
expect(res.list).to.be.an('
|
|
170
|
+
expect(res.list).to.be.an('null');
|
|
171
171
|
})
|
|
172
172
|
});
|
|
173
173
|
|
|
174
|
-
it('分页查询返回 only
|
|
174
|
+
it('分页查询返回 only list', function (){
|
|
175
175
|
return sampleDao.pageQuery({
|
|
176
176
|
initSql: 'select project_id as projectId, name from sample where id = ?',
|
|
177
177
|
initParams: [1],
|
|
@@ -183,7 +183,7 @@ describe('sampleDao', function(){
|
|
|
183
183
|
name: 'xx'
|
|
184
184
|
}
|
|
185
185
|
}).then(res => {
|
|
186
|
-
expect(res.count).to.be.an('
|
|
186
|
+
expect(res.count).to.be.an('null');
|
|
187
187
|
expect(res.list).to.be.an('array');
|
|
188
188
|
})
|
|
189
189
|
});
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "dborm-mysql",
|
|
3
|
-
"version": "2.1.4",
|
|
4
|
-
"description": "a NodeJs ORM for mysql",
|
|
5
|
-
"main": "index.js",
|
|
6
|
-
"types": "index.d.ts",
|
|
7
|
-
"dependencies": {
|
|
8
|
-
"@types/node": "^14.14.13",
|
|
9
|
-
"co": "^4.6.0",
|
|
10
|
-
"lodash": "^4.17.4",
|
|
11
|
-
"moment": "^2.24.0",
|
|
12
|
-
"mysql": "^2.14.1",
|
|
13
|
-
"short-uuid": "^2.2.0",
|
|
14
|
-
"util": "^0.10.3"
|
|
15
|
-
},
|
|
16
|
-
"devDependencies": {
|
|
17
|
-
"chai": "^3.5.0",
|
|
18
|
-
"istanbul": "^1.1.0-alpha.1",
|
|
19
|
-
"mocha": "^3.3.0",
|
|
20
|
-
"should": "~3.3.1"
|
|
21
|
-
},
|
|
22
|
-
"scripts": {
|
|
23
|
-
"test": "istanbul cover node_modules/mocha/bin/_mocha test.js"
|
|
24
|
-
},
|
|
25
|
-
"repository": {
|
|
26
|
-
"type": "git",
|
|
27
|
-
"url": "https://github.com/ZhangDianPeng/dborm"
|
|
28
|
-
},
|
|
29
|
-
"keywords": [
|
|
30
|
-
"nodejs",
|
|
31
|
-
"orm",
|
|
32
|
-
"mysql"
|
|
33
|
-
],
|
|
34
|
-
"author": "zhangdianp@163.com",
|
|
35
|
-
"license": "ISC"
|
|
36
|
-
}
|