Merge branch 'development' into feature/indexing_refactor

Conflicts:
	docs/releases/0.12.rst
This commit is contained in:
Roberto Rosario
2012-02-02 02:59:31 -04:00
52 changed files with 2489 additions and 1506 deletions

View File

@@ -188,10 +188,12 @@ class AccessEntryManager(models.Manager):
content_type = ContentType.objects.get_for_model(obj)
holder_list = []
for access_entry in self.model.objects.filter(content_type=content_type, object_id=obj.pk):
entry = AccessHolder.encapsulate(access_entry.holder_object)
if entry not in holder_list:
holder_list.append(entry)
if access_entry.holder_object:
# Don't add references to non existant content type objects
entry = AccessHolder.encapsulate(access_entry.holder_object)
if entry not in holder_list:
holder_list.append(entry)
return holder_list
@@ -259,16 +261,15 @@ class DefaultAccessEntryManager(models.Manager):
"""
def get_holders_for(self, cls):
cls = get_source_object(cls)
#if isinstance(cls, EncapsulatedObject):
# cls = cls.source_object
content_type = ContentType.objects.get_for_model(cls)
holder_list = []
for access_entry in self.model.objects.filter(content_type=content_type):
entry = ClassAccessHolder.encapsulate(access_entry.holder_object)
if access_entry.holder_object:
# Don't add references to non existant content type objects
entry = ClassAccessHolder.encapsulate(access_entry.holder_object)
if entry not in holder_list:
holder_list.append(entry)
if entry not in holder_list:
holder_list.append(entry)
return holder_list

View File

@@ -7,15 +7,15 @@ from django.contrib.contenttypes.models import ContentType
from common.models import AnonymousUserSingleton
from .models import AccessEntry, DefaultAccessEntry, CreatorSingleton
from .classes import EncapsulatedObject, AccessHolder, ClassAccessHolder
from .classes import (EncapsulatedObject, AccessHolder, ClassAccessHolder,
get_source_object)
logger = logging.getLogger(__name__)
def apply_default_acls(obj, actor=None):
logger.debug('actor, init: %s' % actor)
if isinstance(obj, EncapsulatedObject):
obj = obj.source_object
obj = get_source_object(obj)
if actor:
actor = AnonymousUserSingleton.objects.passthru_check(actor)
@@ -24,10 +24,12 @@ def apply_default_acls(obj, actor=None):
for default_acl in DefaultAccessEntry.objects.filter(content_type=content_type):
holder = CreatorSingleton.objects.passthru_check(default_acl.holder_object, actor)
access_entry = AccessEntry(
permission=default_acl.permission,
holder_object=holder,
content_object=obj,
)
access_entry.save()
if holder:
# When the creator is admin
access_entry = AccessEntry(
permission=default_acl.permission,
holder_object=holder,
content_object=obj,
)
access_entry.save()

View File

@@ -398,9 +398,13 @@ def acl_setup_valid_classes(request):
def acl_class_acl_list(request, access_object_class_gid):
logger.debug('access_object_class_gid: %s' % access_object_class_gid)
Permission.objects.check_permissions(request.user, [ACLS_CLASS_VIEW_ACL])
access_object_class = AccessObjectClass.get(gid=access_object_class_gid)
logger.debug('access_object_class: %s' % access_object_class)
context = {
'object_list': DefaultAccessEntry.objects.get_holders_for(access_object_class.source_object),
'title': _(u'default access control lists for class: %s') % access_object_class,

View File

@@ -0,0 +1,144 @@
# encoding: utf-8
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding model 'Folder'
db.create_table('folders_folder', (
('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
('title', self.gf('django.db.models.fields.CharField')(max_length=32, db_index=True)),
('user', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['auth.User'])),
('datetime_created', self.gf('django.db.models.fields.DateTimeField')()),
))
db.send_create_signal('folders', ['Folder'])
# Adding unique constraint on 'Folder', fields ['title', 'user']
db.create_unique('folders_folder', ['title', 'user_id'])
# Adding model 'FolderDocument'
db.create_table('folders_folderdocument', (
('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
('folder', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['folders.Folder'])),
('document', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['documents.Document'])),
))
db.send_create_signal('folders', ['FolderDocument'])
def backwards(self, orm):
# Removing unique constraint on 'Folder', fields ['title', 'user']
db.delete_unique('folders_folder', ['title', 'user_id'])
# Deleting model 'Folder'
db.delete_table('folders_folder')
# Deleting model 'FolderDocument'
db.delete_table('folders_folderdocument')
models = {
'auth.group': {
'Meta': {'object_name': 'Group'},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
},
'auth.permission': {
'Meta': {'ordering': "('content_type__app_label', 'content_type__model', 'codename')", 'unique_together': "(('content_type', 'codename'),)", 'object_name': 'Permission'},
'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['contenttypes.ContentType']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
},
'auth.user': {
'Meta': {'object_name': 'User'},
'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
'groups': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Group']", 'symmetrical': 'False', 'blank': 'True'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'}),
'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
},
'comments.comment': {
'Meta': {'ordering': "('submit_date',)", 'object_name': 'Comment', 'db_table': "'django_comments'"},
'comment': ('django.db.models.fields.TextField', [], {'max_length': '3000'}),
'content_type': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'content_type_set_for_comment'", 'to': "orm['contenttypes.ContentType']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'ip_address': ('django.db.models.fields.IPAddressField', [], {'max_length': '15', 'null': 'True', 'blank': 'True'}),
'is_public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
'is_removed': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
'object_pk': ('django.db.models.fields.TextField', [], {}),
'site': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['sites.Site']"}),
'submit_date': ('django.db.models.fields.DateTimeField', [], {'default': 'None'}),
'user': ('django.db.models.fields.related.ForeignKey', [], {'blank': 'True', 'related_name': "'comment_comments'", 'null': 'True', 'to': "orm['auth.User']"}),
'user_email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
'user_name': ('django.db.models.fields.CharField', [], {'max_length': '50', 'blank': 'True'}),
'user_url': ('django.db.models.fields.URLField', [], {'max_length': '200', 'blank': 'True'})
},
'contenttypes.contenttype': {
'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
},
'documents.document': {
'Meta': {'ordering': "['-date_added']", 'object_name': 'Document'},
'date_added': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
'description': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}),
'document_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['documents.DocumentType']", 'null': 'True', 'blank': 'True'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'uuid': ('django.db.models.fields.CharField', [], {'max_length': '48', 'blank': 'True'})
},
'documents.documenttype': {
'Meta': {'ordering': "['name']", 'object_name': 'DocumentType'},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '32'})
},
'folders.folder': {
'Meta': {'ordering': "('title',)", 'unique_together': "(('title', 'user'),)", 'object_name': 'Folder'},
'datetime_created': ('django.db.models.fields.DateTimeField', [], {}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'title': ('django.db.models.fields.CharField', [], {'max_length': '32', 'db_index': 'True'}),
'user': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['auth.User']"})
},
'folders.folderdocument': {
'Meta': {'object_name': 'FolderDocument'},
'document': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['documents.Document']"}),
'folder': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['folders.Folder']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
},
'sites.site': {
'Meta': {'ordering': "('domain',)", 'object_name': 'Site', 'db_table': "'django_site'"},
'domain': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
},
'taggit.tag': {
'Meta': {'object_name': 'Tag'},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'slug': ('django.db.models.fields.SlugField', [], {'unique': 'True', 'max_length': '100', 'db_index': 'True'})
},
'taggit.taggeditem': {
'Meta': {'object_name': 'TaggedItem'},
'content_type': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'taggit_taggeditem_tagged_items'", 'to': "orm['contenttypes.ContentType']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'object_id': ('django.db.models.fields.IntegerField', [], {'db_index': 'True'}),
'tag': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'taggit_taggeditem_items'", 'to': "orm['taggit.Tag']"})
}
}
complete_apps = ['folders']

View File

@@ -0,0 +1,121 @@
# encoding: utf-8
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Changing field 'Folder.title'
db.alter_column('folders_folder', 'title', self.gf('django.db.models.fields.CharField')(max_length=128))
def backwards(self, orm):
# Changing field 'Folder.title'
db.alter_column('folders_folder', 'title', self.gf('django.db.models.fields.CharField')(max_length=32))
models = {
'auth.group': {
'Meta': {'object_name': 'Group'},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
},
'auth.permission': {
'Meta': {'ordering': "('content_type__app_label', 'content_type__model', 'codename')", 'unique_together': "(('content_type', 'codename'),)", 'object_name': 'Permission'},
'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['contenttypes.ContentType']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
},
'auth.user': {
'Meta': {'object_name': 'User'},
'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
'groups': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Group']", 'symmetrical': 'False', 'blank': 'True'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'}),
'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
},
'comments.comment': {
'Meta': {'ordering': "('submit_date',)", 'object_name': 'Comment', 'db_table': "'django_comments'"},
'comment': ('django.db.models.fields.TextField', [], {'max_length': '3000'}),
'content_type': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'content_type_set_for_comment'", 'to': "orm['contenttypes.ContentType']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'ip_address': ('django.db.models.fields.IPAddressField', [], {'max_length': '15', 'null': 'True', 'blank': 'True'}),
'is_public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
'is_removed': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
'object_pk': ('django.db.models.fields.TextField', [], {}),
'site': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['sites.Site']"}),
'submit_date': ('django.db.models.fields.DateTimeField', [], {'default': 'None'}),
'user': ('django.db.models.fields.related.ForeignKey', [], {'blank': 'True', 'related_name': "'comment_comments'", 'null': 'True', 'to': "orm['auth.User']"}),
'user_email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
'user_name': ('django.db.models.fields.CharField', [], {'max_length': '50', 'blank': 'True'}),
'user_url': ('django.db.models.fields.URLField', [], {'max_length': '200', 'blank': 'True'})
},
'contenttypes.contenttype': {
'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
},
'documents.document': {
'Meta': {'ordering': "['-date_added']", 'object_name': 'Document'},
'date_added': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
'description': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}),
'document_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['documents.DocumentType']", 'null': 'True', 'blank': 'True'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'uuid': ('django.db.models.fields.CharField', [], {'max_length': '48', 'blank': 'True'})
},
'documents.documenttype': {
'Meta': {'ordering': "['name']", 'object_name': 'DocumentType'},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '32'})
},
'folders.folder': {
'Meta': {'ordering': "('title',)", 'unique_together': "(('title', 'user'),)", 'object_name': 'Folder'},
'datetime_created': ('django.db.models.fields.DateTimeField', [], {}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'title': ('django.db.models.fields.CharField', [], {'max_length': '128', 'db_index': 'True'}),
'user': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['auth.User']"})
},
'folders.folderdocument': {
'Meta': {'object_name': 'FolderDocument'},
'document': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['documents.Document']"}),
'folder': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['folders.Folder']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
},
'sites.site': {
'Meta': {'ordering': "('domain',)", 'object_name': 'Site', 'db_table': "'django_site'"},
'domain': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
},
'taggit.tag': {
'Meta': {'object_name': 'Tag'},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'slug': ('django.db.models.fields.SlugField', [], {'unique': 'True', 'max_length': '100', 'db_index': 'True'})
},
'taggit.taggeditem': {
'Meta': {'object_name': 'TaggedItem'},
'content_type': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'taggit_taggeditem_tagged_items'", 'to': "orm['contenttypes.ContentType']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'object_id': ('django.db.models.fields.IntegerField', [], {'db_index': 'True'}),
'tag': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'taggit_taggeditem_items'", 'to': "orm['taggit.Tag']"})
}
}
complete_apps = ['folders']

View File

View File

@@ -8,7 +8,7 @@ from documents.models import Document
class Folder(models.Model):
title = models.CharField(max_length=32, verbose_name=_(u'title'), db_index=True)
title = models.CharField(max_length=128, verbose_name=_(u'title'), db_index=True)
user = models.ForeignKey(User, verbose_name=_(u'user'))
datetime_created = models.DateTimeField(verbose_name=_(u'datetime created'))
@@ -26,7 +26,7 @@ class Folder(models.Model):
@property
def documents(self):
return [folder_document.document for folder_document in self.folderdocument_set.all()]
return Document.objects.filter(folderdocument__folder=self)
def remove_document(self, document):
folder_document = self.folderdocument_set.get(document=document)

View File

@@ -456,8 +456,8 @@ def setup_metadata_set_edit(request, metadata_set_id):
return assign_remove(
request,
left_list=lambda: generate_choices_w_labels(get_non_set_members(metadata_set)),
right_list=lambda: generate_choices_w_labels(get_set_members(metadata_set)),
left_list=lambda: generate_choices_w_labels(get_non_set_members(metadata_set), display_object_type=False),
right_list=lambda: generate_choices_w_labels(get_set_members(metadata_set), display_object_type=False),
add_method=lambda x: add_set_member(metadata_set, x),
remove_method=lambda x: remove_set_member(metadata_set, x),
left_list_title=_(u'non members of metadata set: %s') % metadata_set,

View File

@@ -209,11 +209,10 @@ def tag_edit(request, tag_id):
def tag_tagged_item_list(request, tag_id):
tag = get_object_or_404(Tag, pk=tag_id)
object_list = [tagged_item.content_object for tagged_item in tag.taggit_taggeditem_items.all()]
return document_list(
request,
object_list=object_list,
object_list=Document.objects.filter(tags__in=[tag]),
title=_('documents with the tag "%s"') % tag,
extra_context={
'object': tag,

229
docs/_ext/djangodocs.py Normal file
View File

@@ -0,0 +1,229 @@
"""
Sphinx plugins for Django documentation.
"""
import os
import re
from docutils import nodes, transforms
try:
import json
except ImportError:
try:
import simplejson as json
except ImportError:
try:
from django.utils import simplejson as json
except ImportError:
json = None
from sphinx import addnodes, roles, __version__ as sphinx_ver
from sphinx.builders.html import StandaloneHTMLBuilder
from sphinx.writers.html import SmartyPantsHTMLTranslator
from sphinx.util.console import bold
from sphinx.util.compat import Directive
# RE for option descriptions without a '--' prefix
simple_option_desc_re = re.compile(
r'([-_a-zA-Z0-9]+)(\s*.*?)(?=,\s+(?:/|-|--)|$)')
def setup(app):
app.add_crossref_type(
directivename = "setting",
rolename = "setting",
indextemplate = "pair: %s; setting",
)
app.add_crossref_type(
directivename = "templatetag",
rolename = "ttag",
indextemplate = "pair: %s; template tag"
)
app.add_crossref_type(
directivename = "templatefilter",
rolename = "tfilter",
indextemplate = "pair: %s; template filter"
)
app.add_crossref_type(
directivename = "fieldlookup",
rolename = "lookup",
indextemplate = "pair: %s; field lookup type",
)
app.add_description_unit(
directivename = "django-admin",
rolename = "djadmin",
indextemplate = "pair: %s; django-admin command",
parse_node = parse_django_admin_node,
)
app.add_description_unit(
directivename = "django-admin-option",
rolename = "djadminopt",
indextemplate = "pair: %s; django-admin command-line option",
parse_node = parse_django_adminopt_node,
)
app.add_config_value('django_next_version', '0.0', True)
app.add_directive('versionadded', VersionDirective)
app.add_directive('versionchanged', VersionDirective)
app.add_builder(DjangoStandaloneHTMLBuilder)
class VersionDirective(Directive):
has_content = True
required_arguments = 1
optional_arguments = 1
final_argument_whitespace = True
option_spec = {}
def run(self):
env = self.state.document.settings.env
arg0 = self.arguments[0]
is_nextversion = env.config.django_next_version == arg0
ret = []
node = addnodes.versionmodified()
ret.append(node)
if not is_nextversion:
if len(self.arguments) == 1:
linktext = 'Please see the release notes </releases/%s>' % (arg0)
xrefs = roles.XRefRole()('doc', linktext, linktext, self.lineno, self.state)
node.extend(xrefs[0])
node['version'] = arg0
else:
node['version'] = "Development version"
node['type'] = self.name
if len(self.arguments) == 2:
inodes, messages = self.state.inline_text(self.arguments[1], self.lineno+1)
node.extend(inodes)
if self.content:
self.state.nested_parse(self.content, self.content_offset, node)
ret = ret + messages
env.note_versionchange(node['type'], node['version'], node, self.lineno)
return ret
class DjangoHTMLTranslator(SmartyPantsHTMLTranslator):
"""
Django-specific reST to HTML tweaks.
"""
# Don't use border=1, which docutils does by default.
def visit_table(self, node):
self._table_row_index = 0 # Needed by Sphinx
self.body.append(self.starttag(node, 'table', CLASS='docutils'))
# <big>? Really?
def visit_desc_parameterlist(self, node):
self.body.append('(')
self.first_param = 1
self.param_separator = node.child_text_separator
def depart_desc_parameterlist(self, node):
self.body.append(')')
if sphinx_ver < '1.0.8':
#
# Don't apply smartypants to literal blocks
#
def visit_literal_block(self, node):
self.no_smarty += 1
SmartyPantsHTMLTranslator.visit_literal_block(self, node)
def depart_literal_block(self, node):
SmartyPantsHTMLTranslator.depart_literal_block(self, node)
self.no_smarty -= 1
#
# Turn the "new in version" stuff (versionadded/versionchanged) into a
# better callout -- the Sphinx default is just a little span,
# which is a bit less obvious that I'd like.
#
# FIXME: these messages are all hardcoded in English. We need to change
# that to accomodate other language docs, but I can't work out how to make
# that work.
#
version_text = {
'deprecated': 'Deprecated in Django %s',
'versionchanged': 'Changed in Django %s',
'versionadded': 'New in Django %s',
}
def visit_versionmodified(self, node):
self.body.append(
self.starttag(node, 'div', CLASS=node['type'])
)
title = "%s%s" % (
self.version_text[node['type']] % node['version'],
len(node) and ":" or "."
)
self.body.append('<span class="title">%s</span> ' % title)
def depart_versionmodified(self, node):
self.body.append("</div>\n")
# Give each section a unique ID -- nice for custom CSS hooks
def visit_section(self, node):
old_ids = node.get('ids', [])
node['ids'] = ['s-' + i for i in old_ids]
node['ids'].extend(old_ids)
SmartyPantsHTMLTranslator.visit_section(self, node)
node['ids'] = old_ids
def parse_django_admin_node(env, sig, signode):
command = sig.split(' ')[0]
env._django_curr_admin_command = command
title = "django-admin.py %s" % sig
signode += addnodes.desc_name(title, title)
return sig
def parse_django_adminopt_node(env, sig, signode):
"""A copy of sphinx.directives.CmdoptionDesc.parse_signature()"""
from sphinx.domains.std import option_desc_re
count = 0
firstname = ''
for m in option_desc_re.finditer(sig):
optname, args = m.groups()
if count:
signode += addnodes.desc_addname(', ', ', ')
signode += addnodes.desc_name(optname, optname)
signode += addnodes.desc_addname(args, args)
if not count:
firstname = optname
count += 1
if not count:
for m in simple_option_desc_re.finditer(sig):
optname, args = m.groups()
if count:
signode += addnodes.desc_addname(', ', ', ')
signode += addnodes.desc_name(optname, optname)
signode += addnodes.desc_addname(args, args)
if not count:
firstname = optname
count += 1
if not firstname:
raise ValueError
return firstname
class DjangoStandaloneHTMLBuilder(StandaloneHTMLBuilder):
"""
Subclass to add some extra things we need.
"""
name = 'djangohtml'
def finish(self):
super(DjangoStandaloneHTMLBuilder, self).finish()
if json is None:
self.warn("cannot create templatebuiltins.js due to missing simplejson dependency")
return
self.info(bold("writing templatebuiltins.js..."))
xrefs = self.env.domaindata["std"]["objects"]
templatebuiltins = {
"ttags": [n for ((t, n), (l, a)) in xrefs.items()
if t == "templatetag" and l == "ref/templates/builtins"],
"tfilters": [n for ((t, n), (l, a)) in xrefs.items()
if t == "templatefilter" and l == "ref/templates/builtins"],
}
outfilename = os.path.join(self.outdir, "templatebuiltins.js")
f = open(outfilename, 'wb')
f.write('var django_template_builtins = ')
json.dump(templatebuiltins, f)
f.write(';\n')
f.close();

File diff suppressed because it is too large Load Diff

View File

@@ -17,6 +17,7 @@ import sys, os
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
#sys.path.insert(0, os.path.abspath('.'))
sys.path.append(os.path.abspath(os.path.join(os.path.dirname(__file__), "_ext")))
# -- General configuration -----------------------------------------------------
@@ -25,7 +26,9 @@ import sys, os
# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.viewcode']
#extensions = ['sphinx.ext.autodoc', 'sphinx.ext.viewcode']
#extensions = ["djangodocs", "sphinx.ext.intersphinx"]
extensions = ['djangodocs']
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
@@ -48,10 +51,10 @@ copyright = u'2011, Roberto Rosario'
# built documents.
#
# The short X.Y version.
version = '0.11.1'
version = '0.12'
# The full version, including alpha/beta/rc tags.
release = '0.11.1'
release = '0.12 beta'
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
@@ -71,15 +74,15 @@ exclude_patterns = ['_build']
#default_role = None
# If true, '()' will be appended to :func: etc. cross-reference text.
#add_function_parentheses = True
add_function_parentheses = True
# If true, the current module name will be prepended to all description
# unit titles (such as .. function::).
#add_module_names = True
add_module_names = False
# If true, sectionauthor and moduleauthor directives will be shown in the
# output. They are ignored by default.
#show_authors = False
show_authors = False
# The name of the Pygments (syntax highlighting) style to use.
pygments_style = 'sphinx'

View File

@@ -1,130 +0,0 @@
===
FAQ
===
Frequently asked questions and solutions
_mysql_exceptions.OperationalError: (1267, "Illegal mix of collations (latin1_swedish_ci,IMPLICIT) and (utf8_general_ci,COERCIBLE) for operation '='")
------------------------------------------------------------------------------------------------------------------------------------------------------
* Solution::
$ manage.py shell
>>> from django.db import connection
>>> cursor = connection.cursor()
>>> cursor.execute('SHOW TABLES')
>>> results=[]
>>> for row in cursor.fetchall(): results.append(row)
>>> for row in results: cursor.execute('ALTER TABLE %s CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;' % (row[0]))
* References:
- http://www.djangoshmango.com/?p=99
- http://stackoverflow.com/questions/1073295/django-character-set-with-mysql-weirdness
Incorrect string value: ``'\xE2\x80\x95rs6...'`` for column ``'content'`` at row 1
----------------------------------------------------------------------------------
When using ``MySQL`` and doing OCR on languages other than English
* Solution:
- Use utf-8 collation on MySQL server, or at least in table 'documents_documentpage', 'content' field
- Ref: 1- http://groups.google.com/group/django-users/browse_thread/thread/429447086fca6412
- Ref: 2- http://markmail.org/message/bqajx2utvmtriixi
File system links not showing when serving content with ``Samba``
-----------------------------------------------------------------
* Solution:
- Disable unix extensions in the [global] section and enable wide links for the file serving share
- Example::
[global]
unix extensions = no
...
[digitalizacion]
path = /var/local/mayan
guest ok = yes
read only = yes
wide links = yes
follow symlinks = yes
- Ref: 1- http://www.samba.org/samba/docs/man/manpages-3/smb.conf.5.html
How to store documents outside of **Mayan EDMS's** path
-------------------------------------------------------
* Sub class Django's ``FileSystemStorage`` class:
- Create a file called ``customstorage.py``::
from django.core.files.storage import FileSystemStorage
class CustomStorage(FileSystemStorage):
def __init__(self, *args, **kwargs):
super(CustomStorage, self).__init__(*args, **kwargs)
self.location='/new/path/to/documents/'
self.base_url='document_storage'
- In the ``settings.py`` add::
from customstorage import CustomStorage
DOCUMENTS_STORAGE_BACKEND = CustomStorage
How to enable the ``GridFS`` storage backend
--------------------------------------------
* Solution:
- Add the following lines to ``settings.py``::
from storage.backends.gridfsstorage import GridFSStorage
DOCUMENTS_STORAGE_BACKEND = GridFSStorage
- Filesystem metadata indexing will not work with this storage backend as
the files are inside a ``MongoDB`` database and can't be linked (at least for now)
Site search is slow
-------------------
* Add indexes to the following fields:
- ``documents_document`` - description, recommended size: 160
- ``documents_documentpage`` - content, recommended size: 3000
How to enable x-sendile support for ``Apache``
----------------------------------------------
* If using Ubuntu execute the following::
$ sudo apt-get install libapache2-mod-xsendfile
* Add the following line to your ``settings.py`` file::
SENDFILE_BACKEND = 'sendfile.backends.xsendfile'
* On your apache configuration file add::
XSendFile on
XSendFileAllowAbove on
The included version of ``unoconv`` in my distribution is too old
-------------------------------------------------------------
* Only the file 'unoconv' file from https://github.com/dagwieers/unoconv is needed.
Put it in a user designated directory for binaries such as /usr/local/bin and
setup Mayan's configuration option in your settings_local.py file like this::
CONVERTER_UNOCONV_PATH = '/usr/local/bin/unoconv'

256
docs/faq/index.rst Normal file
View File

@@ -0,0 +1,256 @@
===
FAQ
===
Frequently asked questions and solutions
Database related
----------------
Q: PostgreSQL vs. MySQL
~~~~~~~~~~~~~~~~~~~~~~~
Since Django abstracts database operations from a functional point of view
**Mayan EDMS** will behave exactly the same either way. The only concern
would be that MySQL doesn't support transactions for schema modifying
commands. The only moment this could cause problems is when running
South migrations during upgrades, if a migration fails the database
structure is left in a transitory state and has to be reverted manually
before trying again.
Q: _mysql_exceptions. OperationalError: (1267, "Illegal mix of collations (latin1_swedish_ci, IMPLICIT) and (utf8_general_ci, COERCIBLE) for operation '='")
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* Solution::
$ manage.py shell
>>> from django.db import connection
>>> cursor = connection.cursor()
>>> cursor.execute('SHOW TABLES')
>>> results=[]
>>> for row in cursor.fetchall(): results.append(row)
>>> for row in results: cursor.execute('ALTER TABLE %s CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;' % (row[0]))
* References:
- http://www.djangoshmango.com/?p=99
- http://stackoverflow.com/questions/1073295/django-character-set-with-mysql-weirdness
Q: Incorrect string value: ``'\xE2\x80\x95rs6...'`` for column ``'content'`` at row 1
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
When using ``MySQL`` and doing OCR on languages other than English
* Solution:
- Use utf-8 collation on MySQL server, or at least in table 'documents_documentpage', 'content' field
- Ref: 1- http://groups.google.com/group/django-users/browse_thread/thread/429447086fca6412
- Ref: 2- http://markmail.org/message/bqajx2utvmtriixi
Document sharing
----------------
Q: File system links not showing when serving content with ``Samba``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* Solution:
- Disable unix extensions in the [global] section and enable wide links for the file serving share
- Example::
[global]
unix extensions = no
...
[digitalizacion]
path = /var/local/mayan
guest ok = yes
read only = yes
wide links = yes
follow symlinks = yes
- Ref: 1- http://www.samba.org/samba/docs/man/manpages-3/smb.conf.5.html
Document handling
-----------------
How to store documents outside of **Mayan EDMS's** path
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* Sub class Django's ``FileSystemStorage`` class:
- Create a file called ``customstorage.py``::
from django.core.files.storage import FileSystemStorage
class CustomStorage(FileSystemStorage):
def __init__(self, *args, **kwargs):
super(CustomStorage, self).__init__(*args, **kwargs)
self.location='/new/path/to/documents/'
self.base_url='document_storage'
- In the ``settings.py`` add::
from customstorage import CustomStorage
DOCUMENTS_STORAGE_BACKEND = CustomStorage
Q: How to enable the ``GridFS`` storage backend
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* Solution:
- Add the following lines to ``settings.py``::
from storage.backends.gridfsstorage import GridFSStorage
DOCUMENTS_STORAGE_BACKEND = GridFSStorage
- Filesystem metadata indexing will not work with this storage backend as
the files are inside a ``MongoDB`` database and can't be linked (at least for now)
Q: How do you upload a new version of an existing file?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* Solution:
- Choose a document, and go to the versions tab, on the right menu at
the bottom under ``Other available action`` there is
``Upload new version``. Clicking it will take you to a very similar
view as the ``Upload new document`` but you will be able to specify
version number and comments for the new version being uploaded.
Q: Site search is slow
~~~~~~~~~~~~~~~~~~~
* Add indexes to the following fields:
- ``documents_document`` - description, recommended size: 160
- ``documents_documentpage`` - content, recommended size: 3000
Webserver
---------
Q: How to enable x-sendile support for ``Apache``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* If using Ubuntu execute the following::
$ sudo apt-get install libapache2-mod-xsendfile
* Add the following line to your ``settings.py`` file::
SENDFILE_BACKEND = 'sendfile.backends.xsendfile'
* On your apache configuration file add::
XSendFile on
XSendFileAllowAbove on
OCR
---
Q: The included version of ``unoconv`` in my distribution is too old
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* Only the file 'unoconv' file from https://github.com/dagwieers/unoconv is needed.
Put it in a user designated directory for binaries such as /usr/local/bin and
setup Mayan's configuration option in your settings_local.py file like this::
CONVERTER_UNOCONV_PATH = '/usr/local/bin/unoconv'
Deployments
-----------
Q: Is virtualenv required as specified in the documentation?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* It is not necessary, it's just a strong recommendation mainly to reduce
dependency conflicts by isolation from the main Python system install.
If not using a virtualenv, pip would install Mayan's dependencies
globally coming in conflict with the distribution's prepackaged Python
libraries messing other Django projects or Python programs, or another
later Python/Django project dependencies coming into conflict causing
Mayan to stop working for no apparent reason.
Q: Mayan EDMS installed correctly and works, but static files are not served
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Django's development server doesn't serve static files unless the ``DEBUG``
option is set to ``True``, this mode of operation should only be used for
development or testing. For production deployments the management command::
$ ./manage.py collectstatic
should be used and the resulting ``static`` folder served from a webserver.
For more information, read https://docs.djangoproject.com/en/dev/howto/static-files/
and https://docs.djangoproject.com/en/1.2/howto/static-files/ or
http://mayan-edms-ru.blogspot.com/2011/11/blog-post_09.html
Other
-----
Q: How to connect Mayan EDMS to an Active Directory tree
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
I used these two libraries as they seemed the most maintained from the quick search I did.
* http://www.python-ldap.org/
* http://packages.python.org/django-auth-ldap/
After figuring out the corresponding OU, CN and such (which took quite a while since I'm not well versed in LDAP). For configuration options, Mayan EDMS imports settings_local.py after importing settings.py to allow users to override the defaults without modifying any file tracked by Git, this makes upgrading by using Git's pull command extremely easy. My settings_local.py file is as follows:
::
import ldap
from django_auth_ldap.config import LDAPSearch
# makes sure this works in Active Directory
ldap.set_option(ldap.OPT_REFERRALS, 0)
AUTH_LDAP_SERVER_URI = "ldap://172.16.XX.XX:389"
AUTH_LDAP_BIND_DN = 'cn=Roberto Rosario Gonzalez,ou=Aguadilla,ou=XX,ou=XX,dc=XX,dc=XX,dc=XX'
AUTH_LDAP_BIND_PASSWORD = 'XXXXXXXXXXXXXX'
AUTH_LDAP_USER_SEARCH = LDAPSearch('dc=XX,dc=XX,dc=XX', ldap.SCOPE_SUBTREE, '(SAMAccountName=%(user)s)')
# Populate the Django user from the LDAP directory.
AUTH_LDAP_USER_ATTR_MAP = {
"first_name": "givenName",
"last_name": "sn",
"email": "mail"
}
# This is the default, but I like to be explicit.
AUTH_LDAP_ALWAYS_UPDATE_USER = True
AUTHENTICATION_BACKENDS = (
'django_auth_ldap.backend.LDAPBackend',
'django.contrib.auth.backends.ModelBackend',
)
if your organization policies don't allow anonymous directory queries,
create a dummy account and set the ``AUTH_LDAP_BIND_DN`` and
``AUTH_LDAP_BIND_PASSWORD`` options to match the account.
For a more advanced example check this StackOverflow question:
http://stackoverflow.com/questions/6493985/django-auth-ldap
Q: Can you change the display order of documents...i.e can they be in alphabetical order?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
A the moment no, but it is something being considered.

View File

@@ -1,100 +0,0 @@
========
Features
========
* Document versioning.
* Store many versions of the same document, download or revert to a previous version.
* Electronic signature verification.
* Check the authenticity of documents by verifying their embedded cryptographic signatures or upload detached signatures for document signed after they were stored.
* Collaboration tools.
* Discuss documents, comment on new version of a document.
* Office document format support.
* Word processing files? Spreadsheets? Sresentations? They are supported too.
* User defined metadata fields and meta data sets.
* Metadata fields can be grouped into sets per technical, legal or structural requirements such as the `Dublin core`_
.. _`Dublin core`: http://dublincore.org/metadata-basics/
* Dynamic default values for metadata.
* Metadata fields can have an initial value which can be static or determined by an user provided Python code snipped.
* Filesystem integration.
* If enabled, the document database index can be mirrored in the filesystem of the hosting computers and shared via Samba_ or any other method to clients computers on a network.
.. _Samba: http://www.samba.org/
* User defined document unique identifier and checksum algorithms.
* Users can alter the default method used to uniquely indentify documents.
* Documents can be uploaded from different sources.
* Local file or server side file uploads.
* Batch upload many documents with the same metadata.
* Clone a document's metadata for speedier uploads and eliminate repetitive data entry.
* Previews for a great deal of image formats, including PDF.
* **Mayan EDMS** provides different file conversion backends with different levels of functionality and requirements to adapt to different deployment environments.
* Full text searching.
* Document can be searched by their text content, their metadata or any other file attribute such as name, extension, etc.
* Configurable document grouping.
* Automatic linking of documents based on metadata values or document properties.
* Roles support.
* Users can created an unlimited amount of different roles and are not restricted to the traditional admin, operator, guest paradigm.
* Fine grained permissions system.
* There is a permission for every atomic operation performed by users.
* Multi page document support.
* Multiple page PDFs and TIFFs files supported.
* Distributed OCR processing.
* The task of transcribing text from documents via OCR can be distributed among several physical or virtual computers to decrease load and increase availability.
* Multilingual user interface (English, Spanish, Portuguese, Russian).
* **Mayan EDMS** is written using the Django_ framework which natively support Unicode, this coupled with the use of text templates allows **Mayan EDMS** to be translated to practically any language spoken in the world, by default four translations are provided: English, Spanish, Portuguese and Russian.
.. _Django: https://www.djangoproject.com/
* Multilingual OCR support.
* *As supported by the OCR engine tesseract.
* Duplicated document search.
* Plugable storage backends (File based and GridFS included).
* Very easy to convert other 3rd party such as the ones available for Amazon EC2.
* Color coded tagging.
* Labeled and color coded tags that are intituitive.
* Staging folders to receive scanned documents directly from network attached scanners.
* Preview scanned files even before uploading them.

View File

@@ -1,49 +1,92 @@
========
Overview
========
Open source, Django_ based document manager with custom metadata indexing, file serving integration, OCR_ capabilities, document versioning and digital signature verification.
.. _index:
.. _Django: http://www.djangoproject.com/
========================
Mayan EDMS documentation
========================
.. rubric:: `Open source`_, Django_ based document manager with custom
metadata_ indexing_, file serving integration, OCR_ capabilities,
document versioning_ and `digital signature verification`_.
:Website: http://www.mayan-edms.com
:Source: http://github.com/rosarior/mayan
:Video: http://bit.ly/pADNXv
:Issue tracker: http://github.com/rosarior/mayan/issues
:Mailing list: http://groups.google.com/group/mayan-edms
**Mayan EDMS** started as a simple project whose only requirement was the storage of PDF files, from there it has grown into a complete electronic document management solution.
**Mayan EDMS** can optimize an organization's bulk upload, storage and retrieval or documents.
Documents are organized using document classes, user defined metadata fields as well as automatic document grouping and indexing. Documents can be retrieved from the document index or by means of full
text searching. Users can search for terms in the document's metadata, properties or contents extracted from PDFs or transcribed by OCR_. **Mayan EDMS** is written in Python_ using the Django_ framework, which makes it very agile and fast, specially when compared with existing Java based solutions.
Being based on patent free, `Open source`_ technologies, **Mayan EDMS** provides legal safety to users and organizations, as well as peace of mind as documents and all related information is stored in open source and transparent formats allowing portability and avoiding `vendor lock-in`_.
Being written using Python_, **Mayan EDMS** runs on many POSIX compliant operating systems, this coupled with many configuration parameters, allows **Mayan EDMS** to be deployed on many hardware and software configurations such as single server based, clusters, virtualized and cloud based hosting giving adopters the choice of using the infrastructure of their choice.
On hosting providers that support Django_ such as DjangoZoom_, **Mayan EDMS** can be deployed in under 2 minutes with just a few clicks of the mouse [#]_.
.. [#] "Deploying Mayan EDMS on DjangoZoom.com" @ Youtube (http://bit.ly/mayan-djangozoom)
.. _`vendor lock-in`: https://secure.wikimedia.org/wikipedia/en/wiki/Vendor_lock-in
.. _Python: http://www.python.org/
.. _Django: http://www.djangoproject.com/
.. _OCR: https://secure.wikimedia.org/wikipedia/en/wiki/Optical_character_recognition
.. _`Open source`: https://secure.wikimedia.org/wikipedia/en/wiki/Open_source
.. _DjangoZoom: http://djangozoom.com/
.. _digital signature verification: http://en.wikipedia.org/wiki/Digital_signature
.. _versioning: http://en.wikipedia.org/wiki/Versioning
.. _metadata: http://en.wikipedia.org/wiki/Metadata
.. _indexing: http://en.wikipedia.org/wiki/Index_card
.. _Open source: http://en.wikipedia.org/wiki/Open_source
Links of interest
=================
* Website: http://www.mayan-edms.com
* Source: http://github.com/rosarior/mayan
* Video: http://bit.ly/pADNXv
* Issue tracker: http://github.com/rosarior/mayan/issues
* Mailing list: http://groups.google.com/group/mayan-edms
========
Contents
========
First steps
===========
:doc:`Overview <intro/overview>` |
:doc:`Features <intro/features>` |
:doc:`Requirements <intro/requirements>` |
:doc:`Installation <intro/installation>`
Understanding Mayan EDMS
========================
:doc:`Transformations <topics/transformations>` |
:doc:`Indexes <topics/indexes>` |
:doc:`Smart links <topics/smart_links>` |
:doc:`Document visualization <topics/document_visualization>` |
:doc:`OCR <topics/ocr>` |
:doc:`File storage <topics/file_storage>`
Between versions
================
.. toctree::
:maxdepth: 2
features
requirements
installation
releases/index
settings
development
contributors
credits
faq
license
releases/index
Customization and fine tunning
==============================
:doc:`Settings <topics/settings>`
For developers
==============
:doc:`Development <topics/development>`
Credits
=======
:doc:`Contributors <topics/contributors>` |
:doc:`Software used <topics/software_used>` |
:doc:`Licensing <license>`
Getting help
============
Having trouble? We'd like to help!
* Try the :doc:`FAQ <faq/index>` -- it's got answers to many common questions.
* Search for information in the `archives of the mayan-edms mailing list`_, or
`post a question`_.
* Report bugs with **Mayan EDMS** using Github's `ticket tracker`_.
.. _archives of the mayan-edms mailing list: http://groups.google.com/group/mayan-edms/
.. _post a question: http://groups.google.com/group/mayan-edms
.. _ticket tracker: http://github.com/rosarior/mayan/issues

100
docs/intro/features.rst Normal file
View File

@@ -0,0 +1,100 @@
========
Features
========
* Document versioning.
* Store many versions of the same document, download or revert to a previous version.
* Electronic signature verification.
* Check the authenticity of documents by verifying their embedded
cryptographic signatures or upload detached signatures for document
signed after they were stored.
* Collaboration tools.
* Discuss documents, comment on new version of a document.
* Office document format support.
* Word processing files? Spreadsheets? Presentations? They are supported too.
* User defined metadata fields and meta data sets.
* Metadata fields can be grouped into sets per technical, legal or structural requirements such as the `Dublin core`_
* Dynamic default values for metadata.
* Metadata fields can have an initial value which can be static or determined by an user provided Python code snipped.
* Filesystem integration.
* If enabled, the document database index can be mirrored in the filesystem of the hosting computers and shared via Samba_ or any other method to clients computers on a network.
* User defined document unique identifier and checksum algorithms.
* Users can alter the default method used to uniquely indentify documents.
* Documents can be uploaded from different sources.
* Local file or server side file uploads.
* Batch upload many documents with the same metadata.
* Clone a document's metadata for speedier uploads and eliminate repetitive data entry.
* Previews for a great deal of image formats, including PDF.
* **Mayan EDMS** provides different file conversion backends with different levels of functionality and requirements to adapt to different deployment environments.
* Full text searching.
* Document can be searched by their text content, their metadata or any other file attribute such as name, extension, etc.
* Configurable document grouping.
* Automatic linking of documents based on metadata values or document properties.
* Roles support.
* Users can created an unlimited amount of different roles and are not restricted to the traditional admin, operator, guest paradigm.
* Fine grained permissions system.
* There is a permission for every atomic operation performed by users.
* Multi page document support.
* Multiple page PDFs and TIFFs files supported.
* Distributed OCR processing.
* The task of transcribing text from documents via OCR can be distributed among several physical or virtual computers to decrease load and increase availability.
* Multilingual user interface (English, Spanish, Portuguese, Russian).
* **Mayan EDMS** is written using the Django_ framework which natively support Unicode, this coupled with the use of text templates allows **Mayan EDMS** to be translated to practically any language spoken in the world, by default four translations are provided: English, Spanish, Portuguese and Russian.
* Multilingual OCR support.
* As supported by the OCR engine tesseract.
* Duplicated document search.
* Plugable storage backends (File based and GridFS included).
* Very easy to use 3rd party plugins such as the ones available for Amazon EC2.
* Color coded tagging.
* Labeled and color coded tags that are intituitive.
* Staging folders to receive scanned documents directly from network attached scanners.
* Preview scanned files even before uploading them.
.. _`Dublin core`: http://dublincore.org/metadata-basics/
.. _Samba: http://www.samba.org/
.. _Django: https://www.djangoproject.com/

View File

@@ -52,25 +52,25 @@ Webfaction
To install **Mayan EDMS** on Webfaction_, follow these steps:
#. Create a new database:
1. Create a new database:
* Enter the following selections:
* Enter the following selections:
* Type:* ``Mysql``
* Name:* ``<username>_mayan``
* Encoding:* ``utf-8``
* Type:* ``Mysql``
* Name:* ``<username>_mayan``
* Encoding:* ``utf-8``
* Anotate the provided password.
* Anotate the provided password.
#. Create a new app:
2. Create a new app:
* Enter the following in the textbox:
* Enter the following in the textbox:
* Name:* ``mayan``
* App category:* ``mod_wsgi``
* App type:* ``mod_wsgi 3.3/Python 2.7``
* Name:* ``mayan``
* App category:* ``mod_wsgi``
* App type:* ``mod_wsgi 3.3/Python 2.7``
#. Login via ssh, and execute::
3. Login via ssh, and execute::
$ easy_install-2.7 virtualenv
$ cd ~/webapps/mayan_app
@@ -81,11 +81,11 @@ To install **Mayan EDMS** on Webfaction_, follow these steps:
$ source ../bin/activate
$ pip install -r requirements/production.txt
#. Install the Python MySQL database driver::
4. Install the Python MySQL database driver::
$ pip install MySQL-python
#. Create a settings_local.py file, and paste into it the following::
5. Create a settings_local.py file, and paste into it the following::
$ DATABASES = {
$ 'default': {
@@ -98,45 +98,45 @@ To install **Mayan EDMS** on Webfaction_, follow these steps:
$ }
$ }
#. Create the database schema (during this step two errors will appears about failling to install indexes on ``documents.Document`` and ``documents.DocumentPage`` models, ignore them for now)::
6. Create the database schema (during this step two errors will appears about failling to install indexes on ``documents.Document`` and ``documents.DocumentPage`` models, ignore them for now)::
$ ./manage.py syncdb --migrate
#. Collect the static files of the apps::
7. Collect the static files of the apps::
$ ./manage.py collectstatic -l --noinput
#. Create a new app:
8. Create a new app:
* Enter the following:
* Enter the following:
* Name:* ``mayan_static``
* App category:* ``Symbolic link``
* App type:* ``Symbolic link to static-only app``
* Extra info: ``/home/<username>/webapps/mayan_app/mayan/mayan/static``
* Name:* ``mayan_static``
* App category:* ``Symbolic link``
* App type:* ``Symbolic link to static-only app``
* Extra info: ``/home/<username>/webapps/mayan_app/mayan/mayan/static``
#. Create the website:
9. Create the website:
* Name: ``mayan_edms``
* Choose a subdomain
* Under ``Site apps:`` enter the following selections:
* Name: ``mayan_edms``
* Choose a subdomain
* Under ``Site apps:`` enter the following selections:
* App #1
* App #1
* App:* ``mayan_app``
* URL path (ex: '/' or '/blog'):* ``/``
* App:* ``mayan_app``
* URL path (ex: '/' or '/blog'):* ``/``
* App #2
* App #2
* App:* ``mayan_static``
* URL path (ex: '/' or '/blog'):* ``/mayan-static``
* App:* ``mayan_static``
* URL path (ex: '/' or '/blog'):* ``/mayan-static``
#. Edit the file ``~/webapps/mayan_app/apache2/conf/httpd.conf``:
10. Edit the file ``~/webapps/mayan_app/apache2/conf/httpd.conf``:
* Disable the ``DirectoryIndex`` line and the ``DocumentRoot`` line
* Add the following line::
* Disable the ``DirectoryIndex`` line and the ``DocumentRoot`` line
* Add the following line::
WSGIScriptAlias / /home/<username>/webapps/mayan_app/mayan/mayan/wsgi/dispatch.wsgi
WSGIScriptAlias / /home/<username>/webapps/mayan_app/mayan/mayan/wsgi/dispatch.wsgi
DjangoZoom
----------
@@ -152,6 +152,7 @@ For instructions on how to deploy **Mayan EDMS** on DjangoZoom, watch the screen
.. _`Open source`: https://secure.wikimedia.org/wikipedia/en/wiki/Open_source
.. _DjangoZoom: http://djangozoom.com/
.. _Youtube: http://bit.ly/mayan-djangozoom
.. _Django: http://www.djangoproject.com/
.. _Apache: https://www.apache.org/
@@ -160,5 +161,4 @@ For instructions on how to deploy **Mayan EDMS** on DjangoZoom, watch the screen
.. _Download: https://github.com/rosarior/mayan/archives/master
.. _Webfaction: http://www.webfaction.com
.. _deployed: https://docs.djangoproject.com/en/1.3/howto/deployment/
.. _Django: https://www.djangoproject.com
.. _virtualenv: http://www.virtualenv.org/en/latest/index.html

19
docs/intro/overview.rst Normal file
View File

@@ -0,0 +1,19 @@
====================
History and overview
====================
**Mayan EDMS** started as a simple project whose only requirement was the storage of PDF files, from there it has grown into a complete electronic document management solution.
**Mayan EDMS** can optimize an organization's bulk upload, storage and retrieval or documents.
Documents are organized using document classes, user defined metadata fields as well as automatic document grouping and indexing. Documents can be retrieved from the document index or by means of full
text searching. Users can search for terms in the document's metadata, properties or contents extracted from PDFs or transcribed by OCR_. **Mayan EDMS** is written in Python_ using the Django_ framework, which makes it very agile and fast, specially when compared with existing Java based solutions.
Being based on patent free, `Open source`_ technologies, **Mayan EDMS** provides legal safety to users and organizations, as well as peace of mind as documents and all related information is stored in open source and transparent formats allowing portability and avoiding `vendor lock-in`_.
Being written using Python_, **Mayan EDMS** runs on many POSIX compliant operating systems, this coupled with many configuration parameters, allows **Mayan EDMS** to be deployed on many hardware and software configurations such as single server based, clusters, virtualized and cloud based hosting giving adopters the choice of using the infrastructure of their choice.
On hosting providers that support Django_ such as DjangoZoom_, **Mayan EDMS** can be deployed in under 2 minutes with just a few clicks of the mouse [#]_.
.. [#] "Deploying Mayan EDMS on DjangoZoom.com" @ Youtube (http://bit.ly/mayan-djangozoom)
.. _`vendor lock-in`: https://secure.wikimedia.org/wikipedia/en/wiki/Vendor_lock-in
.. _Python: http://www.python.org/
.. _Django: http://www.djangoproject.com/
.. _OCR: https://secure.wikimedia.org/wikipedia/en/wiki/Optical_character_recognition
.. _`Open source`: https://secure.wikimedia.org/wikipedia/en/wiki/Open_source
.. _DjangoZoom: http://djangozoom.com/

10
docs/releases/0.10.1.rst Normal file
View File

@@ -0,0 +1,10 @@
Version 0.10.1
--------------
* Upgraded django-compressor to version 1.1.1, run::
$ pip install --upgrade -r requirements/production.txt
to upgrade
* django-compressor is now disabled by default, users must explicitly
enable it adding COMPRESS_ENABLED=True to their settings_local.py file

51
docs/releases/0.10.rst Normal file
View File

@@ -0,0 +1,51 @@
Version 0.10
------------
* Added a proper setup views for the document grouping functionality.
* Document grouping is now called smart linking as it relates better to
how it actually works. The data base schema was changed and users must
do the required::
$ ./manager syncdb
for the new tables to be created.
* Grappelli is no longer required as can be uninstalled.
* New smarter document preview widget that doesn't allow zooming or viewing
unknown or invalid documents.
* New office document converter, requires:
* LibreOffice (https://www.libreoffice.org/)
* unoconv [version 0.5] (https://github.com/dagwieers/unoconv)
* The new office documents converter won't convert files with the extension
.docx because these files are recognized as zip files instead. This
is an issue of the libmagic library.
* New configuration option added ``CONVERTER_UNOCONV_USE_PIPE`` that controls
how unoconv handles the communication with LibreOffice. The default of
``True`` causes unoconv to use **pipes**, this approach is slower than using
**TCP/IP** ports but it is more stable.
* Initial `REST` `API` that exposes documents properties and one method, this
new `API` is used by the new smart document widget and requires the
package ``djangorestframework``, users must issue a::
$ pip install -r requirements/production.txt
to install this new requirement.
* MIME type detection and caching performance updates.
* Updated the included version of ``jQuery`` to 1.7
* Updated the included version of ``JqueryAsynchImageLoader`` to 0.9.7
* Document image serving response now specifies a MIME type for increased
browser compatibility.
* Small change in the scheduler that increases stability.
* Russian translation updates (Сергей Глита [Sergey Glita])
* Improved and generalized the OCR queue locking mechanism, this should
eliminate any posibility of race conditions between Mayan EDMS OCR nodes.
* Added support for signals to the OCR queue, this results in instant OCR
processing upon submittal of a document to the OCR queue, this works in
addition to the current polling processing which eliminates the
posibility of stale documents in the OCR queue.
* Added multiple document OCR submit link
* Re enabled tesseract language specific OCR processing and added a one
(1) time language neutral retry for failed language specific OCR

8
docs/releases/0.11.1.rst Normal file
View File

@@ -0,0 +1,8 @@
Version 0.11.1
--------------
* Fixed a document deletion regression
* Improves error detection when importing keys from a keyserver, catching
the exception KeyImportError and not KeyFetchingError
* Fixes a wrong method call when verifying signatures for the first time upon document uploading
* django-compress is now disabled by default to avoid problems when deploying with DjangoZoom
* Improve post metadata set delete redirection

32
docs/releases/0.11.rst Normal file
View File

@@ -0,0 +1,32 @@
Version 0.11
------------
* Support for signed documents verification added, embedded and detached
signatures are supported. When verifying a document Mayan EDMS will
try to fetch the public key from the list of keyservers provided in the
configuration option SIGNATURES_KEYSERVERS (which defaults to
'pool.sks-keyservers.net'). A public key management view has been added
to the setup menu as well as a key query and fetching view to manually
import keys from a keyserver.
* Added support for document versions. Users can upload unlimited amount
of versions for a document using a very flexible document version numbering
system, users can also revert to a previous document version.
* OCR queue processing improvements.
* Office documents handling improvements.
* Text extraction support for office documents.
* RTF text documents are now handled as office documents.
* Added a view to delete the document image cache, useful when switching
converter backends or doing diagnostics.
* Added South to the requirements.
* Merged documents' filename and extension database fiels into a single
filename field, filename are store as uploaded not manipulation is done
Users with existing data must install South and run the appropiate
migrate commands::
$ pip install -r requirements/production.txt
$ ./manager syncdb
$ ./manage.py migrate documents 0001 --fake
$ ./manage.py migrate documents
* Added new office document mimetype
* application/vnd.ms-office
* Fixed documents not saving the file encoding
* Removed extra slash in ajax-loader.gif URL fixes #15, thanks to
IHLeanne for finding this one

View File

@@ -56,10 +56,10 @@ ACL support
Anonymous user support
~~~~~~~~~~~~~~~~~~~~~~
Anonymous user support is a two tier function, first is the addition of
the COMMON_ALLOW_ANONYMOUS_ACCESS that allows non authenticated to browse
all the pages of a **Mayan EDMS** installation. The second part of this
support is the ability to assign permissions or individual access to objects
to anonymous users.
the :setting:`COMMON_ALLOW_ANONYMOUS_ACCESS` configuration option that
allows non authenticated user to browse all the pages of a **Mayan EDMS** installation.
The second part of this support is the ability to assign permissions
or individual access to objects to anonymous users.
Translations
~~~~~~~~~~~~~~~~~~~
@@ -126,16 +126,20 @@ column after those is ignored.
Upgrading from a previous version
=================================
::
Start off by creating the new database structures with::
$ ./manage.py syncdb
Then migrate existing database schema with::
$ ./manage.py migrate permissions 0001 --fake
$ ./manage.py migrate permissions
When the following message appears
.. epigraph::
::
The following content types are stale and need to be deleted:
permissions | permission
@@ -146,26 +150,35 @@ When the following message appears
Type 'yes' to continue, or 'no' to cancel:
Types ``yes`` and press **Enter**
Type ``yes`` and press **Enter**
::
And continue migrating database schema with::
$ ./manage.py migrate documents
$ ./manage.py migrate document_signatures
$ ./manage.py migrate permissions 0001 --fake
$ ./manage.py migrate permissions
$ ./manage.py migrate folders 0001 --fake
$ ./manage.py migrate folders
$ ./manage.py migrate document_indexing 0001 --fake
$ ./manage.py migrate document_indexing
Again when a similar messages appears
::
The following content types are stale and need to be deleted:
document_indexing | indexinstance
The following content types are stale and need to be deleted:
Any objects related to these content types by a foreign key will also
be deleted. Are you sure you want to delete these content types?
If you're unsure, answer 'no'.
document_indexing | indexinstance
Type 'yes' to continue, or 'no' to cancel: yes
Any objects related to these content types by a foreign key will also
be deleted. Are you sure you want to delete these content types?
If you're unsure, answer 'no'.
Type 'yes' to continue, or 'no' to cancel:
Type ``yes`` and press **Enter**
The upgrade procedure is now complete.
Backward incompatible changes
=============================

10
docs/releases/0.5.1.rst Normal file
View File

@@ -0,0 +1,10 @@
Version 0.5.1
-------------
* Applied initial merge of the new subtemplate renderer
* Fixed tag removal logic
* Initial commit to support document comments
* Updated so that loading spinner is displayed always
* Exclude tags from the local document upload form
* Added document tagging support
- Requires installing ``django-taggit`` and doing a ``sync-db``

300
docs/releases/0.5.rst Normal file
View File

@@ -0,0 +1,300 @@
Version 0.5
-----------
* Added tag list view and global tag delete support
* Added tag editing view and listing documents with an specific tag
* Changed the previewing and deleting staging files views to required
``DOCUMENT_CREATE`` permission
* Added no-parent-history class to document page links so that iframe clicking doesn't affect the parent window history
- Fixes back button issue on Chrome 9 & 10
* Added per app version display tag
* Added loading spinner animation
* Messages tweaks and translation updates
* Converter app cleanups, document pre-cache, magic number removal
* Added OCR view displaying all active OCR tasks from all cluster nodes
* Disabled ``CELERY_DISABLE_RATE_LIMITS`` by default
* Implement local task locking using Django locmem cache backend
* Added doc extension to office document format list
* Removed redundant transformation calculation
* Make sure OCR in processing documents cannot be deleted
* PEP8, pylint cleanups and removal of relative imports
* Removed the obsolete ``DOCUMENTS_GROUP_MAX_RESULTS`` setting option
* Improved visual appearance of messages by displaying them outside the
main form
* Added link to close all notifications with one click
* Made the queue processing interval configurable by means of a new
setting: ``OCR_QUEUE_PROCESSING_INTERVAL``
* Added detection and reset of orphaned ocr documents being left as
'processing' when celery dies
* Improved unknown format detection in the graphicsmagick backend
* Improved document convertion API
* Added initial support for converting office documents (only ods and
docx tested)
* Added sample configuration files for supervisor and apache under
contrib/
* Avoid duplicates in recent document list
* Added the configuration option CONVERTER_GM_SETTINGS to pass
GraphicsMagicks specific commands the the GM backend
* Lower image convertion quality if the format is jpg
* Inverted the rotation button, more intuitive this way
* Merged and reduced the document page zoom and rotation views
* Increased permissions app permission's label field size
- DB Update required
* Added support for metadata group actions
* Reduced the document pages widget size
* Display the metadata group numeric total in the metadata group form
title
* Reorganized page detail icons
* Added first & last page navigation links to document page view
* Added interactive zoom support to document page detail view
* Spanish translation updates
* Added ``DOCUMENTS_ZOOM_PERCENT_STEP``, ``DOCUMENTS_ZOOM_MAX_LEVEL``,
``DOCUMENTS_ZOOM_MIN_LEVEL`` configuration options to allow detailed
zoom control
* Added interactive document page view rotation support
* Changed the side bar document grouping with carousel style document
grouping form widget
* Removed the obsolete ``DOCUMENTS_TRANFORMATION_PREVIEW_SIZE`` and
``DOCUMENTS_GROUP_SHOW_THUMBNAIL`` setting options
* Improved double submit prevention
* Added a direct rename field to the local update and staging upload
forms
* Separated document page detail view into document text and document
image views
* Added grab-scroll to document page view
* Disabled submit buttons and any buttons when during a form submit
* Updated the page preview widget to display a infinite-style horizontal
carousel of page previews
* Added support user document folders
- Must do a ``syncdb`` to add the new tables
* Added support for listing the most recent accessed documents per user
* Added document page navigation
* Fixed diagnostics url resolution
* Added confirmation dialog to document's find missing document file
diagnostic
* Added a document page edit view
* Added support for the command line program pdftotext from the
poppler-utils packages to extract text from PDF documents without
doing OCR
* Fixed document description editing
* Replaced page break text with page number when displaying document
content
* Implemented detail form readonly fields the correct way, this fixes
copy & paste issues with Firefox
* New document page view
* Added view to add or remove user to a specific role
* Updated the jQuery packages with the web_theme app to version 1.5.2
* Made ``AVAILABLE_INDEXING_FUNCTION`` setting a setting of the documents
app instead of the filesystem_serving app
* Fixed document download in FireFox for documents containing spaces in
the filename
* If mime detection fails set mime type to '' instead of 'unknown'
* Use document MIME type when downloading otherwise use
'application/octet-stream' if none
* Changed the way document page count is parsed from the graphics
backend, fixing issue #7
* Optimized document metadata query and display
* Implemented OCR output cleanups for English and Spanish
* Redirect user to the website entry point if already logged and lands
in the login template
* Changed from using SimpleUploadedFile class to stream file to the
simpler File class wrapper
* Updated staging files previews to use sendfile instead of serve_file
* Moved staging file preview creation logic from documents.views to
staging.py
* When deleting staging file, it's cached preview is also deleted
* Added a new setup option:
- ``FILESYSTEM_INDEXING_AVAILABLE_FUNCTIONS`` - a dictionary to allow users
to add custom functions
* Made automatic OCR a function of the OCR app and not of Documents app (via signals)
- Renamed setup option ``DOCUMENT_AUTOMATIC_OCR`` to ``OCR_AUTOMATIC_OCR``
* Clear node name when requeueing a document for OCR
* Added support for editing the metadata of multiple documents at the
same time
* Added Graphics magick support by means of user selectable graphic convertion backends
- Some settings renamed to support this change:
+ ``CONVERTER_CONVERT_PATH`` is now ``CONVERTER_IM_CONVERT_PATH``
+ ``CONVERTER_IDENTIFY_PATH`` is now ``CONVERTER_IM_IDENTIFY_PATH``
- Added options:
+ ``CONVERTER_GM_PATH`` - File path to graphicsmagick's program.
+ ``CONVERTER_GRAPHICS_BACKEND`` - Backend to use: ``ImageMagick`` or
``GraphicMagick``
* Raise ImportError and notify user when specifying a non existant
converter graphics backend
* Fixed issue #4, avoid circular import in permissions/__init__.py
* Add a user to a default role only when the user is created
* Added total page count to statistics view
* Added support to disable the default scrolling JS code included in
web_theme app, saving some KBs in transfer
* Clear last ocr results when requeueing a document
* Removed the 'exists' column in document list view, diagnostics
superceded this
* Added 3rd party sendfile app (support apache's X-sendfile)
* Updated the get_document_image view to use the new sendfile app
* Fixed the issue of the strip spaces middleware conflicting with
downloads
* Removed custom IE9 tags
* Closed Issue #6
* Allow deletion of non existing documents from OCR queue
* Allow OCR requeue of pending documents
* Invalid page numbers now raise Http404, not found instead of error
* Added an additional check to lower the chance of OCR race conditions
between nodes
* Introduce a random delay to each node to further reduce the chance of
a race condition, until row locking can be implemented or is
implemented by Django
* Moved navigation code to its own app
* Reimplemented OCR delay code, only delay new document
Added a new field: delay, update your database schema accordingly
* Made the concurrent ocr code more granular, per node, every node can
handle different amounts of concurrent ocr tasks
Added a new field: node_name, update your database schema acordinging
* Reduced default ocr delay time
* Added a new diagnostics tab under the tools menu
* Added a new option ``OCR_REPLICATION_DELAY`` to allow the storage some
time for replication before attempting to do OCR to a document
* Added OCR multi document re-queue and delete support
* Added simple statistics page (total used storage, total docs, etc)
* Implemented form based and button based multi item actions (button
based by default)
* Added multi document delete
* Fixed a few HTML validation errors
* Issues are now tracked using github
* Added indexing flags to ocr model
* Small optimization in document list view
* Small search optimization
* Display "DEBUG mode" string in title if ``DEBUG`` variable is set to True
* Added the fix-permissions bash script under misc/ folder
* Plugged another file descriptor leak
* Show class name in config settings view
* Added missing config option from the setup menu
* Close file descriptor to avoid leaks
* Don't allow duplicate documents in queues
* Don't raise ``PermissionDenied`` exception in ``PermissionDenied middleware``,
even while debugging
* Fixed page number detection
* Created 'simple document' for non technical users with all of a
document pages content
* Use document preview code for staging file also
* Error picture literal name removal
* Spanish translation updates
* Show document file path in regards of its storage
* Added new setting: side bar search box
* Implemented new ``PermissioDenied`` exception middleware handler
* Permissions app api now returns a ``PermissionDenied`` exception instead
of a custom one
* Added new 403 error template
* Updated the 404 template to display only a not found message
* Moved the login required middleware to the common app
* Fixed search app's model.objects.filter indentation, improved result
count calculation
* Added dynamic comparison types to search app
* Separated search code from view code
* Correctly calculate show result count for multi model searches
* Fixed OCR queue list showing wrong thumbnail
* Fixed staging file preview
* Show current metadata in document upload view sidebar
* Show sentry login for admin users
* Do not reinitialize document queue and/or queued document on reentry
* Try extra hard not to assign same uuid to two documents
* Added new transformation preview size setting
* Renamed document queue state links
* Changed ocr status display sidebar from form based to text based
* Added document action to clear all the document's page transformations
* Allow search across related fields
* Optimzed search for speed and memory footprint
* Added ``LIMIT`` setting to search
* Show search elapsed time on result page
* Converter now differentiates between unknown file format and convert
errors
* Close file descriptors when executing external programs to
prevent/reduce file descriptior leaks
* Improved exception handling of external programs
* Show document thumbnail in document ocr queue list
* Make ocr document date submitted column non breakable
* Fix permissions, directories set to mode 755 and files to mode 644
* Try to fix issue #2, "random ORM field error on search while doing OCR"
* Added configurable location setting for file based storage
* Prepend storage name to differentiate config options
* Fixed duplicated document search
* Optimized document duplicate search
* Added locale middleware, menu bar language switching works now
* Only show language selection list if localemiddleware is active
* Spanish translation updates
* Added links, views and permissions to disable or enable an OCR queue
* Enabled Django's template caching
* Added document queue property side bar window to the document queue
list view
* Added HTML spaceless middleware to remove whitespace in HTML code
* If current user is superuser or staff show thumbnail & preview
generation error messages
* Added a setting to show document thumbnail in metadata group list
* Started adding configurations setting descriptions
* Initial GridFS storage support
* Implemented size and delete methods for GridFS
* Implement GridFS storage user settings
* Added document link in the OCR document queue list
* Link to manually re queue failed OCR
* Don't separate links (encose object list links with white-space:
nowrap;)
* Added document description to the field search list
* Sort OCR queued documents according to submitted date & time
* Document filesystem serving is now a separate app
- Steps to update (Some warnings may be returned, but these are not
fatal as they might be related to missing metadata in some documents):
+ rename the following settings:
+ ``DOCUMENTS_FILESYSTEM_FILESERVING_ENABLE`` to ``FILESYSTEM_FILESERVING_ENABLE``
+ ``DOCUMENTS_FILESYSTEM_FILESERVING_PATH`` to ``FILESYSTEM_FILESERVING_PATH``
+ ``DOCUMENTS_FILESYSTEM_SLUGIFY_PATHS`` to ``FILESYSTEM_SLUGIFY_PATHS``
+ ``DOCUMENTS_FILESYSTEM_MAX_RENAME_COUNT`` to ``FILESYSTEM_MAX_RENAME_COUNT``
+ Do a ./manage.py syncdb
+ Execute 'Recreate index links' locate in the tools menu
+ Wait a few minutes
* Added per document duplicate search and a tools menu option to seach
all duplicated documents
* Added document tool that deletes and re-creates all documents
filesystem links
* Increased document's and document metadata index filename field's size
to 255 characters
* Added sentry to monitor and store error for later debugging
* Zip files can now be uncompressed in memory and their content uploaded
individually in one step
* Added support for concurrent, queued OCR processing using celery
* Apply default transformations to document before OCR
* Added unpaper to the OCR convertion pipe
* Added views to create, edit and grant/revoke permissions to roles
* Added multipage documents support (only tested on pdfs)
- To update a previous database do: [d.update_page_count() for d in Document.objects.all()]
* Added support for document page transformation (no GUI yet)
* Added permissions and roles support
* Added python-magic for smarter MIME type detection
(https://github.com/ahupp/python-magic).
* Added a new Document model field: file_mime_encoding.
* Show only document metadata in document list view.
* If one document type exists, the create document wizard skips the
first step.
* Changed to a liquid css grid
* Added the ability to group documents by their metadata
* New abstracted options to adjust document conversion quality (default,
low, high)

32
docs/releases/0.7.3.rst Normal file
View File

@@ -0,0 +1,32 @@
Version 0.7.3
-------------
* Refactored main menu navigation and converted all apps to this new
system
* Multi item links are now displayed on top of generic lists as well as
on the bottom
* Spanish translation updates
* Updated requirements to use the latest development version of
django-mptt
* Improved user folder document removal views
* Added ability to specify default metadata or metadataset per
document type
* Converted filename handling to use os.path library for improved
portability
* Added edit source object attribute difference detection and logging
to history app
* Missing metadata type in a document during a multi document editing doesn't raise errors anymore.
- This allows for multi document heterogeneous metadata editing in a single step.
* Added document multi item links in search results
- Direct editing can be done from the search result list
* Permissions are now grouped and assigned a group name
* Improved role management views
* Document type is now an optional document property
- Documents can be created without an explicit document type
* Added support for per user staging directories
* Updated logos

6
docs/releases/0.7.4.rst Normal file
View File

@@ -0,0 +1,6 @@
Version 0.7.4
-------------
* Renamed 'secondary actions' to 'secondary menu'
* Added document type setup views to the setup menu
* Added document type file name editing views to the setup menu
* Fixed document queue properties sidebar template not showing

16
docs/releases/0.7.5.rst Normal file
View File

@@ -0,0 +1,16 @@
Version 0.7.5
-------------
* Added a help messages to the sidebar of some views
* Renamed some forms submit button to more intuitive one
- 'Search' on the submit button of the search form
- 'Next step' on the document creation wizard
* Added view to list supported file formats and reported by the
converter backend
* Added redirection support to multi object action views
* Renamed 'document list' link to 'all documents' and
'recent document list' to 'recent documents'
* Removed 'change password' link next to the current user's name and
added a few views to handle the current user's password, details and
details editing

23
docs/releases/0.7.6.rst Normal file
View File

@@ -0,0 +1,23 @@
Version 0.7.6
-------------
* Added recent searches per user support
- The ammount of searches stored is controlled by the setup option
``SEARCH_RECENT_COUNT``
* The document page zoom button are now disabled when reaching the minimum
or maximum zoom level
* The document page navigation links are now disabled when view the first
and last page of a document
* Document page title now displays the current page vs the total page
count
* Document page title now displays the current zoom level and rotation
degrees
* Added means set the expansion compressed files during document creation,
via web interface removing the need for the configuration options:
``UNCOMPRESS_COMPRESSED_LOCAL_FILES`` and ``UNCOMPRESS_COMPRESSED_STAGING_FILES``
* Added 'search again' button to the advances search results view
* Implementes an advanced search feature, which allows for individual field terms
- Search fields supported: document type, MIME type, filename,
extension, metadata values, content, description, tags, comments

13
docs/releases/0.7.rst Normal file
View File

@@ -0,0 +1,13 @@
Version 0.7
-----------
* Added confirmation dialogs icons
* Added comment app with support for adding and deleting comments to
and from documents
* Updated requirements files as per issue #9
* Show tagged item count in the tag list view
* Show tagget document link in the tags subtemplate of documents
* Made comment sorted by oldest first, made comment subtemplate
scrollable
* Rename comments app to document_comment to avoid conflict with
Django's comment app
* Made document comments searchable

32
docs/releases/0.8.1.rst Normal file
View File

@@ -0,0 +1,32 @@
Version 0.8.1
-------------
* Tags can now also be created from the main menu
* Added item count column to index instance list view
* Updated document indexing widget to show different icon for indexes or
indexes that contain documents
* Replaced the Textarea widget with the TextAreaDiv widget on document
and document page detail views
- This change will allow highlighting search terms in the future
* Unknown document file format page count now defaults to 1
- When uploading documents which the selected converted backend doesn't
understand, the total page count will fallback to 1 page to at least
show some data, and a comment will be automatically added to the
document description
* Added new MAIN_DISABLE_ICONS to turn off all icons
- This options works very well when using the ``default`` theme
* The default theme is now ``activo``
* Improved document page views and document page transformation views
navigation
* Added OCR queue document transformations
- Use this for doing resizing or rotation fixes to improve OCR results
* Added reset view link to the document page view to reset the zoom
level and page rotation
* Staging files now show a thumbnail preview instead of preview link

24
docs/releases/0.8.2.rst Normal file
View File

@@ -0,0 +1,24 @@
Version 0.8.2
-------------
* Moved code to Django 1.3
- Users have to use the ``collectstatic`` management command::
$ ./manage.py collectstatic
- The ``site_media`` directory is no more, users must update the media
serving directives in current deployments and point them to the
``static`` directory instead
* The changelog is now available under the ``about`` main menu
* ``Grappelli`` no longer bundled with Mayan
- Users must install Grappelli or execute::
$ pip install --upgrade -r requirements/production.txt
* Even easier UI language switching
* Added email login method, to enable it, set::
AUTHENTICATION_BACKENDS = ('common.auth.email_auth_backend.EmailAuthBackend',)
COMMON_LOGIN_METHOD = 'email'

29
docs/releases/0.8.3.rst Normal file
View File

@@ -0,0 +1,29 @@
Version 0.8.3
-------------
* Added a Contributors file under the docs directory
* Moved the document grouping subtemplate windows into a document
information tab
* Change the mode the setup options are shown, opting to use a more of a
dashboard style now
* Changed the tool menu to use the same button layout of the setup menu
* Moved OCR related handling to the tools main menu
* Improved the metadata type and metadata set selection widget during
the document upload wizard
* Added a view to the about menu to read the LICENSE file included with
Mayan
* Added converter backend agnostic image file format descriptions
* Disable whitelist and blacklist temporarily, removed document_type
field from interactive sources
* Fully disabled watch folders until they are working correctly
* Updated the project title to 'Mayan EDMS'
* If ghostscript is installed add PDF and PS to the list of file formats
by the python converter backend
* Use Pillow (http://pypi.python.org/pypi/Pillow) instead of PIL
- Pillow is a fork of PIL with several updated including better jpeg and png library detection
- Users must uninstall PIL before installing Pillow
* Updated the static media url in the login excempt url list
* Added remediatory code to sidestep issue #10 caused by DjangoZoom's deployment script executing the collectstatic command before creating the database structure with syncdb. Thanks to Joost Cassee (https://github.com/jcassee) for reporting this one.
* Perform extra validation of the image cache directory and fallback to creating a temporary directory on validation failure
* Fixed a source creation bug, that caused invalid links to a non existing source transformation to appear on the sidebar

62
docs/releases/0.8.rst Normal file
View File

@@ -0,0 +1,62 @@
Version 0.8
-----------
* Distributed OCR queue processing via celery is disabled for the time
being
* Added support for local scheduling of jobs
- This addition removes celery beat requirement, and make is optional
* Improve link highlighting
* Navigation improvements
* Documents with an unknown file format now display a mime type place
holder icon instead of a error icon
* Mayan now does pre caching of document visual representation improving
overall thumbnail, preview and display speed
- Page image rotation and zooming is faster too with this update
* Removed all QUALITY related settings
* ``COMMON_TEMPORARY_DIRECTORY`` is now validated when Mayan starts and if
not valid falls back to creating it's own temporary folder
* Added PDF file support to the python converter backend via ghostscript
- This requires the installation of:
+ ghostscript python package
+ ghostscript system binaries and libraries
* Added PDF text parsing support to the python converter backend
- This requires the installation of:
+ pdfminer python package
* Added PDF page count support to the python converter backend
* Added python only converter backend supporting resizing, zooming and rotation
- This backend required the installation of the python image library (PIL)
- This backend is useful when Graphicsmagick or Imagemagick can not be installed for some reason
- If understand fewer file format than the other 2 backends
* Added default tranformation support to document sources
* Removed ``DOCUMENT_DEFAULT_TRANSFORMATIONS`` setup options
* Document sources are now defined via a series of view under the setup main menu
* This removes all the ``DOCUMENT_STAGING`` related setup options
- Two document source types are supported local (via a web form),
and staging
- However multiple document sources can be defined each with their own
set of transformations and default metadata selection
* Use ``python-magic`` to determine a document's mimetype otherwise
fallback to use python's mimetypes library
* Remove the included sources for ``python-magic`` instead it is now fetched
from github by pip
* Removed the document subtemplates and changed to a tabbed style
* Added link to document index content view to navigate the tree upwards
* Added new option ``MAIN_DISABLE_HOME_VIEW`` to disable the home main menu
tab and save some space
* Added new option to the web theme app, ``WEB_THEME_VERBOSE_LOGIN``
that display a more information on the login screen
(version, copyright, logos)
* Added a confirmation dialog to the document tag removal view

7
docs/releases/0.9.1.rst Normal file
View File

@@ -0,0 +1,7 @@
Version 0.9.1
-------------
* Added handling percent encoded unicode query strings in search URL,
thanks to (Сергей Глита [Sergei Glita]) for reporting.
* Added a FAQ explaing how to fix MySQL collation related error when
doing searches also thanks to (Сергей Глита [Sergei Glita]) for
reporting this one.

44
docs/releases/0.9.rst Normal file
View File

@@ -0,0 +1,44 @@
Version 0.9
-----------
* Simplified getting mimetypes from files by merging 2 implementations
(document based and file based)
* Updated python converter backend, document model and staging module
to use the new get_mimetype API
* Only allow clickable thumbnails for document and staging files with a
valid image
* Removed tag count from the group document list widget to conserve
vertical space
* Updated required Django version to 1.3.1
* Removed the included 3rd party module django-sendfile, now added to
the requirement files.
* User should do a pip install -r requirements/production.txt to update
* Changed to Semantic Versioning (http://semver.org/), with
recommendations 7, 8 and 9 causing the most effect in the versioning number.
* Added Russian locale post OCR cleanup backend (Сергей Глита [Sergei Glita])
* Reduced severity of the messages displayed when no OCR cleanup backend
is found for a language
* Complete Portuguese translation (Emerson Soares and Renata Oliveira)
* Complete Russian translation (Сергей Глита [Sergei Glita])
* Added animate.css to use CSS to animate flash messages with better
fallback on non JS browsers
* The admin and sentry links are no longer hard-coded (Meurig Freeman)
* Improved appearance of the document tag widget
(https://p.twimg.com/Ac0Q0b-CAAE1lfA.png:large)
* Added django_compress and cssmin to the requirements files and enabled
django_compress for CSS and JS files
* Added granting and revoking permission methods to the permission model
* Correctly calculate the mimetype icons paths when on development mode
* Added a new more comprehensive method of passing multiple variables
per item in multi item selection views
* Used new multi parameter passing method to improve the usability of
the grant/revoke permission view, thanks to Cezar Jenkins
(https://twitter.com/#!/emperorcezar) for the suggestion
* Added step to the documentation explaining how to install Mayan EDMS
on Webfaction
* Added an entry in the documentation to the screencast explaining how
to install Mayan EDMS on DjangoZoom
* Added required changes to add Mayan EDMS to Transifex.com
* Fixed the apache contrib file static file directory name
* Added improved documentation

View File

@@ -14,7 +14,6 @@ up to and including the new version.
Final releases
==============
0.12 release
-----------
.. toctree::
@@ -22,7 +21,25 @@ Final releases
0.12
Historic releases
=================
Historic changelogs
===================
.. toctree::
:maxdepth: 1
.. include:: ../changelog.rst
0.11.1
0.11
0.10.1
0.10
0.9.1
0.9
0.8.3
0.8.2
0.8.1
0.8
0.7.6
0.7.5
0.7.4
0.7.3
0.7
0.5.1
0.5

View File

@@ -1,423 +0,0 @@
========
Settings
========
**Mayan EDMS** has many configuration options that make it very adaptable to
different server configurations.
Documents
---------
.. data:: DOCUMENTS_CHECKSUM_FUNCTION
Default: ``hashlib.sha256(x).hexdigest()``
.. data:: DOCUMENTS_UUID_FUNCTION
Default: ``unicode(uuid.uuid4())``
.. data:: DOCUMENTS_STORAGE_BACKEND
Default: ``FileBasedStorage`` class
.. data:: DOCUMENTS_PREVIEW_SIZE
Default: ``640x480``
.. data:: DOCUMENTS_PRINT_SIZE
Default: ``1400``
.. data:: DOCUMENTS_MULTIPAGE_PREVIEW_SIZE
Default: ``160x120``
.. data:: DOCUMENTS_THUMBNAIL_SIZE
Default: ``50x50``
.. data:: DOCUMENTS_DISPLAY_SIZE
Default: ``1200``
.. data:: DOCUMENTS_RECENT_COUNT
Default: ``40``
Maximum number of recent (created, edited, viewed) documents to
remember per user.
.. data:: DOCUMENTS_ZOOM_PERCENT_STEP
Default: ``50``
Amount in percent zoom in or out a document page per user interaction.
.. data:: DOCUMENTS_ZOOM_MAX_LEVEL
Default: ``200``
Maximum amount in percent (%) to allow user to zoom in a document page interactively.
.. data:: DOCUMENTS_ZOOM_MIN_LEVEL
Default: ``50``
Minimum amount in percent (%) to allow user to zoom out a document page interactively.
.. data:: DOCUMENTS_ROTATION_STEP
Default: ``90``
Amount in degrees to rotate a document page per user interaction.
.. data:: DOCUMENTS_CACHE_PATH
Default: ``image_cache`` (relative to the installation path)
The path where the visual representations of the documents are stored for fast display.
Converter
---------
.. data:: CONVERTER_IM_CONVERT_PATH
Default: ``/usr/bin/convert``
File path to imagemagick's convert program.
.. data:: CONVERTER_IM_IDENTIFY_PATH
Default: ``/usr/bin/identify``
File path to imagemagick's identify program.
.. data:: CONVERTER_GM_PATH
Default: ``/usr/bin/gm``
File path to graphicsmagick's program.
.. data:: CONVERTER_GM_SETTINGS
Default: None
.. data:: CONVERTER_GRAPHICS_BACKEND
Default: ``converter.backends.python``
Graphics conversion backend to use. Options are: ``converter.backends.imagemagick``,
``converter.backends.graphicsmagick`` and ``converter.backends.python``.
Suggested options: ``-limit files 1 -limit memory 1GB -limit map 2GB -density 200``
.. data:: CONVERTER_UNOCONV_PATH
Default: ``/usr/bin/unoconv``
Path to the unoconv program.
.. data:: CONVERTER_UNOCONV_USE_PIPE
Default: ``True``
Use alternate method of connection to LibreOffice using a pipe, it is slower but less prone to segmentation faults.
Linking
-------
.. data:: LINKING_SHOW_EMPTY_SMART_LINKS
Default: ``True``
Show smart links even when they don't return any documents.
Storage
-------
.. data:: STORAGE_GRIDFS_HOST
Default: ``localhost``
.. data:: STORAGE_GRIDFS_PORT
Default: ``27017``
.. data:: STORAGE_GRIDFS_DATABASE_NAME
Default: ``document_storage``
.. data:: STORAGE_FILESTORAGE_LOCATION
Default: ``document_storage``
Document indexing
-----------------
.. data:: DOCUMENT_INDEXING_AVAILABLE_INDEXING_FUNCTIONS
Default: ``proper_name``
.. data:: DOCUMENT_INDEXING_SUFFIX_SEPARATOR
Default: ``_`` (underscore)
.. data:: DOCUMENT_INDEXING_FILESYSTEM_SLUGIFY_PATHS
Default: ``False``
.. data:: DOCUMENT_INDEXING_FILESYSTEM_MAX_SUFFIX_COUNT
Default: ``1000``
.. data:: DOCUMENT_INDEXING_FILESYSTEM_FILESERVING_PATH
Default: ``/tmp/mayan/documents``
.. data:: DOCUMENT_INDEXING_FILESYSTEM_FILESERVING_ENABLE
Default: ``True``
OCR
---
.. data:: OCR_TESSERACT_PATH
Default: ``/bin/tesseract``
File path to the ``tesseract`` executable, used to perform OCR on document
page's images.
.. data:: OCR_TESSERACT_LANGUAGE
Default: ``eng``
Language code passed to the ``tesseract`` executable.
.. data:: OCR_REPLICATION_DELAY
Default: ``0``
Amount of seconds to delay OCR of documents to allow for the node's
storage replication overhead.
.. data:: OCR_NODE_CONCURRENT_EXECUTION
Default: ``1``
Maximum amount of concurrent document OCRs a node can perform.
.. data:: OCR_AUTOMATIC_OCR
Default: ``False``
Automatically queue newly created documents or newly uploaded versions
of existing documents for OCR.
.. data:: OCR_QUEUE_PROCESSING_INTERVAL
Default: ``10``
.. data:: OCR_UNPAPER_PATH
Default: ``/usr/bin/unpaper``
File path to the ``unpaper`` executable, used to clean up images before
doing OCR.
Metadata
--------
.. data:: METADATA_AVAILABLE_FUNCTIONS
Default: ``current_date``
.. data:: METADATA_AVAILABLE_MODELS
Default: ``User``
Common
------
.. data:: COMMON_TEMPORARY_DIRECTORY
Default: ``/tmp``
Temporary directory used site wide to store thumbnails, previews
and temporary files. If none is specified, one will be created
using tempfile.mkdtemp()
.. data:: COMMON_DEFAULT_PAPER_SIZE
Default: ``Letter``
.. data:: COMMON_DEFAULT_PAGE_ORIENTATION
Default: ``Portrait``
.. data:: COMMON_AUTO_CREATE_ADMIN
Default: ``True``
Automatically creates an administrator superuser with the username
specified by COMMON_AUTO_ADMIN_USERNAME and with the default password
specified by COMMON_AUTO_ADMIN_PASSWORD
.. data:: COMMON_AUTO_ADMIN_USERNAME
Default: ``admin``
Username of the automatically created superuser
.. data:: COMMON_AUTO_ADMIN_PASSWORD
Default: ``admin``
Default password of the automatically created superuser
.. data:: COMMON_LOGIN_METHOD
Default: ``username``
Controls the mechanism used to authenticated user. Options are: ``username``, ``email``
If using the ``email`` login method a proper email authentication backend must used
such as AUTHENTICATION_BACKENDS = ('common.auth.email_auth_backend.EmailAuthBackend',)
.. data:: COMMON_ALLOW_ANONYMOUS_ACCESS
Default: ``False``
Allow non authenticated users, access to all views
Search
------
.. data:: SEARCH_LIMIT
Default: ``100``
Maximum amount search hits to fetch and display.
.. data:: SEARCH_RECENT_COUNT
Default: ``5``
Maximum number of search queries to remember per user.
Web theme
---------
.. data:: WEB_THEME_THEME
Default: ``activo``
CSS theme to apply, options are: ``amro``, ``bec``, ``bec-green``, ``blue``, ``default``, ``djime-cerulean``, ``drastic-dark``, ``kathleene``, ``olive``, ``orange``, ``red``, ``reidb-greenish`` and ``warehouse``.
.. data:: WEB_THEME_VERBOSE_LOGIN
Default: ``True``
Display extra information in the login screen.
Main
----
.. data:: MAIN_SIDE_BAR_SEARCH
Default: ``False``
Controls whether the search functionality is provided by a sidebar widget or by a menu entry.
.. data:: MAIN_DISABLE_HOME_VIEW
Default: ``False``
.. data:: MAIN_DISABLE_ICONS
Default: ``False``
User management
---------------
.. data:: ROLES_DEFAULT_ROLES
Default: ``[]``
A list of existing roles that are automatically assigned to newly created users
Signatures
----------
.. data:: SIGNATURES_KEYSERVERS
Default: ``['pool.sks-keyservers.net']``
List of keyservers to be queried for unknown keys.
.. data:: SIGNATURES_GPG_HOME
Default: ``gpg_home``
Home directory used to store keys as well as configuration files.

View File

@@ -0,0 +1,34 @@
======================
Document visualization
======================
The philosophy in place is to try to avoid having users download a documents and leave
**Mayan EDMS** to be able to see them, so in essence making **Mayan EDMS** a
visualization tool too. The conversion backend is a stack of functions,
first the mimetype is evaluated, if it is an office document it is passed
to Libreoffice_ working in headless mode (and managed by supervisor)
via unoconv for conversion to PDF_. The PDF_ is stored in a temporary
cache along side all the other files that were not office documents,
from here they are inspected to determine the page count and the
corresponding blank database entires are created. After the database
update they all go to the conversion driver specified by the configuration
option :setting:`CONVERTER_GRAPHICS_BACKEND` and a high resolution
master preview of each file is generated and stored in the persistent
cache. From the master previews in the persistent cache, volatile
previews are then created on demand for the different sizes requested
(thumbnail, page preview, full preview) and rotate interactively
in the details view.
Office document conversion however won't always work as expected because
LibreOffice_ do not provide proper API's, so subprocess calling,
temporary files and other black magic needs to be invoked to get it
properly integrated. **Mayan EDMS** treats documents as collections of pages
or frames, and text extraction and OCR is done per page not per document,
thats why even text documents need to be rendered by LibreOffice_
before they can be previewed and text can be extracted.
.. _PDF: http://en.wikipedia.org/wiki/Portable_Document_Format
.. _Libreoffice: http://www.libreoffice.org/

View File

@@ -0,0 +1,25 @@
============
File storage
============
The files are stored and placed under Mayan EDMS "control" to avoid
filename clashes (each file gets renamed to its UUID and with an extension)
and stored in a simple flat arrangement in a directory. This doesn't
stop access to the files but it is not recommended because moving,
renaming or updating the files directly would throw the database out
of sync. For access to the files the recommended way is to create and
index which would create a directory tree like structure in the database
and then turn on the index filesystem mirror options which would create
an actual directory tree and links to the actual stored files but using
the filename of the documents as stored in the database. This
filesystem mirror of the index can them be shared with Samba across the
network. This access would be read-only, and new versions of the files
would have to be uploaded from the web GUI using the new document
versioning support.
Mayan's EDMS components are as decoupled from each other as possible,
storage in this case is very decoupled and its behavior is controlled
not by the project but by the Storage progamming class. Why this design?
All the other part don't make any assumptions about the actual file
storage, so that Mayan EDMS can work saving files locally, over the
network or even across the internet and still operate exactly the same.

12
docs/topics/indexes.rst Normal file
View File

@@ -0,0 +1,12 @@
=======
Indexes
=======
Administrators first define the template of the index and an instance
of the index is then auto-populated with links to the documents depending
on the rules of each branch of the index evaluated againts the metadata
of the documents. The index cannot be edited manually, only changing
the rules or the metadata of the documents would cause the index to be
regenerated. For manual organization of documents there are the folders,
their structure is however flat, and they have to be manually updated and
curated.

18
docs/topics/ocr.rst Normal file
View File

@@ -0,0 +1,18 @@
===
OCR
===
Because OCR is an intensive operation, documents are queued for OCR for
later handling, the amount of documents processed in parallel is
controlled by the :setting:`OCR_NODE_CONCURRENT_EXECUTION` configuration
option. Ideally the machine serving **Mayan EDMS** should disable OCR
processing by settings this options to 0, with other machines or cloud
instances then connected to the same database doing the OCR processing.
The document is checked to see if there are text parsers available, is
no parser is available for that file type then the document is passed
to tesseract page by page and the results stored per page, this is to
keep the page image in sync with the transcribed text. However when
viewing the document in the details tab all the pages text are
concatenated and shown to the user. Setting the :setting:`OCR_AUTOMATIC_OCR`
option to ``True`` would cause all newly uploaded documents to be
queued automatically for OCR.

602
docs/topics/settings.rst Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,9 @@
===========
Smart links
===========
Smart links are usefull for navigation between documents. They are rule
based but don't created any organizational structure just show the documents
that match the rules as evaluated against the metadata of currently
displayed document. The index is global, the smart links are dependant
on the current document the user is viewing.

View File

@@ -1,6 +1,6 @@
=======
Credits
=======
=============
Software used
=============
* Python
* Copyright (c) 2001-2010 Python Software Foundation.

View File

@@ -0,0 +1,12 @@
=========================
What are transformations?
=========================
Transformation are useful to manipulate the preview of the stored documents
in a persistent manner, for example some scanning equipment only produce
landscape PDFs, in this case a default transformation for that document
source would be "rotation: 270 degress", this way whenever a document is
uploaded from that scanner it appears in portrait orientation.
The transformation remains attached to the document, this way the file
is preserved in it's original state (a requirement in legal environments)
but only the representation is transformed to make it look right to the user.

View File

@@ -1,5 +0,0 @@
=========
Changelog
=========
.. include:: changelog.rst