-
Notifications
You must be signed in to change notification settings - Fork 22
Open
Description
First of all thanks for the effort, great library!
I've been working on a project which implemented MvcFileUploader, goal is to integrate the projects functionality into another, larger project that incorporates MVC Areas. The module wasn't working as expected and closer inspection led me to believe MVC Areas are not supported. I've so far only made a quick fix by updating GetUrlPostModel() in MvcFileUploadModelBuilder.cs to include an empty area parameter, in order for MVC routing to this module to work when called from within an area, as such:
private dynamic GetUrlPostModel()
{
return new
{
FileTypes = _fileTypes,
MaxFileSizeInBytes = _maxFileSizeInBytes,
MaxNumberOfFiles=_maxNoOfFiles,
DisableImagePreview=_disableImagePreview,
UploadUrl = _uploadUrl,
UIStyle = _uiStyle,
ReturnUrl = _returnUrl ?? "#",
RenderSharedScript = _includeScriptAndTemplate,
ShowPopUpClose = "link".Equals(_renderType) && _returnUrl != null,
Area = ""
};
}
A better solution would ofcourse be to incorporate area support, e.g. by extending the IMvcFileUploadModelBuilder, are there any plans for that by any chance?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels