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
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
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Mikolaï Krol
erp5
Commits
8c1669e6
Commit
8c1669e6
authored
Dec 27, 2019
by
Arnaud Fontaine
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ZODB Components: Preparation of erp5_base migration from FS: Fix pylint bad-indentation warnings.
parent
232d4b45
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
34 additions
and
34 deletions
+34
-34
product/ERP5/Document/Supply.py
product/ERP5/Document/Supply.py
+33
-33
product/ERP5/mixin/composition.py
product/ERP5/mixin/composition.py
+1
-1
No files found.
product/ERP5/Document/Supply.py
View file @
8c1669e6
...
@@ -33,39 +33,39 @@ from Products.ERP5Type.XMLObject import XMLObject
...
@@ -33,39 +33,39 @@ from Products.ERP5Type.XMLObject import XMLObject
from
Products.ERP5.Document.Path
import
Path
from
Products.ERP5.Document.Path
import
Path
class
Supply
(
Path
,
XMLObject
):
class
Supply
(
Path
,
XMLObject
):
"""A Supply defines precise pricing and shipping conditions between
"""A Supply defines precise pricing and shipping conditions between
two trade parties for a limited selection of traded products,
two trade parties for a limited selection of traded products,
components, services, etc. It can be used to represent price
components, services, etc. It can be used to represent price
catalogs, product referencing, pricing policy, etc.
catalogs, product referencing, pricing policy, etc.
"""
"""
# CMF Type Definition
# CMF Type Definition
meta_type
=
'ERP5 Supply'
meta_type
=
'ERP5 Supply'
portal_type
=
'Supply'
portal_type
=
'Supply'
# Declarative security
# Declarative security
security
=
ClassSecurityInfo
()
security
=
ClassSecurityInfo
()
security
.
declareObjectProtected
(
Permissions
.
AccessContentsInformation
)
security
.
declareObjectProtected
(
Permissions
.
AccessContentsInformation
)
# Default Properties
# Default Properties
property_sheets
=
(
PropertySheet
.
Base
property_sheets
=
(
PropertySheet
.
Base
,
PropertySheet
.
XMLObject
,
PropertySheet
.
XMLObject
,
PropertySheet
.
CategoryCore
,
PropertySheet
.
CategoryCore
,
PropertySheet
.
DublinCore
,
PropertySheet
.
DublinCore
,
PropertySheet
.
Task
,
PropertySheet
.
Task
,
PropertySheet
.
Arrow
,
PropertySheet
.
Arrow
,
PropertySheet
.
Price
,
PropertySheet
.
Price
,
PropertySheet
.
Movement
,
PropertySheet
.
Movement
,
PropertySheet
.
Delivery
,
PropertySheet
.
Delivery
,
PropertySheet
.
Path
,
PropertySheet
.
Path
,
PropertySheet
.
FlowCapacity
,
PropertySheet
.
FlowCapacity
,
PropertySheet
.
Comment
,
PropertySheet
.
Comment
)
)
#######################################################
#######################################################
# Defer indexing process
# Defer indexing process
def
reindexObject
(
self
,
*
k
,
**
kw
):
def
reindexObject
(
self
,
*
k
,
**
kw
):
"""
"""
Reindex children, as editing properties on Supply need
Reindex children, as editing properties on Supply need
to be propagated into predicate table for Supply Line
to be propagated into predicate table for Supply Line
"""
"""
self
.
recursiveReindexObject
(
*
k
,
**
kw
)
self
.
recursiveReindexObject
(
*
k
,
**
kw
)
product/ERP5/mixin/composition.py
View file @
8c1669e6
...
@@ -78,7 +78,7 @@ def _getEffectiveModel(self, start_date, stop_date):
...
@@ -78,7 +78,7 @@ def _getEffectiveModel(self, start_date, stop_date):
sort_on
=
((
'version'
,
'descending'
),))
sort_on
=
((
'version'
,
'descending'
),))
if
not
model_list
:
if
not
model_list
:
if
self
.
getValidationState
()
==
'invalidated'
:
if
self
.
getValidationState
()
==
'invalidated'
:
return
self
return
self
raise
KeyError
(
'No %s found with the reference %s between %s and %s'
%
\
raise
KeyError
(
'No %s found with the reference %s between %s and %s'
%
\
(
self
.
getPortalType
(),
reference
,
start_date
,
stop_date
))
(
self
.
getPortalType
(),
reference
,
start_date
,
stop_date
))
return
model_list
[
0
].
getObject
()
return
model_list
[
0
].
getObject
()
...
...
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