Merge branch 'develop' of gitee.com:fusenpack/fusenapi into develop

This commit is contained in:
laodaming 2023-09-21 12:06:04 +08:00
commit 1dac38e5c5
4 changed files with 15 additions and 4 deletions

View File

@ -20,6 +20,16 @@ import (
"github.com/gorilla/websocket"
"github.com/zeromicro/go-zero/core/logx"
"gopkg.in/yaml.v2"
_ "fusenapi/utils/auth"
_ "fusenapi/utils/autoconfig"
_ "fusenapi/utils/check"
_ "fusenapi/utils/collect"
_ "fusenapi/utils/encryption_decryption"
_ "fusenapi/utils/fsconfig"
_ "fusenapi/utils/fssql"
_ "github.com/zeromicro/go-zero/rest"
)
// Backend结构体

View File

@ -17,7 +17,7 @@ run_server() {
# 导航到相应的目录
cd server/$server_name
go build
go build -linkshared
[ -f .gitignore ] || echo $server_name > .gitignore
# 使用 screen 运行 go run <server_name>.go
screen -dmS $server_name -L ./$server_name
@ -40,9 +40,10 @@ done
# 在每个服务器目录下运行相应的 go 程序
for server_dir in "${server_dirs[@]}"; do
run_server $server_dir &
run_server $server_dir
done
# 定义目录和screen名称
dir_path="./proxyserver"
screen_name="proxyserver"

View File

@ -133,7 +133,7 @@ func (l *InfoLogic) Info(req *types.UserInfoRequest, userinfo *auth.UserInfo) (r
for _, mquery := range mquerys {
sqlstr := fmt.Sprintf("select id, module, %s as querydata from %s where %s order by ctime dec limit 1", mquery.EncodeQuery("metadata"), mquery.TableName, mquery.Cond)
sqlstr := fmt.Sprintf("select id, module, %s as querydata from %s where %s order by ctime DESC limit 1", mquery.EncodeQuery("metadata"), mquery.TableName, mquery.Cond)
raw := l.svcCtx.MysqlConn.Raw(sqlstr)

View File

@ -55,7 +55,7 @@ func TestMain(t *testing.T) {
for _, mquery := range mquerys {
sqlstr := fmt.Sprintf("select id, module, %s as querydata from %s where %s order by ctime asc limit 1", mquery.EncodeQuery("metadata"), mquery.TableName, mquery.Cond)
sqlstr := fmt.Sprintf("select id, module, %s as querydata from %s where %s order by ctime dec limit 1", mquery.EncodeQuery("metadata"), mquery.TableName, mquery.Cond)
raw := conn.Raw(sqlstr)