Skip to content
This repository was archived by the owner on Jun 10, 2021. It is now read-only.

Add sort event to columns #45

Closed
wants to merge 1 commit into from
Closed

Conversation

ceejtron
Copy link

Adds a sort event that is emitted on columns as per #44

@coderdiaz coderdiaz self-requested a review October 11, 2017 17:24
@coderdiaz
Copy link
Owner

The sort feature it's ok =)

Nice work man @ceejtron, but, Can we add an arrows for show DESC or ASC?

Example.
image

@@ -152,7 +153,7 @@ export default {
},
columnItems () {
return this.columns.map((column, index) => {
return <th>{ column.name }</th>
return <th on-click={ (e) => this.sortColumn(e, column, index) }>{ column.name }</th>
Copy link
Owner

@coderdiaz coderdiaz Oct 11, 2017

Choose a reason for hiding this comment

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

Add condition for column.sort is false, the event cannot be handled.

@coderdiaz coderdiaz closed this Oct 23, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants