baja-lite 1.5.11 → 1.5.12
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/package.json +1 -1
- package/sql.js +5 -5
package/package.json
CHANGED
package/sql.js
CHANGED
|
@@ -2655,11 +2655,11 @@ export class SqlService {
|
|
|
2655
2655
|
}
|
|
2656
2656
|
}
|
|
2657
2657
|
template(option) {
|
|
2658
|
-
Throw.if(!!this[_ids] && this[_ids].length > 1 && !option.where,
|
|
2659
|
-
Throw.if((!this[_ids] || this[_ids].length === 0) && !option.where,
|
|
2660
|
-
Throw.if(!option.id && !option.where,
|
|
2661
|
-
Throw.if(!!option.id && !!this[_ids] && this[_ids].length > 1,
|
|
2662
|
-
Throw.if(!!option.id && !!option.where,
|
|
2658
|
+
Throw.if(!!this[_ids] && this[_ids].length > 1 && !option.where, `muit id must set where!(${option.tableName})`);
|
|
2659
|
+
Throw.if((!this[_ids] || this[_ids].length === 0) && !option.where, `if not set id on class, must set where!(${option.tableName})`);
|
|
2660
|
+
Throw.if(!option.id && !option.where, `not found id or where!(${option.tableName})`);
|
|
2661
|
+
Throw.if(!!option.id && !!this[_ids] && this[_ids].length > 1, `muit id must set where!(${option.tableName})`);
|
|
2662
|
+
Throw.if(!!option.id && !!option.where, `id and where only one can set!(${option.tableName})`);
|
|
2663
2663
|
option.mode ?? (option.mode = SelectMode.Common);
|
|
2664
2664
|
option.templateResult ?? (option.templateResult = TemplateResult.AssertOne);
|
|
2665
2665
|
option.error ?? (option.error = 'error data!');
|