예제 #1
0
        public static int Insert(City city)
        {
            var db = DataBaseHelper.Open();
            city.Id = LastIdSvc.GetNextTableId("Cities");
            db.Cities.Insert(city);

            return city.Id;
        }
예제 #2
0
        public ActionResult Create(City model)
        {
            CitySvc.Insert(model);

            return RedirectToAction("Index");
        }