@finos/legend-application-marketplace
Version:
Legend Marketplace application core
54 lines • 3.21 kB
TypeScript
/**
* Copyright (c) 2020-present, Goldman Sachs
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { DataContractViewerState, PermitDataAccessRequestState } from '@finos/legend-extension-dsl-data-product';
import { V1_LiteDataContractWithUserStatus, type V1_DataRequestWithWorkflow } from '@finos/legend-graph';
import type { DataGridColumnDefinition } from '@finos/legend-lego/data-grid';
import type { ContractCreatedByUserDetails, EntitlementsDashboardState } from '../stores/lakehouse/entitlements/EntitlementsDashboardState.js';
export declare const UNKNOWN = "Unknown";
export declare const ROW_KIND_CONTRACT = "contract";
export declare const ROW_KIND_REQUEST = "request";
export declare enum EntitlementsColumnHeader {
TYPE = "Type",
DATE_CREATED = "Date Created",
CONSUMER_TYPE = "Consumer Type",
TARGET_USERS = "Target User(s)",
REQUESTER = "Requester",
TARGET_DATA_PRODUCT = "Target Data Product",
TARGET_ACCESS_POINT_GROUP = "Target Access Point Group",
BUSINESS_JUSTIFICATION = "Business Justification",
STATE = "State",
ASSIGNEES = "Assignees"
}
export declare const CONTRACT_STATE_DISPLAY_LABELS: Record<string, string>;
export declare const TERMINAL_DATA_REQUEST_STATES: Set<string>;
export declare const ENTITLEMENTS_DEFAULT_COL_DEF: DataGridColumnDefinition<EntitlementsRow>;
export type EntitlementsRow = {
kind: 'contract';
data: V1_LiteDataContractWithUserStatus | ContractCreatedByUserDetails;
} | {
kind: 'request';
data: V1_DataRequestWithWorkflow;
};
export declare const getContractData: (row: EntitlementsRow) => import("@finos/legend-graph").V1_LiteDataContract | undefined;
export declare const getRequestData: (row: EntitlementsRow) => import("@finos/legend-graph").V1_DataRequest | undefined;
export declare const getSelectedRowId: (row: EntitlementsRow | undefined) => string | undefined;
export declare const getSelectedContractGuid: (row: EntitlementsRow | undefined) => string | undefined;
export declare const getOpenTaskAssignees: (data: V1_DataRequestWithWorkflow) => string[];
export declare const getConsumer: (row: EntitlementsRow) => import("@finos/legend-graph").V1_OrganizationalScope | undefined;
export declare const getCommonEntitlementsColDefs: (dashboardState: EntitlementsDashboardState) => DataGridColumnDefinition<EntitlementsRow>[];
export declare const useSelectedViewerState: (selectedRow: EntitlementsRow | undefined, selectedRowId: string | undefined) => DataContractViewerState | PermitDataAccessRequestState | undefined;
export declare const useGetDataProductUrl: () => ((dataProductId: string, deploymentId: number) => string);
//# sourceMappingURL=EntitlementsUtils.d.ts.map