@rentman/rm-core 1.1.14 → 1.1.15
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/changelog.md +4 -0
- package/dist/dist/classes/ApiFormatter.d.ts +1 -1
- package/dist/dist/classes/ColumnCache.d.ts +13 -10
- package/dist/dist/classes/ColumnHandler.d.ts +10 -7
- package/dist/dist/interfaces/PromiseInterface.d.ts +6 -3
- package/dist/rm-core.js +19 -23
- package/dist/rm-core.min.js +1 -1
- package/package.json +1 -1
package/changelog.md
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
#Changelog
|
|
2
2
|
Contains new features, breaking changes and their reasoning
|
|
3
3
|
|
|
4
|
+
##v1.15
|
|
5
|
+
- Fix `fetchItemTypesTranslations` function in `ColumnHandler` class.
|
|
6
|
+
- Fix type definition of `PromiseInterface.all`.
|
|
7
|
+
|
|
4
8
|
##v1.14
|
|
5
9
|
- The `ChangesCompiler` now always processes local collections. (Even if they don't have edit resources.) This fixes an
|
|
6
10
|
issue with recurring appointments in the front-end.
|
|
@@ -27,7 +27,7 @@ export declare class ApiFormatter {
|
|
|
27
27
|
formatRequestDate(value: any): any;
|
|
28
28
|
formatRequestDuration(value: any): any;
|
|
29
29
|
formatRequestColor(value: any): any;
|
|
30
|
-
getDefaultValue(columnType: any): false |
|
|
30
|
+
getDefaultValue(columnType: any): false | 0 | "" | moment.Moment | moment.Duration | "0" | "#000000" | null;
|
|
31
31
|
isDefaultValue(columnType: any, value: any): any;
|
|
32
32
|
clone(columnType: any, value: any): any;
|
|
33
33
|
getCloneFunction(columnType: any): (date: any) => any;
|
|
@@ -1,17 +1,20 @@
|
|
|
1
|
-
import { ColumnUtil } from '
|
|
1
|
+
import { ColumnUtil } from '../classes';
|
|
2
|
+
import { ItemType, RequestColumns, ResponseColumn, ResponseColumnMap } from '../types';
|
|
2
3
|
export declare class ColumnCache {
|
|
3
4
|
private columnUtil;
|
|
4
|
-
cache:
|
|
5
|
-
allColumns: {
|
|
5
|
+
cache: ResponseColumnMap;
|
|
6
|
+
allColumns: {
|
|
7
|
+
[itemType: string]: boolean;
|
|
8
|
+
};
|
|
6
9
|
constructor(columnUtil: ColumnUtil);
|
|
7
|
-
setColumn(itemType:
|
|
8
|
-
setColumns(itemType:
|
|
9
|
-
retrieve(itemType:
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
setColumn(itemType: ItemType, responseColumn: ResponseColumn): any;
|
|
11
|
+
setColumns(itemType: ItemType, requestColumns: RequestColumns, responseColumns: ResponseColumnMap): ResponseColumnMap;
|
|
12
|
+
retrieve(itemType: ItemType, requestColumns: RequestColumns): {
|
|
13
|
+
cached: ResponseColumnMap;
|
|
14
|
+
missing: RequestColumns;
|
|
12
15
|
};
|
|
13
|
-
containsAll(itemType:
|
|
14
|
-
getColumns(itemType:
|
|
16
|
+
containsAll(itemType: ItemType): boolean;
|
|
17
|
+
getColumns(itemType: ItemType): ResponseColumnMap;
|
|
15
18
|
private retrieveColumns(itemType, requestColumns, requestAccumulator, responseAccumulator);
|
|
16
19
|
private retrieveColumn(itemType, requestColumn, requestAccumulator, responseAccumulator);
|
|
17
20
|
private getColumn(itemType, columnId);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ColumnCache, ColumnUtil } from '../classes';
|
|
2
2
|
import { ApiRequestServiceInterface, ErrorHandlerInterface, PromiseInterface } from '../interfaces';
|
|
3
|
+
import { ItemType, RequestColumns, ResponseColumn, ResponseColumnMap } from '../types';
|
|
3
4
|
export declare class ColumnHandler {
|
|
4
5
|
private apiRequestService;
|
|
5
6
|
private errorHandler;
|
|
@@ -7,12 +8,14 @@ export declare class ColumnHandler {
|
|
|
7
8
|
private cache;
|
|
8
9
|
private columnUtil;
|
|
9
10
|
constructor(apiRequestService: ApiRequestServiceInterface, errorHandler: ErrorHandlerInterface, promiseService: PromiseInterface, cache: ColumnCache, columnUtil: ColumnUtil);
|
|
10
|
-
setColumn(itemType:
|
|
11
|
-
setColumns(itemType:
|
|
12
|
-
fetchItemTypeTranslations(itemTypes:
|
|
13
|
-
|
|
11
|
+
setColumn(itemType: ItemType, responseColumn: ResponseColumn): ResponseColumn;
|
|
12
|
+
setColumns(itemType: ItemType, requestColumns: RequestColumns, responseColumns: ResponseColumnMap): ResponseColumnMap;
|
|
13
|
+
fetchItemTypeTranslations(itemTypes: ItemType[]): Promise<{
|
|
14
|
+
[itemType: string]: string;
|
|
15
|
+
}>;
|
|
16
|
+
request(itemType: ItemType, columns: RequestColumns, params?: {
|
|
14
17
|
filter: boolean;
|
|
15
|
-
}): Promise<
|
|
16
|
-
fetch(itemType:
|
|
17
|
-
fetchAll(itemType:
|
|
18
|
+
}): Promise<ResponseColumnMap>;
|
|
19
|
+
fetch(itemType: ItemType, requestColumns: RequestColumns, params?: any): Promise<ResponseColumnMap>;
|
|
20
|
+
fetchAll(itemType: ItemType): Promise<ResponseColumnMap>;
|
|
18
21
|
}
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
export interface PromiseInterface {
|
|
2
|
-
all(iterable: Array<Promise<any> | any>
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
all(iterable: Array<Promise<any> | any>): Promise<any[]>;
|
|
3
|
+
all(iterable: {
|
|
4
|
+
[key: string]: Promise<any> | any;
|
|
5
|
+
}): Promise<{
|
|
6
|
+
[key: string]: any;
|
|
7
|
+
}>;
|
|
5
8
|
when(value?: any): Promise<any>;
|
|
6
9
|
reject(value?: any): Promise<any>;
|
|
7
10
|
defer(): {
|