1
0
mirror of https://github.com/flarum/core.git synced 2025-08-06 16:36:47 +02:00

Hello world!

This commit is contained in:
Toby Zerner
2014-12-20 16:56:46 +10:30
commit 74db323f83
279 changed files with 11954 additions and 0 deletions

21
ember/app/models/user.js Normal file
View File

@@ -0,0 +1,21 @@
import Ember from 'ember';
import DS from 'ember-data';
export default DS.Model.extend({
username: DS.attr('string'),
avatarUrl: DS.attr('string'),
joinTime: DS.attr('date'),
lastSeenTime: DS.attr('date'),
discussionsCount: DS.attr('number'),
postsCount: DS.attr('number'),
canEdit: DS.attr('boolean'),
canDelete: DS.attr('boolean'),
groups: DS.hasMany('group'),
avatarNumber: function() {
return Math.random() > 0.3 ? Math.floor(Math.random() * 19) + 1 : null;
}.property()
});