Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
O
odoo
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cooperatic-foodcoops
odoo
Commits
12040160
Commit
12040160
authored
Jun 11, 2021
by
François C.
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix shifts creation bug if non-recurrent shift_template exist in database
parent
f42b52db
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
shift_template.py
intercoop_addons/coop_shift/model/shift_template.py
+2
-0
No files found.
intercoop_addons/coop_shift/model/shift_template.py
View file @
12040160
...
...
@@ -578,6 +578,8 @@ class ShiftTemplate(models.Model):
before
=
fields
.
Datetime
.
to_string
(
datetime
.
today
()
+
timedelta
(
days
=
SHIFT_CREATION_DAYS
))
for
template
in
self
:
if
len
(
str
(
template
.
rrule
)
.
strip
())
==
0
:
continue
# It's not a recurring template
after
=
template
.
last_shift_date
rec_dates
=
template
.
get_recurrent_dates
(
after
=
after
,
before
=
before
)
...
...
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