示例#1
0
        public void Post(object area, bool edit)
        {
            JObject juser         = area as JObject;
            Area    recievingArea = juser.ToObject <Area>();

            if (edit == false)
            {
                recievingArea.created = DateTime.Today;
                areaController.AddArea(recievingArea);
            }
            else
            {
                areaController.EditArea(recievingArea.Id, recievingArea);
            }
        }