@ai-matrx/records 0.87.23 → 0.87.24
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/CHANGELOG.md +14 -2
- package/dist/{client-xyH0cLVd.d.cts → client-C3ZZNfGH.d.cts} +1 -1
- package/dist/{client-Bvk0ymIs.d.ts → client-E0VQ0NPO.d.ts} +1 -1
- package/dist/core/index.d.cts +4 -4
- package/dist/core/index.d.ts +4 -4
- package/dist/data/index.d.cts +2 -2
- package/dist/data/index.d.ts +2 -2
- package/dist/{declareTable-CVzk6RVH.d.ts → declareTable-B12XybRp.d.ts} +2 -2
- package/dist/{declareTable-DNhNDvh9.d.cts → declareTable-BK3zufr7.d.cts} +2 -2
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/react/index.cjs +8 -1
- package/dist/react/index.cjs.map +1 -1
- package/dist/react/index.d.cts +6 -0
- package/dist/react/index.d.ts +6 -0
- package/dist/react/index.js +8 -1
- package/dist/react/index.js.map +1 -1
- package/dist/{table-kind-1aiKFy1k.d.cts → table-kind-BZu8mtND.d.cts} +2 -0
- package/dist/{table-kind-ClSGi6ze.d.ts → table-kind-xKxTHtrV.d.ts} +2 -0
- package/dist/typed-table/index.cjs +8 -1
- package/dist/typed-table/index.cjs.map +1 -1
- package/dist/typed-table/index.d.cts +7 -3
- package/dist/typed-table/index.d.ts +7 -3
- package/dist/typed-table/index.js +8 -1
- package/dist/typed-table/index.js.map +1 -1
- package/package.json +4 -4
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { N as NewFieldSpec } from '../declareTable-
|
|
1
|
+
import { N as NewFieldSpec } from '../declareTable-BK3zufr7.cjs';
|
|
2
2
|
import { U as Uuid, i as RecordsResult, o as RecordPageSort } from '../record-DpB2QgAZ.cjs';
|
|
3
|
-
import { R as RecordsClient } from '../client-
|
|
4
|
-
import { F as FieldDrift, T as TableArchiveProgress } from '../table-kind-
|
|
3
|
+
import { R as RecordsClient } from '../client-C3ZZNfGH.cjs';
|
|
4
|
+
import { F as FieldDrift, T as TableArchiveProgress } from '../table-kind-BZu8mtND.cjs';
|
|
5
5
|
import '../field-BanTVGK2.cjs';
|
|
6
6
|
import '../subscription-BD9DnJxX.cjs';
|
|
7
7
|
import '../ports-D8-iuY1P.cjs';
|
|
@@ -368,6 +368,10 @@ interface AppAutomationSpec {
|
|
|
368
368
|
author: true;
|
|
369
369
|
};
|
|
370
370
|
text: string;
|
|
371
|
+
/** The notice's subject line (in-app and email); defaults to the automation's name. Same `{{key}}` words as `text`. */
|
|
372
|
+
subject?: string;
|
|
373
|
+
/** Where the notice opens: a path (`/hr/performance/{{record_id}}?org={{organization_id}}`) or a URL field's `{{key}}`. */
|
|
374
|
+
link?: string;
|
|
371
375
|
}>;
|
|
372
376
|
}
|
|
373
377
|
/**
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { N as NewFieldSpec } from '../declareTable-
|
|
1
|
+
import { N as NewFieldSpec } from '../declareTable-B12XybRp.js';
|
|
2
2
|
import { U as Uuid, i as RecordsResult, o as RecordPageSort } from '../record-DpB2QgAZ.js';
|
|
3
|
-
import { R as RecordsClient } from '../client-
|
|
4
|
-
import { F as FieldDrift, T as TableArchiveProgress } from '../table-kind-
|
|
3
|
+
import { R as RecordsClient } from '../client-E0VQ0NPO.js';
|
|
4
|
+
import { F as FieldDrift, T as TableArchiveProgress } from '../table-kind-xKxTHtrV.js';
|
|
5
5
|
import '../field-BPABOJ2Y.js';
|
|
6
6
|
import '../subscription-D7KQBHXN.js';
|
|
7
7
|
import '../ports-TMWX-t9l.js';
|
|
@@ -368,6 +368,10 @@ interface AppAutomationSpec {
|
|
|
368
368
|
author: true;
|
|
369
369
|
};
|
|
370
370
|
text: string;
|
|
371
|
+
/** The notice's subject line (in-app and email); defaults to the automation's name. Same `{{key}}` words as `text`. */
|
|
372
|
+
subject?: string;
|
|
373
|
+
/** Where the notice opens: a path (`/hr/performance/{{record_id}}?org={{organization_id}}`) or a URL field's `{{key}}`. */
|
|
374
|
+
link?: string;
|
|
371
375
|
}>;
|
|
372
376
|
}
|
|
373
377
|
/**
|
|
@@ -6738,7 +6738,14 @@ async function ensureAppAutomations(client, def, specs, options = {}) {
|
|
|
6738
6738
|
if (a.do === "set") actions.push({ do: "set", values: keyed(a.values, own.data, own.data, def.name) });
|
|
6739
6739
|
else if (a.do === "notify") {
|
|
6740
6740
|
const to = "field" in a.to ? { field: byId(own.data, a.to.field, def.name) } : a.to;
|
|
6741
|
-
|
|
6741
|
+
const words = (t) => t.replace(/\{\{(\w+)\}\}/g, (m, k) => k === "record_id" || k === "organization_id" ? m : `{{${byId(own.data, k, def.name)}}}`);
|
|
6742
|
+
actions.push({
|
|
6743
|
+
do: "notify",
|
|
6744
|
+
to,
|
|
6745
|
+
text: words(a.text),
|
|
6746
|
+
...a.subject ? { subject: words(a.subject) } : {},
|
|
6747
|
+
...a.link ? { link: words(a.link) } : {}
|
|
6748
|
+
});
|
|
6742
6749
|
} else {
|
|
6743
6750
|
const other = await ensureTypedTable(client, a.table, { organizationId: org.data });
|
|
6744
6751
|
if (!other.ok) return other;
|