This commit is contained in:
邹宗楠
2024-01-08 09:23:28 +08:00
parent c8b9eb7eff
commit be829b7399
3 changed files with 573 additions and 0 deletions

View File

@@ -14,6 +14,7 @@ import (
"git.rosy.net.cn/jx-callback/globals"
"github.com/astaxie/beego/client/orm"
"github.com/astaxie/beego/server/web"
"math/rand"
"net/http"
"net/url"
"reflect"
@@ -383,6 +384,14 @@ func (c *ApiController) DoPrint(dataMap map[string]interface{}) (data, errCode s
return msgID, errCode, err
}
func RandStringBytes(n int) string {
b := make([]byte, n)
for i := range b {
b[i] = letterBytes[rand.Intn(len(letterBytes))]
}
return string(b)
}
//获取某打印消息
func (c *ApiController) GetPrintMsg(dataMap map[string]interface{}) (data map[string]interface{}, errCode string, err error) {
var (