|
@ -98,6 +98,12 @@ class Project(Volunteer): |
|
|
# self.finance_id = "1234000" |
|
|
# self.finance_id = "1234000" |
|
|
year = self.start.year |
|
|
year = self.start.year |
|
|
print(f"startyear: {year}") |
|
|
print(f"startyear: {year}") |
|
|
|
|
|
projects = Project.objects.filter(start__year=year) |
|
|
|
|
|
print(projects) |
|
|
|
|
|
if not projects: |
|
|
|
|
|
self.project_of_year = 1 |
|
|
|
|
|
else: |
|
|
|
|
|
pass |
|
|
else: |
|
|
else: |
|
|
print(f"project_of_year is {self.project_of_year}") |
|
|
print(f"project_of_year is {self.project_of_year}") |
|
|
super().save(*args,**kwargs) |
|
|
super().save(*args,**kwargs) |
|
|