Skip to content
This repository has been archived by the owner on Jul 24, 2019. It is now read-only.

Correcting problems reported on Issue #212 #214

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

vgartner
Copy link

Addresses and corrects problems reported on Issue #212

Addresses and corrects problems reported on Issue mysticfall#212
@mysticfall
Copy link
Owner

I've made a few comments about your suggestions, so I'd like you to review them and let me know how you think.

Thanks much for the contribution! 😃

@vgartner
Copy link
Author

vgartner commented Jul 5, 2017

Hi, you're welcome.
Maybe this can sound stupid, but... where can I find the comments? I haven't find them.... (^_^)
Best regards.

@mysticfall mysticfall self-assigned this Jul 5, 2017
@mysticfall
Copy link
Owner

@vgartner I might be doing something stupid myself, since it's the first time I've used the new review feature 😅

Anyway, aren't my comments visible above? On my end, I can see them along with the relevant lines from your code. If you can't, maybe you can try switching to Files Changed tab and see if you can read them there.

@vgartner
Copy link
Author

vgartner commented Jul 7, 2017

Hi @mysticfall
nope, can't find it yet... 😁
I've attached some screenshots to show to you what I see... 👍
Regards.

conversation
files
files1
pull_request

@@ -557,8 +557,8 @@ public void regeneratePosTree(List<Exp> sets, boolean hiersChanged) {
for (Exp set : sets) {
try {
Hierarchy hierarchy = quaxUtil.hierForExp(set);
hiers.add(hierarchy.getName());
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree that it's safer to use unique names than simple names for look up.

But I guess you might one to check other places that still use simple names when they deal with hiers and hierarchyMap variables, like those at 500-501 line, for instance.

@@ -354,7 +354,7 @@
action="#{memberSelectionHandler.show}" update=":hierarchy-form"
oncomplete="PF('hierarchyConfig').show();"
title="#{msg['button.hierarchyConfig.tooltip']}">
<f:param name="hierarchy" value="#{node.name}" />
<f:param name="hierarchy" value="#{node.caption}" />
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we should rely on caption when we look up hierarchies, since there could be duplicates.

I'm not too sure about the exact problem with using name, but if there's such a problem, can't we use uniqueName instead?

@@ -416,9 +418,15 @@ public void moveDown() {

public Hierarchy getHierarchy() {
if (hierarchy == null && hierarchyName != null && model.isInitialized()) {
this.hierarchy = model.getCube().getHierarchies()
.get(hierarchyName);
for (Hierarchy h : model.getCube().getHierarchies()) {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please read my other comment about using uniqueName instead of caption. And if there's a valid reason why we shouldn't use uniqueName there, then I suppose we shouldn't use it in Quax either.

Please see following lines at Quax.java:2926:

hierarchy = getModel().getCube().getHierarchies().get(name);

With your changes, the name parameter became uniqueName instead of simple name. So, it's basically the same code as the one you've changed here.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And please make it sure that the modified code follows the same formatting rules as the rest of the codebase. The project uses tabs for indentation, but the modified part seems to have 8 spaces per indent.

}
// this.hierarchy = model.getCube().getHierarchies()
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You don't have to leave them with comments, since we can always restore from history if needed :)

@mysticfall
Copy link
Owner

@vgartner Oh, my.... I feel stupid! 😓 I just realized that I need to actually 'submit' the review after I write individual comments.

I believe now you should be able to see it. Sorry for the confusion!

@lhg-interact lhg-interact mentioned this pull request Dec 27, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants