/// <summary>
        /// 获取营收信息
        /// </summary>
        /// <param name="driverModel"></param>
        /// <returns></returns>
        public PaymentMonthly GetRevenueMsg(Driver driverModel)
        {
            PaymentMonthly paymentModel = new PaymentMonthly();

            paymentModel = _sl.GetRevenueMsg(driverModel);
            return(paymentModel);
        }
Ejemplo n.º 2
0
 /// <summary>
 /// 获取营收信息
 /// </summary>
 /// <param name="driverModel"></par am>
 /// <returns></returns>
 public PaymentMonthly GetRevenueMsg(Driver driverModel)
 {
     using (SqlSugarClient _dbDriverSql = SugarDao.SugarDao_DriverRevenueSql.GetInstance())
     {
         PaymentMonthly paymentModel = new PaymentMonthly();
         try
         {
             int      year          = DateTime.Now.Year;
             int      month         = DateTime.Now.Month;
             DateTime accountPeriod = DateTime.Parse(year + "-" + month + "-" + "01");
             paymentModel = _dbDriverSql.Queryable <PaymentMonthly>().Where(i => i.DriverId == driverModel.Id && i.AccountPeriod == accountPeriod).SingleOrDefault();
         }
         catch (Exception ex)
         {
             Common.LogHelper.LogHelper.WriteLog(ex.Message);
         }
         finally
         {
         }
         return(paymentModel);
     }
 }