summaryrefslogtreecommitdiff
path: root/django/contrib/admin/templates/widget/one_to_one.html
diff options
context:
space:
mode:
Diffstat (limited to 'django/contrib/admin/templates/widget/one_to_one.html')
-rw-r--r--django/contrib/admin/templates/widget/one_to_one.html3
1 files changed, 2 insertions, 1 deletions
diff --git a/django/contrib/admin/templates/widget/one_to_one.html b/django/contrib/admin/templates/widget/one_to_one.html
index 151fe04f30..a79a12314f 100644
--- a/django/contrib/admin/templates/widget/one_to_one.html
+++ b/django/contrib/admin/templates/widget/one_to_one.html
@@ -1 +1,2 @@
-{% include "widget/foreign" %}
+{% if add %}{% include "widget/foreign.html" %}{% endif %}
+{% if change %}{% if bound_field.existing_display %}&nbsp;<strong>{{ bound_field.existing_display|truncatewords:"14" }}</strong>{% endif %}{% endif %}