mirror of
https://git.rwth-aachen.de/acs/public/villas/web/
synced 2025-03-23 00:00:02 +01:00

Change adapter and serializer to REST api. Add session-user to get logged-in user in every controller/route Change models to async relationships, this way the data is only loaded when requested.
8 lines
231 B
JavaScript
8 lines
231 B
JavaScript
import Model from 'ember-data/model';
|
|
import attr from 'ember-data/attr';
|
|
import { belongsTo } from 'ember-data/relationships';
|
|
|
|
export default Model.extend({
|
|
name: attr('string'),
|
|
owner: belongsTo('user', { async: true })
|
|
});
|