@finos/legend-application-marketplace 0.0.19 → 0.0.21
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/lib/__lib__/LegendMarketplaceNavigation.d.ts +3 -0
- package/lib/__lib__/LegendMarketplaceNavigation.d.ts.map +1 -1
- package/lib/__lib__/LegendMarketplaceNavigation.js +11 -1
- package/lib/__lib__/LegendMarketplaceNavigation.js.map +1 -1
- package/lib/app.css +2 -2
- package/lib/app.css.map +1 -1
- package/lib/application/LegendMarketplaceApplicationConfig.d.ts +10 -0
- package/lib/application/LegendMarketplaceApplicationConfig.d.ts.map +1 -1
- package/lib/application/LegendMarketplaceApplicationConfig.js +10 -0
- package/lib/application/LegendMarketplaceApplicationConfig.js.map +1 -1
- package/lib/application/LegendMarketplaceFrameworkProvider.d.ts.map +1 -1
- package/lib/application/LegendMarketplaceFrameworkProvider.js +2 -2
- package/lib/application/LegendMarketplaceFrameworkProvider.js.map +1 -1
- package/lib/application/LegendMarketplaceWebApplication.d.ts.map +1 -1
- package/lib/application/LegendMarketplaceWebApplication.js +18 -8
- package/lib/application/LegendMarketplaceWebApplication.js.map +1 -1
- package/lib/components/DataProductCard/LegendMarketplaceDataProductSearchCard.d.ts.map +1 -1
- package/lib/components/DataProductCard/LegendMarketplaceDataProductSearchCard.js +6 -3
- package/lib/components/DataProductCard/LegendMarketplaceDataProductSearchCard.js.map +1 -1
- package/lib/components/DataProductCard/LegendMarketplaceLightDataProductCard.d.ts.map +1 -1
- package/lib/components/DataProductCard/LegendMarketplaceLightDataProductCard.js +9 -6
- package/lib/components/DataProductCard/LegendMarketplaceLightDataProductCard.js.map +1 -1
- package/lib/components/{Lakehouse/LakehouseHeader.d.ts → Header/MarketplaceLakehouseHeader.d.ts} +2 -2
- package/lib/components/Header/MarketplaceLakehouseHeader.d.ts.map +1 -0
- package/lib/components/{Lakehouse/LakehouseHeader.js → Header/MarketplaceLakehouseHeader.js} +8 -4
- package/lib/components/Header/MarketplaceLakehouseHeader.js.map +1 -0
- package/lib/components/MarketplaceCard/LegendMarketplaceCard.d.ts +25 -0
- package/lib/components/MarketplaceCard/LegendMarketplaceCard.d.ts.map +1 -0
- package/lib/components/MarketplaceCard/LegendMarketplaceCard.js +32 -0
- package/lib/components/MarketplaceCard/LegendMarketplaceCard.js.map +1 -0
- package/lib/components/ProviderCard/LegendMarketplaceProviderCard.d.ts.map +1 -1
- package/lib/components/ProviderCard/LegendMarketplaceProviderCard.js +6 -3
- package/lib/components/ProviderCard/LegendMarketplaceProviderCard.js.map +1 -1
- package/lib/components/__test-utils__/LegendMarketplaceStoreTestUtils.d.ts.map +1 -1
- package/lib/components/__test-utils__/LegendMarketplaceStoreTestUtils.js +3 -6
- package/lib/components/__test-utils__/LegendMarketplaceStoreTestUtils.js.map +1 -1
- package/lib/index.css +2 -2
- package/lib/index.css.map +1 -1
- package/lib/package.json +2 -1
- package/lib/pages/Home/LegendMarketplaceHome.d.ts.map +1 -1
- package/lib/pages/Home/LegendMarketplaceHome.js +4 -4
- package/lib/pages/Home/LegendMarketplaceHome.js.map +1 -1
- package/lib/pages/Lakehouse/DataProductDataAccess.d.ts.map +1 -0
- package/lib/{components → pages}/Lakehouse/DataProductDataAccess.js +41 -9
- package/lib/pages/Lakehouse/DataProductDataAccess.js.map +1 -0
- package/lib/pages/Lakehouse/DataProductHolder.d.ts.map +1 -0
- package/lib/pages/Lakehouse/DataProductHolder.js.map +1 -0
- package/lib/pages/Lakehouse/DataProductViewer.d.ts.map +1 -0
- package/lib/pages/Lakehouse/DataProductViewer.js.map +1 -0
- package/lib/pages/Lakehouse/DataProductViewerActivityBar.d.ts.map +1 -0
- package/lib/pages/Lakehouse/DataProductViewerActivityBar.js.map +1 -0
- package/lib/pages/Lakehouse/DataProductWiki.d.ts.map +1 -0
- package/lib/pages/Lakehouse/DataProductWiki.js.map +1 -0
- package/lib/pages/Lakehouse/LakehouseDataProduct.d.ts.map +1 -0
- package/lib/{components → pages}/Lakehouse/LakehouseDataProduct.js +3 -3
- package/lib/pages/Lakehouse/LakehouseDataProduct.js.map +1 -0
- package/lib/{components/Lakehouse/LakehouseMarketplace.d.ts → pages/Lakehouse/MarketplaceLakehouseHome.d.ts} +2 -2
- package/lib/pages/Lakehouse/MarketplaceLakehouseHome.d.ts.map +1 -0
- package/lib/pages/Lakehouse/MarketplaceLakehouseHome.js +54 -0
- package/lib/pages/Lakehouse/MarketplaceLakehouseHome.js.map +1 -0
- package/lib/{components/Lakehouse/MarketLakehouseStoreProvider.d.ts → pages/Lakehouse/MarketplaceLakehouseStoreProvider.d.ts} +1 -1
- package/lib/pages/Lakehouse/MarketplaceLakehouseStoreProvider.d.ts.map +1 -0
- package/lib/{components/Lakehouse/MarketLakehouseStoreProvider.js → pages/Lakehouse/MarketplaceLakehouseStoreProvider.js} +1 -1
- package/lib/pages/Lakehouse/MarketplaceLakehouseStoreProvider.js.map +1 -0
- package/lib/{components/Lakehouse/entitlements/LakehouseEntitlements.d.ts → pages/Lakehouse/entitlements/EntitlementsDashboard.d.ts} +6 -5
- package/lib/pages/Lakehouse/entitlements/EntitlementsDashboard.d.ts.map +1 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsDashboard.js +194 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsDashboard.js.map +1 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsDataContractCreator.d.ts +24 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsDataContractCreator.d.ts.map +1 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsDataContractCreator.js +38 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsDataContractCreator.js.map +1 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsDataContractViewer.d.ts +22 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsDataContractViewer.d.ts.map +1 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsDataContractViewer.js +23 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsDataContractViewer.js.map +1 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsTaskViewer.d.ts +21 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsTaskViewer.d.ts.map +1 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsTaskViewer.js +32 -0
- package/lib/pages/Lakehouse/entitlements/EntitlementsTaskViewer.js.map +1 -0
- package/lib/pages/Lakehouse/entitlements/LakehouseEntitlements.d.ts +17 -0
- package/lib/pages/Lakehouse/entitlements/LakehouseEntitlements.d.ts.map +1 -0
- package/lib/pages/Lakehouse/entitlements/LakehouseEntitlements.js +55 -0
- package/lib/pages/Lakehouse/entitlements/LakehouseEntitlements.js.map +1 -0
- package/lib/pages/Lakehouse/entitlements/LakehouseEntitlementsStoreProvider.d.ts.map +1 -0
- package/lib/pages/Lakehouse/entitlements/LakehouseEntitlementsStoreProvider.js.map +1 -0
- package/lib/pages/Lakehouse/shared/GridItemViewer.d.ts +21 -0
- package/lib/pages/Lakehouse/shared/GridItemViewer.d.ts.map +1 -0
- package/lib/pages/Lakehouse/shared/GridItemViewer.js +46 -0
- package/lib/pages/Lakehouse/shared/GridItemViewer.js.map +1 -0
- package/lib/pages/Lakehouse/subscriptions/LakehouseSubscriptions.d.ts +29 -0
- package/lib/pages/Lakehouse/subscriptions/LakehouseSubscriptions.d.ts.map +1 -0
- package/lib/pages/Lakehouse/subscriptions/LakehouseSubscriptions.js +152 -0
- package/lib/pages/Lakehouse/subscriptions/LakehouseSubscriptions.js.map +1 -0
- package/lib/pages/Lakehouse/subscriptions/LakehouseSubscriptionsStoreProvider.d.ts +22 -0
- package/lib/pages/Lakehouse/subscriptions/LakehouseSubscriptionsStoreProvider.d.ts.map +1 -0
- package/lib/pages/Lakehouse/subscriptions/LakehouseSubscriptionsStoreProvider.js +34 -0
- package/lib/pages/Lakehouse/subscriptions/LakehouseSubscriptionsStoreProvider.js.map +1 -0
- package/lib/pages/LegendMarketplacePage.d.ts +23 -0
- package/lib/pages/LegendMarketplacePage.d.ts.map +1 -0
- package/lib/pages/LegendMarketplacePage.js +23 -0
- package/lib/pages/LegendMarketplacePage.js.map +1 -0
- package/lib/pages/SearchResults/LegendMarketplaceSearchResults.d.ts.map +1 -1
- package/lib/pages/SearchResults/LegendMarketplaceSearchResults.js +13 -13
- package/lib/pages/SearchResults/LegendMarketplaceSearchResults.js.map +1 -1
- package/lib/pages/VendorData/LegendMarketplaceVendorData.d.ts.map +1 -1
- package/lib/pages/VendorData/LegendMarketplaceVendorData.js +6 -6
- package/lib/pages/VendorData/LegendMarketplaceVendorData.js.map +1 -1
- package/lib/stores/LakehouseContractServerClient.d.ts +11 -4
- package/lib/stores/LakehouseContractServerClient.d.ts.map +1 -1
- package/lib/stores/LakehouseContractServerClient.js +21 -3
- package/lib/stores/LakehouseContractServerClient.js.map +1 -1
- package/lib/stores/LegendMarketplaceBaseStore.d.ts +3 -0
- package/lib/stores/LegendMarketplaceBaseStore.d.ts.map +1 -1
- package/lib/stores/LegendMarketplaceBaseStore.js +8 -1
- package/lib/stores/LegendMarketplaceBaseStore.js.map +1 -1
- package/lib/stores/lakehouse/DataProductDataAccessState.d.ts +6 -7
- package/lib/stores/lakehouse/DataProductDataAccessState.d.ts.map +1 -1
- package/lib/stores/lakehouse/DataProductDataAccessState.js +47 -48
- package/lib/stores/lakehouse/DataProductDataAccessState.js.map +1 -1
- package/lib/stores/lakehouse/DataProductViewerState.d.ts +7 -3
- package/lib/stores/lakehouse/DataProductViewerState.d.ts.map +1 -1
- package/lib/stores/lakehouse/DataProductViewerState.js +51 -22
- package/lib/stores/lakehouse/DataProductViewerState.js.map +1 -1
- package/lib/stores/lakehouse/LakehouseUtils.d.ts +50 -0
- package/lib/stores/lakehouse/LakehouseUtils.d.ts.map +1 -0
- package/lib/stores/lakehouse/LakehouseUtils.js +267 -0
- package/lib/stores/lakehouse/LakehouseUtils.js.map +1 -0
- package/lib/stores/lakehouse/MarketplaceLakehouseStore.d.ts.map +1 -1
- package/lib/stores/lakehouse/MarketplaceLakehouseStore.js +9 -4
- package/lib/stores/lakehouse/MarketplaceLakehouseStore.js.map +1 -1
- package/lib/stores/lakehouse/entitlements/EntitlementsDashboardState.d.ts +31 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsDashboardState.d.ts.map +1 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsDashboardState.js +110 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsDashboardState.js.map +1 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsDataContractViewerState.d.ts +30 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsDataContractViewerState.d.ts.map +1 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsDataContractViewerState.js +65 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsDataContractViewerState.js.map +1 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsTaskViewerState.d.ts +41 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsTaskViewerState.d.ts.map +1 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsTaskViewerState.js +146 -0
- package/lib/stores/lakehouse/entitlements/EntitlementsTaskViewerState.js.map +1 -0
- package/lib/stores/lakehouse/entitlements/LakehouseEntitlementsStore.d.ts +10 -32
- package/lib/stores/lakehouse/entitlements/LakehouseEntitlementsStore.d.ts.map +1 -1
- package/lib/stores/lakehouse/entitlements/LakehouseEntitlementsStore.js +49 -163
- package/lib/stores/lakehouse/entitlements/LakehouseEntitlementsStore.js.map +1 -1
- package/lib/stores/lakehouse/entitlements/LakehouseViewerState.d.ts +23 -0
- package/lib/stores/lakehouse/entitlements/LakehouseViewerState.d.ts.map +1 -0
- package/lib/stores/lakehouse/entitlements/LakehouseViewerState.js +24 -0
- package/lib/stores/lakehouse/entitlements/LakehouseViewerState.js.map +1 -0
- package/lib/stores/lakehouse/subscriptions/LakehouseSubscriptionsStore.d.ts +30 -0
- package/lib/stores/lakehouse/subscriptions/LakehouseSubscriptionsStore.d.ts.map +1 -0
- package/lib/stores/lakehouse/subscriptions/LakehouseSubscriptionsStore.js +63 -0
- package/lib/stores/lakehouse/subscriptions/LakehouseSubscriptionsStore.js.map +1 -0
- package/package.json +5 -4
- package/src/__lib__/LegendMarketplaceNavigation.ts +16 -1
- package/src/application/LegendMarketplaceApplicationConfig.ts +25 -0
- package/src/application/LegendMarketplaceFrameworkProvider.tsx +2 -0
- package/src/application/LegendMarketplaceWebApplication.tsx +50 -12
- package/src/components/DataProductCard/LegendMarketplaceDataProductSearchCard.tsx +41 -33
- package/src/components/DataProductCard/LegendMarketplaceLightDataProductCard.tsx +33 -36
- package/src/components/{Lakehouse/LakehouseHeader.tsx → Header/MarketplaceLakehouseHeader.tsx} +7 -3
- package/src/components/MarketplaceCard/LegendMarketplaceCard.tsx +98 -0
- package/src/components/ProviderCard/LegendMarketplaceProviderCard.tsx +47 -39
- package/src/components/__test-utils__/LegendMarketplaceStoreTestUtils.tsx +2 -14
- package/src/pages/Home/LegendMarketplaceHome.tsx +42 -51
- package/src/{components → pages}/Lakehouse/DataProductDataAccess.tsx +91 -12
- package/src/{components → pages}/Lakehouse/LakehouseDataProduct.tsx +14 -23
- package/src/pages/Lakehouse/MarketplaceLakehouseHome.tsx +167 -0
- package/src/pages/Lakehouse/entitlements/EntitlementsDashboard.tsx +390 -0
- package/src/pages/Lakehouse/entitlements/EntitlementsDataContractCreator.tsx +99 -0
- package/src/pages/Lakehouse/entitlements/EntitlementsDataContractViewer.tsx +33 -0
- package/src/pages/Lakehouse/entitlements/EntitlementsTaskViewer.tsx +73 -0
- package/src/pages/Lakehouse/entitlements/LakehouseEntitlements.tsx +82 -0
- package/src/pages/Lakehouse/shared/GridItemViewer.tsx +105 -0
- package/src/pages/Lakehouse/subscriptions/LakehouseSubscriptions.tsx +358 -0
- package/src/pages/Lakehouse/subscriptions/LakehouseSubscriptionsStoreProvider.tsx +65 -0
- package/src/pages/LegendMarketplacePage.tsx +26 -0
- package/src/pages/SearchResults/LegendMarketplaceSearchResults.tsx +58 -65
- package/src/pages/VendorData/LegendMarketplaceVendorData.tsx +44 -42
- package/src/stores/LakehouseContractServerClient.ts +78 -10
- package/src/stores/LegendMarketplaceBaseStore.ts +16 -1
- package/src/stores/lakehouse/DataProductDataAccessState.ts +67 -63
- package/src/stores/lakehouse/DataProductViewerState.ts +86 -29
- package/src/stores/lakehouse/LakehouseUtils.ts +345 -0
- package/src/stores/lakehouse/MarketplaceLakehouseStore.ts +10 -6
- package/src/stores/lakehouse/entitlements/EntitlementsDashboardState.ts +167 -0
- package/src/stores/lakehouse/entitlements/EntitlementsDataContractViewerState.ts +101 -0
- package/src/stores/lakehouse/entitlements/EntitlementsTaskViewerState.ts +227 -0
- package/src/stores/lakehouse/entitlements/LakehouseEntitlementsStore.ts +69 -231
- package/src/stores/lakehouse/entitlements/LakehouseViewerState.ts +27 -0
- package/src/stores/lakehouse/subscriptions/LakehouseSubscriptionsStore.ts +100 -0
- package/tsconfig.json +26 -13
- package/lib/components/Lakehouse/DataProductDataAccess.d.ts.map +0 -1
- package/lib/components/Lakehouse/DataProductDataAccess.js.map +0 -1
- package/lib/components/Lakehouse/DataProductHolder.d.ts.map +0 -1
- package/lib/components/Lakehouse/DataProductHolder.js.map +0 -1
- package/lib/components/Lakehouse/DataProductViewer.d.ts.map +0 -1
- package/lib/components/Lakehouse/DataProductViewer.js.map +0 -1
- package/lib/components/Lakehouse/DataProductViewerActivityBar.d.ts.map +0 -1
- package/lib/components/Lakehouse/DataProductViewerActivityBar.js.map +0 -1
- package/lib/components/Lakehouse/DataProductWiki.d.ts.map +0 -1
- package/lib/components/Lakehouse/DataProductWiki.js.map +0 -1
- package/lib/components/Lakehouse/LakehouseDataProduct.d.ts.map +0 -1
- package/lib/components/Lakehouse/LakehouseDataProduct.js.map +0 -1
- package/lib/components/Lakehouse/LakehouseHeader.d.ts.map +0 -1
- package/lib/components/Lakehouse/LakehouseHeader.js.map +0 -1
- package/lib/components/Lakehouse/LakehouseMarketplace.d.ts.map +0 -1
- package/lib/components/Lakehouse/LakehouseMarketplace.js +0 -57
- package/lib/components/Lakehouse/LakehouseMarketplace.js.map +0 -1
- package/lib/components/Lakehouse/MarketLakehouseStoreProvider.d.ts.map +0 -1
- package/lib/components/Lakehouse/MarketLakehouseStoreProvider.js.map +0 -1
- package/lib/components/Lakehouse/entitlements/LakehouseEntitlements.d.ts.map +0 -1
- package/lib/components/Lakehouse/entitlements/LakehouseEntitlements.js +0 -147
- package/lib/components/Lakehouse/entitlements/LakehouseEntitlements.js.map +0 -1
- package/lib/components/Lakehouse/entitlements/LakehouseEntitlementsStoreProvider.d.ts.map +0 -1
- package/lib/components/Lakehouse/entitlements/LakehouseEntitlementsStoreProvider.js.map +0 -1
- package/lib/stores/MarketplaceLakehouseServerClient.d.ts +0 -25
- package/lib/stores/MarketplaceLakehouseServerClient.d.ts.map +0 -1
- package/lib/stores/MarketplaceLakehouseServerClient.js +0 -27
- package/lib/stores/MarketplaceLakehouseServerClient.js.map +0 -1
- package/lib/stores/lakehouse/entitlements/DataContractState.d.ts +0 -27
- package/lib/stores/lakehouse/entitlements/DataContractState.d.ts.map +0 -1
- package/lib/stores/lakehouse/entitlements/DataContractState.js +0 -115
- package/lib/stores/lakehouse/entitlements/DataContractState.js.map +0 -1
- package/src/components/Lakehouse/LakehouseMarketplace.tsx +0 -193
- package/src/components/Lakehouse/entitlements/LakehouseEntitlements.tsx +0 -332
- package/src/stores/MarketplaceLakehouseServerClient.ts +0 -40
- package/src/stores/lakehouse/entitlements/DataContractState.ts +0 -131
- /package/lib/{components → pages}/Lakehouse/DataProductDataAccess.d.ts +0 -0
- /package/lib/{components → pages}/Lakehouse/DataProductHolder.d.ts +0 -0
- /package/lib/{components → pages}/Lakehouse/DataProductHolder.js +0 -0
- /package/lib/{components → pages}/Lakehouse/DataProductViewer.d.ts +0 -0
- /package/lib/{components → pages}/Lakehouse/DataProductViewer.js +0 -0
- /package/lib/{components → pages}/Lakehouse/DataProductViewerActivityBar.d.ts +0 -0
- /package/lib/{components → pages}/Lakehouse/DataProductViewerActivityBar.js +0 -0
- /package/lib/{components → pages}/Lakehouse/DataProductWiki.d.ts +0 -0
- /package/lib/{components → pages}/Lakehouse/DataProductWiki.js +0 -0
- /package/lib/{components → pages}/Lakehouse/LakehouseDataProduct.d.ts +0 -0
- /package/lib/{components → pages}/Lakehouse/entitlements/LakehouseEntitlementsStoreProvider.d.ts +0 -0
- /package/lib/{components → pages}/Lakehouse/entitlements/LakehouseEntitlementsStoreProvider.js +0 -0
- /package/src/{components → pages}/Lakehouse/DataProductHolder.tsx +0 -0
- /package/src/{components → pages}/Lakehouse/DataProductViewer.tsx +0 -0
- /package/src/{components → pages}/Lakehouse/DataProductViewerActivityBar.tsx +0 -0
- /package/src/{components → pages}/Lakehouse/DataProductWiki.tsx +0 -0
- /package/src/{components/Lakehouse/MarketLakehouseStoreProvider.tsx → pages/Lakehouse/MarketplaceLakehouseStoreProvider.tsx} +0 -0
- /package/src/{components → pages}/Lakehouse/entitlements/LakehouseEntitlementsStoreProvider.tsx +0 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* Copyright (c) 2020-present, Goldman Sachs
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { createContext, useContext } from 'react';
|
|
18
|
+
import { useLocalObservable } from 'mobx-react-lite';
|
|
19
|
+
import { guaranteeNonNullable } from '@finos/legend-shared';
|
|
20
|
+
import { useLegendMarketplaceApplicationStore, useLegendMarketplaceBaseStore, } from '../../../application/LegendMarketplaceFrameworkProvider.js';
|
|
21
|
+
import { LakehouseSubscriptionsStore } from '../../../stores/lakehouse/subscriptions/LakehouseSubscriptionsStore.js';
|
|
22
|
+
const LakehouseSubscriptionsStoreContext = createContext(undefined);
|
|
23
|
+
export const LakehouseSubscriptionsStoreProvider = ({ children }) => {
|
|
24
|
+
const applicationStore = useLegendMarketplaceApplicationStore();
|
|
25
|
+
const baseStore = useLegendMarketplaceBaseStore();
|
|
26
|
+
const lakehouseServerClient = guaranteeNonNullable(baseStore.lakehouseServerClient, 'lakehouse server client required to render');
|
|
27
|
+
const store = useLocalObservable(() => new LakehouseSubscriptionsStore(applicationStore, lakehouseServerClient));
|
|
28
|
+
return (_jsx(LakehouseSubscriptionsStoreContext.Provider, { value: store, children: children }));
|
|
29
|
+
};
|
|
30
|
+
export const useLakehouseSubscriptionsStore = () => guaranteeNonNullable(useContext(LakehouseSubscriptionsStoreContext), `Can't find lakehouse subscriptions store in context`);
|
|
31
|
+
export const withLakehouseSubscriptionsStore = (WrappedComponent) => function WithLakehouseSubscriptionsStore() {
|
|
32
|
+
return (_jsx(LakehouseSubscriptionsStoreProvider, { children: _jsx(WrappedComponent, {}) }));
|
|
33
|
+
};
|
|
34
|
+
//# sourceMappingURL=LakehouseSubscriptionsStoreProvider.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LakehouseSubscriptionsStoreProvider.js","sourceRoot":"","sources":["../../../../src/pages/Lakehouse/subscriptions/LakehouseSubscriptionsStoreProvider.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAClD,OAAO,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AACrD,OAAO,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAC;AAC5D,OAAO,EACL,oCAAoC,EACpC,6BAA6B,GAC9B,MAAM,4DAA4D,CAAC;AACpE,OAAO,EAAE,2BAA2B,EAAE,MAAM,wEAAwE,CAAC;AAErH,MAAM,kCAAkC,GAAG,aAAa,CAEtD,SAAS,CAAC,CAAC;AAEb,MAAM,CAAC,MAAM,mCAAmC,GAE3C,CAAC,EAAE,QAAQ,EAAE,EAAE,EAAE;IACpB,MAAM,gBAAgB,GAAG,oCAAoC,EAAE,CAAC;IAChE,MAAM,SAAS,GAAG,6BAA6B,EAAE,CAAC;IAClD,MAAM,qBAAqB,GAAG,oBAAoB,CAChD,SAAS,CAAC,qBAAqB,EAC/B,4CAA4C,CAC7C,CAAC;IACF,MAAM,KAAK,GAAG,kBAAkB,CAC9B,GAAG,EAAE,CACH,IAAI,2BAA2B,CAAC,gBAAgB,EAAE,qBAAqB,CAAC,CAC3E,CAAC;IACF,OAAO,CACL,KAAC,kCAAkC,CAAC,QAAQ,IAAC,KAAK,EAAE,KAAK,YACtD,QAAQ,GACmC,CAC/C,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,8BAA8B,GAAG,GAAgC,EAAE,CAC9E,oBAAoB,CAClB,UAAU,CAAC,kCAAkC,CAAC,EAC9C,qDAAqD,CACtD,CAAC;AAEJ,MAAM,CAAC,MAAM,+BAA+B,GAAG,CAC7C,gBAA0B,EAChB,EAAE,CACZ,SAAS,+BAA+B;IACtC,OAAO,CACL,KAAC,mCAAmC,cAClC,KAAC,gBAAgB,KAAG,GACgB,CACvC,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2020-present, Goldman Sachs
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import type React from 'react';
|
|
17
|
+
export declare const LegendMarketplacePage: ((props: {
|
|
18
|
+
className?: string;
|
|
19
|
+
children: React.ReactNode;
|
|
20
|
+
}) => import("react/jsx-runtime").JSX.Element) & {
|
|
21
|
+
displayName: string;
|
|
22
|
+
};
|
|
23
|
+
//# sourceMappingURL=LegendMarketplacePage.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LegendMarketplacePage.d.ts","sourceRoot":"","sources":["../../src/pages/LegendMarketplacePage.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAIH,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,eAAO,MAAM,qBAAqB,WACxB;IAAE,SAAS,CAAC,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;CAAE;;CAI1D,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* Copyright (c) 2020-present, Goldman Sachs
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { clsx } from '@finos/legend-art';
|
|
18
|
+
import { observer } from 'mobx-react-lite';
|
|
19
|
+
export const LegendMarketplacePage = observer((props) => {
|
|
20
|
+
const { className, children } = props;
|
|
21
|
+
return _jsx("div", { className: clsx('app__page', className), children: children });
|
|
22
|
+
});
|
|
23
|
+
//# sourceMappingURL=LegendMarketplacePage.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LegendMarketplacePage.js","sourceRoot":"","sources":["../../src/pages/LegendMarketplacePage.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AACzC,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAG3C,MAAM,CAAC,MAAM,qBAAqB,GAAG,QAAQ,CAC3C,CAAC,KAAwD,EAAE,EAAE;IAC3D,MAAM,EAAE,SAAS,EAAE,QAAQ,EAAE,GAAG,KAAK,CAAC;IACtC,OAAO,cAAK,SAAS,EAAE,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,YAAG,QAAQ,GAAO,CAAC;AACxE,CAAC,CACF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LegendMarketplaceSearchResults.d.ts","sourceRoot":"","sources":["../../../src/pages/SearchResults/LegendMarketplaceSearchResults.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAmBH,eAAO,MAAM,8BAA8B;;
|
|
1
|
+
{"version":3,"file":"LegendMarketplaceSearchResults.d.ts","sourceRoot":"","sources":["../../../src/pages/SearchResults/LegendMarketplaceSearchResults.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAmBH,eAAO,MAAM,8BAA8B;;CAoHzC,CAAC"}
|
|
@@ -16,7 +16,6 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
16
16
|
*/
|
|
17
17
|
import { observer } from 'mobx-react-lite';
|
|
18
18
|
import { LegendMarketplaceSearchBar } from '../../components/SearchBar/LegendMarketplaceSearchBar.js';
|
|
19
|
-
import { LegendMarketplaceHeader } from '../../components/Header/LegendMarketplaceHeader.js';
|
|
20
19
|
import { useApplicationStore } from '@finos/legend-application';
|
|
21
20
|
import { generateSearchResultsRoute } from '../../__lib__/LegendMarketplaceNavigation.js';
|
|
22
21
|
import { DataProductSearchResult } from '@finos/legend-server-marketplace';
|
|
@@ -27,6 +26,7 @@ import { assertErrorThrown } from '@finos/legend-shared';
|
|
|
27
26
|
import { LegendMarketplaceSearchResultDrawerContent } from './LegendMarketplaceSearchResultDrawerContent.js';
|
|
28
27
|
import { Drawer, Grid2 as Grid } from '@mui/material';
|
|
29
28
|
import { LegendMarketplaceProductSearchCard } from '../../components/DataProductCard/LegendMarketplaceDataProductSearchCard.js';
|
|
29
|
+
import { LegendMarketplacePage } from '../LegendMarketplacePage.js';
|
|
30
30
|
export const LegendMarketplaceSearchResults = observer(() => {
|
|
31
31
|
const applicationStore = useApplicationStore();
|
|
32
32
|
const store = useLegendMarketplaceBaseStore();
|
|
@@ -59,17 +59,17 @@ export const LegendMarketplaceSearchResults = observer(() => {
|
|
|
59
59
|
const onSearch = (provider, query) => {
|
|
60
60
|
applicationStore.navigationService.navigator.goToLocation(generateSearchResultsRoute(provider, query));
|
|
61
61
|
};
|
|
62
|
-
return (
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
62
|
+
return (_jsxs(LegendMarketplacePage, { className: "legend-marketplace-search-results", children: [_jsx("div", { className: "legend-marketplace-search-results__search-bar", children: _jsx(LegendMarketplaceSearchBar, { onSearch: onSearch, initialValue: params.query?.trim() ?? '' }) }), _jsxs("div", { className: "legend-marketplace-search-results__results", children: [_jsx(CubesLoadingIndicator, { isLoading: isLoading, children: _jsx(CubesLoadingIndicatorIcon, {}) }), isError ? (_jsx("div", { children: "Error loading results" })) : (_jsx(Grid, { container: true, spacing: { xs: 4 }, columns: { xs: 1, sm: 2, lg: 3, xxl: 4, xxxl: 5, xxxxl: 6 }, className: "legend-marketplace-search-results__results__cards", children: results.map((result) => (_jsx(Grid, { size: 1, children: _jsx(LegendMarketplaceProductSearchCard, { productSearchResult: result, onPreviewClick: () => {
|
|
63
|
+
setSelectedPreviewResult(result);
|
|
64
|
+
}, onLearnMoreClick: () => {
|
|
65
|
+
applicationStore.navigationService.navigator.visitAddress(result.data_product_link);
|
|
66
|
+
} }) }, `${result.vendor_name}-${result.data_product_name}`))) }))] }), _jsx(Drawer, { anchor: "right", open: selectedPreviewResult !== undefined, onClose: () => setSelectedPreviewResult(undefined), slotProps: {
|
|
67
|
+
paper: {
|
|
68
|
+
sx: {
|
|
69
|
+
width: '40%',
|
|
70
|
+
maxWidth: '100rem',
|
|
71
|
+
},
|
|
72
|
+
},
|
|
73
|
+
}, children: _jsx(LegendMarketplaceSearchResultDrawerContent, { productSearchResult: selectedPreviewResult }) })] }));
|
|
74
74
|
});
|
|
75
75
|
//# sourceMappingURL=LegendMarketplaceSearchResults.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LegendMarketplaceSearchResults.js","sourceRoot":"","sources":["../../../src/pages/SearchResults/LegendMarketplaceSearchResults.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAC3C,OAAO,EAAE,0BAA0B,EAAE,MAAM,0DAA0D,CAAC;AACtG,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"LegendMarketplaceSearchResults.js","sourceRoot":"","sources":["../../../src/pages/SearchResults/LegendMarketplaceSearchResults.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;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C,SAAS,CAAC,EAClD,SAAS,EAAE;oBACT,KAAK,EAAE;wBACL,EAAE,EAAE;4BACF,KAAK,EAAE,KAAK;4BACZ,QAAQ,EAAE,QAAQ;yBACnB;qBACF;iBACF,YAED,KAAC,0CAA0C,IACzC,mBAAmB,EAAE,qBAAqB,GAC1C,GACK,IACa,CACzB,CAAC;AACJ,CAAC,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LegendMarketplaceVendorData.d.ts","sourceRoot":"","sources":["../../../src/pages/VendorData/LegendMarketplaceVendorData.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAmBH,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,kDAAkD,CAAC;
|
|
1
|
+
{"version":3,"file":"LegendMarketplaceVendorData.d.ts","sourceRoot":"","sources":["../../../src/pages/VendorData/LegendMarketplaceVendorData.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAmBH,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,kDAAkD,CAAC;AAIzG,eAAO,MAAM,0BAA0B;;CAsBrC,CAAC;AA2CH,eAAO,MAAM,qBAAqB,WACxB;IAAE,0BAA0B,EAAE,gCAAgC,CAAA;CAAE;;CAgDzE,CAAC;AAEF,eAAO,MAAM,2BAA2B;;CAmDtC,CAAC"}
|
|
@@ -15,14 +15,14 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
17
|
import { observer } from 'mobx-react-lite';
|
|
18
|
-
import { LegendMarketplaceHeader } from '../../components/Header/LegendMarketplaceHeader.js';
|
|
19
18
|
import { useEffect, useState } from 'react';
|
|
20
19
|
import { LegendMarketplaceSearchBar } from '../../components/SearchBar/LegendMarketplaceSearchBar.js';
|
|
21
|
-
import { Badge, Button, ButtonGroup, Checkbox, FormControlLabel, FormGroup, Typography, } from '@mui/material';
|
|
20
|
+
import { Badge, Button, ButtonGroup, Checkbox, FormControlLabel, FormGroup, Grid2 as Grid, Typography, } from '@mui/material';
|
|
22
21
|
import { flowResult } from 'mobx';
|
|
23
22
|
import { useApplicationStore } from '@finos/legend-application';
|
|
24
23
|
import { LegendMarketplaceProviderCard } from '../../components/ProviderCard/LegendMarketplaceProviderCard.js';
|
|
25
24
|
import { useLegendMarketplaceBaseStore } from '../../application/LegendMarketplaceFrameworkProvider.js';
|
|
25
|
+
import { LegendMarketplacePage } from '../LegendMarketplacePage.js';
|
|
26
26
|
export const RefinedVendorRadioSelector = observer(() => {
|
|
27
27
|
const radioOptions = ['All', 'Datafeeds', 'Terminal License', 'Add-Ons'];
|
|
28
28
|
const [selected, setSelected] = useState(radioOptions[0] ?? 'All');
|
|
@@ -37,7 +37,7 @@ const SearchResultsRenderer = observer((props) => {
|
|
|
37
37
|
const onAddToCartClick = (providerResult) => {
|
|
38
38
|
applicationStore.notificationService.notifySuccess(`'${providerResult.productName}' is added to your cart`);
|
|
39
39
|
};
|
|
40
|
-
return (_jsxs("div", { children: [_jsxs("div", { className: "legend-marketplace-vendordata-main-search-results__category", children: [_jsx("div", { className: "legend-marketplace-vendordata-main-sidebar__title", children: sectionTitle }), _jsx("a", { href: "#", className: "see-all", children: _jsx("strong", { children: "See All>" }) })] }), _jsx(
|
|
40
|
+
return (_jsxs("div", { children: [_jsxs("div", { className: "legend-marketplace-vendordata-main-search-results__category", children: [_jsx("div", { className: "legend-marketplace-vendordata-main-sidebar__title", children: sectionTitle }), _jsx("a", { href: "#", className: "see-all", children: _jsx("strong", { children: "See All>" }) })] }), _jsx(Grid, { container: true, spacing: { xs: 4 }, columns: { xs: 1, sm: 2, lg: 3, xxl: 4, xxxl: 5, xxxxl: 6 }, className: "legend-marketplace-vendordata-main-search-results__card-group", children: providerResults.map((provider) => (_jsx(Grid, { size: 1, children: _jsx(LegendMarketplaceProviderCard, { providerResult: provider, onAddToCartClick: () => onAddToCartClick(provider) }) }, provider.id))) })] }));
|
|
41
41
|
});
|
|
42
42
|
export const VendorDataMainContent = observer((props) => {
|
|
43
43
|
const { marketPlaceVendorDataState } = props;
|
|
@@ -53,8 +53,8 @@ export const LegendMarketPlaceVendorData = observer(() => {
|
|
|
53
53
|
useEffect(() => {
|
|
54
54
|
flowResult(marketPlaceVendorDataState.populateProviders()).catch(applicationStore.alertUnhandledError);
|
|
55
55
|
}, [marketPlaceVendorDataState, applicationStore]);
|
|
56
|
-
return (
|
|
57
|
-
|
|
58
|
-
|
|
56
|
+
return (_jsxs(LegendMarketplacePage, { className: "legend-marketplace-vendor-data", children: [_jsxs("div", { className: "legend-marketplace-banner", children: [_jsx("div", { className: "legend-marketplace-banner__title", children: "Vendor Data" }), _jsx("div", { className: "legend-marketplace-banner__subtitle", children: _jsx("p", { children: "Discover high quality data" }) })] }), _jsxs("div", { className: "legend-marketplace-new-datasets", children: [_jsx("h3", { children: "Recently Onboarded" }), _jsx("div", { className: "legend-marketplace-new-datasets__buttons", children: marketPlaceVendorDataState.dataFeedProviders
|
|
57
|
+
.slice(0, 10)
|
|
58
|
+
.map((vendor) => (_jsx(Badge, { className: "legend-marketplace-new-datasets__providers", title: vendor.productName, children: vendor.productName }, vendor.id))) })] }), _jsxs("div", { className: "legend-marketplace-body__content", children: [_jsx(RefinedVendorRadioSelector, {}), _jsx(LegendMarketplaceSearchBar, { onSearch: onChange }), _jsx(VendorDataMainContent, { marketPlaceVendorDataState: marketPlaceVendorDataState })] })] }));
|
|
59
59
|
});
|
|
60
60
|
//# sourceMappingURL=LegendMarketplaceVendorData.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LegendMarketplaceVendorData.js","sourceRoot":"","sources":["../../../src/pages/VendorData/LegendMarketplaceVendorData.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAC3C,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"Legend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13,7 +13,7 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import type { V1_ContractCreate_LegendDataProduct, V1_DataContract, V1_DataContractsRecord,
|
|
16
|
+
import type { V1_ContractCreate_LegendDataProduct, V1_CreateSubscriptionInput, V1_DataContract, V1_DataContractsRecord, V1_DataSubscriptionResponse, V1_PendingTasksRespond, V1_TaskStatus, V1_UserPendingContractsResponse } from '@finos/legend-graph';
|
|
17
17
|
import { AbstractServerClient, type PlainObject } from '@finos/legend-shared';
|
|
18
18
|
export interface LakehouseContractServerClientConfig {
|
|
19
19
|
baseUrl: string;
|
|
@@ -24,14 +24,21 @@ export declare class LakehouseContractServerClient extends AbstractServerClient
|
|
|
24
24
|
private _contracts;
|
|
25
25
|
getDataProducts: (token?: string | undefined) => Promise<PlainObject[]>;
|
|
26
26
|
private _dataContracts;
|
|
27
|
-
getPendingContracts: (token?: string | undefined) => Promise<PlainObject[]>;
|
|
28
27
|
getDataContracts: (token: string | undefined) => Promise<PlainObject<V1_DataContractsRecord>>;
|
|
29
28
|
getDataContract: (id: string, token: string | undefined) => Promise<PlainObject<V1_DataContractsRecord>>;
|
|
29
|
+
getApprovedUsersForDataContract: (id: string, token: string | undefined) => Promise<PlainObject<V1_DataContractsRecord>>;
|
|
30
30
|
getDataContractsFromDID: (body: PlainObject<AppendMode>[], token: string | undefined) => Promise<PlainObject<V1_DataContractsRecord>>;
|
|
31
|
-
|
|
31
|
+
getPendingContracts: (user: string | undefined, token: string | undefined) => Promise<PlainObject<V1_UserPendingContractsResponse>>;
|
|
32
|
+
createContract: (contractRequest: PlainObject<V1_ContractCreate_LegendDataProduct>, token: string | undefined) => Promise<V1_DataContract>;
|
|
32
33
|
private _tasks;
|
|
34
|
+
private _contract_tasks;
|
|
33
35
|
getPendingTasks: (user: string | undefined, token: string | undefined) => Promise<PlainObject<V1_PendingTasksRespond>>;
|
|
36
|
+
getTask: (taskId: string, token: string | undefined) => Promise<PlainObject<V1_PendingTasksRespond>>;
|
|
37
|
+
getContractTasks: (contractId: string, token: string | undefined) => Promise<PlainObject<V1_PendingTasksRespond>>;
|
|
34
38
|
approveTask: (id: string, token: string | undefined) => Promise<PlainObject<V1_TaskStatus>>;
|
|
35
|
-
|
|
39
|
+
denyTask: (id: string, token: string | undefined) => Promise<PlainObject<V1_TaskStatus>>;
|
|
40
|
+
private _subscriptions;
|
|
41
|
+
getAllSubscriptions: (token: string | undefined) => Promise<PlainObject<V1_DataSubscriptionResponse>[]>;
|
|
42
|
+
createSubscription: (input: PlainObject<V1_CreateSubscriptionInput>, token: string | undefined) => Promise<PlainObject<V1_DataSubscriptionResponse>>;
|
|
36
43
|
}
|
|
37
44
|
//# sourceMappingURL=LakehouseContractServerClient.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LakehouseContractServerClient.d.ts","sourceRoot":"","sources":["../../src/stores/LakehouseContractServerClient.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EACV,mCAAmC,EACnC,eAAe,EACf,sBAAsB,EACtB,aAAa,EACb,
|
|
1
|
+
{"version":3,"file":"LakehouseContractServerClient.d.ts","sourceRoot":"","sources":["../../src/stores/LakehouseContractServerClient.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EACV,mCAAmC,EACnC,0BAA0B,EAC1B,eAAe,EACf,sBAAsB,EACtB,2BAA2B,EAC3B,sBAAsB,EACtB,aAAa,EACb,+BAA+B,EAChC,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,oBAAoB,EAAE,KAAK,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAE9E,MAAM,WAAW,mCAAmC;IAClD,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,qBAAa,6BAA8B,SAAQ,oBAAoB;gBACzD,MAAM,EAAE,mCAAmC;IAOvD,OAAO,CAAC,MAAM,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M,EAClB,OAAO,MAAM,GAAG,SAAS,KACxB,OAAO,CAAC,WAAW,CAAC,sBAAsB,CAAC,CAAC,CAS7C;IAEF,WAAW,GACT,IAAI,MAAM,EACV,OAAO,MAAM,GAAG,SAAS,KACxB,OAAO,CAAC,WAAW,CAAC,aAAa,CAAC,CAAC,CAMlC;IAEJ,QAAQ,GACN,IAAI,MAAM,EACV,OAAO,MAAM,GAAG,SAAS,KACxB,OAAO,CAAC,WAAW,CAAC,aAAa,CAAC,CAAC,CAMlC;IAIJ,OAAO,CAAC,cAAc,CAAiD;IAEvE,mBAAmB,GACjB,OAAO,MAAM,GAAG,SAAS,KACxB,OAAO,CAAC,WAAW,CAAC,2BAA2B,CAAC,EAAE,CAAC,CACI;IAE1D,kBAAkB,GAChB,OAAO,WAAW,CAAC,0BAA0B,CAAC,EAC9C,OAAO,MAAM,GAAG,SAAS,KACxB,OAAO,CAAC,WAAW,CAAC,2BAA2B,CAAC,CAAC,CACmB;CACxE"}
|
|
@@ -28,21 +28,39 @@ export class LakehouseContractServerClient extends AbstractServerClient {
|
|
|
28
28
|
getDataProducts = (token) => this.get(`${this._contracts()}/dataProducts`, {}, this._token(token));
|
|
29
29
|
// ------------------------------------------- Data Contracts -------------------------------------------
|
|
30
30
|
_dataContracts = () => `${this.baseUrl}/datacontracts`;
|
|
31
|
-
getPendingContracts = (token) => this.get(`${this._dataContracts()}/pendingContractsForUser`, {}, this._token(token));
|
|
32
31
|
getDataContracts = (token) => this.get(this._dataContracts(), {}, this._token(token));
|
|
33
32
|
getDataContract = (id, token) => this.get(`${this._dataContracts()}/${encodeURIComponent(id)}`, {}, this._token(token));
|
|
33
|
+
getApprovedUsersForDataContract = (id, token) => this.get(`${this._dataContracts()}/${encodeURIComponent(id)}/approvedUsers`, {}, this._token(token));
|
|
34
34
|
getDataContractsFromDID = (body, token) => {
|
|
35
35
|
return this.post(`${this._dataContracts()}/query/accessPointsOwnedByDeployments`, body, undefined, this._token(token));
|
|
36
36
|
};
|
|
37
|
-
|
|
37
|
+
getPendingContracts = (user, token) => {
|
|
38
|
+
return this.get(`${this._dataContracts()}/pendingContractsForUser`, {}, this._token(token), { user });
|
|
39
|
+
};
|
|
40
|
+
createContract = (contractRequest, token) => this.post(`${this._dataContracts()}/alloyDataProduct`, contractRequest, undefined, this._token(token));
|
|
38
41
|
// ------------------------------------------- Tasks -------------------------------------------
|
|
39
42
|
_tasks = () => `${this.baseUrl}/datacontracts/tasks`;
|
|
43
|
+
_contract_tasks = () => `${this._tasks()}/query/contract`;
|
|
40
44
|
getPendingTasks = (user, token) => {
|
|
41
45
|
return this.get(`${this._tasks()}/pending`, {}, this._token(token), {
|
|
42
46
|
user,
|
|
43
47
|
});
|
|
44
48
|
};
|
|
49
|
+
getTask = (taskId, token) => {
|
|
50
|
+
return this.get(`${this._tasks()}/${encodeURIComponent(taskId)}`, {}, this._token(token), {
|
|
51
|
+
user: taskId,
|
|
52
|
+
});
|
|
53
|
+
};
|
|
54
|
+
getContractTasks = (contractId, token) => {
|
|
55
|
+
return this.get(`${this._contract_tasks()}/${encodeURIComponent(contractId)}`, {}, this._token(token), {
|
|
56
|
+
user: contractId,
|
|
57
|
+
});
|
|
58
|
+
};
|
|
45
59
|
approveTask = (id, token) => this.post(`${this._tasks()}/${encodeURIComponent(id)}/approve`, {}, {}, this._token(token));
|
|
46
|
-
|
|
60
|
+
denyTask = (id, token) => this.post(`${this._tasks()}/${encodeURIComponent(id)}/deny`, {}, {}, this._token(token));
|
|
61
|
+
// --------------------------------------- Subscriptions ---------------------------------------
|
|
62
|
+
_subscriptions = () => `${this.baseUrl}/subscriptions`;
|
|
63
|
+
getAllSubscriptions = (token) => this.get(this._subscriptions(), {}, this._token(token));
|
|
64
|
+
createSubscription = (input, token) => this.post(`${this._subscriptions()}`, input, {}, this._token(token));
|
|
47
65
|
}
|
|
48
66
|
//# sourceMappingURL=LakehouseContractServerClient.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LakehouseContractServerClient.js","sourceRoot":"","sources":["../../src/stores/LakehouseContractServerClient.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;
|
|
1
|
+
{"version":3,"file":"LakehouseContractServerClient.js","sourceRoot":"","sources":["../../src/stores/LakehouseContractServerClient.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAYH,OAAO,EAAE,oBAAoB,EAAoB,MAAM,sBAAsB,CAAC;AAM9E,MAAM,OAAO,6BAA8B,SAAQ,oBAAoB;IACrE,YAAY,MAA2C;QACrD,KAAK,CAAC;YACJ,OAAO,EAAE,MAAM,CAAC,OAAO;SACxB,CAAC,CAAC;IACL,CAAC;IAED,OAAO;IACC,MAAM,GAAG,CAAC,KAAc,EAAE,EAAE,CAAC,CAAC;QACpC,aAAa,EAAE,UAAU,KAAK,EAAE;KACjC,CAAC,CAAC;IAEK,UAAU,GAAG,GAAW,EAAE,CAAC,GAAG,IAAI,CAAC,OAAO,YAAY,CAAC;IAE/D,eAAe,GAAG,CAAC,KAA0B,EAA0B,EAAE,CACvE,IAAI,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC,UAAU,EAAE,eAAe,EAAE,EAAE,EAAE,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;IAExE,yGAAyG;IAEjG,cAAc,GAAG,GAAW,EAAE,CAAC,GAAG,IAAI,CAAC,OAAO,gBAAgB,CAAC;IAEvE,gBAAgB,GAAG,CACjB,KAAyB,EACqB,EAAE,CAChD,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,cAAc,EAAE,EAAE,EAAE,EAAE,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;IAE1D,eAAe,GAAG,CAChB,EAAU,EACV,KAAyB,EACqB,EAAE,CAChD,IAAI,CAAC,GAAG,CACN,GAAG,IAAI,CAAC,cAAc,EAAE,IAAI,kBAAkB,CAAC,EAAE,CAAC,EAAE,EACpD,EAAE,EACF,IAAI,CAAC,MAAM,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C4B,EAAE,CACvD,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,cAAc,EAAE,EAAE,EAAE,EAAE,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;IAE1D,kBAAkB,GAAG,CACnB,KAA8C,EAC9C,KAAyB,EAC0B,EAAE,CACrD,IAAI,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC,cAAc,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE,EAAE,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;CACxE"}
|
|
@@ -17,6 +17,7 @@ import { type GeneratorFn, ActionState } from '@finos/legend-shared';
|
|
|
17
17
|
import { type ApplicationStore } from '@finos/legend-application';
|
|
18
18
|
import { DepotServerClient } from '@finos/legend-server-depot';
|
|
19
19
|
import { MarketplaceServerClient } from '@finos/legend-server-marketplace';
|
|
20
|
+
import { type V1_EngineServerClient, V1_RemoteEngine } from '@finos/legend-graph';
|
|
20
21
|
import type { LegendMarketplaceApplicationConfig } from '../application/LegendMarketplaceApplicationConfig.js';
|
|
21
22
|
import type { LegendMarketplacePluginManager } from '../application/LegendMarketplacePluginManager.js';
|
|
22
23
|
import { LakehouseContractServerClient } from './LakehouseContractServerClient.js';
|
|
@@ -28,6 +29,8 @@ export declare class LegendMarketplaceBaseStore {
|
|
|
28
29
|
readonly depotServerClient: DepotServerClient;
|
|
29
30
|
readonly lakehouseServerClient: LakehouseContractServerClient | undefined;
|
|
30
31
|
readonly pluginManager: LegendMarketplacePluginManager;
|
|
32
|
+
readonly engineServerClient: V1_EngineServerClient;
|
|
33
|
+
readonly remoteEngine: V1_RemoteEngine;
|
|
31
34
|
readonly initState: ActionState;
|
|
32
35
|
marketplaceVendorDataState: LegendMarketPlaceVendorDataState;
|
|
33
36
|
constructor(applicationStore: LegendMarketplaceApplicationStore);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LegendMarketplaceBaseStore.d.ts","sourceRoot":"","sources":["../../src/stores/LegendMarketplaceBaseStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EACL,KAAK,WAAW,EAChB,WAAW,EAGZ,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACL,KAAK,gBAAgB,EAGtB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAC/D,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;
|
|
1
|
+
{"version":3,"file":"LegendMarketplaceBaseStore.d.ts","sourceRoot":"","sources":["../../src/stores/LegendMarketplaceBaseStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EACL,KAAK,WAAW,EAChB,WAAW,EAGZ,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACL,KAAK,gBAAgB,EAGtB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAC/D,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAC3E,OAAO,EAEL,KAAK,qBAAqB,EAC1B,eAAe,EAChB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,kCAAkC,EAAE,MAAM,sDAAsD,CAAC;AAC/G,OAAO,KAAK,EAAE,8BAA8B,EAAE,MAAM,kDAAkD,CAAC;AAEvG,OAAO,EAAE,6BAA6B,EAAE,MAAM,oCAAoC,CAAC;AACnF,OAAO,EAAE,gCAAgC,EAAE,MAAM,uCAAuC,CAAC;AAEzF,MAAM,MAAM,iCAAiC,GAAG,gBAAgB,CAC9D,kCAAkC,EAClC,8BAA8B,CAC/B,CAAC;AAEF,qBAAa,0BAA0B;IACrC,QAAQ,CAAC,gBAAgB,EAAE,iCAAiC,CAAC;IAC7D,QAAQ,CAAC,uBAAuB,EAAE,uBAAuB,CAAC;IAC1D,QAAQ,CAAC,iBAAiB,EAAE,iBAAiB,CAAC;IAC9C,QAAQ,CAAC,qBAAqB,EAAE,6BAA6B,GAAG,SAAS,CAAC;IAC1E,QAAQ,CAAC,aAAa,EAAE,8BAA8B,CAAC;IACvD,QAAQ,CAAC,kBAAkB,EAAE,qBAAqB,CAAC;IACnD,QAAQ,CAAC,YAAY,EAAE,eAAe,CAAC;IAEvC,QAAQ,CAAC,SAAS,cAAwB;IAE1C,0BAA0B,EAAE,gCAAgC,CAAC;gBAEjD,gBAAgB,EAAE,iCAAiC;IAiD9D,UAAU,IAAI,WAAW,CAAC,IAAI,CAAC;CAyCjC"}
|
|
@@ -18,7 +18,7 @@ import { LegendApplicationTelemetryHelper, APPLICATION_EVENT, } from '@finos/leg
|
|
|
18
18
|
import { flow, makeObservable } from 'mobx';
|
|
19
19
|
import { DepotServerClient } from '@finos/legend-server-depot';
|
|
20
20
|
import { MarketplaceServerClient } from '@finos/legend-server-marketplace';
|
|
21
|
-
import { getCurrentUserIDFromEngineServer } from '@finos/legend-graph';
|
|
21
|
+
import { getCurrentUserIDFromEngineServer, V1_RemoteEngine, } from '@finos/legend-graph';
|
|
22
22
|
import { LegendMarketplaceEventHelper } from '../__lib__/LegendMarketplaceEventHelper.js';
|
|
23
23
|
import { LakehouseContractServerClient } from './LakehouseContractServerClient.js';
|
|
24
24
|
import { LegendMarketPlaceVendorDataState } from './LegendMarketPlaceVendorDataState.js';
|
|
@@ -28,6 +28,8 @@ export class LegendMarketplaceBaseStore {
|
|
|
28
28
|
depotServerClient;
|
|
29
29
|
lakehouseServerClient;
|
|
30
30
|
pluginManager;
|
|
31
|
+
engineServerClient;
|
|
32
|
+
remoteEngine;
|
|
31
33
|
initState = ActionState.create();
|
|
32
34
|
marketplaceVendorDataState;
|
|
33
35
|
constructor(applicationStore) {
|
|
@@ -53,6 +55,11 @@ export class LegendMarketplaceBaseStore {
|
|
|
53
55
|
});
|
|
54
56
|
this.lakehouseServerClient.setTracerService(this.applicationStore.tracerService);
|
|
55
57
|
}
|
|
58
|
+
this.remoteEngine = new V1_RemoteEngine({
|
|
59
|
+
baseUrl: this.applicationStore.config.engineServerUrl,
|
|
60
|
+
}, applicationStore.logService);
|
|
61
|
+
this.engineServerClient = this.remoteEngine.getEngineServerClient();
|
|
62
|
+
this.engineServerClient.setTracerService(applicationStore.tracerService);
|
|
56
63
|
this.marketplaceVendorDataState = new LegendMarketPlaceVendorDataState(this.applicationStore, this);
|
|
57
64
|
}
|
|
58
65
|
*initialize() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LegendMarketplaceBaseStore.js","sourceRoot":"","sources":["../../src/stores/LegendMarketplaceBaseStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAEL,WAAW,EACX,QAAQ,EACR,iBAAiB,GAClB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAEL,gCAAgC,EAChC,iBAAiB,GAClB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,MAAM,MAAM,CAAC;AAC5C,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAC/D,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAC3E,OAAO,
|
|
1
|
+
{"version":3,"file":"LegendMarketplaceBaseStore.js","sourceRoot":"","sources":["../../src/stores/LegendMarketplaceBaseStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAEL,WAAW,EACX,QAAQ,EACR,iBAAiB,GAClB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAEL,gCAAgC,EAChC,iBAAiB,GAClB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,MAAM,MAAM,CAAC;AAC5C,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAC/D,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAC3E,OAAO,EACL,gCAAgC,EAE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AAC,UAAU,CAAC,KAAK,CACpC,QAAQ,CAAC,MAAM,CAAC,iBAAiB,CAAC,4BAA4B,CAAC,EAC/D,KAAK,CACN,CAAC;gBACF,IAAI,CAAC,gBAAgB,CAAC,mBAAmB,CAAC,aAAa,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;YACzE,CAAC;QACH,CAAC;QAED,0BAA0B;QAC1B,IAAI,CAAC,gBAAgB,CAAC,gBAAgB,CAAC,KAAK,EAAE,CAAC;QAE/C,gCAAgC,CAAC,2CAA2C,CAC1E,IAAI,CAAC,gBAAgB,CAAC,gBAAgB,EACtC,IAAI,CAAC,gBAAgB,CACtB,CAAC;QAEF,4BAA4B,CAAC,+BAA+B,CAC1D,IAAI,CAAC,gBAAgB,CAAC,YAAY,CACnC,CAAC;QAEF,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,CAAC;IAC5B,CAAC;CACF"}
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import {
|
|
16
|
+
import type { V1_DataContract, V1_AccessPointGroup, V1_DataProduct } from '@finos/legend-graph';
|
|
17
17
|
import type { DataProductViewerState } from './DataProductViewerState.js';
|
|
18
18
|
import { ActionState, type GeneratorFn } from '@finos/legend-shared';
|
|
19
19
|
export declare enum DataProductGroupAccess {
|
|
@@ -26,15 +26,14 @@ export declare class DataProductGroupAccessState {
|
|
|
26
26
|
readonly accessState: DataProductDataAccessState;
|
|
27
27
|
readonly group: V1_AccessPointGroup;
|
|
28
28
|
id: string;
|
|
29
|
-
access: DataProductGroupAccess;
|
|
30
29
|
fetchingAccessState: ActionState;
|
|
31
30
|
requestingAccessState: ActionState;
|
|
31
|
+
associatedContract: V1_DataContract | undefined | false;
|
|
32
32
|
constructor(group: V1_AccessPointGroup, accessState: DataProductDataAccessState);
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
goToEtask(): GeneratorFn<void>;
|
|
33
|
+
get access(): DataProductGroupAccess;
|
|
34
|
+
setAssociatedContract(val: V1_DataContract | undefined): void;
|
|
35
|
+
handleDataProductContracts(contracts: V1_DataContract[]): void;
|
|
36
|
+
handleClick(): void;
|
|
38
37
|
}
|
|
39
38
|
export declare class DataProductDataAccessState {
|
|
40
39
|
readonly viewerState: DataProductViewerState;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataProductDataAccessState.d.ts","sourceRoot":"","sources":["../../../src/stores/lakehouse/DataProductDataAccessState.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"DataProductDataAccessState.d.ts","sourceRoot":"","sources":["../../../src/stores/lakehouse/DataProductDataAccessState.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EACV,eAAe,EACf,mBAAmB,EACnB,cAAc,EACf,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AAC1E,OAAO,EACL,WAAW,EAGX,KAAK,WAAW,EACjB,MAAM,sBAAsB,CAAC;AAgB9B,oBAAY,sBAAsB;IAEhC,OAAO,YAAY;IAEnB,OAAO,YAAY;IACnB,SAAS,cAAc;IACvB,SAAS,cAAc;CACxB;AAmBD,qBAAa,2BAA2B;IACtC,QAAQ,CAAC,WAAW,EAAE,0BAA0B,CAAC;IACjD,QAAQ,CAAC,KAAK,EAAE,mBAAmB,CAAC;IACpC,EAAE,SAAU;IAEZ,mBAAmB,cAAwB;IAC3C,qBAAqB,cAAwB;IAI7C,kBAAkB,EAAE,eAAe,GAAG,SAAS,GAAG,KAAK,CAAS;gBAG9D,KAAK,EAAE,mBAAmB,EAC1B,WAAW,EAAE,0BAA0B;IAazC,IAAI,MAAM,IAAI,sBAAsB,CASnC;IAED,qBAAqB,CAAC,GAAG,EAAE,eAAe,GAAG,SAAS,GAAG,IAAI;IAI7D,0BAA0B,CAAC,SAAS,EAAE,eAAe,EAAE,GAAG,IAAI;IAiB9D,WAAW,IAAI,IAAI;CAYpB;AAED,qBAAa,0BAA0B;IACrC,QAAQ,CAAC,WAAW,EAAE,sBAAsB,CAAC;IAC7C,iBAAiB,EAAE,2BAA2B,EAAE,CAAC;IACjD,8BAA8B,cAAwB;gBAE1C,WAAW,EAAE,sBAAsB;IAa9C,eAAe,IAAI,WAAW,CAAC,IAAI,CAAC;IAYrC,IAAI,OAAO,IAAI,cAAc,CAE5B;CACF"}
|
|
@@ -13,9 +13,10 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import {} from '@finos/legend-
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
16
|
+
import { ActionState, assertErrorThrown, uuid, } from '@finos/legend-shared';
|
|
17
|
+
import { action, flow, makeAutoObservable, makeObservable, observable, } from 'mobx';
|
|
18
|
+
import { dataContractContainsAccessGroup, isContractCompleted, isContractPending, isMemberOfContract, } from './LakehouseUtils.js';
|
|
19
|
+
import { generateLakehouseContractPath } from '../../__lib__/LegendMarketplaceNavigation.js';
|
|
19
20
|
export var DataProductGroupAccess;
|
|
20
21
|
(function (DataProductGroupAccess) {
|
|
21
22
|
// can be used to indicate fetching or resyncing of group access
|
|
@@ -27,64 +28,67 @@ export var DataProductGroupAccess;
|
|
|
27
28
|
const generatePromise = (time) => {
|
|
28
29
|
return new Promise((resolve) => setTimeout(resolve, time ?? 5000));
|
|
29
30
|
};
|
|
31
|
+
const getDataProductGroupAccessFromContract = (val) => {
|
|
32
|
+
if (isContractCompleted(val)) {
|
|
33
|
+
return DataProductGroupAccess.COMPLETED;
|
|
34
|
+
}
|
|
35
|
+
if (isContractPending(val)) {
|
|
36
|
+
return DataProductGroupAccess.PENDING;
|
|
37
|
+
}
|
|
38
|
+
return DataProductGroupAccess.UNKNOWN;
|
|
39
|
+
};
|
|
30
40
|
export class DataProductGroupAccessState {
|
|
31
41
|
accessState;
|
|
32
42
|
group;
|
|
33
43
|
id = uuid();
|
|
34
|
-
access = DataProductGroupAccess.UNKNOWN;
|
|
35
44
|
fetchingAccessState = ActionState.create();
|
|
36
45
|
requestingAccessState = ActionState.create();
|
|
46
|
+
// ASSUMPTION: one contract per user per group;
|
|
47
|
+
// false here mentions contracts have not been fetched
|
|
48
|
+
associatedContract = false;
|
|
37
49
|
constructor(group, accessState) {
|
|
38
50
|
this.group = group;
|
|
39
51
|
this.accessState = accessState;
|
|
40
52
|
makeAutoObservable(this, {
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
requestAccess: flow,
|
|
44
|
-
handleClick: flow,
|
|
45
|
-
goToEtask: flow,
|
|
53
|
+
handleClick: action,
|
|
54
|
+
handleDataProductContracts: action,
|
|
46
55
|
requestingAccessState: observable,
|
|
56
|
+
associatedContract: observable,
|
|
57
|
+
setAssociatedContract: action,
|
|
47
58
|
});
|
|
48
59
|
}
|
|
49
|
-
|
|
50
|
-
this.
|
|
51
|
-
|
|
52
|
-
fetchGroupAccess() { }
|
|
53
|
-
*handleClick() {
|
|
54
|
-
if (this.access === DataProductGroupAccess.NO_ACCESS) {
|
|
55
|
-
flowResult(this.requestAccess()).catch(this.accessState.viewerState.applicationStore.alertUnhandledError);
|
|
56
|
-
}
|
|
57
|
-
else if (this.access === DataProductGroupAccess.PENDING) {
|
|
58
|
-
flowResult(this.goToEtask()).catch(this.accessState.viewerState.applicationStore.alertUnhandledError);
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
*requestAccess() {
|
|
62
|
-
try {
|
|
63
|
-
this.requestingAccessState.inProgress();
|
|
64
|
-
this.accessState.viewerState.applicationStore.alertService.setBlockingAlert({
|
|
65
|
-
message: 'Requesting Access...',
|
|
66
|
-
showLoading: true,
|
|
67
|
-
});
|
|
68
|
-
assertTrue(this.access === DataProductGroupAccess.NO_ACCESS, `Access Group must be in no access state to request access`);
|
|
69
|
-
yield generatePromise();
|
|
70
|
-
this.setAccess(DataProductGroupAccess.PENDING);
|
|
60
|
+
get access() {
|
|
61
|
+
if (this.associatedContract === false) {
|
|
62
|
+
return DataProductGroupAccess.UNKNOWN;
|
|
71
63
|
}
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
this.requestingAccessState.complete();
|
|
64
|
+
if (this.associatedContract) {
|
|
65
|
+
return getDataProductGroupAccessFromContract(this.associatedContract);
|
|
75
66
|
}
|
|
76
|
-
|
|
77
|
-
|
|
67
|
+
else {
|
|
68
|
+
return DataProductGroupAccess.NO_ACCESS;
|
|
78
69
|
}
|
|
79
70
|
}
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
71
|
+
setAssociatedContract(val) {
|
|
72
|
+
this.associatedContract = val;
|
|
73
|
+
}
|
|
74
|
+
handleDataProductContracts(contracts) {
|
|
75
|
+
const groupContracts = contracts
|
|
76
|
+
.filter((_contract) => dataContractContainsAccessGroup(this.group, _contract))
|
|
77
|
+
.filter((_contract) => isMemberOfContract(this.accessState.viewerState.applicationStore.identityService
|
|
78
|
+
.currentUser, _contract));
|
|
79
|
+
// ASSUMPTION: one contract per user per group
|
|
80
|
+
const userContract = groupContracts[0];
|
|
81
|
+
this.setAssociatedContract(userContract);
|
|
82
|
+
}
|
|
83
|
+
handleClick() {
|
|
84
|
+
if (this.access === DataProductGroupAccess.NO_ACCESS) {
|
|
85
|
+
this.accessState.viewerState.setDataContractAccessPointGroup(this.group);
|
|
85
86
|
}
|
|
86
|
-
|
|
87
|
-
|
|
87
|
+
else if (this.access === DataProductGroupAccess.PENDING) {
|
|
88
|
+
const associatedContract = this.associatedContract;
|
|
89
|
+
if (associatedContract) {
|
|
90
|
+
this.accessState.viewerState.applicationStore.navigationService.navigator.updateCurrentLocation(generateLakehouseContractPath(associatedContract.guid));
|
|
91
|
+
}
|
|
88
92
|
}
|
|
89
93
|
}
|
|
90
94
|
}
|
|
@@ -106,11 +110,6 @@ export class DataProductDataAccessState {
|
|
|
106
110
|
// dummy fetch to get access
|
|
107
111
|
this.fetchingDataProductAccessState.inProgress();
|
|
108
112
|
yield generatePromise();
|
|
109
|
-
if (this.accessGroupStates.length === 3) {
|
|
110
|
-
this.accessGroupStates[0]?.setAccess(DataProductGroupAccess.NO_ACCESS);
|
|
111
|
-
this.accessGroupStates[1]?.setAccess(DataProductGroupAccess.PENDING);
|
|
112
|
-
this.accessGroupStates[2]?.setAccess(DataProductGroupAccess.COMPLETED);
|
|
113
|
-
}
|
|
114
113
|
}
|
|
115
114
|
catch (error) {
|
|
116
115
|
assertErrorThrown(error);
|