Update signature API to support uploads
Signed-off-by: Roberto Rosario <roberto.rosario@mayan-edms.com>
This commit is contained in:
@@ -43,7 +43,10 @@ class SignatureBaseModel(models.Model):
|
||||
date = models.DateField(
|
||||
blank=True, editable=False, null=True, verbose_name=_('Date signed')
|
||||
)
|
||||
key_id = models.CharField(max_length=40, verbose_name=_('Key ID'))
|
||||
key_id = models.CharField(
|
||||
help_text=_('ID of the key that will be used to sign the document.'),
|
||||
max_length=40, verbose_name=_('Key ID')
|
||||
)
|
||||
# With proper key
|
||||
signature_id = models.CharField(
|
||||
blank=True, editable=False, null=True, max_length=64,
|
||||
@@ -128,7 +131,9 @@ class EmbeddedSignature(SignatureBaseModel):
|
||||
@python_2_unicode_compatible
|
||||
class DetachedSignature(SignatureBaseModel):
|
||||
signature_file = models.FileField(
|
||||
blank=True, null=True, storage=storage_detachedsignature,
|
||||
blank=True, help_text=_(
|
||||
'Signature file previously generated.'
|
||||
), null=True, storage=storage_detachedsignature,
|
||||
upload_to=upload_to, verbose_name=_('Signature file')
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user