public ActionResult FileActionDefault(SQLFileExplorerGetParams args) { SQLFileExplorerOperations sqlobj = new SQLFileExplorerOperations("FileExplorerConnection", "Product", "NameDetail"); IEnumerable <SQLFileExplorerDirectoryContent> SelectedItems = null; if (args.SelectedItems != null) { var serializer = new JavaScriptSerializer(); SelectedItems = (IEnumerable <SQLFileExplorerDirectoryContent>)serializer.Deserialize(args.SelectedItems.ToString(), typeof(IEnumerable <SQLFileExplorerDirectoryContent>)); } switch (args.ActionType) { case "Download": sqlobj.Download(args.Path, args.Names, SelectedItems); break; case "GetImage": sqlobj.GetImage(args.Path, SelectedItems); break; } return(Json("")); }
public ActionResult GetImage(SQLFileExplorerGetParams args) { args.ActionType = "GetImage"; return(FileActionDefault(args)); }