Example #1
0
 /// <summary>
 /// 添加学校
 /// </summary>
 /// <returns></returns>
 private bool AddSchoolInfo()
 {
     if (!CheckData())
     {//数据检验不通过
         return(false);
     }
     else
     {
         try
         {
             string handleResult = SchoolMainWindow.AddSchoolInfo(SchoolModelInfo);
             if (string.IsNullOrEmpty(handleResult))
             {
                 return(true);
             }
             else
             {
                 ErrorMessage = handleResult;
                 return(false);
             }
         }
         catch (AMS.Model.CustomerException ex)
         {
             ErrorMessage = ex.Message;
             return(false);
         }
         catch (Exception ex)
         {
             ErrorMessage = ex.Message;
             return(false);
         }
     }
 }