fix: UDMVolte用户特殊VoIP数据

This commit is contained in:
TsMask
2025-04-25 17:24:34 +08:00
parent 8d73d0ef2f
commit b29a36e7b5
4 changed files with 48 additions and 35 deletions

View File

@@ -44,7 +44,7 @@ type UDMVolteIMSController struct {
// @Param neId path string true "NE ID" default(001)
// @Success 200 {object} object "Response Results"
// @Security TokenAuth
// @Summary UDM Authentication User Data Refresh
// @Summary UDM VolteIMS User Data Refresh
// @Description UDM Authenticated User Data List Refresh Synchronization Latest
// @Router /neData/udm/volte-ims/resetData/{neId} [put]
func (s *UDMVolteIMSController) ResetData(c *gin.Context) {
@@ -72,8 +72,8 @@ func (s *UDMVolteIMSController) ResetData(c *gin.Context) {
// @Param pageSize query number true "pageSize" default(10)
// @Success 200 {object} object "Response Results"
// @Security TokenAuth
// @Summary UDM Authentication User List
// @Description UDM Authentication User List
// @Summary UDM VolteIMS User List
// @Description UDM VolteIMS User List
// @Router /neData/udm/volte-ims/list [get]
func (s *UDMVolteIMSController) List(c *gin.Context) {
query := reqctx.QueryMap(c)
@@ -93,18 +93,22 @@ func (s *UDMVolteIMSController) List(c *gin.Context) {
// @Param msisdn query string true "MSISDN"
// @Success 200 {object} object "Response Results"
// @Security TokenAuth
// @Summary UDM Authentication User Information
// @Description UDM Authentication User Information
// @Summary UDM VolteIMS User Information
// @Description UDM VolteIMS User Information
// @Router /neData/udm/volte-ims/{neId}/{value} [get]
func (s *UDMVolteIMSController) Info(c *gin.Context) {
language := reqctx.AcceptLanguage(c)
neId := c.Param("neId")
imsi := c.Param("imsi")
msisdn := c.Query("msisdn")
if neId == "" || imsi == "" || msisdn == "" {
if neId == "" || imsi == "" {
c.JSON(400, resp.CodeMsg(400, i18n.TKey(language, "app.common.err400")))
return
}
if msisdn == "" {
c.JSON(400, resp.CodeMsg(400, "msisdn is required"))
return
}
// 查询网元获取IP
neInfo := s.neInfoService.FindByNeTypeAndNeID("UDM", neId)
@@ -138,6 +142,7 @@ func (s *UDMVolteIMSController) Info(c *gin.Context) {
if u.ID != "" {
s.udmVolteIMSService.InsertByIMSI(imsi, neId)
c.JSON(200, resp.OkData(u))
return
}
c.JSON(200, resp.ErrMsg("No Volte IMS Data"))
}
@@ -153,8 +158,8 @@ func (s *UDMVolteIMSController) Info(c *gin.Context) {
// @Param data body object true "Request Param"
// @Success 200 {object} object "Response Results"
// @Security TokenAuth
// @Summary UDM Authentication User Added
// @Description UDM Authentication User Added
// @Summary UDM VolteIMS User Added
// @Description UDM VolteIMS User Added If VoIP tag=0, then MSISDN and IMSI need to be the same.
// @Router /neData/udm/volte-ims/{neId} [post]
func (s *UDMVolteIMSController) Add(c *gin.Context) {
language := reqctx.AcceptLanguage(c)
@@ -219,8 +224,8 @@ func (s *UDMVolteIMSController) Add(c *gin.Context) {
// @Param data body object true "Request Param"
// @Success 200 {object} object "Response Results"
// @Security TokenAuth
// @Summary UDM Authentication User Batch Add
// @Description UDM Authentication User Batch Add
// @Summary UDM VolteIMS User Batch Add
// @Description UDM VolteIMS User Batch Add
// @Router /neData/udm/volte-ims/{neId}/{value} [post]
func (s *UDMVolteIMSController) Adds(c *gin.Context) {
language := reqctx.AcceptLanguage(c)
@@ -361,8 +366,8 @@ func (s *UDMVolteIMSController) Remove(c *gin.Context) {
// @Param num path number true "Number of releases, value includes start imsi"
// @Success 200 {object} object "Response Results"
// @Security TokenAuth
// @Summary UDM Authentication User Batch Deletion
// @Description UDM Authentication User Batch Deletion
// @Summary UDM VolteIMS User Batch Deletion
// @Description UDM VolteIMS User Batch Deletion
// @Router /neData/udm/volte-ims/{neId}/{imsi}/{num} [delete]
func (s *UDMVolteIMSController) Removes(c *gin.Context) {
language := reqctx.AcceptLanguage(c)