@dforge-core/metadata 0.0.41 → 0.0.43

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 CHANGED
@@ -5,7 +5,40 @@ All notable changes to `@dforge-core/metadata` are documented here.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this package adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
- ## [Unreleased]
8
+ ## [0.0.43] — 2026-10-19
9
+
10
+ ### Added
11
+
12
+ - **`registers.schema.json`, `analyticTotals`:** an `accounting` register's second per-period cache,
13
+ keyed by the analytic slots as well as the account, cached dimensions and period, for the accounts
14
+ the chart flags (`accountFlag`). It sits beside `totals` in an entity of its own. Declares `entity`,
15
+ `period`, `periodField`, `accountField`, `accountFlag`, `analyticFields`, `resources` and optional
16
+ `dimensions`; balance, turnover and information registers refuse it.
17
+ - **`entity.schema.json`, `lineDateField`:** an `A` column that posts from lines names a line column
18
+ dating each line's movement instead of `dateField`. Needs `lineEntity`; an `L` column refuses it.
19
+ Its period is judged by the stamped date (after `dateTrunc`); `recordChangesOnly` info registers take
20
+ one line per key. Pack-time check also refuses it with `periodDimField`, or missing from
21
+ `lockedLineFields` / `groupLinesBy`.
22
+
23
+ ## [0.0.42] — 2026-10-15
24
+
25
+ ### Added
26
+
27
+ - **`entity.schema.json`, `periodGuards`:** closed-period locks for a document that posts to no
28
+ register — a period entity, the date the period follows from, the column that references it, and
29
+ `lockedFields` (with `lineEntity` / `lineField` / `lockedLineFields` for lines). Not allowed on an
30
+ extension.
31
+ - **`entity.schema.json`, partial and unique indexes:** an entry in `indexes` takes `unique` and
32
+ `where` (a SQL condition, so uniqueness holds among the rows it selects).
33
+ - **`roles.schema.json`, rights keys are checked for their prefix:** `propertyNames` accepts a bare
34
+ entity code, `module.entity`, `action:<code>`, and `sp:` / `report:` with an optional module
35
+ qualifier, so an editor flags `"post_invoice": "E"` (which install would drop) as it is typed.
36
+ - **`RegisterSource`** type is exported from the package root.
37
+
38
+ ### Changed
39
+
40
+ - **DSL builtins `getAccountBalance` / `getAccountTurnover`:** the signatures and hints show the new
41
+ last `options` argument — `groupBy`, `exclude` and (balance only) `before`.
9
42
 
10
43
  ## [0.0.41] — 2026-10-13
11
44
 
package/dist/dsl/index.js CHANGED
@@ -805,15 +805,15 @@ var BUILTINS = [
805
805
  },
806
806
  {
807
807
  name: "getAccountBalance",
808
- signature: "getAccountBalance(register, account, filter?, asOf?)",
808
+ signature: "getAccountBalance(register, account, filter?, asOf?, options?)",
809
809
  returns: "object",
810
- doc: "Balance of one account of an accounting register: `{debit, credit, net}` per resource. `filter` narrows by a dimension, or by an analytic kind the ACCOUNT declares \u2014 an analytic takes the key alone, or `{ entity, value }` to name one entity of a kind that is a union of several."
810
+ doc: "Balance of one account of an accounting register: `{debit, credit, net}` per resource. `filter` narrows by a dimension, or by an analytic kind the ACCOUNT declares \u2014 an analytic takes the key alone, or `{ entity, value }` to name one entity of a kind that is a union of several. `options`: `groupBy` (a name or array \u2014 returns an array, a row per combination with a non-zero balance), `exclude: { entity, key }` (leaves out that document's postings) and `before` (a moment, exclusive, in place of `asOf`)."
811
811
  },
812
812
  {
813
813
  name: "getAccountTurnover",
814
- signature: "getAccountTurnover(register, account, filter, from, to)",
814
+ signature: "getAccountTurnover(register, account, filter, from, to, options?)",
815
815
  returns: "object",
816
- doc: "What moved through one account over an interval: `{debit, credit, net}` per resource. `filter` narrows as in `getAccountBalance` and may be `null`; `from` and `to` are both required."
816
+ doc: "What moved through one account over an interval: `{debit, credit, net}` per resource. `filter` narrows as in `getAccountBalance` and may be `null`; `from` and `to` are both required. `options` takes `groupBy` and `exclude` as in `getAccountBalance`; a grouped turnover has a row per combination that moved."
817
817
  },
818
818
  {
819
819
  name: "getCorrespondence",