/// <summary>
        /// 更新数据
        /// </summary>
        /// <param name="entity"></param>
        public bool UpdateResult(OpenResultEntity newItem, string lotteryType)
        {
            try
            {
                //"sp_UpdateOpenResult"

                var lotteryId = LotteryIssuesData.GetAllLotterys().Where(item => item.LotteryCode == lotteryType).FirstOrDefault().Id;

                return(UpdateResult(newItem, lotteryId));
            }
            catch (Exception ex)
            {
                LogManager.Error(string.Format("保存开奖结果异常,期号{0}  类型{1}", newItem.expect, lotteryType), ex);
            }
            return(false);
        }
 /// <summary>
 /// 更新数据
 /// </summary>
 /// <param name="entity"></param>
 public bool UpdateResult(OpenResultEntity newItem, int lotteryid)
 {
     try
     {
         //var dataItem = this.mLotteryIssueService.Where(item => item.IssueCode == newItem.expect && item.LotteryId == lotteryid).FirstOrDefault();
         //if (null == dataItem)
         //    return false;
         //dataItem.Result = newItem.opencode;
         //dataItem.LotteryTime = newItem.opentime;
         //this.mLotteryIssueService.Save();
         return(this.mLotteryIssueService.UpdateOpenResult(newItem.expect, newItem.opencode, newItem.opentime, lotteryid));
     }
     catch (Exception ex)
     {
         LogManager.Error(string.Format("保存开奖结果异常,期号{0}  类型{1}", newItem.expect, lotteryid), ex);
     }
     return(false);
 }