Kendo UI Yükleme (MVC sarmalayıcı) async modunda kullanmaya çalışıyorum. Chrome'da işler iyi görünüyor, ancak IE'de böyle bir şans yok (şu andan itibaren sadece IE 9'da test edildi). Yüklemeyi başlattığında, eylem yöntemime ulaştığını ve isteğin beklediğim verileri içerdiğini görebiliyorum, ancak hiçbir şey kaydedilmiyor.Kendo UI Async Upload Internet Explorer'da çalışmıyor Upload
Kod örnekleri aşağıdadır: aslında çalıştığınızda (upload)
_EditForm.cshtml
@(Html.Kendo().Upload()
.Name(string.Format("upload{0}", "background"))
.Multiple(true)
.Events(evt => evt.Success("refreshBackgroundImages"))
.Messages(msg => msg.DropFilesHere("drag and drop images from your computer here")
.StatusUploaded("Files have been uploaded"))
.Async(a => a.AutoUpload(true)
.SaveField("files")
.Save("UploadImage", "Packages", new { siteId = Model.WebsiteId, type = "background" })))
Kontrolör ActionMethod
[HttpPost]
public ActionResult UploadImage(IEnumerable<HttpPostedFileBase> files, Guid siteId, string type)
{
var site = _websiteService.GetWebsite(siteId);
var path = Path.Combine(_fileSystem.OutletVirtualPath, site.Outlet.AssetBaseFolder);
if (type == "background")
{
path = Path.Combine(path, _backgroundImageFolder);
}
else if (type == "image")
{
path = Path.Combine(path, _foregroundImageFolder);
}
foreach (var file in files)
{
_fileSystem.SaveFile(path, file.FileName, file.InputStream, file.ContentType, true);
}
// Return empty string to signify success
return Content("");
}
Sürüm? – Andrei
@AndreiMikhalevich - Üzgünüm, sadece bunu dahil etmek için soruyu güncelledi. Bu sürüm 9. –
@AndreiMikhalevich Bu öyle görünüyor, bu yüzden neden Chrome'da çalışıyor, ancak IE neden daha karışıktır. –