當前位置: 首頁>>代碼示例>>TypeScript>>正文


TypeScript core.AccountService類代碼示例

本文整理匯總了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();
                });
開發者ID:Danils123,項目名稱:Prueba-azure,代碼行數:9,代碼來源:account.service.spec.ts

示例2: ngOnInit

 ngOnInit() {
     this.loadAll();
     this.accountService.identity().then(account => {
         this.currentAccount = account;
     });
     this.registerChangeInTrackingNumbers();
 }
開發者ID:timstoner,項目名稱:taskapp,代碼行數:7,代碼來源:tracking-number.component.ts

示例3:

 () => {
     this.error = null;
     this.success = 'OK';
     this.accountService.identity(true).then(account => {
         this.settingsAccount = this.copyAccount(account);
     });
 },
開發者ID:Danils123,項目名稱:Prueba-azure,代碼行數:7,代碼來源:settings.component.ts

示例4: ngOnInit

 ngOnInit() {
     this.loadAll();
     this.accountService.identity().then(account => {
         this.currentAccount = account;
     });
     this.registerChangeInAclObjectIdentities();
 }
開發者ID:timstoner,項目名稱:taskapp,代碼行數:7,代碼來源:acl-object-identity.component.ts

示例5: ngOnInit

 ngOnInit() {
   this.loadAll();
   this.accountService.identity().then(account => {
     this.currentAccount = account;
   });
   this.registerChangeInCartaoRecompensas();
 }
開發者ID:jbbfreitas,項目名稱:BestMeal,代碼行數:7,代碼來源:cartao-recompensa.component.ts

示例6: ngOnInit

 ngOnInit() {
   this.loadAll();
   this.accountService.identity().then(account => {
     this.currentAccount = account;
   });
   this.registerChangeInRestaurantes();
 }
開發者ID:jbbfreitas,項目名稱:BestMeal,代碼行數:7,代碼來源:restaurante.component.ts

示例7: ngOnInit

  ngOnInit() {
    this.sessionsService.findAll().subscribe(sessions => (this.sessions = sessions));

    this.accountService.identity().then(account => {
      this.account = account;
    });
  }
開發者ID:jhipster,項目名稱:jhipster-sample-app-gradle,代碼行數:7,代碼來源:sessions.component.ts

示例8: ngOnInit

 ngOnInit() {
   this.loadAll();
   this.accountService.identity().then(account => {
     this.currentAccount = account;
   });
   this.registerChangeInFornecedors();
 }
開發者ID:jbbfreitas,項目名稱:BestMeal,代碼行數:7,代碼來源:fornecedor.component.ts


注:本文中的app/core.AccountService類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。