★ wanayoo — archive 1999 https://github.com/SimplifyNet/Simplify.Web.MultipartNouvelle recherche | Portail wanayoo
Skip to content
master
Go to file
Code
This branch is 59 commits ahead, 1 commit behind i4004:master.

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
src
 
 
 
 
 
 
 
 
 
 

README.md

Simplify.Web.Multipart

Nuget Version Nuget Download AppVeyor branch Libraries.io dependency status for latest release CodeFactor Grade Platform Dependabot Status PRs Welcome

Simplify.Web.Multipart is a package which provides multipart form view model and model binder for Simplify.Web web-framework.

Quick start

Registering binder

public void Configuration(IApplicationBuilder app)
{
    ...
    HttpModelHandler.RegisterModelBinder<HttpMultipartFormModelBinder>();
    ...
    app.UseSimplifyWeb();
}

public void ConfigureServices(IServiceCollection services)
{
    ...
    DIContainer.Current.RegisterHttpMultipartFormModelBinder();
    ...
}

Getting files from client

Multipart files will be deserialized to the controller model on first model access

public class MyController : Controller<MultipartViewModel>
{
    public override ControllerResponse Invoke()
    {
        Model.Files
    }
}
You can’t perform that action at this time.