@veloceapps/api 8.0.0-2 → 8.0.0-200
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/esm2020/index.mjs +10 -1
- package/esm2020/lib/api.module.mjs +32 -5
- package/esm2020/lib/services/account-api.service.mjs +11 -4
- package/esm2020/lib/services/auth.service.mjs +22 -0
- package/esm2020/lib/services/catalog-admin-api.service.mjs +3 -3
- package/esm2020/lib/services/catalog-api.service.mjs +3 -3
- package/esm2020/lib/services/configuration-api.service.mjs +48 -15
- package/esm2020/lib/services/configuration-processors-api.service.mjs +38 -0
- package/esm2020/lib/services/configuration-settings-api.service.mjs +3 -3
- package/esm2020/lib/services/context-api.service.mjs +3 -3
- package/esm2020/lib/services/contracted-price-api.service.mjs +45 -0
- package/esm2020/lib/services/delta-api.service.mjs +3 -3
- package/esm2020/lib/services/document-attachment-api.service.mjs +3 -3
- package/esm2020/lib/services/document-templates-api.service.mjs +9 -7
- package/esm2020/lib/services/endpoints-api.service.mjs +3 -3
- package/esm2020/lib/services/flow-state-api.mjs +142 -0
- package/esm2020/lib/services/flows-api.service.mjs +12 -8
- package/esm2020/lib/services/guided-sellings-admin-api.service.mjs +3 -3
- package/esm2020/lib/services/guided-sellings-api.service.mjs +3 -3
- package/esm2020/lib/services/offers-api.service.mjs +3 -3
- package/esm2020/lib/services/org-info-api.service.mjs +47 -12
- package/esm2020/lib/services/picklists-api.service.mjs +3 -3
- package/esm2020/lib/services/portals-api.service.mjs +76 -0
- package/esm2020/lib/services/price-api.service.mjs +3 -3
- package/esm2020/lib/services/procedures-api.service.mjs +10 -4
- package/esm2020/lib/services/product-api.service.mjs +3 -3
- package/esm2020/lib/services/product-model-api.service.mjs +3 -3
- package/esm2020/lib/services/promotions-api.service.mjs +68 -0
- package/esm2020/lib/services/quote-api.service.mjs +21 -5
- package/esm2020/lib/services/ramp-api.service.mjs +3 -3
- package/esm2020/lib/services/rebate-program-api.service.mjs +68 -0
- package/esm2020/lib/services/rebate-type-api.service.mjs +68 -0
- package/esm2020/lib/services/rule-groups-api.service.mjs +3 -3
- package/esm2020/lib/services/rules-api.service.mjs +20 -7
- package/esm2020/lib/services/salesforce-api.service.mjs +7 -5
- package/esm2020/lib/services/sandbox-manager-api.service.mjs +94 -0
- package/esm2020/lib/services/scripts-api.service.mjs +15 -8
- package/esm2020/lib/services/shopping-cart-settings-api.service.mjs +3 -3
- package/esm2020/lib/services/stateful-configuration-api.mjs +4 -4
- package/esm2020/lib/services/ui-definitions-api.service.mjs +3 -3
- package/esm2020/lib/services/ui-templates-api.service.mjs +9 -4
- package/esm2020/lib/services/veloce-objects-api.service.mjs +14 -4
- package/esm2020/lib/types/auth.types.mjs +2 -0
- package/esm2020/lib/types/index.mjs +3 -1
- package/esm2020/lib/types/org-info.types.mjs +1 -1
- package/esm2020/lib/types/quote.types.mjs +2 -0
- package/esm2020/lib/types/stateful-configuration.types.mjs +1 -1
- package/esm2020/lib/utils/canvas.utils.mjs +33 -0
- package/fesm2015/veloceapps-api.mjs +891 -143
- package/fesm2015/veloceapps-api.mjs.map +1 -1
- package/fesm2020/veloceapps-api.mjs +906 -139
- package/fesm2020/veloceapps-api.mjs.map +1 -1
- package/index.d.ts +9 -0
- package/lib/services/account-api.service.d.ts +2 -1
- package/lib/services/auth.service.d.ts +11 -0
- package/lib/services/configuration-api.service.d.ts +5 -0
- package/lib/services/configuration-processors-api.service.d.ts +14 -0
- package/lib/services/contracted-price-api.service.d.ts +16 -0
- package/lib/services/flow-state-api.d.ts +84 -0
- package/lib/services/flows-api.service.d.ts +1 -1
- package/lib/services/org-info-api.service.d.ts +13 -7
- package/lib/services/portals-api.service.d.ts +20 -0
- package/lib/services/procedures-api.service.d.ts +1 -0
- package/lib/services/promotions-api.service.d.ts +19 -0
- package/lib/services/quote-api.service.d.ts +13 -6
- package/lib/services/rebate-program-api.service.d.ts +19 -0
- package/lib/services/rebate-type-api.service.d.ts +19 -0
- package/lib/services/rules-api.service.d.ts +2 -1
- package/lib/services/salesforce-api.service.d.ts +1 -1
- package/lib/services/sandbox-manager-api.service.d.ts +24 -0
- package/lib/services/scripts-api.service.d.ts +2 -2
- package/lib/services/stateful-configuration-api.d.ts +2 -2
- package/lib/services/ui-templates-api.service.d.ts +1 -0
- package/lib/services/veloce-objects-api.service.d.ts +2 -1
- package/lib/types/auth.types.d.ts +4 -0
- package/lib/types/index.d.ts +2 -0
- package/lib/types/org-info.types.d.ts +19 -0
- package/lib/types/quote.types.d.ts +8 -0
- package/lib/types/stateful-configuration.types.d.ts +1 -1
- package/lib/utils/canvas.utils.d.ts +18 -0
- package/package.json +1 -1
package/index.d.ts
CHANGED
@@ -1,26 +1,34 @@
|
|
1
1
|
export { ApiModule } from './lib/api.module';
|
2
2
|
export { AccountApiService } from './lib/services/account-api.service';
|
3
|
+
export { VeloceAuthService } from './lib/services/auth.service';
|
3
4
|
export { CatalogAdminApiService } from './lib/services/catalog-admin-api.service';
|
4
5
|
export { CatalogApiService } from './lib/services/catalog-api.service';
|
5
6
|
export { ConfigurationApiService } from './lib/services/configuration-api.service';
|
7
|
+
export { ConfigurationProcessorsApiService } from './lib/services/configuration-processors-api.service';
|
6
8
|
export { ConfigurationSettingsApiService } from './lib/services/configuration-settings-api.service';
|
7
9
|
export { ContextApiService } from './lib/services/context-api.service';
|
10
|
+
export { ContractedPriceApiService } from './lib/services/contracted-price-api.service';
|
8
11
|
export { DeltaApiService } from './lib/services/delta-api.service';
|
9
12
|
export { DocumentAttachmentApiService } from './lib/services/document-attachment-api.service';
|
10
13
|
export { DocumentTemplatesApiService } from './lib/services/document-templates-api.service';
|
11
14
|
export { EndpointsApiService } from './lib/services/endpoints-api.service';
|
15
|
+
export { FlowStateApiService } from './lib/services/flow-state-api';
|
12
16
|
export { FlowsApiService } from './lib/services/flows-api.service';
|
13
17
|
export { GuidedSellingsAdminApiService } from './lib/services/guided-sellings-admin-api.service';
|
14
18
|
export { GuidedSellingApiService } from './lib/services/guided-sellings-api.service';
|
15
19
|
export { OffersApiService } from './lib/services/offers-api.service';
|
16
20
|
export { OrgInfoApiService } from './lib/services/org-info-api.service';
|
17
21
|
export { PicklistsApiService } from './lib/services/picklists-api.service';
|
22
|
+
export { PortalsApiService } from './lib/services/portals-api.service';
|
18
23
|
export { PriceApiService } from './lib/services/price-api.service';
|
19
24
|
export { ProceduresApiService } from './lib/services/procedures-api.service';
|
20
25
|
export { ProductApiService } from './lib/services/product-api.service';
|
21
26
|
export { ProductModelApiService } from './lib/services/product-model-api.service';
|
27
|
+
export { PromotionsApiService } from './lib/services/promotions-api.service';
|
22
28
|
export { QuoteApiService } from './lib/services/quote-api.service';
|
23
29
|
export { RampApiService } from './lib/services/ramp-api.service';
|
30
|
+
export { RebateProgramApiService } from './lib/services/rebate-program-api.service';
|
31
|
+
export { RebateTypeApiService } from './lib/services/rebate-type-api.service';
|
24
32
|
export { RuleGroupsApiService } from './lib/services/rule-groups-api.service';
|
25
33
|
export { RulesApiService } from './lib/services/rules-api.service';
|
26
34
|
export { SalesforceApiService } from './lib/services/salesforce-api.service';
|
@@ -30,4 +38,5 @@ export { StatefulConfigurationApiService } from './lib/services/stateful-configu
|
|
30
38
|
export { UIDefinitionsApiService } from './lib/services/ui-definitions-api.service';
|
31
39
|
export { UITemplatesApiService } from './lib/services/ui-templates-api.service';
|
32
40
|
export { VeloceObjectsApiService } from './lib/services/veloce-objects-api.service';
|
41
|
+
export { SandboxManagerApiService } from './lib/services/sandbox-manager-api.service';
|
33
42
|
export * from './lib/types';
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { Account, BaseHttpService, HttpRequestConfigurableOptions, LineItem, Order, Quote } from '@veloceapps/core';
|
1
|
+
import { Account, AccountAssetsState, BaseHttpService, HttpRequestConfigurableOptions, LineItem, Order, Quote } from '@veloceapps/core';
|
2
2
|
import { Observable } from 'rxjs';
|
3
3
|
import { QuerySearchParams } from '../types';
|
4
4
|
import * as i0 from "@angular/core";
|
@@ -9,6 +9,7 @@ export declare class AccountApiService {
|
|
9
9
|
getAccounts$(options?: HttpRequestConfigurableOptions): Observable<Account[]>;
|
10
10
|
searchAccounts$(searchParams?: QuerySearchParams, options?: HttpRequestConfigurableOptions): Observable<Account[]>;
|
11
11
|
getAccount$(id: string, options?: HttpRequestConfigurableOptions): Observable<Account>;
|
12
|
+
getAssetsState(accountId: string, options?: HttpRequestConfigurableOptions): Observable<AccountAssetsState>;
|
12
13
|
getAssets(accountId: string, options?: HttpRequestConfigurableOptions): Observable<LineItem[]>;
|
13
14
|
getOrders(accountId: string, options?: HttpRequestConfigurableOptions): Observable<Order[]>;
|
14
15
|
getQuotes(accountId: string, options?: HttpRequestConfigurableOptions): Observable<Quote[]>;
|
@@ -0,0 +1,11 @@
|
|
1
|
+
import { HttpClient } from '@angular/common/http';
|
2
|
+
import { Observable } from 'rxjs';
|
3
|
+
import { VeloceAuthResponse } from '../types';
|
4
|
+
import * as i0 from "@angular/core";
|
5
|
+
export declare class VeloceAuthService {
|
6
|
+
private http;
|
7
|
+
constructor(http: HttpClient);
|
8
|
+
auth$(instanceUrl: string, accessToken: string): Observable<VeloceAuthResponse>;
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<VeloceAuthService, never>;
|
10
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<VeloceAuthService>;
|
11
|
+
}
|
@@ -10,6 +10,11 @@ export declare class ConfigurationApiService {
|
|
10
10
|
runtimeModel?: RuntimeModel;
|
11
11
|
pricingEnabled?: boolean;
|
12
12
|
}): Observable<ConfigurePrice>;
|
13
|
+
customConfigurePrice({ url, configurationRequest, runtimeModel, }: {
|
14
|
+
url: string;
|
15
|
+
configurationRequest: ConfigurationRequest;
|
16
|
+
runtimeModel?: RuntimeModel;
|
17
|
+
}): Observable<ConfigurePrice>;
|
13
18
|
getRuntimeDataByProductId(productId: string, offeringId?: string): Observable<RuntimeData>;
|
14
19
|
getRuntimeDataByModelId(modelId: string): Observable<RuntimeData>;
|
15
20
|
private updatePortDomains;
|
@@ -0,0 +1,14 @@
|
|
1
|
+
import { BaseHttpService, ConfigurationProcessor } from '@veloceapps/core';
|
2
|
+
import { Observable } from 'rxjs';
|
3
|
+
import * as i0 from "@angular/core";
|
4
|
+
export declare class ConfigurationProcessorsApiService {
|
5
|
+
private baseHttpService;
|
6
|
+
private readonly serviceUrl;
|
7
|
+
constructor(baseHttpService: BaseHttpService);
|
8
|
+
fetchConfigurationProcessors$: (ownerId: string) => Observable<ConfigurationProcessor[]>;
|
9
|
+
createConfigurationProcessors$: (configurationProcessor: ConfigurationProcessor) => Observable<ConfigurationProcessor>;
|
10
|
+
updateConfigurationProcessors$: (configurationProcessor: ConfigurationProcessor) => Observable<ConfigurationProcessor>;
|
11
|
+
deleteConfigurationProcessors$: (configurationProcessor: ConfigurationProcessor) => Observable<void>;
|
12
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ConfigurationProcessorsApiService, never>;
|
13
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ConfigurationProcessorsApiService>;
|
14
|
+
}
|
@@ -0,0 +1,16 @@
|
|
1
|
+
import { BaseHttpService, ContractedPrice, Expression, GuidedSelling, NewContractedPrice } from '@veloceapps/core';
|
2
|
+
import { Observable } from 'rxjs';
|
3
|
+
import { QuerySearchParams } from '../types';
|
4
|
+
import * as i0 from "@angular/core";
|
5
|
+
export declare class ContractedPriceApiService {
|
6
|
+
private baseHttpService;
|
7
|
+
private readonly serviceUrl;
|
8
|
+
constructor(baseHttpService: BaseHttpService);
|
9
|
+
fetchContractedPrices$: () => Observable<ContractedPrice[]>;
|
10
|
+
fetchContractedPrice$: (id: string) => Observable<ContractedPrice>;
|
11
|
+
createContractedPrice$: (data: NewContractedPrice) => Observable<ContractedPrice>;
|
12
|
+
updateContractedPrice$: (data: ContractedPrice) => Observable<ContractedPrice>;
|
13
|
+
searchContractedPrices$: (searchParams?: QuerySearchParams, expression?: Expression) => Observable<GuidedSelling[]>;
|
14
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ContractedPriceApiService, never>;
|
15
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ContractedPriceApiService>;
|
16
|
+
}
|
@@ -0,0 +1,84 @@
|
|
1
|
+
import { BaseHttpService, ConfigurationStateExecuteRequest, ConfigurationStateNewRequest, ConfigurationStateStartRequest, FlowState, FlowStateExecutionRequestDTO, FlowStateExecutionResult, FlowStateInitRequest, FlowStateInitResponse } from '@veloceapps/core';
|
2
|
+
import { Observable } from 'rxjs';
|
3
|
+
import * as i0 from "@angular/core";
|
4
|
+
export declare class FlowStateApiService {
|
5
|
+
private httpService;
|
6
|
+
private readonly SERVICE_URL;
|
7
|
+
constructor(httpService: BaseHttpService);
|
8
|
+
/**
|
9
|
+
* Initialize flow state
|
10
|
+
* @param request Request
|
11
|
+
* @returns Flow initialization response, which contains session ID and result of selectors
|
12
|
+
*/
|
13
|
+
init(request: FlowStateInitRequest): Observable<FlowStateInitResponse>;
|
14
|
+
/**
|
15
|
+
* Get existing state by ID
|
16
|
+
* @param id ID
|
17
|
+
* @returns Flow State
|
18
|
+
*/
|
19
|
+
get(id: string): Observable<FlowState>;
|
20
|
+
/**
|
21
|
+
* Execute actions/selectors
|
22
|
+
* @param id State ID
|
23
|
+
* @param request Request
|
24
|
+
* @returns Execute result
|
25
|
+
*/
|
26
|
+
execute(id: string, request: FlowStateExecutionRequestDTO): Observable<FlowStateExecutionResult>;
|
27
|
+
/**
|
28
|
+
* Save Quote in the state
|
29
|
+
* @param id State ID
|
30
|
+
*/
|
31
|
+
save(id: string): Observable<{
|
32
|
+
quoteId: string;
|
33
|
+
}>;
|
34
|
+
/**
|
35
|
+
* Submit Quote in the state
|
36
|
+
* @param id State ID
|
37
|
+
*/
|
38
|
+
submit(id: string): Observable<{
|
39
|
+
quoteId: string;
|
40
|
+
}>;
|
41
|
+
/**
|
42
|
+
* Close Flow state
|
43
|
+
* @param id State ID
|
44
|
+
*/
|
45
|
+
cancel(id: string): Observable<void>;
|
46
|
+
/**
|
47
|
+
* Initialize stateful configuration
|
48
|
+
* @param stateId string
|
49
|
+
* @param request Request
|
50
|
+
* @returns Flow initialization response, which contains session ID and result of selectors
|
51
|
+
*/
|
52
|
+
newConfiguration(stateId: string, request: ConfigurationStateNewRequest): Observable<FlowStateExecutionResult>;
|
53
|
+
/**
|
54
|
+
* Start stateful configuration
|
55
|
+
* @param stateId string
|
56
|
+
* @param request Request
|
57
|
+
* @returns Flow initialization response, which contains session ID and result of selectors
|
58
|
+
*/
|
59
|
+
startConfiguration(stateId: string, request: ConfigurationStateStartRequest): Observable<FlowStateExecutionResult>;
|
60
|
+
/**
|
61
|
+
* Execute stateful configuration
|
62
|
+
* @param stateId string
|
63
|
+
* @param configurationId string
|
64
|
+
* @param request Request
|
65
|
+
* @returns Flow initialization response, which contains session ID and result of selectors
|
66
|
+
*/
|
67
|
+
executeConfiguration(stateId: string, configurationId: string, request: ConfigurationStateExecuteRequest): Observable<FlowStateExecutionResult>;
|
68
|
+
/**
|
69
|
+
* Save stateful configuration
|
70
|
+
* @param stateId string
|
71
|
+
* @param configurationId string
|
72
|
+
*/
|
73
|
+
saveConfiguration(stateId: string, configurationId: string): Observable<{
|
74
|
+
quoteId: string;
|
75
|
+
}>;
|
76
|
+
/**
|
77
|
+
* Cancel stateful configuration
|
78
|
+
* @param stateId string
|
79
|
+
* @param configurationId string
|
80
|
+
*/
|
81
|
+
cancelConfiguration(stateId: string, configurationId: string): Observable<void>;
|
82
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FlowStateApiService, never>;
|
83
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<FlowStateApiService>;
|
84
|
+
}
|
@@ -6,7 +6,7 @@ export declare class FlowsApiService {
|
|
6
6
|
private configurationSettingsApiService;
|
7
7
|
private readonly flowsKey;
|
8
8
|
constructor(configurationSettingsApiService: ConfigurationSettingsApiService);
|
9
|
-
getFlow(id: string): Observable<Flow
|
9
|
+
getFlow(id: string): Observable<Flow>;
|
10
10
|
fetchFlows(): Observable<Flow[]>;
|
11
11
|
static ɵfac: i0.ɵɵFactoryDeclaration<FlowsApiService, never>;
|
12
12
|
static ɵprov: i0.ɵɵInjectableDeclaration<FlowsApiService>;
|
@@ -1,13 +1,19 @@
|
|
1
|
-
import {
|
1
|
+
import { MessageService } from 'primeng/api';
|
2
2
|
import { Observable } from 'rxjs';
|
3
|
-
import { OrgInfo } from '../types/org-info.types';
|
3
|
+
import { AvailableVersionsInfo, OrgInfo } from '../types/org-info.types';
|
4
4
|
import * as i0 from "@angular/core";
|
5
5
|
export declare class OrgInfoApiService {
|
6
|
-
private
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
6
|
+
private messageService;
|
7
|
+
constructor(messageService: MessageService);
|
8
|
+
getOrgInfo$(): Observable<OrgInfo | undefined>;
|
9
|
+
getAvailableVersionsInfo$(): Observable<AvailableVersionsInfo | undefined>;
|
10
|
+
upgradeVersion$(targetVersion: string): Observable<OrgInfo | undefined>;
|
11
|
+
/**
|
12
|
+
* Shows an error message using the message service.
|
13
|
+
*
|
14
|
+
* @param {string} message - the error message to be published.
|
15
|
+
*/
|
16
|
+
private publishErrorMessage;
|
11
17
|
static ɵfac: i0.ɵɵFactoryDeclaration<OrgInfoApiService, never>;
|
12
18
|
static ɵprov: i0.ɵɵInjectableDeclaration<OrgInfoApiService>;
|
13
19
|
}
|
@@ -0,0 +1,20 @@
|
|
1
|
+
import { BaseHttpService, Expression, NewPortal, Portal, PortalCustomization } from '@veloceapps/core';
|
2
|
+
import { Observable } from 'rxjs';
|
3
|
+
import { CloneRequest } from '../types/clone-request.types';
|
4
|
+
import * as i0 from "@angular/core";
|
5
|
+
export declare class PortalsApiService {
|
6
|
+
private baseHttpService;
|
7
|
+
static MAX_RESULTS: number;
|
8
|
+
private readonly serviceUrl;
|
9
|
+
constructor(baseHttpService: BaseHttpService);
|
10
|
+
createNewPortal$(body: NewPortal): Observable<Portal>;
|
11
|
+
updatePortal$(portal: Portal, settings: PortalCustomization): Observable<Portal>;
|
12
|
+
getPortals$: (skip?: number, name?: string) => Observable<Portal[]>;
|
13
|
+
searchPortals$: (skip?: number, expression?: Expression) => Observable<Portal[]>;
|
14
|
+
removePortal$: (id: string) => Observable<string>;
|
15
|
+
restore$: (id: string) => Observable<void>;
|
16
|
+
duplicatePortal$: (cloneRequest: CloneRequest) => Observable<string>;
|
17
|
+
getPortal$: (id: string) => Observable<Portal>;
|
18
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PortalsApiService, never>;
|
19
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<PortalsApiService>;
|
20
|
+
}
|
@@ -23,6 +23,7 @@ export declare class ProceduresApiService {
|
|
23
23
|
* @returns
|
24
24
|
*/
|
25
25
|
apply$(body: QuoteDraft): Observable<QuoteDraft>;
|
26
|
+
fetchDefaultPricingSteps$(): Observable<any>;
|
26
27
|
static ɵfac: i0.ɵɵFactoryDeclaration<ProceduresApiService, never>;
|
27
28
|
static ɵprov: i0.ɵɵInjectableDeclaration<ProceduresApiService>;
|
28
29
|
}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
import { BaseHttpService, Expression, NewPromotion, Promotion } from '@veloceapps/core';
|
2
|
+
import { Observable } from 'rxjs';
|
3
|
+
import { CloneRequest } from '../types';
|
4
|
+
import * as i0 from "@angular/core";
|
5
|
+
export declare class PromotionsApiService {
|
6
|
+
private baseHttpService;
|
7
|
+
private readonly serviceUrl;
|
8
|
+
constructor(baseHttpService: BaseHttpService);
|
9
|
+
fetchAll$: () => Observable<Promotion>;
|
10
|
+
search$(expression: Expression, skip?: number, count?: number): Observable<Promotion[]>;
|
11
|
+
fetchOne$: (id: string) => Observable<Promotion>;
|
12
|
+
create$(body: NewPromotion): Observable<Promotion>;
|
13
|
+
update$(body: Promotion): Observable<Promotion>;
|
14
|
+
remove$: (id: string) => Observable<string>;
|
15
|
+
restore$: (id: string) => Observable<void>;
|
16
|
+
duplicate$: (body: CloneRequest) => Observable<string>;
|
17
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PromotionsApiService, never>;
|
18
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<PromotionsApiService>;
|
19
|
+
}
|
@@ -1,18 +1,25 @@
|
|
1
1
|
import { BaseHttpService, HttpRequestConfigurableOptions, QuoteDraft } from '@veloceapps/core';
|
2
2
|
import { Dictionary } from 'lodash';
|
3
3
|
import { Observable } from 'rxjs';
|
4
|
+
import { SaveQuoteResponse, SubmitQuoteResponse } from '../types';
|
4
5
|
import * as i0 from "@angular/core";
|
5
6
|
export declare class QuoteApiService {
|
6
7
|
private httpService;
|
7
8
|
private readonly SERVICE_URL;
|
8
9
|
constructor(httpService: BaseHttpService);
|
10
|
+
/**
|
11
|
+
* @deprecated Use getQuoteState instead
|
12
|
+
*/
|
9
13
|
getQuoteDraft(objectId: string, params?: Dictionary<string>, errorHandler?: (error: any) => void): Observable<QuoteDraft>;
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
14
|
+
/**
|
15
|
+
* Comparing to deprecated `getQuoteDraft` this endpoint doesn't include orders and assets
|
16
|
+
* @param objectId quoteId | accountId | opportunityId | orderId
|
17
|
+
* @param params Query params
|
18
|
+
* @param options Request options
|
19
|
+
*/
|
20
|
+
getQuoteState(objectId: string, params?: Dictionary<string>, options?: HttpRequestConfigurableOptions): Observable<QuoteDraft>;
|
21
|
+
upsertQuote(request: QuoteDraft, options?: HttpRequestConfigurableOptions): Observable<SaveQuoteResponse>;
|
22
|
+
submitQuote(request: QuoteDraft, options?: HttpRequestConfigurableOptions): Observable<SubmitQuoteResponse>;
|
16
23
|
attachDocument(id: string, documentName: string, data: any): Observable<void>;
|
17
24
|
static ɵfac: i0.ɵɵFactoryDeclaration<QuoteApiService, never>;
|
18
25
|
static ɵprov: i0.ɵɵInjectableDeclaration<QuoteApiService>;
|
@@ -0,0 +1,19 @@
|
|
1
|
+
import { BaseHttpService, Expression, NewRebateProgram, RebateProgram } from '@veloceapps/core';
|
2
|
+
import { Observable } from 'rxjs';
|
3
|
+
import { CloneRequest } from '../types';
|
4
|
+
import * as i0 from "@angular/core";
|
5
|
+
export declare class RebateProgramApiService {
|
6
|
+
private baseHttpService;
|
7
|
+
private readonly serviceUrl;
|
8
|
+
constructor(baseHttpService: BaseHttpService);
|
9
|
+
fetchAll$: () => Observable<RebateProgram[]>;
|
10
|
+
search$(expression: Expression, skip?: number, count?: number): Observable<RebateProgram[]>;
|
11
|
+
fetchOne$: (id: string) => Observable<RebateProgram>;
|
12
|
+
create$(body: NewRebateProgram): Observable<RebateProgram>;
|
13
|
+
update$(body: RebateProgram): Observable<RebateProgram>;
|
14
|
+
remove$: (id: string) => Observable<string>;
|
15
|
+
restore$: (id: string) => Observable<void>;
|
16
|
+
duplicate$: (body: CloneRequest) => Observable<string>;
|
17
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<RebateProgramApiService, never>;
|
18
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<RebateProgramApiService>;
|
19
|
+
}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
import { BaseHttpService, Expression, NewRebateType, RebateType } from '@veloceapps/core';
|
2
|
+
import { Observable } from 'rxjs';
|
3
|
+
import { CloneRequest } from '../types';
|
4
|
+
import * as i0 from "@angular/core";
|
5
|
+
export declare class RebateTypeApiService {
|
6
|
+
private baseHttpService;
|
7
|
+
private readonly serviceUrl;
|
8
|
+
constructor(baseHttpService: BaseHttpService);
|
9
|
+
fetchAll$: () => Observable<RebateType>;
|
10
|
+
search$(expression: Expression, skip?: number, count?: number): Observable<RebateType[]>;
|
11
|
+
fetchOne$: (id: string) => Observable<RebateType>;
|
12
|
+
create$(body: NewRebateType): Observable<RebateType>;
|
13
|
+
update$(body: RebateType): Observable<RebateType>;
|
14
|
+
remove$: (id: string) => Observable<string>;
|
15
|
+
restore$: (id: string) => Observable<void>;
|
16
|
+
duplicate$: (body: CloneRequest) => Observable<string>;
|
17
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<RebateTypeApiService, never>;
|
18
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<RebateTypeApiService>;
|
19
|
+
}
|
@@ -7,7 +7,7 @@ export declare class RulesApiService {
|
|
7
7
|
private readonly serviceUrl;
|
8
8
|
constructor(baseHttpService: BaseHttpService);
|
9
9
|
fetchRules$: () => Observable<Rule[]>;
|
10
|
-
searchRules$: (expression: Expression, skip
|
10
|
+
searchRules$: (expression: Expression, skip?: number, count?: number) => Observable<Rule[]>;
|
11
11
|
createRule$: (rule: NewRule) => Observable<Rule>;
|
12
12
|
updateRule$: (rule: Rule) => Observable<Rule>;
|
13
13
|
duplicateRule$: (body: CloneRequest) => Observable<string>;
|
@@ -16,6 +16,7 @@ export declare class RulesApiService {
|
|
16
16
|
fetchRule$(id: string): Observable<Rule>;
|
17
17
|
fetchHeaderFields$(): Observable<HeaderField[]>;
|
18
18
|
execute$(body: RuleExecuteRequest): Observable<string[]>;
|
19
|
+
private getExecuteRuleUrl;
|
19
20
|
static ɵfac: i0.ɵɵFactoryDeclaration<RulesApiService, never>;
|
20
21
|
static ɵprov: i0.ɵɵInjectableDeclaration<RulesApiService>;
|
21
22
|
}
|
@@ -20,7 +20,7 @@ export declare class SalesforceApiService {
|
|
20
20
|
describeObject(objectName: string, options?: HttpRequestConfigurableOptions): Observable<SalesforceField[]>;
|
21
21
|
describeField(objectName: string, fieldName: string, options?: HttpRequestConfigurableOptions): Observable<SalesforceField>;
|
22
22
|
describe2<T>(objectName: string, fields: string[], options?: HttpRequestConfigurableOptions): Observable<T>;
|
23
|
-
apexGetRequest<T>(path: string, params: HttpParams, options?: HttpRequestConfigurableOptions): Observable<T>;
|
23
|
+
apexGetRequest<T>(path: string, params: HttpParams | Record<string, any>, options?: HttpRequestConfigurableOptions): Observable<T>;
|
24
24
|
apexPostRequest<T, S>(path: string, body: S, options?: HttpRequestConfigurableOptions): Observable<T>;
|
25
25
|
getGlobalPicklists(): Observable<GlobalPicklist[]>;
|
26
26
|
getGlobalPicklistValues(id: string): Observable<GlobalPicklistValue[]>;
|
@@ -0,0 +1,24 @@
|
|
1
|
+
import { NewSalesforceOrganization, SalesforceOrganization } from '@veloceapps/core';
|
2
|
+
import { Dictionary } from 'lodash';
|
3
|
+
import { MessageService } from 'primeng/api';
|
4
|
+
import { Observable } from 'rxjs';
|
5
|
+
import * as i0 from "@angular/core";
|
6
|
+
export declare class SandboxManagerApiService {
|
7
|
+
private messageService;
|
8
|
+
constructor(messageService: MessageService);
|
9
|
+
getSalesforceOrganizations$(): Observable<SalesforceOrganization[]>;
|
10
|
+
getAvailableSalesforceOrganizationSizes$(): Observable<Dictionary<number>>;
|
11
|
+
createSalesforceOrganization$(payload: NewSalesforceOrganization): Observable<SalesforceOrganization | undefined>;
|
12
|
+
updateSalesforceOrganization$(payload: SalesforceOrganization): Observable<SalesforceOrganization | undefined>;
|
13
|
+
deleteSalesforceOrganization$(payload: SalesforceOrganization): Observable<SalesforceOrganization | undefined>;
|
14
|
+
activateSalesforceOrganization$(payload: SalesforceOrganization): Observable<SalesforceOrganization | undefined>;
|
15
|
+
deactivateSalesforceOrganization$(payload: SalesforceOrganization): Observable<SalesforceOrganization | undefined>;
|
16
|
+
/**
|
17
|
+
* Shows an error message using the message service.
|
18
|
+
*
|
19
|
+
* @param {string} message - the error message to be published.
|
20
|
+
*/
|
21
|
+
private publishErrorMessage;
|
22
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SandboxManagerApiService, never>;
|
23
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<SandboxManagerApiService>;
|
24
|
+
}
|
@@ -7,10 +7,10 @@ export declare class ScriptsApiService {
|
|
7
7
|
private readonly serviceUrl;
|
8
8
|
constructor(baseHttpService: BaseHttpService);
|
9
9
|
fetchScripts$: () => Observable<Script[]>;
|
10
|
-
searchScripts$: (expression: Expression, skip
|
10
|
+
searchScripts$: (expression: Expression, skip?: number, count?: number) => Observable<Script[]>;
|
11
11
|
fetchScript$: (id: string) => Observable<ScriptDetails>;
|
12
12
|
createScript$: (script: NewScript) => Observable<Script>;
|
13
|
-
updateScriptMeta$: (script: Script) => Observable<
|
13
|
+
updateScriptMeta$: (script: Script) => Observable<ScriptDetails>;
|
14
14
|
updateScriptDetails$: (script: ScriptDetails) => Observable<ScriptDetails>;
|
15
15
|
cloneScript$: (cloneRequest: CloneRequest) => Observable<string>;
|
16
16
|
removeScript$: (id: string) => Observable<string>;
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { BaseHttpService, ConfigurationExecuteRequest, ConfigurationExecuteResponse,
|
1
|
+
import { BaseHttpService, ConfigurationExecuteRequest, ConfigurationExecuteResponse, QuoteDraft } from '@veloceapps/core';
|
2
2
|
import { Observable } from 'rxjs';
|
3
3
|
import { StatefulConfigurationRequest } from '../types/stateful-configuration.types';
|
4
4
|
import * as i0 from "@angular/core";
|
@@ -17,7 +17,7 @@ export declare class StatefulConfigurationApiService {
|
|
17
17
|
* @param id ID
|
18
18
|
* @returns Configuration State
|
19
19
|
*/
|
20
|
-
get(id: string): Observable<
|
20
|
+
get(id: string): Observable<QuoteDraft>;
|
21
21
|
/**
|
22
22
|
* Execute actions/selectors
|
23
23
|
* @param id State ID
|
@@ -42,6 +42,7 @@ export declare class UITemplatesApiService {
|
|
42
42
|
attachTemplateThumbnail$(templateId: string, file: File): Observable<any>;
|
43
43
|
removeTemplateThumbnail$(templateId: string): Observable<any>;
|
44
44
|
fetchComponentAttachments$: (templateId: string, component: TemplateComponent) => Observable<ComponentAttachments>;
|
45
|
+
fetchComponentsAttachments$: (templateId: string) => Observable<ComponentAttachments[]>;
|
45
46
|
private fetchComponentAttachmentFile$;
|
46
47
|
uploadComponentAttachments$: (templateId: string, componentId: string, attachments: ComponentAttachments) => Observable<void>;
|
47
48
|
static ɵfac: i0.ɵɵFactoryDeclaration<UITemplatesApiService, never>;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { BaseHttpService, Expression, NewVeloceObject, NewVeloceObjectCategory, VeloceObject, VeloceObjectCategory } from '@veloceapps/core';
|
2
2
|
import { Observable } from 'rxjs';
|
3
|
-
import { QuerySearchParams } from '../types';
|
3
|
+
import { CloneRequest, QuerySearchParams } from '../types';
|
4
4
|
import * as i0 from "@angular/core";
|
5
5
|
export declare class VeloceObjectsApiService {
|
6
6
|
private baseHttpService;
|
@@ -16,6 +16,7 @@ export declare class VeloceObjectsApiService {
|
|
16
16
|
createObject$(object: NewVeloceObject): Observable<VeloceObject>;
|
17
17
|
updateObject$(object: VeloceObject): Observable<VeloceObject>;
|
18
18
|
deleteObject$: (id: string) => Observable<void>;
|
19
|
+
duplicateObject$: (body: CloneRequest) => Observable<string>;
|
19
20
|
restoreObject$: (id: string) => Observable<void>;
|
20
21
|
static ɵfac: i0.ɵɵFactoryDeclaration<VeloceObjectsApiService, never>;
|
21
22
|
static ɵprov: i0.ɵɵInjectableDeclaration<VeloceObjectsApiService>;
|
package/lib/types/index.d.ts
CHANGED
@@ -23,4 +23,23 @@ export interface OrgInfo {
|
|
23
23
|
DefaultDataVersion: string;
|
24
24
|
SelfRegistered: boolean;
|
25
25
|
SelfRegisteredExpireAt: string;
|
26
|
+
Scratch: boolean;
|
27
|
+
}
|
28
|
+
export interface AvailableVersionsInfo {
|
29
|
+
orgId: string;
|
30
|
+
name: string;
|
31
|
+
envId: string;
|
32
|
+
client: string;
|
33
|
+
currentVersion: VersionInfo;
|
34
|
+
availableVersions: VersionInfo[];
|
35
|
+
}
|
36
|
+
export interface VersionInfo {
|
37
|
+
release: string;
|
38
|
+
integrationVersion?: string;
|
39
|
+
componentVersions: ComponentVersionInfo[];
|
40
|
+
}
|
41
|
+
export interface ComponentVersionInfo {
|
42
|
+
name: string;
|
43
|
+
displayName: string;
|
44
|
+
version: string;
|
26
45
|
}
|
@@ -4,7 +4,7 @@ interface ConfigurationProcessorOverride {
|
|
4
4
|
script: string;
|
5
5
|
}
|
6
6
|
export interface StatefulConfigurationRequest {
|
7
|
-
|
7
|
+
item: ConfigurationRequest;
|
8
8
|
actions?: ConfigurationProcessorOverride[];
|
9
9
|
selectors?: ConfigurationProcessorOverride[];
|
10
10
|
}
|
@@ -0,0 +1,18 @@
|
|
1
|
+
/**
|
2
|
+
* Parses the response from Canvas and checks for errors.
|
3
|
+
* - If an error is found, publishes an error message and returns the failover value.
|
4
|
+
* - If no error is found, returns the parsed response.
|
5
|
+
*
|
6
|
+
* Note! The API call first goes to APEX before reaching the Canvas, so errors can originate from either APEX or Canvas.
|
7
|
+
*
|
8
|
+
* @param {string} response - The JSON string response from the Canvas call.
|
9
|
+
* @param {T} failover - The value to return in case of error.
|
10
|
+
* @returns {T | K} The parsed response or the failover value.
|
11
|
+
*
|
12
|
+
* @template T The expected type of the parsed response.
|
13
|
+
* @template K The type of the failover value.
|
14
|
+
*
|
15
|
+
* @remarks If there's an Apex error, the response data can be an array.
|
16
|
+
* In such cases, the function extracts the first element of the array.
|
17
|
+
*/
|
18
|
+
export declare const handleCanvasResponse: <T, K>(response: string, failover: K, errorPublisher: (message: string) => void) => T | K;
|