You may be missing something - in the template, you don't need to use a query to get the value of a field, if you already have that field. In other words, you could have something like "{{#ifeq:{{{Type|}}}|Employee|....}}".
Yaron Koren (talk)