Browse Source

Ascending ordering for sign in time.

feature/python-error-tracking
Drew Larson 8 years ago
parent
commit
883cebac74
  1. 8
      bikeshop_project/assets/js/components/SignedInList.jsx

8
bikeshop_project/assets/js/components/SignedInList.jsx

@ -23,8 +23,12 @@ export default class SignedInList extends React.Component {
} }
render () { render () {
let members = this.props.members.map((member) => { const members = this.props.members.sort((l, r) => {
return <ListItem key={member.id} primaryText={member.text} secondaryText={`${member.purpose}${member.at.fromNow()}`} /> return l.at.diff(r.at);
})
.reverse()
.map((member) => {
return <ListItem key={member.id} primaryText={member.text} secondaryText={`${member.purpose}${member.at.fromNow()}`} />
}); });
return ( return (

Loading…
Cancel
Save