作者 yangfu

限制两百M

@@ -21,7 +21,7 @@ type BuckObject struct { @@ -21,7 +21,7 @@ type BuckObject struct {
21 FileName string `json:"fileName"` 21 FileName string `json:"fileName"`
22 } 22 }
23 23
24 -//创建视频上传凭证 24 +// 创建视频上传凭证
25 func CreateOssUpload(header *protocol.RequestHeader, MultipartForm *multipart.Form) (rsp interface{}, err error) { 25 func CreateOssUpload(header *protocol.RequestHeader, MultipartForm *multipart.Form) (rsp interface{}, err error) {
26 var objects []aliyun.Object 26 var objects []aliyun.Object
27 var listPath []BuckObject 27 var listPath []BuckObject
@@ -34,7 +34,7 @@ func CreateOssUpload(header *protocol.RequestHeader, MultipartForm *multipart.Fo @@ -34,7 +34,7 @@ func CreateOssUpload(header *protocol.RequestHeader, MultipartForm *multipart.Fo
34 for k, _ := range MultipartForm.File { 34 for k, _ := range MultipartForm.File {
35 v := MultipartForm.File[k] 35 v := MultipartForm.File[k]
36 for i := range v { 36 for i := range v {
37 - if v[i].Size > 1024*1024*50 { 37 + if v[i].Size > 1024*1024*200 {
38 continue 38 continue
39 } 39 }
40 f, _ := v[i].Open() 40 f, _ := v[i].Open()
@@ -67,7 +67,7 @@ func CreateOssUpload(header *protocol.RequestHeader, MultipartForm *multipart.Fo @@ -67,7 +67,7 @@ func CreateOssUpload(header *protocol.RequestHeader, MultipartForm *multipart.Fo
67 return 67 return
68 } 68 }
69 69
70 -//创建视频上传凭证 70 +// 创建视频上传凭证
71 func CreateStsAuth(header *protocol.RequestHeader, files []string) (rsp interface{}, err error) { 71 func CreateStsAuth(header *protocol.RequestHeader, files []string) (rsp interface{}, err error) {
72 access, e := aliyun.DefaultSts() 72 access, e := aliyun.DefaultSts()
73 if e != nil { 73 if e != nil {