Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Binding form file using a struct#2446

confusionhill started this conversation inGeneral
Discussion options

Hello, i got this requirement where the payload look like this

{
userID
file_type
file
}

I tried to do something like this

type UploadDocumentRequestDTO struct { UserID 'form:"uid"' File *multipart.FileHeader 'form:"file" validate:"required"' Msg string 'file:"msg" validate:"required"' }

doesn't seems to work.

Is it possible to do something like that?

Thank you

You must be logged in to vote

Replies: 1 comment

Comment options

You can trythis

You must be logged in to vote
0 replies
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Category
General
Labels
None yet
2 participants
@confusionhill@manicar2093

[8]ページ先頭

©2009-2025 Movatter.jp