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

data not refreshed when model changes when using data-sorter #39

Closed
ctcpip opened this issue Dec 6, 2018 · 0 comments · Fixed by #40
Closed

data not refreshed when model changes when using data-sorter #39

ctcpip opened this issue Dec 6, 2018 · 0 comments · Fixed by #40

Comments

@ctcpip
Copy link
Contributor

ctcpip commented Dec 6, 2018

same cause of #17 -- but the fix for that was only applied to data-filterer. that same fix needs to be applied to data-sorter as well (and maybe other components)

basically when you have code like this:

      {{#data-sorter data=model as |ds|}}
        {{#data-table data=ds.data as |t|}}
          {{t.sortableColumn propertyName='name' name="Name"}}
        {{/data-table}}
      {{/data-sorter}}

if the model changes, the table does not show the new data

the fix is the same as for #17 (fixed by #18)

-  sortedData:computed('data', 'sortFields.[]', 'sorter', function() {
+  sortedData:computed('data.[]', 'sortFields.[]', 'sorter', function() {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant