Exemplo n.º 1
0
        /// <summary>
        /// 异步获取提现
        /// </summary>
        public async Task <OutCashDto> GetOutCashByIdAsync(Guid id)
        {
            var entity = await OutCashRepository.FindAsync(id);

            var result = entity.ToDto();

            return(result);
        }
Exemplo n.º 2
0
        /// <summary>
        /// 修改提现
        /// </summary>
        public async Task UpdateAsync(OutCashUpdateRequest request)
        {
            var entity = await OutCashRepository.FindAsync(request.OutCashId);

            request.MapTo(entity);
            await OutCashRepository.UpdateAsync(entity);

            await UnitOfWork.CommitAsync();
        }
Exemplo n.º 3
0
        public async Task <PagerList <OutCashDto> > PagerQueryOutCashAsync(OutCashQuery parameter)
        {
            if (parameter == null)
            {
                return(new PagerList <OutCashDto>());
            }

            var query = await CreateQuery(parameter);

            var queryable = OutCashRepository.Find().Include(x => x.Agent).Where(query);

            queryable = Filter(queryable, parameter);
            return((queryable.ToPagerList(query.GetPager())).Convert(ToDto));
        }