Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
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
Lu Xu
slapos.core
Commits
4a5051de
Commit
4a5051de
authored
Mar 12, 2012
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Stabilise stop_date setting.
parent
bc49a68e
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
10 deletions
+15
-10
master/bt5/vifib_slap/SkinTemplateItem/portal_skins/vifib_slap/Person_updateOpenOrder.xml
...teItem/portal_skins/vifib_slap/Person_updateOpenOrder.xml
+14
-9
master/bt5/vifib_slap/bt/revision
master/bt5/vifib_slap/bt/revision
+1
-1
No files found.
master/bt5/vifib_slap/SkinTemplateItem/portal_skins/vifib_slap/Person_updateOpenOrder.xml
View file @
4a5051de
...
...
@@ -122,7 +122,12 @@ else:\n
order = previous_open_sale_order or open_sale_order\n
need_update = False\n
for line in order.contentValues(portal_type=\'Open Sale Order Line\'):\n
if line.getStopDate() is not None and line.getStopDate()
< next_month:
\n
old_stop_date = line.getStopDate()\n
if old_stop_date is not None:\n
new_stop_date = stop_date\n
if new_stop_date is None:\n
new_stop_date = old_stop_date + getNumberOfDayInMonth(old_stop_date)\n
if new_stop_date
< next_month:
\n
need_update =
True\n
break\n
\n
...
...
@@ -131,11 +136,11 @@ if need_update:\n
open_sale_order =
previous_open_sale_order.Base_createCloneDocument(batch_mode=1)\n
for
line
in
open_sale_order.contentValues(
portal_type=
\'Open
Sale
Order
Line\'):\n
old_stop_date =
line.getStopDate()\n
if
old_stop_date
is
not
None
and
old_stop_date
<
next_month:\n
if
stop_date
is
not
None:\n
if
old_stop_date
is
not
None:\n
new_stop_date =
stop_date\n
else:\n
new_stop_date =
old_stop_date
+
getNumberOfDayInMonth(old_stop_date)
\n
if
new_stop_date
is
None:\n
new_stop_date =
old_stop_date
+
getNumberOfDayInMonth(old_stop_date)\n
if
new_stop_date
<
next_month:\n
line.setStopDate(new_stop_date,
activate_kw=
activate_kw)\n
\n
for
remove_hosting
in
remove_hosting_list:\n
...
...
master/bt5/vifib_slap/bt/revision
View file @
4a5051de
634
\ No newline at end of file
635
\ No newline at end of file
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