Show contribution history from events
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
import Ember from 'ember';
|
||||
|
||||
export default Ember.Component.extend({
|
||||
|
||||
tagName: 'ul',
|
||||
classNames: ['contribution-list'],
|
||||
|
||||
contributionsWithContributors: function() {
|
||||
return this.get('contributions').map((c) => {
|
||||
c.set('contributor', this.get('contributors')
|
||||
.findBy('address', c.get('recipientAddress')));
|
||||
return c;
|
||||
});
|
||||
}.property('contributions.@each')
|
||||
|
||||
});
|
||||
@@ -0,0 +1,7 @@
|
||||
{{#each contributionsWithContributors as |contribution|}}
|
||||
<li title="({{contribution.kind}}) {{contribution.description}}">
|
||||
<span class="category {{contribution.kind}}">♥</span>
|
||||
<span class="amount">{{contribution.amount}}</span><span class="symbol">₭S</span>
|
||||
for <span class="recipient">{{contribution.contributor.name}}</span>
|
||||
</li>
|
||||
{{/each}}
|
||||
Reference in New Issue
Block a user