I want to disable a column, I use this code:
<ice-cc:selectBooleanColumn title="Installed" property="installed" disabled="true" ></ice-cc:selectBooleanColumn>
...but the column is still able to change.
Please help :)
By "disabled" you mean it shouldn't appear? Try rendered="false" maybe if this is the case.
There is no disabled attribute in selectBooleanColumn component, as said in API docs. I fear this cannot be done using ice-cc:editableTable.
Related
I want to render a absolute link in table from value of cell but I got a relative link instead.
Here is my configuration:
What I got when click on cell:
http://10.93.9.209:3000/http%3A%2F%2F10.131.227.253%2Fjob%2FPerformance%20Testing%20Pipeline%2Fjob%2Fstable%2F21%2F
In Grafana 7 (new table panel) it's ${__data.fields[2]} where number is column index.
This is a change introduced in one of the new Grafana versions. If you want an absolute URL, you must use ${__cell:raw} instead of ${__cell}. Reference
If you want to reference another column when clicking:
This is possible, I am using 9.1.7 and originally used the old table; however, after migrating noticed the same issue. That said, I found a way to make this work:
Add the ID column that you want to hide; example simID
If the column is the first column, say 0; then use:
var-whatever=${__data.fields[0]}
Now, override the column, field with name: simID Add option ‘Hide in Table’ and turn on
I also had to format the number, e.g. remove decimals & set unit to standard
Hope that helps someone… took me a good 2 hours to figure.
Btw, it also works on graphs and you do not have to hide; aka reference your original query in the datasource and add a data link with the same options.
What result do you get if you try $__cell_2?
The syntax above no longer works. The value is now ${__value:raw}
$__cell_2 above solution worked for me.
With the new table panel introduced in Grafana either ${__cell} or ${__cell:raw} do not work for this now.
You must use ${__value:raw}
i try to display a dialog for selection the fields of a source.
i like to use the ListSelectionDialog, but i'm not sure what to use for the input parameter.
all the examples in the web uses the
ResourcesPlugin.getWorkspace().getRoot()
as input and yeah, all the projects are displayed.
but i have a list of Fields (IField[]) that i want to show for selection.
the constructor of ListSelectionDialog accept the parameter, but the dialog shows nothing... :(
does anybody has an idea?
thanks a lot!
Sven
I don't think using BaseWorkbenchContentProvider is right. Try ArrayContentProvider.
So something like:
new ListSelectionDialog(shell, fields, new ArrayContentProvider(), labelProvider, msg);
I have discovered a nice component for confirming actions - ice:panelConfirmation. But I think, it has one big mistake. I can't change the name of heading, there is always "Confirm". It is really so bad? Or is there some possibility to change it? I need to translate it to another language, for example.
Here is my code:
<ice:panelConfirmation id="deleteConfirm" message="#{msg['really']}"
acceptLabel="#{msg['yes']}" styleClass="dialog"
cancelLabel="#{msg['no']}" displayAtMouse="true"/>
...
<ice:commandButton image="/resources/images/delete.png" action="#{postManager.delete(item)}"
title="#{msg['news.delete']}" styleClass="smallSpaces"
panelConfirmation="deleteConfirm"/>
The ice:panelConfirmation component has a "title" attribute that you can use to set the text of the popup header. Have a look here
I am extremely new to Zend Framework, In registration form, i need label text in two line. For Example:- In the case First name, I need to display like below:
First
Name:
How can i implement this? Please anyone help me!!!
By default, input fields labels are being escaped by Zend_View_Helper_FormLabel. However, you can easy switch this off:
$yourTextInputElement->getDecorator('label')->setOption('escape', false);
This way you can use labels as e.g. $yourTextInputElement->setLabel('First <br/> name');.
What about this nifty solution ?
http://jsfiddle.net/J67GD/
The best way is probably to use Description decorator, or subclass one of other standard ZF decorators.
Yanick's CSS solution might be a good choice too, depending what are you trying to do.
pratically I build up a tableviewer as usual, but initially it does not sort all the rows according the column defined for sorting.
The code I am using:
viewer.getTable().setSortColumn(viewer.getTable().getColumn(4));
viewer.getTable().setSortDirection(SWT.UP);
Only after clicking manually the column #4 I obtain the correct order, otherwise it follows exactly the "insert order" of the object list linked to the ViewContentProvider. Please can you help me? Tnx
You just need to refresh the table.
Just had the same problem.
When using ...
tableViewer.setComparator(comparator)
... the above code is ignored.
You have to set manually the initial sort column index in the extended ViewerComparator.
Building off Devalex's answer, the following worked for me:
viewer.setContentProvider(...);
viewer.setInput(...);
viewer.setComparator(myComparator);
myComparator.setColumn(colIndex);
viewer.refresh();