fix: UDM用户数据响应信息

This commit is contained in:
TsMask
2023-11-28 09:37:46 +08:00
parent 08b4174b83
commit 05d94572f4
3 changed files with 16 additions and 18 deletions

View File

@@ -77,7 +77,7 @@ func (s *UDMSubController) Info(c *gin.Context) {
// 查询网元获取IP
neInfo := s.neInfoService.SelectNeInfoByNeTypeAndNeID("UDM", neId)
if neInfo.NeId != neId || neInfo.IP == "" {
c.JSON(200, result.OkData(i18n.TKey(language, "app.common.noNEInfo")))
c.JSON(200, result.ErrMsg(i18n.TKey(language, "app.common.noNEInfo")))
return
}
@@ -158,7 +158,7 @@ func (s *UDMSubController) Add(c *gin.Context) {
// 查询网元获取IP
neInfo := s.neInfoService.SelectNeInfoByNeTypeAndNeID("UDM", neId)
if neInfo.NeId != neId || neInfo.IP == "" {
c.JSON(200, result.OkData(i18n.TKey(language, "app.common.noNEInfo")))
c.JSON(200, result.ErrMsg(i18n.TKey(language, "app.common.noNEInfo")))
return
}
@@ -206,7 +206,7 @@ func (s *UDMSubController) Adds(c *gin.Context) {
// 查询网元获取IP
neInfo := s.neInfoService.SelectNeInfoByNeTypeAndNeID("UDM", neId)
if neInfo.NeId != neId || neInfo.IP == "" {
c.JSON(200, result.OkData(i18n.TKey(language, "app.common.noNEInfo")))
c.JSON(200, result.ErrMsg(i18n.TKey(language, "app.common.noNEInfo")))
return
}
@@ -253,7 +253,7 @@ func (s *UDMSubController) Edit(c *gin.Context) {
// 查询网元获取IP
neInfo := s.neInfoService.SelectNeInfoByNeTypeAndNeID("UDM", neId)
if neInfo.NeId != neId || neInfo.IP == "" {
c.JSON(200, result.OkData(i18n.TKey(language, "app.common.noNEInfo")))
c.JSON(200, result.ErrMsg(i18n.TKey(language, "app.common.noNEInfo")))
return
}
@@ -344,7 +344,7 @@ func (s *UDMSubController) Remove(c *gin.Context) {
// 查询网元获取IP
neInfo := s.neInfoService.SelectNeInfoByNeTypeAndNeID("UDM", neId)
if neInfo.NeId != neId || neInfo.IP == "" {
c.JSON(200, result.OkData(i18n.TKey(language, "app.common.noNEInfo")))
c.JSON(200, result.ErrMsg(i18n.TKey(language, "app.common.noNEInfo")))
return
}
@@ -381,7 +381,7 @@ func (s *UDMSubController) Removes(c *gin.Context) {
// 查询网元获取IP
neInfo := s.neInfoService.SelectNeInfoByNeTypeAndNeID("UDM", neId)
if neInfo.NeId != neId || neInfo.IP == "" {
c.JSON(200, result.OkData(i18n.TKey(language, "app.common.noNEInfo")))
c.JSON(200, result.ErrMsg(i18n.TKey(language, "app.common.noNEInfo")))
return
}
@@ -492,7 +492,7 @@ func (s *UDMSubController) Import(c *gin.Context) {
// 查询网元获取IP
neInfo := s.neInfoService.SelectNeInfoByNeTypeAndNeID("UDM", neId)
if neInfo.NeId != neId || neInfo.IP == "" {
c.JSON(200, result.OkData(i18n.TKey(language, "app.common.noNEInfo")))
c.JSON(200, result.ErrMsg(i18n.TKey(language, "app.common.noNEInfo")))
return
}