예제 #1
0
        /// <summary>
        /// 删除CAR
        /// </summary>
        /// <param name="dal"></param>
        static void DeleteCar(InventoryDAL dal)
        {
            //获取要删除的carID
            Console.WriteLine("请输入要删除的CarID");
            int id = int.Parse(Console.ReadLine());

            //以防违反,引用完整性
            try
            {
                dal.DelteCar(id);
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex.Message);
            }
        }