var self = this var peerid = app.nav.current.context[':id'] var postpath = app.nav.current.postpath var path = 'xio/admin/peers/'+peerid if (postpath) { path = path+'/'+postpath } showResource = function() { $(self).find('section').html('') } debugResource = function() { app.server.about(path).then(function(resp) { console.log(resp.content) var html = json2html(resp.content) $(self).find('section').html(html) }) } showResource()