Ejemplo n.º 1
0
 public static void Evaluate(LinkedStaffMember account)
 {
     if (account.Wisa.Account.CODE != account.Directory.Account.WisaID || account.Wisa.Account.CODE != account.Smartschool.Account.AccountID)
     {
         account.Actions.Add(new UpdateWisaName());
         account.Directory.FlagWarning();
         account.OK = false;
     }
 }
 public static void Evaluate(LinkedStaffMember account)
 {
     if (account.Directory.Account.Mail != account.Directory.Account.PrincipalName)
     {
         account.Actions.Add(new PrincipalNameMustEqualMail());
         account.Directory.FlagWarning();
         account.OK = false;
     }
 }
        public async override Task Apply(LinkedStaffMember account)
        {
            bool connected = await State.App.Instance.AD.Connect().ConfigureAwait(false);

            if (!connected)
            {
                return;
            }

            account.Directory.Account.PrincipalName = account.Directory.Account.Mail;
        }
Ejemplo n.º 4
0
        public override FlowDocument GetDetails(LinkedStaffMember account)
        {
            var result = new FlowTableCreator(false);

            result.SetHeaders(new string[] { "Wisa", "Directory", "Smartschool" });

            result.AddRow(new List <string>()
            {
                "Wisa ID", account.Wisa.Account.CODE, account.Directory.Account.WisaID, account.Smartschool.Account.AccountID
            });

            FlowDocument document = new FlowDocument();

            document.Blocks.Add(result.Create());

            return(document);
        }
Ejemplo n.º 5
0
        public async override Task Apply(LinkedStaffMember account)
        {
            bool connected = await State.App.Instance.AD.Connect().ConfigureAwait(false);

            if (!connected)
            {
                return;
            }

            if (account.Directory.Account.WisaID != account.Wisa.Account.CODE)
            {
                await account.Directory.Account.SetWisaID(account.Wisa.Account.CODE).ConfigureAwait(false);
            }
            if (account.Smartschool.Account.AccountID != account.Wisa.Account.CODE)
            {
                account.Smartschool.Account.AccountID = account.Wisa.Account.CODE;
                await AccountApi.Smartschool.AccountManager.ChangeAccountID(account.Smartschool.Account).ConfigureAwait(false);
            }
        }
        public override FlowDocument GetDetails(LinkedStaffMember account)
        {
            var result = new FlowTableCreator(false);

            result.SetHeaders(new string[] { "Veld", "Waarde" });
            result.AddRow(new List <string>()
            {
                "Mail", account.Directory.Account.Mail
            });
            result.AddRow(new List <string>()
            {
                "UserPrincipalName", account.Directory.Account.PrincipalName
            });

            FlowDocument document = new FlowDocument();

            document.Blocks.Add(result.Create());

            return(document);
        }