Uat_Study
he 2023-06-02 10:49:37 +08:00
parent 59ff0f2ad0
commit 8b490dd4f9
2 changed files with 3 additions and 2 deletions

View File

@ -100,7 +100,8 @@ namespace IRaCIS.Core.Application.Contracts
.WhereIf(!string.IsNullOrWhiteSpace(queryQCQuestionConfigure.Type), t => t.Type.Contains(queryQCQuestionConfigure.Type))
.WhereIf(queryQCQuestionConfigure.LanguageType!=null, t =>t.LanguageType== queryQCQuestionConfigure.LanguageType)
.WhereIf(queryQCQuestionConfigure.IsDefeaultViewParent==true,t=>t.ParentId==null)
.OrderBy(t=>t.ShowOrder)
.OrderByDescending(x=>x.LanguageType)
.ThenBy(t=>t.ShowOrder)
.ProjectTo<QCQuestionConfigureView>(_mapper.ConfigurationProvider);
return await QCQuestionQueryable.ToPagedListAsync(queryQCQuestionConfigure.PageIndex, queryQCQuestionConfigure.PageSize, queryQCQuestionConfigure.SortField.IsNullOrEmpty()?nameof(queryQCQuestionConfigure.QuestionName): queryQCQuestionConfigure.SortField, queryQCQuestionConfigure.Asc);

View File

@ -48,7 +48,7 @@ namespace IRaCIS.Core.Application.Contracts
.ProjectTo<TrialQCQuestionConfigureView>(_mapper.ConfigurationProvider);
var list = await trialQCQuestionQueryable.OrderBy(t => t.ShowOrder).ToListAsync();
var list = await trialQCQuestionQueryable.OrderByDescending(x=>x.LanguageType).ThenBy(t => t.ShowOrder).ToListAsync();
var isHaveQCQuestion = _repository.Where<TrialQCQuestion>(t => t.TrialId == queryTrialQCQuestionConfigure.TrialId).Any();