@koolbase/core 12.54.0 → 12.55.0
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.
|
@@ -56,6 +56,13 @@ export interface KbSortField {
|
|
|
56
56
|
lat: number;
|
|
57
57
|
lng: number;
|
|
58
58
|
};
|
|
59
|
+
/**
|
|
60
|
+
* A Choice field in the order its choices are declared now (Lead,
|
|
61
|
+
* Qualified, Won), where the plain sort orders by their text. Whichever
|
|
62
|
+
* way it runs: the declared choices first, then values that are not among
|
|
63
|
+
* them, then records with none.
|
|
64
|
+
*/
|
|
65
|
+
by?: 'choices';
|
|
59
66
|
}
|
|
60
67
|
export declare const KbWhere: {
|
|
61
68
|
/** Every condition must hold. */
|
|
@@ -129,6 +136,13 @@ export declare function KbField(name: string): {
|
|
|
129
136
|
export declare const KbSort: {
|
|
130
137
|
asc: (field: string) => KbSortField;
|
|
131
138
|
desc: (field: string) => KbSortField;
|
|
139
|
+
/**
|
|
140
|
+
* A Choice field in the order its choices are declared, on the server and
|
|
141
|
+
* before the page: a list grouped by a stage runs Lead, Qualified, Won,
|
|
142
|
+
* not alphabetically. Values no longer among the choices come after them,
|
|
143
|
+
* and records with no value last, whichever way it runs.
|
|
144
|
+
*/
|
|
145
|
+
choices: (field: string, dir?: "asc" | "desc") => KbSortField;
|
|
132
146
|
/** A location field (G5) by distance from the point, nearest first; records with no position last. */
|
|
133
147
|
near: (field: string, lat: number, lng: number) => KbSortField;
|
|
134
148
|
};
|
|
@@ -143,6 +143,13 @@ function KbField(name) {
|
|
|
143
143
|
exports.KbSort = {
|
|
144
144
|
asc: (field) => ({ field, dir: 'asc' }),
|
|
145
145
|
desc: (field) => ({ field, dir: 'desc' }),
|
|
146
|
+
/**
|
|
147
|
+
* A Choice field in the order its choices are declared, on the server and
|
|
148
|
+
* before the page: a list grouped by a stage runs Lead, Qualified, Won,
|
|
149
|
+
* not alphabetically. Values no longer among the choices come after them,
|
|
150
|
+
* and records with no value last, whichever way it runs.
|
|
151
|
+
*/
|
|
152
|
+
choices: (field, dir = 'asc') => ({ field, dir, by: 'choices' }),
|
|
146
153
|
/** A location field (G5) by distance from the point, nearest first; records with no position last. */
|
|
147
154
|
near: (field, lat, lng) => {
|
|
148
155
|
checkPoint(lat, lng);
|
|
@@ -56,6 +56,13 @@ export interface KbSortField {
|
|
|
56
56
|
lat: number;
|
|
57
57
|
lng: number;
|
|
58
58
|
};
|
|
59
|
+
/**
|
|
60
|
+
* A Choice field in the order its choices are declared now (Lead,
|
|
61
|
+
* Qualified, Won), where the plain sort orders by their text. Whichever
|
|
62
|
+
* way it runs: the declared choices first, then values that are not among
|
|
63
|
+
* them, then records with none.
|
|
64
|
+
*/
|
|
65
|
+
by?: 'choices';
|
|
59
66
|
}
|
|
60
67
|
export declare const KbWhere: {
|
|
61
68
|
/** Every condition must hold. */
|
|
@@ -129,6 +136,13 @@ export declare function KbField(name: string): {
|
|
|
129
136
|
export declare const KbSort: {
|
|
130
137
|
asc: (field: string) => KbSortField;
|
|
131
138
|
desc: (field: string) => KbSortField;
|
|
139
|
+
/**
|
|
140
|
+
* A Choice field in the order its choices are declared, on the server and
|
|
141
|
+
* before the page: a list grouped by a stage runs Lead, Qualified, Won,
|
|
142
|
+
* not alphabetically. Values no longer among the choices come after them,
|
|
143
|
+
* and records with no value last, whichever way it runs.
|
|
144
|
+
*/
|
|
145
|
+
choices: (field: string, dir?: "asc" | "desc") => KbSortField;
|
|
132
146
|
/** A location field (G5) by distance from the point, nearest first; records with no position last. */
|
|
133
147
|
near: (field: string, lat: number, lng: number) => KbSortField;
|
|
134
148
|
};
|
|
@@ -137,6 +137,13 @@ export function KbField(name) {
|
|
|
137
137
|
export const KbSort = {
|
|
138
138
|
asc: (field) => ({ field, dir: 'asc' }),
|
|
139
139
|
desc: (field) => ({ field, dir: 'desc' }),
|
|
140
|
+
/**
|
|
141
|
+
* A Choice field in the order its choices are declared, on the server and
|
|
142
|
+
* before the page: a list grouped by a stage runs Lead, Qualified, Won,
|
|
143
|
+
* not alphabetically. Values no longer among the choices come after them,
|
|
144
|
+
* and records with no value last, whichever way it runs.
|
|
145
|
+
*/
|
|
146
|
+
choices: (field, dir = 'asc') => ({ field, dir, by: 'choices' }),
|
|
140
147
|
/** A location field (G5) by distance from the point, nearest first; records with no position last. */
|
|
141
148
|
near: (field, lat, lng) => {
|
|
142
149
|
checkPoint(lat, lng);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@koolbase/core",
|
|
3
|
-
"version": "12.
|
|
3
|
+
"version": "12.55.0",
|
|
4
4
|
"description": "Koolbase SDK core — shared behaviour behind @koolbase/react-native and @koolbase/js. Install one of those, not this.",
|
|
5
5
|
"main": "./dist/cjs/index.js",
|
|
6
6
|
"react-native": "./dist/esm/index.js",
|