update
This commit is contained in:
+5
-1
@@ -57,6 +57,9 @@ class Worker:
|
||||
if end_oop_date > Rota.rota_end_date:
|
||||
end_oop_date = Rota.rota_end_date
|
||||
|
||||
if start_oop_date < Rota.start_date:
|
||||
start_oop_date = Rota.start_date
|
||||
|
||||
oop_length = (end_oop_date - start_oop_date).days
|
||||
days_to_work = days_to_work - oop_length
|
||||
|
||||
@@ -85,9 +88,10 @@ class Worker:
|
||||
self.fte_adj = self.fte * self.proportion_rota_to_work
|
||||
|
||||
def __lt__(self, other):
|
||||
return (self.site, self.grade, self.name) < (
|
||||
return (self.site, self.grade, self.fte_adj, self.name) < (
|
||||
other.site,
|
||||
other.grade,
|
||||
other.fte_adj,
|
||||
other.name,
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user