本文整理匯總了TypeScript中app/core.AccountService類的典型用法代碼示例。如果您正苦於以下問題:TypeScript AccountService類的具體用法?TypeScript AccountService怎麽用?TypeScript AccountService使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
在下文中一共展示了AccountService類的8個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: it
it('should return false if user is logged and has not authority', async () => {
service.authenticate({
authorities: ['ROLE_USER']
});
const hasAuthority = await service.hasAuthority('ROLE_ADMIN');
expect(hasAuthority).toBeFalsy();
});
示例2: ngOnInit
ngOnInit() {
this.loadAll();
this.accountService.identity().then(account => {
this.currentAccount = account;
});
this.registerChangeInTrackingNumbers();
}
示例3:
() => {
this.error = null;
this.success = 'OK';
this.accountService.identity(true).then(account => {
this.settingsAccount = this.copyAccount(account);
});
},
示例4: ngOnInit
ngOnInit() {
this.loadAll();
this.accountService.identity().then(account => {
this.currentAccount = account;
});
this.registerChangeInAclObjectIdentities();
}
示例5: ngOnInit
ngOnInit() {
this.loadAll();
this.accountService.identity().then(account => {
this.currentAccount = account;
});
this.registerChangeInCartaoRecompensas();
}
示例6: ngOnInit
ngOnInit() {
this.loadAll();
this.accountService.identity().then(account => {
this.currentAccount = account;
});
this.registerChangeInRestaurantes();
}
示例7: ngOnInit
ngOnInit() {
this.sessionsService.findAll().subscribe(sessions => (this.sessions = sessions));
this.accountService.identity().then(account => {
this.account = account;
});
}
示例8: ngOnInit
ngOnInit() {
this.loadAll();
this.accountService.identity().then(account => {
this.currentAccount = account;
});
this.registerChangeInFornecedors();
}