@g1cloud/bluesea 5.0.0-alpha.13 → 5.0.0-alpha.14
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/dist/bluesea.js +9 -8
- package/dist/bluesea.umd.cjs +9 -8
- package/dist/model/SearchModel.d.ts +1 -1
- package/package.json +1 -1
package/dist/bluesea.js
CHANGED
|
@@ -30494,19 +30494,20 @@ const valueToFilter = (filters) => {
|
|
|
30494
30494
|
const serializeFilter = (filters) => {
|
|
30495
30495
|
if (filters.length === 0)
|
|
30496
30496
|
return void 0;
|
|
30497
|
-
else
|
|
30498
|
-
|
|
30499
|
-
|
|
30500
|
-
|
|
30497
|
+
else {
|
|
30498
|
+
const ser = filters.length === 1 ? filters[0].serialize() : andFilter(filters).serialize();
|
|
30499
|
+
return encodeURIComponent(JSON.stringify(ser));
|
|
30500
|
+
}
|
|
30501
30501
|
};
|
|
30502
30502
|
const serializeSort = (sorts) => {
|
|
30503
30503
|
if (sorts) {
|
|
30504
|
-
|
|
30504
|
+
const ser = sorts.map((sort) => {
|
|
30505
30505
|
const dir = sort.ascending ? "" : "-";
|
|
30506
|
-
const propertyId =
|
|
30507
|
-
const nulls = sort.nullHandling
|
|
30508
|
-
return `${dir}${propertyId}
|
|
30506
|
+
const propertyId = sort.propertyId;
|
|
30507
|
+
const nulls = sort.nullHandling && sort.nullHandling !== "D" ? `:${sort.nullHandling}` : "";
|
|
30508
|
+
return `${dir}${propertyId}${nulls}`;
|
|
30509
30509
|
}).join(",");
|
|
30510
|
+
return encodeURIComponent(ser);
|
|
30510
30511
|
}
|
|
30511
30512
|
};
|
|
30512
30513
|
class SearchParam {
|
package/dist/bluesea.umd.cjs
CHANGED
|
@@ -30495,19 +30495,20 @@ img.ProseMirror-separator {
|
|
|
30495
30495
|
const serializeFilter = (filters) => {
|
|
30496
30496
|
if (filters.length === 0)
|
|
30497
30497
|
return void 0;
|
|
30498
|
-
else
|
|
30499
|
-
|
|
30500
|
-
|
|
30501
|
-
|
|
30498
|
+
else {
|
|
30499
|
+
const ser = filters.length === 1 ? filters[0].serialize() : andFilter(filters).serialize();
|
|
30500
|
+
return encodeURIComponent(JSON.stringify(ser));
|
|
30501
|
+
}
|
|
30502
30502
|
};
|
|
30503
30503
|
const serializeSort = (sorts) => {
|
|
30504
30504
|
if (sorts) {
|
|
30505
|
-
|
|
30505
|
+
const ser = sorts.map((sort) => {
|
|
30506
30506
|
const dir = sort.ascending ? "" : "-";
|
|
30507
|
-
const propertyId =
|
|
30508
|
-
const nulls = sort.nullHandling
|
|
30509
|
-
return `${dir}${propertyId}
|
|
30507
|
+
const propertyId = sort.propertyId;
|
|
30508
|
+
const nulls = sort.nullHandling && sort.nullHandling !== "D" ? `:${sort.nullHandling}` : "";
|
|
30509
|
+
return `${dir}${propertyId}${nulls}`;
|
|
30510
30510
|
}).join(",");
|
|
30511
|
+
return encodeURIComponent(ser);
|
|
30511
30512
|
}
|
|
30512
30513
|
};
|
|
30513
30514
|
class SearchParam {
|
|
@@ -2,7 +2,7 @@ import { Filter } from '../model/FilterModel.ts';
|
|
|
2
2
|
export type Sort = {
|
|
3
3
|
propertyId: string;
|
|
4
4
|
ascending?: boolean;
|
|
5
|
-
nullHandling?: '
|
|
5
|
+
nullHandling?: 'D' | 'F' | 'L';
|
|
6
6
|
};
|
|
7
7
|
export declare class SearchParam {
|
|
8
8
|
offset?: number;
|