Skip to content

Commit

Permalink
Merge pull request #82 from patymori/tk-proc-409
Browse files Browse the repository at this point in the history
Adiciona novo campo 'aop_url_segs' em 'Article'
  • Loading branch information
patymori authored Feb 15, 2019
2 parents 04ec817 + 220c4f1 commit abfb022
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
9 changes: 9 additions & 0 deletions opac_schema/v1/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,14 @@ def __unicode__(self):
return self.name


class AOPUrlSegments(EmbeddedDocument):
url_seg_article = StringField()
url_seg_issue = StringField()

def __unicode__(self):
return "%s/%s" % (self.url_seg_issue, self.url_seg_article)


class Collection(Document):
_id = StringField(max_length=32, primary_key=True, required=True)
acronym = StringField(max_length=50, required=True, unique=True)
Expand Down Expand Up @@ -612,6 +620,7 @@ class Article(Document):
fpage_sequence = StringField()
lpage = StringField()
url_segment = StringField()
aop_url_segs = EmbeddedDocumentField(AOPUrlSegments)

meta = {
'collection': 'article',
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

setup(
name="Opac Schema",
version='2.51',
version='2.52',
description="Schema of SciELO OPAC",
author="SciELO",
author_email="[email protected]",
Expand Down

0 comments on commit abfb022

Please sign in to comment.