equal
deleted
inserted
replaced
70 """ |
70 """ |
71 |
71 |
72 rights = {} |
72 rights = {} |
73 rights['unspecified'] = [access.checkIsDeveloper] |
73 rights['unspecified'] = [access.checkIsDeveloper] |
74 rights['any_access'] = [access.allow] |
74 rights['any_access'] = [access.allow] |
75 rights['public'] = [access.allow] |
75 rights['show'] = [access.allow] |
76 |
76 |
77 new_params = {} |
77 new_params = {} |
78 new_params['logic'] = soc.logic.models.site.logic |
78 new_params['logic'] = soc.logic.models.site.logic |
79 new_params['rights'] = rights |
79 new_params['rights'] = rights |
80 |
80 |
99 page_name = "Home Page" |
99 page_name = "Home Page" |
100 patterns += [(r'^$', 'soc.views.models.%(module_name)s.main_public', |
100 patterns += [(r'^$', 'soc.views.models.%(module_name)s.main_public', |
101 page_name)] |
101 page_name)] |
102 |
102 |
103 page_name = "Edit Site" |
103 page_name = "Edit Site" |
104 patterns += [(r'^%(url_name)s/edit$', |
104 patterns += [(r'^%(url_name)s/(?P<access_type>edit)$', |
105 'soc.views.models.%(module_name)s.main_edit', |
105 'soc.views.models.%(module_name)s.main_edit', |
106 page_name)] |
106 page_name)] |
107 |
107 |
108 new_params['extra_django_patterns'] = patterns |
108 new_params['extra_django_patterns'] = patterns |
109 |
109 |
144 # No entity in this case, since Site key values are hard-coded for the |
144 # No entity in this case, since Site key values are hard-coded for the |
145 # Site singleton, so pass in None to match parent method footprint. |
145 # Site singleton, so pass in None to match parent method footprint. |
146 values = self._logic.getKeyValues(None) |
146 values = self._logic.getKeyValues(None) |
147 key_values = dicts.zip(keys, values) |
147 key_values = dicts.zip(keys, values) |
148 |
148 |
149 return self.public(request, page_name, **key_values) |
149 return self.public(request, "show", page_name, **key_values) |
150 |
150 |
151 def mainEdit(self, request, page_name=None, **kwargs): |
151 def mainEdit(self, request, page_name=None, **kwargs): |
152 """Displays the edit page for the main site settings page. |
152 """Displays the edit page for the main site settings page. |
153 |
153 |
154 Args: |
154 Args: |