Skip to content
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

Table persistent state #5953

Merged
merged 22 commits into from
Apr 25, 2016
Merged

Table persistent state #5953

merged 22 commits into from
Apr 25, 2016

Conversation

panda01
Copy link
Contributor

@panda01 panda01 commented Jan 20, 2016

Added column sorting persistent state to the tables.

This affects all of the paginated_tables in kibana, and they should all be checked to make sure they work as expected.

You should make a visualization with multiple tables and check to make sure that all of the sorting stays in sync.
You should check that sorting in the field list in settings, and on discover works as expected.

closes #3721.

@panda01 panda01 self-assigned this Jan 21, 2016
@epixa epixa assigned epixa and unassigned panda01 Jan 21, 2016
@epixa
Copy link
Contributor

epixa commented Jan 25, 2016

One thing I noticed: if you freshly load a saved visualization, the save button is disabled (presumably because there are no changes to save). However, changing the sort of the data table does not re-enable the save button.

@epixa epixa assigned panda01 and unassigned epixa Jan 25, 2016
@epixa
Copy link
Contributor

epixa commented Jan 25, 2016

Can you make sure the existing tests are updated to reflect these changes? I didn't check every file, but for example, paginated_table.js does have tests that can be updated with the added behaviors.

@panda01
Copy link
Contributor Author

panda01 commented Jan 27, 2016

@epixa The spy panel also when loaded doesn't affect the save button when changed however, i would say this is a bug, we solve in another PR.

I addressed your other concerns regarding tests.

@panda01 panda01 assigned epixa and unassigned panda01 Jan 27, 2016
@epixa
Copy link
Contributor

epixa commented Jan 27, 2016

Sounds good

@epixa
Copy link
Contributor

epixa commented Jan 29, 2016

LGTM

@epixa epixa assigned panda01 and unassigned epixa Jan 29, 2016
@panda01 panda01 force-pushed the enhance/data-table branch 2 times, most recently from c906e7e to 902d96f Compare February 5, 2016 20:23
@epixa
Copy link
Contributor

epixa commented Feb 8, 2016

jenkins, test it

@epixa
Copy link
Contributor

epixa commented Feb 8, 2016

This needs to be rebased on master or have master merged into it.

@epixa
Copy link
Contributor

epixa commented Apr 8, 2016

Test failure. Looks like you need to import lodash into that file.

@epixa epixa assigned panda01 and unassigned epixa Apr 8, 2016
@@ -116,6 +116,7 @@ uiModules
};

$state = new AppState(stateDefaults);
$scope.uiState = $state.makeStateful('uiState');
Copy link
Contributor Author

Choose a reason for hiding this comment

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

};
function valueGetter(row) {
let value = row[self.sort.columnIndex];
if (value && value.value != null) value = value.value;
Copy link
Contributor

Choose a reason for hiding this comment

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

Should this be !== or are you intentionally checking for null-like instead of null?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

That is intentional. All I was attempting to do was move the above code into something simpler since it seems it was never used.

@epixa
Copy link
Contributor

epixa commented Apr 12, 2016

If the != that I linked to above is intentional, this LGTM

@epixa epixa assigned panda01 and unassigned epixa Apr 12, 2016
@panda01
Copy link
Contributor Author

panda01 commented Apr 12, 2016

Thanks @epixa! I'll pass it to someone else to take a look at as well.

@panda01 panda01 assigned spalger and unassigned panda01 Apr 12, 2016
@rashidkpc
Copy link
Contributor

@panda01 merge master then assign this to me

@rashidkpc rashidkpc assigned panda01 and unassigned spalger Apr 15, 2016
@panda01 panda01 assigned rashidkpc and unassigned panda01 Apr 15, 2016
@rashidkpc rashidkpc merged commit b2e6502 into elastic:master Apr 25, 2016
@w33ble w33ble mentioned this pull request Dec 11, 2017
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Save sort state in data table vis
4 participants