reciprocals
This commit is contained in:
@@ -39,13 +39,12 @@
|
||||
</ul>
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% if model.relations %}
|
||||
Relations:
|
||||
<ul>
|
||||
{% for rel in model.relations %}
|
||||
<li>
|
||||
<span title="{{rel.model.id}}">"{{rel.model.name}}", pointing to: <i>{{rel.related_name}}</i> (reciprocal as "{{rel.model.reciprocal_name}}")</span>
|
||||
<span title="{{rel.model.id}}">"{{rel.model.name}}" -> <i>{{rel.related_name}} (reciprocally as "{{rel.model.reciprocal_name}}")</i></span>
|
||||
{%- if rel.model.optional %}, OPTIONAL{% endif %}
|
||||
{%- if rel.model.multiple %}, MULTIPLE{% endif %}
|
||||
<br>
|
||||
@@ -68,6 +67,17 @@
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
|
||||
{% if model.reciprocal_relations %}
|
||||
Incoming relations:
|
||||
<ul>
|
||||
{% for rel in model.reciprocal_relations %}
|
||||
<li>
|
||||
<span title="{{rel.model.id}}">"{{rel.model.reciprocal_name}}" <- <i>{{rel.related_name}}</i> (reciprocally as "{{rel.model.name}}")</span>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
|
||||
Reference in New Issue
Block a user