mirror of
https://gitlab.silvrtree.co.uk/martind2000/censis-obrand.git
synced 2025-02-14 15:59:15 +00:00
27 lines
657 B
JavaScript
27 lines
657 B
JavaScript
|
import Ember from 'ember';
|
||
|
|
||
|
const { inject: { service }, RSVP } = Ember;
|
||
|
|
||
|
export default Ember.Route.extend({
|
||
|
|
||
|
sessionAccount: service('session-account'),
|
||
|
model: function(params) {
|
||
|
'use strict';
|
||
|
const accountId = this.get('sessionAccount.account.id');
|
||
|
|
||
|
/*return new RSVP.Promise((resolve,reject) => {
|
||
|
return this.get('store').find('profile',accountId)
|
||
|
.then(function(p) {
|
||
|
resolve(p);
|
||
|
},reject);
|
||
|
});*/
|
||
|
|
||
|
return new RSVP.Promise((resolve,reject) => {
|
||
|
console.log('***HERE***');
|
||
|
return this.get('store').find('profile',accountId)
|
||
|
.then(resolve,reject);
|
||
|
});
|
||
|
|
||
|
}
|
||
|
});
|