Skip to main content
Sign in
Snippets Groups Projects
Commit ce26c958 authored by Emmanuel Raviart's avatar Emmanuel Raviart
Browse files

Merge branch 'fix-rsa' into 'master'

Fix the attribution of RSA for test cases with high income

See merge request leximpact/leximpact-socio-fiscal-ui!12
parents c78f6b9c 9c122279
Branches
Tags
1 merge request!12Fix the attribution of RSA for test cases with high income
......@@ -209,12 +209,25 @@
...adultes.map((adulte, index) => [
`Adulte ${index + 1}`,
{
// set all resources for 3 years
// salaire_de_base: { [year]: adulte.salaire_de_base },
salaire_de_base: Object.fromEntries(
[...new Array(12)].map((_, index) => [
[...new Array(12)]
.map((_, index) => [
[
`${year - 2}-${(index + 1).toString().padStart(2, "0")}`,
adulte.salaire_de_base / 12,
],
[
`${year - 1}-${(index + 1).toString().padStart(2, "0")}`,
adulte.salaire_de_base / 12,
],
[
`${year}-${(index + 1).toString().padStart(2, "0")}`,
adulte.salaire_de_base / 12,
]),
],
])
.flat(1),
),
},
]),
......
......
......@@ -173,12 +173,25 @@
...adultes.map((adulte, index) => [
`Adulte ${index + 1}`,
{
// set all resources for 3 years
// salaire_de_base: { [year]: adulte.salaire_de_base },
salaire_de_base: Object.fromEntries(
[...new Array(12)].map((_, index) => [
[...new Array(12)]
.map((_, index) => [
[
`${year - 2}-${(index + 1).toString().padStart(2, "0")}`,
adulte.salaire_de_base / 12,
],
[
`${year - 1}-${(index + 1).toString().padStart(2, "0")}`,
adulte.salaire_de_base / 12,
],
[
`${year}-${(index + 1).toString().padStart(2, "0")}`,
adulte.salaire_de_base / 12,
]),
],
])
.flat(1),
),
},
]),
......
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment