style: 去除Impl接口声明层聚焦服务函数

This commit is contained in:
TsMask committed 2024-10-12 19:06:12 +08:00
1 parent 94bba0c910
commit 1f0c932be8
102 files changed
+5540 -6236

No files matched your search

+3 -3
View File
@@ -189,7 +189,7 @@ func (r *TraceTask) Insert(task model.TraceTask) error {
task.NotifyUrl = fmt.Sprintf("udp:%s:%d", host, port)
// 查询网元获取IP
neInfo := neService.NewNeInfoImpl.SelectNeInfoByNeTypeAndNeID(task.NeType, task.NeId)
neInfo := neService.NewNeInfo.SelectNeInfoByNeTypeAndNeID(task.NeType, task.NeId)
if neInfo.NeId != task.NeId || neInfo.IP == "" {
return fmt.Errorf("app.common.noNEInfo")
}
@@ -254,7 +254,7 @@ func (r *TraceTask) Update(task model.TraceTask) error {
task.NotifyUrl = fmt.Sprintf("udp:%s:%d", host, port)
// 查询网元获取IP
neInfo := neService.NewNeInfoImpl.SelectNeInfoByNeTypeAndNeID(task.NeType, task.NeId)
neInfo := neService.NewNeInfo.SelectNeInfoByNeTypeAndNeID(task.NeType, task.NeId)
if neInfo.NeId != task.NeId || neInfo.IP == "" {
return fmt.Errorf("app.common.noNEInfo")
}
@@ -309,7 +309,7 @@ func (r *TraceTask) DeleteByIds(ids []string) (int64, error) {
if len(rows) == len(ids) {
// 停止任务
for _, v := range rows {
neInfo := neService.NewNeInfoImpl.SelectNeInfoByNeTypeAndNeID(v.NeType, v.NeId)
neInfo := neService.NewNeInfo.SelectNeInfoByNeTypeAndNeID(v.NeType, v.NeId)
if neInfo.NeId != v.NeId || neInfo.IP == "" {
continue
}