Beispiel #1
0
 public int DeleteMachine(int machineAddr)
 {
     using (GardenInfoDataAccess gardenInfoDataAccess = new GardenInfoDataAccess())
     {
         return(gardenInfoDataAccess.DeleteMachine(machineAddr));
     }
 }
Beispiel #2
0
        /// <summary>
        /// 调用DataAccess层删除幼儿园信息
        /// </summary>
        /// <param name="gardenID">要删除的GardenInfo</param>
        /// <returns>返回影响的行数</returns>
        public int DeleteGardenInfo(string gardenID)
        {
            int rowsAffected = 0;

            using (GardenInfoDataAccess gardenInfoDataAccess = new GardenInfoDataAccess())
            {
                rowsAffected = gardenInfoDataAccess.DeleteGardenInfo(gardenID);
            }

            return(rowsAffected);
        }
Beispiel #3
0
        /// <summary>
        /// 调用DataAccess层更新幼儿园信息
        /// </summary>
        /// <param name="gardenInfo">要更改的GardenInfo</param>
        /// <returns>返回影响的行数</returns>
        public int UpdateGardenInfo(GardenInfo gardenInfo)
        {
            int rowsAffected = 0;

            using (GardenInfoDataAccess gardenInfoDataAccess = new GardenInfoDataAccess())
            {
                rowsAffected = gardenInfoDataAccess.UpdateGardenInfo(gardenInfo);
            }

            return(rowsAffected);
        }
Beispiel #4
0
        public DataSet GetMachineInfo()
        {
            DataSet dsMachineInfo = null;

            using (GardenInfoDataAccess gardenInfoDataAccess = new GardenInfoDataAccess())
            {
                dsMachineInfo = gardenInfoDataAccess.GetMachineInfo();
            }

            return(dsMachineInfo);
        }
Beispiel #5
0
        /// <summary>
        /// 调用DataAccess层检索幼儿园信息
        /// </summary>
        /// <returns>返回GardenInfo所有信息的DataSet</returns>
        public DataSet GetGardenInfo()
        {
            DataSet gardenInfo = null;

            using (GardenInfoDataAccess gardenInfoDataAccess = new GardenInfoDataAccess())
            {
                gardenInfo = gardenInfoDataAccess.GetGardenInfo();
            }

            return(gardenInfo);
        }