lucid-extension-sdk 0.0.94 → 0.0.95
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
CHANGED
|
@@ -33,7 +33,7 @@ export declare abstract class TaskManagementCardIntegration {
|
|
|
33
33
|
/**
|
|
34
34
|
* Callback to provide a list of all supported field names for the card integration.
|
|
35
35
|
*/
|
|
36
|
-
getAllFields: (collection: CollectionProxy) => Promise<string[]>;
|
|
36
|
+
getAllFields: (collection: CollectionProxy, dataSource: DataSourceProxy) => Promise<string[]>;
|
|
37
37
|
/**
|
|
38
38
|
* Callback that handled changes in the fields the user wants to be displayed in the card integration.
|
|
39
39
|
* If this callback is not provided then the user will not be shown the modal to configure fields.
|
|
@@ -48,7 +48,7 @@ export declare abstract class TaskManagementCardIntegration {
|
|
|
48
48
|
/**
|
|
49
49
|
* Provide the default configuration for a new import
|
|
50
50
|
*/
|
|
51
|
-
abstract getDefaultConfig: (collection: CollectionProxy) => Promise<CardIntegrationConfig>;
|
|
51
|
+
abstract getDefaultConfig: (collection: CollectionProxy, dataSource: DataSourceProxy) => Promise<CardIntegrationConfig>;
|
|
52
52
|
/**
|
|
53
53
|
* If specified, allow the user to import cards using the standard card-import modal.
|
|
54
54
|
*
|
|
@@ -2,10 +2,12 @@ import { SerializedFieldType } from '../data/serializedfield/serializedfields';
|
|
|
2
2
|
/** @ignore */
|
|
3
3
|
export interface GetFieldsParam {
|
|
4
4
|
'c': string;
|
|
5
|
+
'd': string;
|
|
5
6
|
}
|
|
6
7
|
/** @ignore */
|
|
7
8
|
export interface GetDefaultConfigParam {
|
|
8
9
|
'c': string;
|
|
10
|
+
'd': string;
|
|
9
11
|
}
|
|
10
12
|
/** @ignore */
|
|
11
13
|
export interface OnSelectedFieldsChangeParam {
|
|
@@ -33,7 +33,8 @@ class TaskManagementCardRegistry {
|
|
|
33
33
|
const getFieldsActionName = TaskManagementCardRegistry.nextHookName();
|
|
34
34
|
client.registerAction(getFieldsActionName, async (param) => {
|
|
35
35
|
const collection = new collectionproxy_1.CollectionProxy(param['c'], client);
|
|
36
|
-
const
|
|
36
|
+
const dataSource = new datasourceproxy_1.DataSourceProxy(param['d'], client);
|
|
37
|
+
const fields = await cardIntegration.fieldConfiguration.getAllFields(collection, dataSource);
|
|
37
38
|
return fields;
|
|
38
39
|
});
|
|
39
40
|
let onSelectedFieldsChangeActionName = undefined;
|
|
@@ -48,7 +49,8 @@ class TaskManagementCardRegistry {
|
|
|
48
49
|
const getDefaultConfigActionName = TaskManagementCardRegistry.nextHookName();
|
|
49
50
|
client.registerAction(getDefaultConfigActionName, async (param) => {
|
|
50
51
|
const collection = new collectionproxy_1.CollectionProxy(param['c'], client);
|
|
51
|
-
|
|
52
|
+
const dataSource = new datasourceproxy_1.DataSourceProxy(param['d'], client);
|
|
53
|
+
return (0, cardintegrationconfig_1.serializeCardIntegrationConfig)(await cardIntegration.getDefaultConfig(collection, dataSource));
|
|
52
54
|
});
|
|
53
55
|
let showIntroActionName = undefined;
|
|
54
56
|
if (cardIntegration.showIntro) {
|