From 3eb4a41139e83e6cf1e0826e3750a29d0e23033a Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sun, 11 Sep 2022 20:36:45 +0530 Subject: [PATCH] Content server custom book list: Allow using short text columns --- src/pyj/book_list/custom_list.pyj | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/pyj/book_list/custom_list.pyj b/src/pyj/book_list/custom_list.pyj index e60d3b0cc0..0b55e6373a 100644 --- a/src/pyj/book_list/custom_list.pyj +++ b/src/pyj/book_list/custom_list.pyj @@ -151,9 +151,8 @@ def render_field(field, mi, book_id): # {{{ name = fm.name or field datatype = fm.datatype - if field is 'comments' or datatype is 'comments': + if field is 'comments': return - func = None if datatype is 'composite': func = process_composite elif field is 'formats': @@ -172,6 +171,11 @@ def render_field(field, mi, book_id): # {{{ func = process_datetime elif datatype is 'series': func = process_series + elif datatype is 'comments': + if fm.display?.interpret_as is 'short-text': + return add_val(val) + else: + return elif field.endswith('_index'): func = process_series_index elif field is 'size':