/// <summary>
        /// 数据检索
        /// </summary>
        /// <param name="input"></param>
        /// <returns></returns>
        protected override IQueryable<Tfmonitorabnormal> CreateQueryable(GetTfmonitorabnormalPageInput input)
        {
            IQueryable<Tfmonitorabnormal> queryable = base.CreateQueryable(input);

            queryable = queryable.WhereIf(input.Id !=null, t => t.Id == input.Id).AsQueryable();

            queryable = queryable.WhereIf(input.Exception !=null, t => t.Exception == input.Exception).AsQueryable();

            queryable = queryable.WhereIf(input.AbnormalContext !=null, t => t.AbnormalContext == input.AbnormalContext).AsQueryable();

            queryable = queryable.WhereIf(input.AddressName !=null, t => t.AddressName == input.AddressName).AsQueryable();

            queryable = queryable.WhereIf(input.StartTime.HasValue, t => t.StartTime == input.StartTime.Value).AsQueryable();

            queryable = queryable.WhereIf(input.EndTime.HasValue, t => t.EndTime == input.EndTime.Value).AsQueryable();

            queryable = queryable.WhereIf(input.MaxAlarmValue !=null, t => t.MaxAlarmValue == input.MaxAlarmValue).AsQueryable();

            queryable = queryable.WhereIf(input.MaxAlarmTime.HasValue, t => t.MaxAlarmTime == input.MaxAlarmTime.Value).AsQueryable();

            queryable = queryable.WhereIf(input.Reason !=null, t => t.Reason == input.Reason).AsQueryable();

            queryable = queryable.WhereIf(input.Remarks !=null, t => t.Remarks == input.Remarks).AsQueryable();

            return queryable;
        }
Exemplo n.º 2
0
        /// <summary>
        /// 数据检索
        /// </summary>
        /// <param name="input"></param>
        /// <returns></returns>
        protected override IQueryable <Tfmonitorabnormal> CreateQueryable(GetTfmonitorabnormalPageInput input)
        {
            IQueryable <Tfmonitorabnormal> queryable = base.CreateQueryable(input);

            queryable = queryable.WhereIf(input.Id != null, t => t.Id == input.Id).AsQueryable();


            queryable = queryable.WhereIf(input.Exception != null, t => t.Exception == input.Exception).AsQueryable();


            queryable = queryable.WhereIf(input.AbnormalContext != null, t => t.AbnormalContext == input.AbnormalContext).AsQueryable();


            queryable = queryable.WhereIf(input.AddressName != null, t => t.AddressName == input.AddressName).AsQueryable();

            queryable = queryable.WhereIf(input.StartTime.HasValue, t => t.StartTime == input.StartTime.Value).AsQueryable();

            queryable = queryable.WhereIf(input.EndTime.HasValue, t => t.EndTime == input.EndTime.Value).AsQueryable();


            queryable = queryable.WhereIf(input.MaxAlarmValue != null, t => t.MaxAlarmValue == input.MaxAlarmValue).AsQueryable();

            queryable = queryable.WhereIf(input.MaxAlarmTime.HasValue, t => t.MaxAlarmTime == input.MaxAlarmTime.Value).AsQueryable();


            queryable = queryable.WhereIf(input.Reason != null, t => t.Reason == input.Reason).AsQueryable();


            queryable = queryable.WhereIf(input.Remarks != null, t => t.Remarks == input.Remarks).AsQueryable();

            return(queryable);
        }