Exemple #1
0
 public void DeleteFormSubMenu(string ticket, int menuId, ref string message)
 {
     try
     {
         message = "";
         if (!IsTicketValid(ticket))
         {
             throw new Exception("票证验证失败!");
         }
         YnFormSubMenuService.GetInstance().Delete(menuId);
     }
     catch (Exception ex)
     {
         message = ex.Message;
     }
 }
Exemple #2
0
 public string GetFormSubMenu(string ticket, int subMenuId, ref string message)
 {
     try
     {
         message = "";
         if (!IsTicketValid(ticket))
         {
             throw new Exception("票证验证失败!");
         }
         YnFormSubMenu ynFormSubMenu = YnFormSubMenuService.GetInstance().Get(subMenuId);
         return(YnBaseClass2.Helper.ObjectHelper.Serialize(ynFormSubMenu));
     }
     catch (Exception ex)
     {
         message = ex.Message;
     }
     return(null);
 }
Exemple #3
0
        public bool UpdateFormSubMenu(string ticket, string _ynFormSubMenu, ref string message)
        {
            try
            {
                message = "";
                if (!IsTicketValid(ticket))
                {
                    throw new Exception("票证验证失败!");
                }

                YnFormSubMenu ynFormSubMenu = (YnFormSubMenu)YnBaseClass2.Helper.ObjectHelper.Deserialize(typeof(YnFormSubMenu), _ynFormSubMenu);
                //ynUser.lastLoginDate = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
                YnFormSubMenuService.GetInstance().Update(ynFormSubMenu);
                return(true);
            }
            catch (Exception ex)
            {
                message = ex.Message;
            }
            return(false);
        }