} else {
sortValues = sortValues + ", '" + yuiImage.getDesc() + "'";
sortIds = sortIds + ", 'dd" + i + "_" + id + "'";
}
}
PackagedTextTemplate template = new PackagedTextTemplate(
SortGroup.class, "init.js");
Map<String, Object> variables = new HashMap<String, Object>(4);
variables.put("javaScriptId", javaScriptId);
variables.put("mode", "YAHOO.util.DDM." + mode);
variables.put("sortValues", sortValues);
variables.put("sortIds", sortIds);
variables.put("valueId", "'" + valueId + "'");
template.interpolate(variables);
return template.getString();
}