public ActionResult Poor_Edit(f_poor model) { string sql = string.Format("update f_poor t set name='{0}',xzqhcode='{1}',population={2},square={3} where t.id={4}", model.name, model.xzqhcode, model.population, model.square, model.id); int count = DbHelperMySQL.ExecuteSql(sql); return(Json(Result.AutoResult(count), JsonRequestBehavior.AllowGet)); }
public ActionResult Poor_Add(f_poor model) { string sql = string.Format("insert into f_poor(name,xzqhcode,population,square,del) values('{0}','{1}',{2},0)", model.name, model.xzqhcode, model.population, model.square); int count = DbHelperMySQL.ExecuteSql(sql); return(Json(Result.AutoResult(count), JsonRequestBehavior.AllowGet)); }