From 20f6d8eab27703e264c763e029de51788219a630 Mon Sep 17 00:00:00 2001 From: "Denis V. Dedkov" Date: Tue, 16 Jun 2015 20:33:36 +0500 Subject: [PATCH] =?UTF-8?q?=D0=90=D0=B2=D1=82=D0=BE=D0=BC=D0=B0=D1=82?= =?UTF-8?q?=D0=B8=D1=87=D0=B5=D1=81=D0=BA=D0=B0=D1=8F=20=D1=88=D0=B8=D1=80?= =?UTF-8?q?=D0=B8=D0=BD=D0=B0=20=D1=8D=D0=B4=D0=B8=D1=82=D0=BE=D1=80=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Добавил автоматическую установку ширины в inplace edit --- asuzr/tables.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/asuzr/tables.py b/asuzr/tables.py index 0c9ca23..e65d13b 100644 --- a/asuzr/tables.py +++ b/asuzr/tables.py @@ -17,12 +17,12 @@ class EditableColumn(tables.TemplateColumn): main_part = '' if object_name == '': main_part = ''' - {{% inplace_edit "record.{field}" auto_height = 1 %}} + {{% inplace_edit "record.{field}" auto_height = 1, auto_width = 1 %}} ''' else: main_part = ''' {{% if record.{object_name} %}} - {{% inplace_edit "record.{object_name}.{field}" auto_height = 1 %}} + {{% inplace_edit "record.{object_name}.{field}" auto_height = 1, auto_width = 1 %}} {{% endif %}} ''' template = template.format(main_part = main_part)