From 5427c1b503fb887da69210f50818d8b564a46e0b Mon Sep 17 00:00:00 2001 From: Massimo Di Pierro Date: Tue, 14 Feb 2012 08:44:25 -0600 Subject: [PATCH] http://groups.google.com/group/web2py/browse_thread/thread/54dde625a2a19d19#, thanks Roderick --- VERSION | 2 +- gluon/sqlhtml.py | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/VERSION b/VERSION index 5c1822c2..542b46bc 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 1.99.4 (2012-02-14 08:39:29) stable +Version 1.99.4 (2012-02-14 08:44:22) stable diff --git a/gluon/sqlhtml.py b/gluon/sqlhtml.py index f4c353ae..06d51ef4 100644 --- a/gluon/sqlhtml.py +++ b/gluon/sqlhtml.py @@ -1939,7 +1939,9 @@ class SQLFORM(FORM): previous_tablename,previous_fieldname,previous_id = \ tablename,fieldname,id try: - name = db[referee]._format % record + format = db[referee]._format + if callable(format): name = format(record) + else: name = format % record except TypeError: name = id breadcrumbs += [A(T(db[referee]._plural),