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
Labels
Merge Requests
141
Merge Requests
141
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
nexedi
erp5
Commits
da9f2870
Commit
da9f2870
authored
Jan 27, 2024
by
Jérome Perrin
Committed by
Arnaud Fontaine
Jul 05, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
accounting py3
parent
e645052d
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
10 deletions
+15
-10
bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountingTransactionLine_getNodeItemList.py
...5_accounting/AccountingTransactionLine_getNodeItemList.py
+1
-4
bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountingTransactionModule_getAgedBalanceLineList.py
...ing/AccountingTransactionModule_getAgedBalanceLineList.py
+1
-1
bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountingTransactionModule_getAgedBalanceReportSectionList.py
...ntingTransactionModule_getAgedBalanceReportSectionList.py
+12
-4
bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountingTransaction_getAccountingTransactionLineList.py
...AccountingTransaction_getAccountingTransactionLineList.py
+1
-1
No files found.
bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountingTransactionLine_getNodeItemList.py
View file @
da9f2870
...
...
@@ -50,9 +50,6 @@ def display(x):
display_cache
[
x
]
=
display_funct
(
x
)
return
display_cache
[
x
]
def
sort
(
x
,
y
):
return
cmp
(
display
(
x
),
display
(
y
))
def
getItemList
(
category
=
None
,
portal_path
=
None
,
mirror
=
0
,
omit_filter
=
0
,
simulation_state
=
None
):
"""Returns a list of Account path items. """
...
...
@@ -71,7 +68,7 @@ def getItemList(category=None, portal_path=None, mirror=0, omit_filter=0,
portal_type
=
'Account'
,
base
=
0
,
display_method
=
display
,
sort_
method
=
sort
,
sort_
key
=
display
,
filter
=
filter_dict
)
return
item_list
...
...
bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountingTransactionModule_getAgedBalanceLineList.py
View file @
da9f2870
...
...
@@ -118,7 +118,7 @@ for brain in portal.portal_simulation.getMovementHistoryList(
if
by_mirror_section_list_dict
:
for
row
in
portal_catalog
(
select_list
=
[
'title'
],
uid
=
by_mirror_section_list_dict
.
keys
(
),
uid
=
list
(
by_mirror_section_list_dict
.
keys
()
),
):
title
=
row
.
title
for
line
in
by_mirror_section_list_dict
[
row
.
uid
]:
...
...
bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountingTransactionModule_getAgedBalanceReportSectionList.py
View file @
da9f2870
import
six
from
Products.ERP5Type.Message
import
translateString
from
Products.ERP5Form.Report
import
ReportSection
if
six
.
PY2
:
def
translate
(
*
args
,
**
kw
):
return
unicode
(
translateString
(
*
args
,
**
kw
))
else
:
def
translate
(
*
args
,
**
kw
):
return
str
(
translateString
(
*
args
,
**
kw
))
request
=
container
.
REQUEST
section_category
=
request
[
'section_category'
]
section_category_strict
=
request
[
'section_category_strict'
]
...
...
@@ -30,16 +38,16 @@ previous_period = 0
for
idx
,
period
in
enumerate
(
period_list
):
if
idx
!=
0
:
previous_period
=
period_list
[
idx
-
1
]
selection_columns
.
append
((
'period_%s'
%
idx
,
unicode
(
translateString
(
selection_columns
.
append
((
'period_%s'
%
idx
,
translate
(
'Period ${period_number} (from ${from} to ${to} days)'
,
mapping
=
{
'period_number'
:
1
+
idx
,
'from'
:
previous_period
,
'to'
:
period
}
)))
)
'to'
:
period
}
)))
editable_columns
.
append
((
'period_%s'
%
idx
,
''
))
selection_columns
.
append
((
'period_%s'
%
(
idx
+
1
),
unicode
(
translateString
(
'Older (more than ${day_count} days)'
,
mapping
=
{
'day_count'
:
period_list
[
-
1
]})))
)
translate
(
'Older (more than ${day_count} days)'
,
mapping
=
{
'day_count'
:
period_list
[
-
1
]})))
editable_columns
.
append
((
'period_%s'
%
(
idx
+
1
),
''
))
selection_params
=
dict
(
section_category
=
section_category
,
...
...
bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountingTransaction_getAccountingTransactionLineList.py
View file @
da9f2870
...
...
@@ -9,6 +9,6 @@ sort_dict = { 'income': 0,
'refundable_vat'
:
-
1
}
def
getAccountingTransactionLineSortKey
(
line
):
return
sort_dict
.
get
(
line
.
getId
(),
line
.
getIntIndex
()
or
line
.
getIntId
(
))
return
sort_dict
.
get
(
line
.
getId
(),
(
line
.
getIntIndex
()
or
line
.
getIntId
()
or
0
))
return
sorted
(
context
.
contentValues
(
portal_type
=
portal_type
,
checked_permission
=
"View"
),
key
=
getAccountingTransactionLineSortKey
)
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