Beispiel #1
0
        private void runSchedule(User user, DicList <CoreError> errors)
        {
            try
            {
                parent.Safe.VerifyUser(user);
            }
            catch (CoreError e)
            {
                if (e.Type != Error.NotSignedLastContract)
                {
                    errors.Add(user.Email, e);
                }

                return;
            }

            try
            {
                runSchedule(
                    repos.Schedule.GetRunnable(user),
                    errors
                    );

                parent.BaseMove.FixSummaries(user);

                user.SetRobotCheckDay();
            }
            catch (CoreError e)
            {
                errors.Add(user.Email, e);
            }
        }
Beispiel #2
0
 public void AddDic(RfDiction dic)
 {
     if (DicList == null)
     {
         DicList = new List <RfDiction>();
     }
     DicList.Add(dic);
 }
Beispiel #3
0
        internal Language(String name, IDictionary <String, String> sentences)
        {
            PhraseList = new DicList <Phrase>();

            Name = name.Replace("_", "-");

            foreach (var sentence in sentences)
            {
                var dicPhrase = new Phrase(
                    sentence.Key,
                    sentence.Value
                    );

                PhraseList.Add(dicPhrase);
            }
        }
Beispiel #4
0
        internal Section(String name, JsonDictionary translations)
        {
            LanguageList = new DicList <Language>();

            Name = name;

            foreach (var language in translations)
            {
                var dicLanguage = new Language(
                    language.Key,
                    language.Value
                    );

                LanguageList.Add(dicLanguage);
            }
        }
Beispiel #5
0
 private void runSchedule(IList <Schedule> scheduleList, DicList <CoreError> errors)
 {
     foreach (var schedule in scheduleList)
     {
         try
         {
             inTransaction(
                 "RunSchedule",
                 () => addNewMoves(schedule)
                 );
         }
         catch (CoreError e)
         {
             errors.Add(schedule.User.Email, e);
         }
     }
 }