ss
This commit is contained in:
@@ -7,6 +7,7 @@ import (
|
||||
"net/http"
|
||||
"os"
|
||||
"path"
|
||||
"syscall"
|
||||
"time"
|
||||
|
||||
"git.rosy.net.cn/jx-callback/business/jxstore/event"
|
||||
@@ -399,11 +400,12 @@ func (c *EventController) UploadAudio() {
|
||||
fileName := utils.GetUUID() + "_" + timeStr + path.Ext(head.Filename)
|
||||
fmt.Println("aaaaaaaaaaaaaaaaaaaaaaa", fileName)
|
||||
if _, err = os.Stat(filePath); os.IsNotExist(err) {
|
||||
err = os.MkdirAll(filePath, os.ModePerm)
|
||||
if err != nil {
|
||||
return retVal, "", err
|
||||
}
|
||||
os.Chmod(filePath, os.ModePerm)
|
||||
syscall.Mkdir(filePath, 0777)
|
||||
// err = os.MkdirAll(filePath, os.ModePerm)
|
||||
// if err != nil {
|
||||
// return retVal, "", err
|
||||
// }
|
||||
// os.Chmod(filePath, os.ModePerm)
|
||||
}
|
||||
f, err := os.OpenFile(filePath, os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0666)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user