def get_success_url(self):
messages.success(self.request, _('The File Link "%s" was removed successfully from virtual environment "%s"!')%(self.object.name, self.object.topic.subject.name))
self.log_context['category_id'] = self.object.topic.subject.category.id
self.log_context['category_name'] = self.object.topic.subject.category.name
self.log_context['category_slug'] = self.object.topic.subject.category.slug
self.log_context['subject_id'] = self.object.topic.subject.id
self.log_context['subject_name'] = self.object.topic.subject.name
self.log_context['subject_slug'] = self.object.topic.subject.slug
self.log_context['topic_id'] = self.object.topic.id
self.log_context['topic_name'] = self.object.topic.name
self.log_context['topic_slug'] = self.object.topic.slug
self.log_context['filelink_id'] = self.object.id
self.log_context['filelink_name'] = self.object.name
self.log_context['filelink_slug'] = self.object.slug
super(DeleteView, self).createLog(self.request.user, self.log_component, self.log_action, self.log_resource, self.log_context)
return reverse_lazy('subjects:view', kwargs = {'slug': self.object.topic.subject.slug})
评论列表
文章目录