Ejemplo n.º 1
0
 public void Import(ImportBinding Model, string UserID)
 {
     using (var _c = db)
     {
         Can(Model.SiteID, UserID, _c);
         byte[] binary = Convert.FromBase64String(Model.FileRead.FileContent.Split(',')[1]);
         var _Items = JsonConvert.DeserializeObject<ICollection<ContentBindingList>>(Encoding.UTF8.GetString(binary));
         Import(_Items, Model.SiteID, Model.ContentPropertyID, UserID, _c);
     }
 }
Ejemplo n.º 2
0
 public IHttpActionResult PostImport(ImportBinding Model)
 {
     _ContentService.Import(Model, User.Identity.GetUserId());
     return Ok();
 }