TODO comment cleanups. Remove unused Document model method.
This commit is contained in:
@@ -348,8 +348,6 @@ class SingleObjectDetailView(ViewPermissionCheckMixin, ObjectPermissionCheckMixi
|
||||
return context
|
||||
|
||||
|
||||
# TODO: check/test if ViewPermissionCheckMixin, ObjectPermissionCheckMixin are
|
||||
# in the right MRO
|
||||
class SingleObjectEditView(ViewPermissionCheckMixin, ObjectPermissionCheckMixin, ExtraContextMixin, RedirectionMixin, UpdateView):
|
||||
template_name = 'appearance/generic_form.html'
|
||||
|
||||
|
||||
@@ -107,7 +107,6 @@ class ObjectPermissionCheckMixin(object):
|
||||
return self.get_object()
|
||||
|
||||
def dispatch(self, request, *args, **kwargs):
|
||||
|
||||
if self.object_permission:
|
||||
try:
|
||||
Permission.check_permissions(
|
||||
|
||||
@@ -271,13 +271,6 @@ class Document(models.Model):
|
||||
def date_updated(self):
|
||||
return self.latest_version.timestamp
|
||||
|
||||
# TODO: look to remove, only used by the OCR parser
|
||||
def document_save_to_temp_dir(self, filename, buffer_size=1024 * 1024):
|
||||
temporary_path = os.path.join(
|
||||
setting_temporary_directory.value, filename
|
||||
)
|
||||
return self.save_to_file(temporary_path, buffer_size)
|
||||
|
||||
# TODO: rename to file_encoding
|
||||
@property
|
||||
def file_mime_encoding(self):
|
||||
|
||||
Reference in New Issue
Block a user