fix: UDM签约批量添加msisdn和start_msisdn识别导致数据一致

This commit is contained in:
TsMask
2024-12-05 18:33:47 +08:00
parent 408eeb8ce0
commit a96f265e84

View File

@@ -192,6 +192,8 @@ func (s *UDMSubController) Adds(c *gin.Context) {
if body.StaticIp != "" {
cmd += fmt.Sprintf(",static_ip=%s", body.StaticIp)
}
omemsisdn := fmt.Sprintf(",msisdn=%s,", body.MSISDN)
cmd = strings.Replace(cmd, omemsisdn, ",", 1)
data, err := telnet.ConvertToStr(telnetClient, cmd)
if err != nil {
c.JSON(200, result.ErrMsg(err.Error()))