解析表单

This commit is contained in:
白茶清欢 2022-07-03 00:57:41 +08:00
parent 0e14eb64d1
commit c80236b3a2

View File

@ -23,12 +23,12 @@ import (
type form struct { type form struct {
} }
// ParseRequestForm 解析请求表单 // Parse 解析请求表单
// //
// Author : go_developer@163.com<白茶清欢> // Author : go_developer@163.com<白茶清欢>
// //
// Date : 00:34 2022/7/3 // Date : 00:34 2022/7/3
func (f *form) ParseRequestForm(ctx *gin.Context, receiver interface{}) error { func (f *form) Parse(ctx *gin.Context, receiver interface{}) error {
method := strings.ToUpper(ctx.Request.Method) method := strings.ToUpper(ctx.Request.Method)
if method == http.MethodGet || if method == http.MethodGet ||
method == http.MethodPatch || method == http.MethodPatch ||