@diy-accounting-uk/diya-gl 1.2.11 → 1.2.12

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.
@@ -519,6 +519,32 @@
519
519
  "scorecard": "101565 passed, 0 warnings, 0 failed"
520
520
  }
521
521
  }
522
+ },
523
+ {
524
+ "tag": "diya-gl-v1.2.11",
525
+ "date": "2026-09-13",
526
+ "formatVersion": "diya-gl/1",
527
+ "engineVersion": "1.2.11+32b8b8c8",
528
+ "taxDataHash": "4ecdbe985d22",
529
+ "reconciledCommit": "c910fdeefbe4f2f71ae9ec5f5d4a713783a1c0c7",
530
+ "templates": {
531
+ "bst": {
532
+ "hash": "0d003e10e00c",
533
+ "scorecard": "812 passed, 0 warnings, 0 failed"
534
+ },
535
+ "taxi": {
536
+ "hash": "1ff69654d64d",
537
+ "scorecard": "686 passed, 0 warnings, 0 failed"
538
+ },
539
+ "se": {
540
+ "hash": "2d5629384e82",
541
+ "scorecard": "7952 passed, 0 warnings, 0 failed"
542
+ },
543
+ "ltd": {
544
+ "hash": "caa14632083b",
545
+ "scorecard": "101605 passed, 0 warnings, 0 failed"
546
+ }
547
+ }
522
548
  }
523
549
  ]
524
550
  }
@@ -20,5 +20,5 @@
20
20
  "cell/SE Short!D94": "The SA103S view's box table (sa103s, books/products/bst.js) does not print this box.",
21
21
  "section/self-assessment-sa103s/other-tax-adjustments": "The SA103S view's box table (sa103s, books/products/bst.js) does not print this box.",
22
22
  "cell/SE Short!D106": "The SA103S view's box table (sa103s, books/products/bst.js) does not print this box.",
23
- "section/self-assessment-sa103s/net-profit-for-tax-calc": "The SA103S view's box table (sa103s, books/products/bst.js) does not print this box."
23
+ "section/self-assessment-sa103s/net-profit-for-tax-calc-box-31": "The SA103S view's box table (sa103s, books/products/bst.js) does not print this box."
24
24
  }
@@ -1179,9 +1179,11 @@ export function calculateSeCells(book, lines, taxData, scenario = {}) {
1179
1179
  seFull.O204 = pl.B11;
1180
1180
  seFull.O199 = carry([seFull.O194], () => (sheetNumber(seFull.D179) > 0 ? 0 : Math.min(seFull.O194 + seFull.O204, lossesBroughtForward)));
1181
1181
  seFull.O210 = carry([seFull.O194, seFull.O199], () => seFull.O194 - seFull.O199 + seFull.O204);
1182
- // Box 77 is O179+E197+D210+P190: the box 68 and 72 terms read the blank
1183
- // cell beside each printed dash, so only box 71 joins the loss.
1184
- seFull.D219 = carry([seFull.O179], () => seFull.O179 + sheetNumber(seFull.D210));
1182
+ // Box 77 is O179-N(D197)-D210-N(O190): box 65 reduced by boxes 68, 71 and
1183
+ // 72. Boxes 68 and 72 have no input cell on this template, so their
1184
+ // printed dash cells (D197, O190) always contribute nil; box 71 (D210)
1185
+ // is the only one that moves the figure.
1186
+ seFull.D219 = carry([seFull.O179], () => seFull.O179 - sheetNumber(seFull.D210));
1185
1187
  seFull.O224 = seFull.D219;
1186
1188
  seFull.D231 = contractorDeductions;
1187
1189
  seFull.J280 = admin.N20;
@@ -12,7 +12,7 @@
12
12
 
13
13
  export const PROVENANCE_DATA = {
14
14
  formatVersion: "diya-gl/1",
15
- engineVersion: "1.2.11+32b8b8c8",
15
+ engineVersion: "1.2.12+8ad4ddf1",
16
16
  taxDataHash: "4ecdbe985d22",
17
17
  reconciledCommit: "c910fdeefbe4f2f71ae9ec5f5d4a713783a1c0c7",
18
18
  templates: {
@@ -25,7 +25,7 @@ export const PROVENANCE_DATA = {
25
25
  scorecard: "686 passed, 0 warnings, 0 failed",
26
26
  },
27
27
  se: {
28
- hash: "2d5629384e82",
28
+ hash: "4decdcb12664",
29
29
  scorecard: "7952 passed, 0 warnings, 0 failed",
30
30
  },
31
31
  ltd: {
@@ -231,9 +231,9 @@ export const DISALLOWABLE_PERCENT_CELLS = {
231
231
  // names. Verified against the template: SE Full!O154 (box 57) reads
232
232
  // D139+D144+D147+D152+D156+D160+O139+O144+O149, so every allowance cell here
233
233
  // is a term of the total; O169 (box 63) reads O154+D179; D219 (box 77) reads
234
- // O179+E197+D210+P190. Box 54's caption at N136 is "Electric charge-point
235
- // allowance" (L136 = 54); box 55's cell O144 is the small pools formula, so
236
- // the enhanced-allowance figure has no input cell of its own.
234
+ // O179-N(D197)-D210-N(O190). Box 54's caption at N136 is "Electric
235
+ // charge-point allowance" (L136 = 54); box 55's cell O144 is the small pools
236
+ // formula, so the enhanced-allowance figure has no input cell of its own.
237
237
  export const ANNUAL_ALLOWANCE_CELLS = {
238
238
  zeroEmissionsGoodsVehicleAllowance: "D152",
239
239
  zeroEmissionsCarAllowance: "D156",
@@ -2604,12 +2604,13 @@ export function checkCompliance(results, expected, taxData, calculateExpectedTax
2604
2604
  num(seFull.D174) - num(seFull.O122) - num(seFull.O160),
2605
2605
  ownUseStated,
2606
2606
  );
2607
- // Box 77's formula is O179+E197+D210+P190: box 65 plus box 71, with the
2608
- // box 68 and 72 terms reading the blank cell beside each dash.
2607
+ // Box 77's formula is O179-N(D197)-D210-N(O190): box 65 reduced by box
2608
+ // 71, with the box 68 and 72 terms reading each printed dash (always
2609
+ // nil -- neither box has an input cell on this template).
2609
2610
  check(
2610
- "SA103F box 77 adjusted loss (D219) = box 65 plus the box 71 figure the book states",
2611
+ "SA103F box 77 adjusted loss (D219) = box 65 less the box 71 figure the book states",
2611
2612
  num(seFull.D219),
2612
- num(seFull.O179) + (statedAdjustments.accountingAdjustment || 0),
2613
+ num(seFull.O179) - (statedAdjustments.accountingAdjustment || 0),
2613
2614
  );
2614
2615
  // Box 73 reads box 64 alone (O194 = O174). HMRC's working sheet adds box
2615
2616
  // 71 to the adjusted profit; the sheet carries box 71 into box 77 only.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@diy-accounting-uk/diya-gl",
3
- "version": "1.2.11",
3
+ "version": "1.2.12",
4
4
  "type": "module",
5
5
  "description": "Recalculate, read and write DIYA-GL books from the command line",
6
6
  "license": "Apache-2.0",