equal
deleted
inserted
replaced
138 new_params['list_main'] = 'soc/list/main.html' |
138 new_params['list_main'] = 'soc/list/main.html' |
139 new_params['list_pagination'] = 'soc/list/pagination.html' |
139 new_params['list_pagination'] = 'soc/list/pagination.html' |
140 new_params['list_row'] = 'soc/%(module_name)s/list/row.html' % params |
140 new_params['list_row'] = 'soc/%(module_name)s/list/row.html' % params |
141 new_params['list_heading'] = 'soc/%(module_name)s/list/heading.html' % params |
141 new_params['list_heading'] = 'soc/%(module_name)s/list/heading.html' % params |
142 |
142 |
143 new_params['list_action'] = '/' + params['url_name'] + '/edit' |
143 new_params['list_action'] = (self.getEditRedirect, None) |
144 new_params['list_params'] = { |
144 new_params['list_params'] = { |
145 'list_action': 'action', |
145 'list_action': 'action', |
146 'list_description': 'description', |
146 'list_description': 'description', |
147 'list_main': 'main', |
147 'list_main': 'main', |
148 'list_pagination': 'pagination', |
148 'list_pagination': 'pagination', |
441 self._logic.delete(entity) |
441 self._logic.delete(entity) |
442 redirect = params['delete_redirect'] |
442 redirect = params['delete_redirect'] |
443 |
443 |
444 return http.HttpResponseRedirect(redirect) |
444 return http.HttpResponseRedirect(redirect) |
445 |
445 |
|
446 def getEditRedirect(self, entity, _): |
|
447 """Returns the edit redirect for the specified entity |
|
448 """ |
|
449 |
|
450 suffix = self._logic.getKeySuffix(entity) |
|
451 url_name = self._params['url_name'] |
|
452 return '/%s/edit/%s' % (url_name, suffix) |
|
453 |
446 def _editPost(self, request, entity, fields): |
454 def _editPost(self, request, entity, fields): |
447 """Performs any required processing on the entity to post its edit page. |
455 """Performs any required processing on the entity to post its edit page. |
448 |
456 |
449 Args: |
457 Args: |
450 request: the django request object |
458 request: the django request object |