[Geomoose-users] Formatting the results tab to include number

Mark Volz MarkVolz at co.lyon.mn.us
Wed Nov 10 08:02:43 PST 2021


James, and others

I was able to remove the ??? value from blank results by specifying how blanks should be handled such as:   <div class="item"><label>Property Address:</label> {{ properties.TXPADR1|blank>N/A }}</div>.   Thank you for your help.  Unfortunately, I am still having trouble trying to figure out how to properly call the toPrecision function.

Thanks!

Parcels.html
var context = { num: {properties.TXDEED}};
var template = "{{num|call>toPrecision>5}}";
var result = Mark.up(template, context);
<div class="identify-result">
    <div class="feature-class">Parcel (remote template14)</div>
    <div class="item"><label>PIN Number:</label> {{ properties.Parcel_ID }}</div>
    <div class="item"><label>Rounding Deeded Acres (works):</label> {{ properties.TXDEED|round}}</div>
    <div class="item"><label>Deeded Acres inline precision (does not work):</label> {{ properties.TXDEED|call>toPrecision>2}}</div>
    <div class="item"><label>Deeded Acres by calling variables above (does not work):</label> {result}</div>
    <div class="item"><label>Deeded Acres by calling variables inline inline var(does not work):</label> {var context = { properties.TXDEED}; var template = "{{num|call>toPrecision>5}}"; Mark.up(template, context);}</div>
</div>


>Look at choose and/or if for ??? and fix for formatting numbers.
>
>https://github.com/adammark/Markup.js

> On Nov 10, 2021, at 07:57, Mark Volz <MarkVolz at co.lyon.mn.us> wrote:
>
> ?
> Hello,
>
> I would like to change the format of my results tab so that:
> ?         Display only two digits for floating point value.  We could do this in older versions of GeoMOOSE by specifying a precision [item name="Acres" precision=2]
> ?         When a value is blank or null change the result from ????? to an empty text.  For example not all of our parcels have property addresses.
>
> Thank You!
> Mark Volz


More information about the Geomoose-users mailing list