#set ($layout="json.vm")
#set ($dummy = $dbtool)
#set ($res=${response.setContentType("application/json")})
#if($params.computer)
#set ($attrs=$properties.fetchForComputerName($params.computer))
#elseif($params.profile)
#set ($attrs=$properties.fetchForProfileName($params.profile))
#else
Nope
#stop
#end
#set ($count=$attrs.size())
[
#foreach ($a in $sorter.sort($attrs,"name"))
#if ($count!=$velocityCount)
#set ($sep=",")
#else
#set ($sep="")
#end
{ "id": $a.id, "name": "$a.name", "value": "$a.value", "category": "$!a.category", "type":"$!a.typeHint" }$!sep
#end
]
