guacamole-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joachim Lindenberg" <joac...@lindenberg.one>
Subject AW: Extension... showing VM status?
Date Sun, 18 Mar 2018 18:34:17 GMT
Hi Mike,

my current status.html is

<meta name="after-children" content=".name">

<span ng-show="item.attributes['Status']"></span>

hoping that “name” would stand for the connection name in the list shown to the user.
Interestingly the list of connections was truncated at the last used connection when I used
"item.wrappedItem.attributes['Status']” following the initial extension example, which made
me think of a javascript error.. but with item.attributes, the javascript console is silent
and I don´t know how to get the column displayed.

Thanks,

Joachim

 

 

 

Von: Mike Jumper [mailto:mike.jumper@guac-dev.org] 
Gesendet: Sonntag, 18. März 2018 08:24
An: user@guacamole.apache.org
Betreff: Re: Extension... showing VM status?

 

On Fri, Mar 16, 2018 at 11:16 AM, Joachim Lindenberg <joachim@lindenberg.one <mailto:joachim@lindenberg.one>
> wrote:

... However the status is not shown in the UI, although I created a status.html and listed
that in my guac-manifest.json.

 

Can you provide your status.html?

 

But I couldn´t figure out from  <http://guacamole.apache.org/doc/gug/guacamole-ext.html#ext-patch-html>
http://guacamole.apache.org/doc/gug/guacamole-ext.html#ext-patch-html, what selector values
are defined

 

Any CSS selector. The selector just has to match an element within any defined template. The
main gotcha here is that the selector is evaluated within the context of each, not within
the context of the page. Elements outside the template are not taken into account.

 

The example I pointed to uses the ".home-connection" CSS selector, which selects any element
having the "home-connection" class. There is only one such element which occurs only in one
template:

 

https://github.com/apache/guacamole-client/blob/4f27a03adfe54d18772c81553c730f5cdc9115e4/guacamole/src/main/webapp/app/home/templates/connection.html#L1

 

and what the meaning of the <span> contents are.

 

In the case of the "shared-connection.html" patch that I cited as an example, the "translate"
and "translate-values" attributes are used by angular-translate [1], which is the i18n library
we use within Guacamole. That "HOME.INFO_SHARED_BY" is a reference to a translation string
defined by the JDBC auth:

 

https://github.com/apache/guacamole-client/blob/4f27a03adfe54d18772c81553c730f5cdc9115e4/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/resources/translations/en.json#L74-L76

 

- Mike

 

[1] https://angular-translate.github.io/

 


Mime
View raw message