I am creating a web application using Dojo, composed of a treeView in the left side and a Data Grid on its right. After being loaded,I want the root of the treeView to be focused and clicked, so that the content of the datagrid can be changed accordingly.
I haven't success in doing this..
Thanks for your help
Thanks #Philippe for the clue about logic problem. Because of this clue, I am able to focus my mind by searching the error code. I found it in the defintion of query of the grid. <table id="jurnalGrid" dojoType="dojox.grid.DataGrid" jsId="jurnalGrid" columnReordering="true" sortFields="['tanggal','kode_jurnal']" store="jurnalStore" query="{id: '*'}" I think you can guess that my query string is not correct :) I still left the code from that link without changing it to suit my need. Thanks... –
Related
There are many buttons sharing the same class.
May have to go with clicking the link /account/logout'.
This is the code I'm trying to use:
input class="btnRed text-uppercase fo_white" value="Logout" onclick="window.location.href='/account/logout';" type="button"
Hard to say because you didn't provide enough info, but you could probably make it work by using value attribute. Something like this if you are using java.
driver.findElement(By.cssSelector("[value='Logout']")).click();
Not pretty solution, but give it a try:
driver.findElement(By.cssSelector(".btnRed.text-uppercase.fo_white")).click();
Looking at your HTML DOM this command will work for you:
driver.findElement(By.xpath("//input[#value='Logout']")).click();
Let me know if it works for you.
Looking at your HTML, this should work
driver.findElement(By.xpath("//input[#value='Logout'][#type='button']")).click();
Let me know if it works.
Is your element visible/enabled? In order to select an element, it must be present in your DOM. If the element is activated through an event, it cannot be selected until the event occurs.
Take a look at this post. This other post also have good ideas.
I am trying to build an admin dashboard using material design framework. As a part of it, I am trying to add modal-trigger element inside a <td></td> tag of a table that uses datatable.js library. But when I click on the trigger no modal is appearing. Did anyone face similar issue before?
I think that what's happening is that your trigger isn't in the DOM when you draw the table, but without seeing your code I can't be sure. Generally, it will trigger a modal when it is clicked or something? You might want to change the actual triggering to clicking on a td with a given class contained within the table so something like this:
$(".modal-trigger").click(function(){//Open Modal});
This would work on the first page but not after the first draw of the table as the event had been registered before the elements were within the DOM. Rather, you'd need to listen to the click within the table like this:
$("#table-id").on("click", ".modal-trigger", function(){//Open Modal});
I hope that makes sense and that it helps, if not perhaps work up a JSFiddle illustrating your issue?
a) I have a complex of nodes and edges. I want to add a title to the complex. Is there any way in Cytoscape.js, where I can display the title of the complex?
b) Additionally, I want to give user an option to download the complex in png file with a right click option, but my right click on the cytoscape div doesn't work. Is there any way or any flag I need to change to enable my right click on the picture?
Looks like no one is going to answer my question, answering them myself:
So, after struggling with these questions; I have got the solution for my first problem i.e. putting the title. We can have a parent node with the label as your complex title and then display it on the node. Don't think that it is a good way to do it. There should be something in cytoscape.js to display the title as well. But I don't think it is there yet.
In cytoscape there is an option to bind the event on right click, "cxttap" I used that to make a right click event. But I don't know how to give options on that click, working on that..!! If you are looking for same solution, stay tuned ;)
You can use right button with cytoscapejs by modifying the code below, adding your code
cy.on('cxttap', function(e){
console.log("right click!"); // just to check that it works, look at the console
// add here your code...
// ....
})
Im using dropkick on a site and it works really well and looks great. However when I try to use it within a tab (organinc tabs) the dropkick data is on sent.
Any ideas why this may be happening and solutions would be greatly appreciated.
thanks in advance.
The problem is that dropkick is not intiated on a hidden div. You can use Jquery to activate dropkick once the tab in question is selected.
I am trying to make a custom listview with his items bigger, with an image in the background and a text over it.
I'm trying to use the Kiva example on the docs, but I cannot understand nothing about how is doing that.
Someone could help me understand how to make that? or ar approach to do?
If you want to use sencha-touch 2.0, I think Sencha-touch2.0 guide helps you.
Of course if you want to edit style, you must change via css or template of listview (via listview's tpl attribute).