Quote:
Originally Posted by ownedbycats
On a non-fanfiction book with an undefined ccount this displays as "None." If I switch to non-raw field it becomes blank instead.
I don't mind it here, but why does raw field result in "none" instead of blank?
Actually I just realized I could probably remove the second elif statement and combine it with the third with a != compare op...
|
$$#x is equivalent to raw_field('#x'), which returns 'None' if the value is undefined. If you don't want that then use raw_field('#x', default) where default is whatever you want to see if the value isn't defined. In your case I think you want default to be ''.
EDIT: BTW: raw_field() is useful where the field is formatted in its column definition with characters so that the displayed value is no longer a number. The raw_field() function returns the underlying number, not the formatted one.