Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5_fork
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
Eteri
erp5_fork
Commits
d23c2a26
Commit
d23c2a26
authored
Apr 10, 2014
by
Sebastien Robin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_calendar: make sure to take into account start and stop date of assignment
parent
2e617f64
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
5 deletions
+10
-5
bt5/erp5_calendar/DocumentTemplateItem/portal_components/document.erp5.GroupCalendarAssignment.py
...ortal_components/document.erp5.GroupCalendarAssignment.py
+9
-4
bt5/erp5_calendar/bt/revision
bt5/erp5_calendar/bt/revision
+1
-1
No files found.
bt5/erp5_calendar/DocumentTemplateItem/portal_components/document.erp5.GroupCalendarAssignment.py
View file @
d23c2a26
...
...
@@ -40,11 +40,16 @@ class GroupCalendarAssignment(PresencePeriod):
def
_getDatePeriodDataList
(
self
):
result
=
[]
start_date
=
self
.
getStartDate
()
stop_date
=
self
.
getStopDate
()
group_calendar
=
self
.
getSpecialiseValue
()
if
not
(
None
in
(
self
.
getDestinationUid
(),
group_calendar
)):
if
not
(
None
in
(
self
.
getDestinationUid
(),
group_calendar
,
start_date
,
stop_date
)):
presence_period_list
=
group_calendar
.
objectValues
(
portal_type
=
"Group Presence Period"
)
for
presence_period
in
presence_period_list
:
result
.
extend
(
presence_period
.
_getDatePeriodDataList
())
for
date_period_data
in
presence_period
.
_getDatePeriodDataList
():
if
date_period_data
[
'start_date'
].
greaterThanEqualTo
(
start_date
)
and
\
date_period_data
[
'stop_date'
].
lessThanEqualTo
(
stop_date
):
result
.
append
(
date_period_data
)
return
result
\ No newline at end of file
bt5/erp5_calendar/bt/revision
View file @
d23c2a26
385
\ No newline at end of file
386
\ 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