Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Mukul
erp5
Commits
4c59a549
Commit
4c59a549
authored
Jan 03, 2018
by
Nicolas Wavrant
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_payroll_l10n_fr: declares CTP 801 and 059 with correct signs
parent
924411f0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
5 deletions
+12
-5
bt5/erp5_payroll_l10n_fr/SkinTemplateItem/portal_skins/erp5_payroll_l10n_fr/DSNMonthlyReport_getDataDict.py
...kins/erp5_payroll_l10n_fr/DSNMonthlyReport_getDataDict.py
+2
-1
bt5/erp5_payroll_l10n_fr/SkinTemplateItem/portal_skins/erp5_payroll_l10n_fr/PaySheetTransaction_getSocialContributionDict.py
..._l10n_fr/PaySheetTransaction_getSocialContributionDict.py
+10
-4
No files found.
bt5/erp5_payroll_l10n_fr/SkinTemplateItem/portal_skins/erp5_payroll_l10n_fr/DSNMonthlyReport_getDataDict.py
View file @
4c59a549
...
...
@@ -205,7 +205,8 @@ if block_id == 'S21.G00.23':
if
target
[
'code'
][:
3
]
!=
'801'
:
assert
target
[
'quantity'
]
>
0
else
:
assert
target
[
'quantity'
]
<
0
target
[
'quantity'
]
=
target
[
'quantity'
]
*
-
1.
assert
target
[
'quantity'
]
>
0
rubric_value_dict
[
'S21.G00.23.005'
]
=
formatFloat
(
round
(
target
[
'quantity'
]))
else
:
rubric_value_dict
[
'S21.G00.23.004'
]
=
formatFloat
(
round
(
target
[
'base'
]))
...
...
bt5/erp5_payroll_l10n_fr/SkinTemplateItem/portal_skins/erp5_payroll_l10n_fr/PaySheetTransaction_getSocialContributionDict.py
View file @
4c59a549
...
...
@@ -56,7 +56,7 @@ INSEE_CODE = getINSEECode(ZIP_CODE)
def
makeCTPBlock
(
movement
,
category
):
quantity
=
0.
if
category
[:
3
]
in
(
'437'
,
'671'
):
if
category
[:
3
]
in
(
'437'
,
'671'
,
'801'
):
quantity
=
getattr
(
movement
,
'employer_total_price'
,
0.
)
+
getattr
(
movement
,
'employee_total_price'
,
0.
)
return
{
'code'
:
category
,
...
...
@@ -106,11 +106,17 @@ def makeTaxableBaseComponentBlock(movement, category):
def
makeIndividualContributionBlock
(
movement
,
category
):
base
=
quantity
=
0.0
if
category
in
(
'018'
,
'063'
,
'064'
,
'059'
):
if
category
in
(
'018'
,
'063'
,
'064'
):
quantity
=
(
getattr
(
movement
,
'employer_total_price'
,
0
)
+
getattr
(
movement
,
'employee_total_price'
,
0
))
*
-
1
if
category
==
'018'
:
# If "reduction generale but CTP is 801P then it should be positive, as we have to give money back
if
category
==
'018'
and
'base_amount/payroll/l10n/fr/ctp/801P'
not
in
movement
.
getBaseContributionList
():
assert
quantity
<=
0.
,
"Quantity in %s should be negative"
%
movement
.
absolute_url
()
base
=
movement
.
base
elif
category
==
'018'
:
assert
quantity
>=
0.
,
"Quantity in %s should be positive"
%
movement
.
absolute_url
()
base
=
movement
.
base
elif
category
in
(
'059'
,):
quantity
=
(
getattr
(
movement
,
'employer_total_price'
,
0
)
+
getattr
(
movement
,
'employee_total_price'
,
0
))
*
-
1
base
=
0.
else
:
base
=
movement
.
base
return
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment