Пример #1
0
        public JsonResult SaveContacter(SampleRequestParam param)
        {
            Common.Data.JsonData json      = new Common.Data.JsonData();
            ContactData          contacter = new ContactData()
            {
                ContactName   = param.Name,
                ContactTypeId = string.IsNullOrEmpty(param.Code)?-1: int.Parse(param.Code),
                Value         = param.Value,
                Desc          = param.Desc
            };
            IContactDataService contactService = IocMvcFactoryHelper.GetInterface <IContactDataService>();

            json = contactService.Add(contacter);
            return(Json(json));
        }
 private void Save(Window window)
 {
     _dataService.Add(NewContact);
     window.Close();
 }