public void RemoveClassLessonQuizz(int qcId, int qcLessonIndex, bool callSaveChanges = true)
        {
            var entity = GetCurrentMemberFromQCId(qcId);

            if (entity != null)
            {
                var intArrHelper = new IntArray(entity.NewLessonQuizzCount);
                intArrHelper.ResetAtIndex(qcLessonIndex);
                entity.NewLessonQuizzCount = intArrHelper.GetStringArray();
                _uow.QuizzClassMembers.Update(entity);
            }

            if (callSaveChanges)
            {
                _uow.SaveChanges();
            }
        }
        public int RemoveClassLessonDiscussion(int qcId, int qcLessonIndex, int countToRemove, bool callSaveChanges = true)
        {
            var ret    = 0;
            var entity = GetCurrentMemberFromQCId(qcId);

            if (entity != null)
            {
                var intArrHelper = new IntArray(entity.NewLessonCommentCount);
                ret = intArrHelper.SubAtIndex(qcLessonIndex, countToRemove);
                entity.NewLessonCommentCount = intArrHelper.GetStringArray();
                _uow.QuizzClassMembers.Update(entity);
            }

            if (callSaveChanges)
            {
                _uow.SaveChanges();
            }

            return(ret);
        }
        public void SubClassLessonQuizz(int qcId, int qcLessonIndex, bool callSaveChanges = true)
        {
            List <QuizzClassMember> list = GetMembersFromQCId(qcId);

            foreach (var item in list)
            {
                if (item.IsParent)
                {
                    continue;
                }

                var intArrHelper = new IntArray(item.NewLessonQuizzCount);
                intArrHelper.DecAtIndex(qcLessonIndex);
                item.NewLessonQuizzCount = intArrHelper.GetStringArray();
                _uow.QuizzClassMembers.Update(item);
            }

            if (callSaveChanges)
            {
                _uow.SaveChanges();
            }
        }