-
-
Notifications
You must be signed in to change notification settings - Fork 176
Clicking on hyperlink in column doesn't run ts linkTxt #324
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
This is my most significant blocker at this time for the project. I will try to use the pop up menu to select to launch to this link. Some more information on the link itself and debugging it in typescript trying to understand why we cannot see the onclick when debugging and determining if this is a reason why the click function is not run with HtmlUnit: This functions the same as other widgets that can accept clicking event, such as the refresh icon at the up right corner of the table. It also has a (click) in the html:
But in the debug console of the browser, (onclick) is missing too: I do not know how angular integrates and generates the html that shown in the browser. And whether it is related to this problem of no response when clicking the link with HtmlUnit. I will try clicking the refresh button to see if that works with HtmlUnit next. |
Hi Lora, thanks for the detailed description. At the moment i have no real idea what is going wrong here - as always is there something in the logs? Another option is to force HtmlUnit to ignore the visibility - sometimes HtmlUnit thinks the control is not visible and because of this the click is not processed. See #301 for details. |
I have tried the full click line as is done if the element is not visible: There isn't any output indicating that the "click" was not activated for any reason.
plenty of variations on CSS warnings/errors:
later more similar CSS errors and warnings:
Plenty of these:
after SEVERE errors (parser error as posted in issue #318 ) |
Hi Lora, Just as an idea - maybe the event is assigned to some element in the shadow dom? |
I will ask a team member. I don't see anything related to the shadow dom, but not sure what to look for. |
Angular, does supports shadow dom when creating a component, but we haven't utilized this option in our code. By default, Angular operates dom directly. I have searched the html/xml for any #shadow and nothing is there. |
maybe related to #346? |
The table column has a hyperlink for launching to the perspective graph:
For column w hyper link, an object is used to store the hyper link part and non-hyper link part.
public persNameDisplayObj:{}=null;
in perspective-info-manager.ts: initializes this object
tmpPersInfo.persNameDisplayObj = {linkTxt: tmpPersInfo.getPerspectiveName(), otherTxt: ""};
<span *ngIf="col.hyperlink" style="vertical-align:middle;">{{rowData[col.hyperlink].otherTxt}}<a href="javascript:void(0);"(click)= "onLinkClick.emit({row:rowData,col:col.hyperlink})">{{rowData[col.hyperlink].linkTxt}}</a></span>
Above for the column in basictable, "javascript:vodi(0)" means we go nowhere but execute the click function. So here the onLinkClick() function is triggered and passed the perspective info and hyper link object name as parameters.
When clicked in the browser, the onLinkClick() function invokes gotoDojoGraph() method with the perspective name information and the router routes to the "dojo-graph" path. The component DojoGraphLauncher(dojo.graph.launcher.ts) is then invoked
In the gotoDojoGraph() function, the router routes to the "dojo-graph" path, and its corresponding component is DojoGraphLauncher(dojo.graph.launcher.ts). All the routing configuration info are stored in performance.routing.module.ts:
The template of DojoGraphLauncher component is dojo.graph.launcher.html. The DojoGraphLauncher object is constructed with the perspective info passed in and in the ngOnInit() function it finally loads our js script DojoGraphLauncher.js. In the js, it loads all the dojo classes and parses the dojo widgets in dojo.graph.launcher.html and finally calls DojoGraph.js.
In DojoGraph.js, it will send request to the server side and get the data to render on the chart by sending an Ajax request with the url:
url = "/Navigator/DispatcherServlet/perf/dojoChartRequestHandler?f=getData"
The servlet will find the controller class PerformanceController by this part:
In PerformanceController, it will find the method dojoChartRequestHandler to handle this request:
9). The chart data will be returned to the DojoGraph.js from the getData() function of GraphDataProvider directly.
Doing a click on this element in HtmlUnit does not end up activating this same code.
Is there a way to determine why the onLinkClick() and gotoDojoGraph() methods are not being processed when calling "click()" for the table element?
On the page we are processing with the table and perspective names, this is the element we want to "click on";
For a page like this, we can select one of the items in the 2nd column (CPU Utilization (Average) or "Database Health Indicators"), or alternatively we can do the pop-up menu and select "Investigate Data" which should launch the same chart for whatever row we are hovered over ("Disk Health Indicators" in this screenshot).

Here is a full row:
NewFile.xml.txt
Is there something else that needs to be done for the click to be activated in this situation? I gave you I think a lot more information that may be needed to make sure the whole setup was defined. If you need clarification on anything just ask.
The text was updated successfully, but these errors were encountered: