Exemplo n.º 1
0
        public AzureAccountControlViewModel()
        {
            Account = new ConnectedAzureAccount();
            _azure  = MultiTenantAzure.FromAccount(Account);
            _azure.UserTokenInteraction = this;

            InitialiseAsync().Forget();
        }
Exemplo n.º 2
0
        public AzureAccount(ConnectedAzureAccount connectedAzureAccount) : base(connectedAzureAccount.DisplayName, "azure/directory")
        {
            _client = MultiTenantAzure.FromAccount(connectedAzureAccount);

            CommandGroups.Add(new HierarchicalResourceCommandGroup(
                                  new HierarchicalResourceCommand("refresh", Symbol.Refresh, RefreshAsync),
                                  new HierarchicalResourceCommand("delete", Symbol.Delete, DeleteAsync)));

            RefreshAsync().Forget();
            _connectedAzureAccount = connectedAzureAccount;
        }