Example #1
0
        public bool DeleteTrue(iPow.Infrastructure.Data.DataSys.Sys_TourPlanDetail entity, iPow.Infrastructure.Data.DataSys.Sys_AdminUser operUser)
        {
            var res = false;

            if (entity != null)
            {
                try
                {
                    tourPlanDetailRepository.Delete(entity);
                    tourPlanDetailRepository.Uow.Commit();
                    res = true;
                }
                catch (Exception ex)
                {
                }
            }
            return(res);
        }
Example #2
0
        /// <summary>
        /// 删除该UserID 下的景点
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public bool UpdatesightById(int id)
        {
            bool count = false;
            var  res   = tourPlanDetailRepository.GetList(e => e.PlanID == id).First();

            tourPlanDetailRepository.Delete(res);
            tourPlanDetailRepository.Uow.Commit();
            count = true;
            return(count);
        }
Example #3
0
        public ActionResult DeleteMulTourDetailPlan(FormCollection del)
        {
            var selectedList = del.GetValues("selectRow");

            if (selectedList != null && selectedList.Count() > 0)
            {
                foreach (var item in selectedList)
                {
                    var intDel = 0;
                    int.TryParse(item.ToString(), out intDel);
                    if (intDel != 0)
                    {
                        var temp = this.SysSingleTourDetailPlan(intDel);
                        tourPlanDetailRepository.Delete(temp);
                    }
                }
                tourPlanDetailRepository.Uow.Commit();
            }
            return(new EmptyResult());
        }