Changed some instances of .slug to _id
- Legacy-Id: 14985
This commit is contained in:
parent
dde5cfb11e
commit
db3a4eb20e
|
@ -156,7 +156,7 @@ def needed_ballot_positions(doc, active_positions):
|
|||
else:
|
||||
related_set = RelatedDocHistory.objects.none()
|
||||
for rel in related_set.filter(relationship__slug__in=['tops', 'tois', 'tohist', 'toinf', 'tobcp', 'toexp']):
|
||||
if (rel.target.document.std_level.slug in ['bcp','ps','ds','std']) or (rel.relationship.slug in ['tops','tois','tobcp']):
|
||||
if (rel.target.document.std_level_id in ['bcp','ps','ds','std']) or (rel.relationship_id in ['tops','tois','tobcp']):
|
||||
needed = two_thirds_rule(recused=len(recuse))
|
||||
break
|
||||
else:
|
||||
|
|
|
@ -283,7 +283,7 @@ def default_approval_text(status_change,relateddoc):
|
|||
|
||||
current_text = status_change.text_or_error() # pyflakes:ignore
|
||||
|
||||
if relateddoc.target.document.std_level.slug in ('std','ps','ds','bcp',):
|
||||
if relateddoc.target.document.std_level_id in ('std','ps','ds','bcp',):
|
||||
action = "Protocol Action"
|
||||
else:
|
||||
action = "Document Action"
|
||||
|
|
|
@ -59,7 +59,7 @@ def get_doc_section(doc):
|
|||
elif doc.type_id == 'statchg':
|
||||
protocol_action = False
|
||||
for relation in doc.relateddocument_set.filter(relationship__slug__in=('tops','tois','tohist','toinf','tobcp','toexp')):
|
||||
if relation.relationship.slug in ('tops','tois') or relation.target.document.std_level.slug in ('std','ds','ps'):
|
||||
if relation.relationship_id in ('tops','tois') or relation.target.document.std_level_id in ('std','ds','ps'):
|
||||
protocol_action = True
|
||||
if protocol_action:
|
||||
s = "2.3"
|
||||
|
|
Loading…
Reference in a new issue