コード例 #1
0
        /// <summary>
        /// Makes a new Student
        /// </summary>
        /// <param name="data"></param>
        /// <returns>Student Passed In</returns>
        public StudentModel Create(StudentModel data, DataSourceEnum dataSourceEnum = DataSourceEnum.Unknown)
        {
            StudentBackend.SetDataSource(DataSourceEnum.Mock);

            DataSet.Add(data);

            DataSet = DataSet.OrderBy(x => x.Name).ToList();

            return(data);
        }
コード例 #2
0
        /// <summary>
        /// Changes the data source, does not call for a reset, that allows for how swapping but keeping the original data in place
        /// </summary>
        public void SetDataSource(DataSourceEnum dataSourceEnum)
        {
            SchoolDismissalSettingsBackend.SetDataSource(dataSourceEnum);
            SchoolCalendarBackend.SetDataSource(dataSourceEnum);

            ShopInventoryBackend.SetDataSource(dataSourceEnum);

            // Avatar must be reset before Student, because Student needs the default avatarID
            AvatarBackend.SetDataSource(dataSourceEnum);
            StudentBackend.SetDataSource(dataSourceEnum);
        }
コード例 #3
0
        /// <summary>
        /// Makes a new Student
        /// </summary>
        /// <param name="data"></param>
        /// <returns>Student Passed In</returns>
        public StudentModel Create(StudentModel data, DataSourceEnum dataSourceEnum = DataSourceEnum.Unknown)
        {
            StudentBackend.SetDataSource(DataSourceEnum.Mock);

            DataSet.Add(data);

            var idResult = IdentityBackend.Instance.CreateNewStudentUserIdRecordOnly(data);

            DataSet = DataSet.OrderBy(x => x.Name).ToList();

            return(data);
        }
コード例 #4
0
        /// <summary>
        /// Changes the data source, does not call for a reset, that allows for how swapping but keeping the original data in place
        /// </summary>
        public void SetDataSource(DataSourceEnum dataSourceEnum)
        {
            // Set the Global DataSourceEnum Value
            SystemGlobalsModel.SetDataSourceEnum(dataSourceEnum);

            // Avatar must be reset before Student, because Student needs the default avatar

            AvatarItemBackend.SetDataSource(SystemGlobalsModel.Instance.DataSourceValue);
            KioskSettingsBackend.SetDataSource(SystemGlobalsModel.Instance.DataSourceValue);

            SchoolDismissalSettingsBackend.SetDataSource(SystemGlobalsModel.Instance.DataSourceValue);

            StudentBackend.SetDataSource(SystemGlobalsModel.Instance.DataSourceValue);
        }
コード例 #5
0
 /// <summary>
 /// Changes the data source, does not call for a reset, that allows for how swapping but keeping the original data in place
 /// </summary>
 public void SetDataSource(DataSourceEnum dataSourceEnum)
 {
     // Avatar must be reset before Student, because Student needs the default avatarID
     AvatarBackend.SetDataSource(dataSourceEnum);
     StudentBackend.SetDataSource(dataSourceEnum);
 }
コード例 #6
0
 /// <summary>
 /// Changes the data source, does not call for a reset, that allows for how swapping but keeping the original data in place
 /// </summary>
 public void SetDataSource(DataSourceEnum dataSourceEnum)
 {
     StudentBackend.SetDataSource(dataSourceEnum);
 }