Пример #1
0
        public List <BorrowingEntity> SelectLoanList(string token = "")
        {
            var res = new  List <BorrowingEntity>();

            try
            {
                res = _logic.SelectLoanList("0");
                return(res);
            }
            catch (Exception ex)
            {
                LoggerHelper.Error(ex.ToString());
                return(null);
            }
        }
Пример #2
0
        public ResponseP2PeyeLoan SelectLoanList(string status    = "", string time_from  = "", string time_to = "",
                                                 string page_size = "", string page_index = "", string token   = "")
        {
            var res = new ResponseP2PeyeLoan();

            try
            {
                var items = _logic.SelectLoanList(status, time_from, time_to, page_size, page_index);
                if (items != null)
                {
                    res.loans       = items;
                    res.result_code = "1";
                    res.result_msg  = "获取数据成功";
                    res.page_index  = items.CurrentPage;
                    res.page_count  = items.PageCount;
                }
                else
                {
                    res.result_code = "-1";
                    res.result_msg  = "未授权的访问!";
                    res.page_count  = 0;
                    res.page_index  = 0;
                    res.loans       = null;
                }
            }
            catch (Exception ex)
            {
                res.result_code = "-1";
                res.result_msg  = "未授权的访问!";
                res.page_count  = 0;
                res.page_index  = 0;
                res.loans       = null;

                LoggerHelper.Error(ex.ToString());
            }
            return(res);
        }