@maiyunnet/kebab 7.0.0 → 7.0.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/index.d.ts +1 -1
- package/index.js +1 -1
- package/package.json +1 -1
- package/sys/mod.js +9 -9
package/index.d.ts
CHANGED
package/index.js
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* --- 本文件用来定义每个目录实体地址的常量 ---
|
|
7
7
|
*/
|
|
8
8
|
/** --- 当前系统版本号 --- */
|
|
9
|
-
export const VER = '7.0.
|
|
9
|
+
export const VER = '7.0.1';
|
|
10
10
|
// --- 服务端用的路径 ---
|
|
11
11
|
const imu = decodeURIComponent(import.meta.url).replace('file://', '').replace(/^\/(\w:)/, '$1');
|
|
12
12
|
/** --- /xxx/xxx --- */
|
package/package.json
CHANGED
package/sys/mod.js
CHANGED
|
@@ -82,7 +82,7 @@ export default class Mod {
|
|
|
82
82
|
this._sql = lSql.get({
|
|
83
83
|
'service': this._db.getService() ?? lDb.ESERVICE.PGSQL,
|
|
84
84
|
'ctr': opt.ctr,
|
|
85
|
-
'pre': opt.pre,
|
|
85
|
+
'pre': opt.pre ?? this.constructor._$pre,
|
|
86
86
|
});
|
|
87
87
|
if (opt.index) {
|
|
88
88
|
this._index = typeof opt.index === 'string' ? [opt.index] : [...new Set(opt.index)];
|
|
@@ -123,7 +123,7 @@ export default class Mod {
|
|
|
123
123
|
const sq = lSql.get({
|
|
124
124
|
'service': db.getService() ?? lDb.ESERVICE.PGSQL,
|
|
125
125
|
'ctr': opt.ctr,
|
|
126
|
-
'pre': opt.pre,
|
|
126
|
+
'pre': opt.pre ?? this.constructor._$pre,
|
|
127
127
|
});
|
|
128
128
|
if (!vs) {
|
|
129
129
|
// --- 单行 ---
|
|
@@ -172,7 +172,7 @@ export default class Mod {
|
|
|
172
172
|
const sq = lSql.get({
|
|
173
173
|
'service': db.getService() ?? lDb.ESERVICE.PGSQL,
|
|
174
174
|
'ctr': opt.ctr,
|
|
175
|
-
'pre': opt.pre,
|
|
175
|
+
'pre': opt.pre ?? this.constructor._$pre,
|
|
176
176
|
});
|
|
177
177
|
sq.insert(this._$table + (opt.index ? ('_' + opt.index) : '')).values(cs, vs);
|
|
178
178
|
return sq.format();
|
|
@@ -190,7 +190,7 @@ export default class Mod {
|
|
|
190
190
|
const sq = lSql.get({
|
|
191
191
|
'service': db.getService() ?? lDb.ESERVICE.PGSQL,
|
|
192
192
|
'ctr': opt.ctr,
|
|
193
|
-
'pre': opt.pre,
|
|
193
|
+
'pre': opt.pre ?? this.constructor._$pre,
|
|
194
194
|
});
|
|
195
195
|
sq.delete(this._$table + (index ? ('_' + index) : '')).where(where);
|
|
196
196
|
if (opt.by) {
|
|
@@ -220,7 +220,7 @@ export default class Mod {
|
|
|
220
220
|
const sq = lSql.get({
|
|
221
221
|
'service': db.getService() ?? lDb.ESERVICE.PGSQL,
|
|
222
222
|
'ctr': opt.ctr,
|
|
223
|
-
'pre': opt.pre,
|
|
223
|
+
'pre': opt.pre ?? this.constructor._$pre,
|
|
224
224
|
});
|
|
225
225
|
sq.delete(this._$table + (opt.index ? ('_' + opt.index) : '')).where(where);
|
|
226
226
|
if (opt.by) {
|
|
@@ -245,7 +245,7 @@ export default class Mod {
|
|
|
245
245
|
const sq = lSql.get({
|
|
246
246
|
'service': db.getService() ?? lDb.ESERVICE.PGSQL,
|
|
247
247
|
'ctr': opt.ctr,
|
|
248
|
-
'pre': opt.pre,
|
|
248
|
+
'pre': opt.pre ?? this.constructor._$pre,
|
|
249
249
|
});
|
|
250
250
|
sq.update(this._$table + (index ? ('_' + index) : ''), data).where(where);
|
|
251
251
|
if (opt.by) {
|
|
@@ -276,7 +276,7 @@ export default class Mod {
|
|
|
276
276
|
const sq = lSql.get({
|
|
277
277
|
'service': db.getService() ?? lDb.ESERVICE.PGSQL,
|
|
278
278
|
'ctr': opt.ctr,
|
|
279
|
-
'pre': opt.pre,
|
|
279
|
+
'pre': opt.pre ?? this.constructor._$pre,
|
|
280
280
|
});
|
|
281
281
|
sq.update(this._$table + (opt.index ? ('_' + opt.index) : ''), data).where(where);
|
|
282
282
|
if (opt.by) {
|
|
@@ -324,7 +324,7 @@ export default class Mod {
|
|
|
324
324
|
const sq = lSql.get({
|
|
325
325
|
'service': db.getService() ?? lDb.ESERVICE.PGSQL,
|
|
326
326
|
'ctr': opt.ctr,
|
|
327
|
-
'pre': opt.pre,
|
|
327
|
+
'pre': opt.pre ?? this.constructor._$pre,
|
|
328
328
|
});
|
|
329
329
|
const updates = {};
|
|
330
330
|
const keys = [];
|
|
@@ -494,7 +494,7 @@ export default class Mod {
|
|
|
494
494
|
const sq = lSql.get({
|
|
495
495
|
'service': db.getService() ?? lDb.ESERVICE.PGSQL,
|
|
496
496
|
'ctr': opt.ctr,
|
|
497
|
-
'pre': opt.pre,
|
|
497
|
+
'pre': opt.pre ?? this.constructor._$pre,
|
|
498
498
|
});
|
|
499
499
|
sq.select(this._$primary, this._$table + (opt.index ? ('_' + opt.index) : '')).where(where);
|
|
500
500
|
const r = await db.query(sq.getSql(), sq.getData());
|