Quote:
Originally Posted by DNSB
I think it broke on my Kobos between 4.38/45.23640 and 4.38/45.23649. The template tester still shows the series index converting from 5.08 to 5-8 but on the Kobo, the series index shows as 5.08.
|
This template works for me on fw 4.38.23684 - it turns 1.03 into 1-3 and 0 into unnumbered
Code:
program:
if
'^omnibus$' inlist_field '#admintags'
&& $series_index !=#0
then
series_start = floor($series_index);
fraction = fractional_part($series_index);
if
fraction ==# 0
then
result = series_start
else
series_end = floor(fraction*100);
if
series_end >=# 0
then
result = series_start & '-' & series_end
fi
fi
elif
$series_index ==#0
then
result = ''
else
result = $series_index
fi;
result