数据有更改时发送通知

This commit is contained in:
GoEdgeLab
2021-08-08 15:47:48 +08:00
parent 07aa0990f8
commit e979414973
40 changed files with 548 additions and 185 deletions

View File

@@ -3,7 +3,6 @@ package services
import (
"context"
"github.com/TeaOSLab/EdgeAPI/internal/db/models"
"github.com/TeaOSLab/EdgeAPI/internal/db/models/nameservers"
"github.com/TeaOSLab/EdgeAPI/internal/db/models/stats"
rpcutils "github.com/TeaOSLab/EdgeAPI/internal/rpc/utils"
"github.com/TeaOSLab/EdgeCommon/pkg/rpc/pb"
@@ -34,7 +33,7 @@ func (this *ServerDailyStatService) UploadServerDailyStats(ctx context.Context,
var clusterId int64
switch role {
case rpcutils.UserTypeDNS:
clusterId, err = nameservers.SharedNSNodeDAO.FindNodeClusterId(tx, nodeId)
clusterId, err = models.SharedNSNodeDAO.FindNodeClusterId(tx, nodeId)
if err != nil {
return nil, err
}