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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Sebastien Robin
erp5
Commits
e3e31c6f
Commit
e3e31c6f
authored
Dec 20, 2012
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
no need to set date on trade conditions
parent
f523bb61
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
12 deletions
+9
-12
bt5/erp5_configurator_standard/TestTemplateItem/testStandardConfigurationWorkflow.py
...ard/TestTemplateItem/testStandardConfigurationWorkflow.py
+7
-6
product/ERP5Configurator/Document/PurchaseTradeConditionConfiguratorItem.py
...urator/Document/PurchaseTradeConditionConfiguratorItem.py
+1
-3
product/ERP5Configurator/Document/SaleTradeConditionConfiguratorItem.py
...nfigurator/Document/SaleTradeConditionConfiguratorItem.py
+1
-3
No files found.
bt5/erp5_configurator_standard/TestTemplateItem/testStandardConfigurationWorkflow.py
View file @
e3e31c6f
...
...
@@ -755,8 +755,9 @@ class StandardConfigurationMixin(TestLiveConfiguratorWorkflowMixin):
sale_trade_condition
.
getTitle
())
self
.
assertEquals
(
"STC-General"
,
sale_trade_condition
.
getReference
())
self
.
assertNotEquals
(
None
,
sale_trade_condition
.
getEffectiveDate
())
self
.
assertNotEquals
(
None
,
sale_trade_condition
.
getExpirationDate
())
# Trade condition does not need dates
self
.
assertEquals
(
None
,
sale_trade_condition
.
getEffectiveDate
())
self
.
assertEquals
(
None
,
sale_trade_condition
.
getExpirationDate
())
# Check relation with Business Process
business_process_list
=
\
...
...
@@ -801,8 +802,9 @@ class StandardConfigurationMixin(TestLiveConfiguratorWorkflowMixin):
purchase_trade_condition
.
getTitle
())
self
.
assertEquals
(
"PTC-General"
,
purchase_trade_condition
.
getReference
())
self
.
assertNotEquals
(
None
,
purchase_trade_condition
.
getEffectiveDate
())
self
.
assertNotEquals
(
None
,
purchase_trade_condition
.
getExpirationDate
())
# Trade condition does not need dates
self
.
assertEquals
(
None
,
purchase_trade_condition
.
getEffectiveDate
())
self
.
assertEquals
(
None
,
purchase_trade_condition
.
getExpirationDate
())
# Check relation with Business Process
business_process_list
=
\
...
...
@@ -932,8 +934,7 @@ class StandardConfigurationMixin(TestLiveConfiguratorWorkflowMixin):
resource
.
validate
()
self
.
tic
()
start_date
=
sale_trade_condition
.
getEffectiveDate
()
+
1
stop_date
=
sale_trade_condition
.
getExpirationDate
()
-
1
start_date
=
stop_date
=
DateTime
()
order
=
module
.
newContent
(
portal_type
=
'Sale Order'
,
specialise
=
(
sale_trade_condition
.
getRelativeUrl
(),),
...
...
product/ERP5Configurator/Document/PurchaseTradeConditionConfiguratorItem.py
View file @
e3e31c6f
...
...
@@ -72,9 +72,7 @@ class PurchaseTradeConditionConfiguratorItem(ConfiguratorItemMixin, XMLObject):
trade_condition
=
portal
.
purchase_trade_condition_module
.
newContent
(
portal_type
=
"Purchase Trade Condition"
,
reference
=
self
.
getReference
(),
title
=
self
.
getTitle
(),
effective_date
=
DateTime
()
-
1
,
expiration_date
=
DateTime
()
+
10
*
365
)
title
=
self
.
getTitle
(),
)
trade_condition
.
setSpecialise
(
"business_process_module/%s"
%
\
business_process_id
)
...
...
product/ERP5Configurator/Document/SaleTradeConditionConfiguratorItem.py
View file @
e3e31c6f
...
...
@@ -72,9 +72,7 @@ class SaleTradeConditionConfiguratorItem(ConfiguratorItemMixin, XMLObject):
trade_condition
=
portal
.
sale_trade_condition_module
.
newContent
(
portal_type
=
"Sale Trade Condition"
,
reference
=
self
.
getReference
(),
title
=
self
.
getTitle
(),
effective_date
=
DateTime
()
-
1
,
expiration_date
=
DateTime
()
+
10
*
365
)
title
=
self
.
getTitle
())
trade_condition
.
setSpecialise
(
"business_process_module/%s"
%
\
business_process_id
)
...
...
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