@aglyn/aglyn 1.0.0-beta.164 → 1.0.0-beta.165
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +10 -10
- package/src/lib/app-utils/crm.d.ts +29 -3
- package/src/lib/app-utils/crm.js +8 -3
- package/src/lib/app-utils/crm.js.map +1 -1
- package/src/lib/app-utils/docs-help.generated.d.ts +1 -1
- package/src/lib/app-utils/docs-help.generated.js +1 -1
- package/src/lib/app-utils/docs-help.generated.js.map +1 -1
- package/src/lib/app-utils/docs-index.generated.js +10 -10
- package/src/lib/app-utils/docs-index.generated.js.map +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aglyn/aglyn",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.165",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"homepage": "https://aglyn.com",
|
|
6
6
|
"repository": {
|
|
@@ -33,15 +33,15 @@
|
|
|
33
33
|
"./package.json": "./package.json"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@aglyn/shared-data-enums": "1.0.0-beta.
|
|
37
|
-
"@aglyn/shared-data-mdi": "1.0.0-beta.
|
|
38
|
-
"@aglyn/shared-data-types": "1.0.0-beta.
|
|
39
|
-
"@aglyn/shared-util-email": "1.0.0-beta.
|
|
40
|
-
"@aglyn/shared-util-http": "1.0.0-beta.
|
|
41
|
-
"@aglyn/shared-util-logger": "1.0.0-beta.
|
|
42
|
-
"@aglyn/shared-util-timestamp": "1.0.0-beta.
|
|
43
|
-
"@aglyn/shared-util-tools": "1.0.0-beta.
|
|
44
|
-
"@aglyn/shared-util-vendor": "1.0.0-beta.
|
|
36
|
+
"@aglyn/shared-data-enums": "1.0.0-beta.165",
|
|
37
|
+
"@aglyn/shared-data-mdi": "1.0.0-beta.165",
|
|
38
|
+
"@aglyn/shared-data-types": "1.0.0-beta.165",
|
|
39
|
+
"@aglyn/shared-util-email": "1.0.0-beta.165",
|
|
40
|
+
"@aglyn/shared-util-http": "1.0.0-beta.165",
|
|
41
|
+
"@aglyn/shared-util-logger": "1.0.0-beta.165",
|
|
42
|
+
"@aglyn/shared-util-timestamp": "1.0.0-beta.165",
|
|
43
|
+
"@aglyn/shared-util-tools": "1.0.0-beta.165",
|
|
44
|
+
"@aglyn/shared-util-vendor": "1.0.0-beta.165",
|
|
45
45
|
"@data-driven-forms/react-form-renderer": "^4.2.0",
|
|
46
46
|
"@msgpack/msgpack": "^3.1.3",
|
|
47
47
|
"@types/unist": "^3.0.3",
|
|
@@ -578,9 +578,18 @@ export interface CrmActivity extends CrmScoped {
|
|
|
578
578
|
sourceActionId?: string;
|
|
579
579
|
/**
|
|
580
580
|
* The plugin that filed it on the record-timeline seam (AGL-2981) — an
|
|
581
|
-
* email a sequence sent, a reply it read
|
|
581
|
+
* email a sequence sent, a reply it read — or the CRM's own id on an
|
|
582
|
+
* entry it wrote about a filing (AGL-3274), so a reader can tell the
|
|
583
|
+
* bookkeeping entries from what a person logged.
|
|
582
584
|
*/
|
|
583
585
|
sourcePluginId?: string;
|
|
586
|
+
/**
|
|
587
|
+
* The campaign a filing entry is about (AGL-3274): "Filed under" and
|
|
588
|
+
* "Removed from" name it in the body and carry the container's id here,
|
|
589
|
+
* so a campaign's own page can one day list what happened under it
|
|
590
|
+
* without parsing a sentence.
|
|
591
|
+
*/
|
|
592
|
+
campaignId?: string;
|
|
584
593
|
contactId?: string;
|
|
585
594
|
companyId?: string;
|
|
586
595
|
dealId?: string;
|
|
@@ -834,9 +843,12 @@ export interface ContactFieldDefinition extends CrmScoped {
|
|
|
834
843
|
}
|
|
835
844
|
/**
|
|
836
845
|
* The records a custom field may describe, in the order the Fields
|
|
837
|
-
* section tabs them (AGL-2661).
|
|
846
|
+
* section tabs them (AGL-2661), with `lead` since AGL-3272.
|
|
847
|
+
*
|
|
848
|
+
* A lead is last because it is the record a person leaves: the three
|
|
849
|
+
* before it are what a lead becomes, and the tabs read in that order.
|
|
838
850
|
*/
|
|
839
|
-
export declare const CRM_FIELD_OBJECTS: readonly ["contact", "company", "deal"];
|
|
851
|
+
export declare const CRM_FIELD_OBJECTS: readonly ["contact", "company", "deal", "lead"];
|
|
840
852
|
export type CrmFieldObject = (typeof CRM_FIELD_OBJECTS)[number];
|
|
841
853
|
/** How each object reads on the Fields section's tabs and in a refusal. */
|
|
842
854
|
export declare const CRM_FIELD_OBJECT_LABELS: Record<CrmFieldObject, string>;
|
|
@@ -1373,6 +1385,20 @@ export interface CrmLeadFields extends CrmLeadProfile {
|
|
|
1373
1385
|
* handed to the contact's facet when the lead converts.
|
|
1374
1386
|
*/
|
|
1375
1387
|
campaignIds?: string[];
|
|
1388
|
+
/**
|
|
1389
|
+
* The org's custom LEAD fields, keyed by each definition's `key`
|
|
1390
|
+
* (AGL-3272) — the same map a contact facet, a company and a deal keep,
|
|
1391
|
+
* judged against the definitions whose `object` is `lead`.
|
|
1392
|
+
*
|
|
1393
|
+
* It does NOT travel to the contact on convert. Keys are unique per
|
|
1394
|
+
* object, so a lead's `budget` and a contact's `budget` are two
|
|
1395
|
+
* definitions that may hold two types, and copying one map into the
|
|
1396
|
+
* other would write a value the receiving definition never agreed to.
|
|
1397
|
+
* Salesforce answers this with an explicit lead field mapping; until
|
|
1398
|
+
* there is one here the values stay on the lead, which a converted lead
|
|
1399
|
+
* is still read back for.
|
|
1400
|
+
*/
|
|
1401
|
+
custom?: Record<string, CrmCustomValue>;
|
|
1376
1402
|
}
|
|
1377
1403
|
/** The longest text one profile field holds — the contact's own cap. */
|
|
1378
1404
|
export declare const CRM_LEAD_TEXT_MAX = 120;
|
package/src/lib/app-utils/crm.js
CHANGED
|
@@ -558,16 +558,21 @@ const DAY_MS = 24 * HOUR_MS;
|
|
|
558
558
|
}
|
|
559
559
|
/**
|
|
560
560
|
* The records a custom field may describe, in the order the Fields
|
|
561
|
-
* section tabs them (AGL-2661).
|
|
561
|
+
* section tabs them (AGL-2661), with `lead` since AGL-3272.
|
|
562
|
+
*
|
|
563
|
+
* A lead is last because it is the record a person leaves: the three
|
|
564
|
+
* before it are what a lead becomes, and the tabs read in that order.
|
|
562
565
|
*/ export const CRM_FIELD_OBJECTS = [
|
|
563
566
|
'contact',
|
|
564
567
|
'company',
|
|
565
|
-
'deal'
|
|
568
|
+
'deal',
|
|
569
|
+
'lead'
|
|
566
570
|
];
|
|
567
571
|
/** How each object reads on the Fields section's tabs and in a refusal. */ export const CRM_FIELD_OBJECT_LABELS = {
|
|
568
572
|
contact: 'Contacts',
|
|
569
573
|
company: 'Companies',
|
|
570
|
-
deal: 'Deals'
|
|
574
|
+
deal: 'Deals',
|
|
575
|
+
lead: 'Leads'
|
|
571
576
|
};
|
|
572
577
|
export function isCrmFieldObject(value) {
|
|
573
578
|
return typeof value === 'string' && CRM_FIELD_OBJECTS.includes(value);
|