'Recursively render a node as list item (with subnodes
as unsorted list inside the item)
@param node_id: the node ID
@param widget_id: the unique ID for the outermost list
@param represent: the node ID representation method
@return: the list item (LI)
@todo: option to add CRUD permissions'

def _html(self, node_id, widget_id, represent=None):

    node = self.nodes.get(node_id)
    if (not node):
        return None
    label = self.label(node_id, represent=represent)
    if (label is None):
        label = s3_unicode(node_id)
    subnodes = node['s']
    item = LI(label, _id=('%s-%s' % (widget_id, node_id)), _rel=('parent' if subnodes else 'leaf'), _class='s3-hierarchy-node')
    html = self._html
    if subnodes:
        sublist = UL([html(n, widget_id, represent=represent) for n in subnodes])
        item.append(sublist)
    return item
