equal
deleted
inserted
replaced
20 __authors__ = [ |
20 __authors__ = [ |
21 '"Sverre Rabbelier" <sverre@rabbelier.nl>', |
21 '"Sverre Rabbelier" <sverre@rabbelier.nl>', |
22 ] |
22 ] |
23 |
23 |
24 |
24 |
|
25 from soc.cache import sidebar |
25 from soc.logic.models import presence_with_tos |
26 from soc.logic.models import presence_with_tos |
26 |
27 |
27 import soc.models.presence_with_tos |
28 import soc.models.presence_with_tos |
28 import soc.models.site |
29 import soc.models.site |
29 |
30 |
77 def getSingleton(self): |
78 def getSingleton(self): |
78 """Return singleton Site settings entity, since there is always only one. |
79 """Return singleton Site settings entity, since there is always only one. |
79 """ |
80 """ |
80 return self.getFromFields(link_id=self.DEF_SITE_LINK_ID) |
81 return self.getFromFields(link_id=self.DEF_SITE_LINK_ID) |
81 |
82 |
|
83 def _onCreate(self, entity): |
|
84 """Flush the sidebar cache when a new active role entity has been created. |
|
85 """ |
|
86 |
|
87 sidebar.flush() |
|
88 |
82 |
89 |
83 logic = Logic() |
90 logic = Logic() |