fix: 参数查询查询状态获取sn版本号
This commit is contained in:
@@ -71,9 +71,13 @@ func (s *ConfigImpl) ConfigUploadOSS(neType string) error {
|
||||
//
|
||||
// 请参考NRM数据模型规范中类型为“R”的参数。
|
||||
func (s *ConfigImpl) ConfigParamQuery(neInfo neModel.NeInfo, operPara []string) map[string]any {
|
||||
fmt.Println(neInfo)
|
||||
fmt.Println(operPara)
|
||||
resultMap := map[string]any{}
|
||||
|
||||
neState, err := neService.NeState(neInfo)
|
||||
if err != nil {
|
||||
return resultMap
|
||||
}
|
||||
|
||||
for _, key := range operPara {
|
||||
// 网络设备的全网唯一标识 RW
|
||||
if key == "Ruid" {
|
||||
@@ -93,11 +97,11 @@ func (s *ConfigImpl) ConfigParamQuery(neInfo neModel.NeInfo, operPara []string)
|
||||
}
|
||||
// 设备序列号
|
||||
if key == "SerialNumber" {
|
||||
resultMap["SerialNumber"] = "-"
|
||||
resultMap["SerialNumber"] = neState["sn"]
|
||||
}
|
||||
// 硬件版本
|
||||
if key == "HardwareVersion" {
|
||||
resultMap["HardwareVersion"] = "-"
|
||||
resultMap["HardwareVersion"] = neState["version"]
|
||||
}
|
||||
// 运行时长
|
||||
if key == "RunTime" {
|
||||
@@ -131,7 +135,7 @@ func (s *ConfigImpl) ConfigParamQuery(neInfo neModel.NeInfo, operPara []string)
|
||||
}
|
||||
// 系统当前版本
|
||||
if key == "CurrentSoftwareVersion" {
|
||||
resultMap["CurrentSoftwareVersion"] = "-"
|
||||
resultMap["CurrentSoftwareVersion"] = neState["version"]
|
||||
}
|
||||
// 系统备份版本
|
||||
if key == "BackupSoftwareVersion" {
|
||||
@@ -158,11 +162,11 @@ func (s *ConfigImpl) ConfigParamQuery(neInfo neModel.NeInfo, operPara []string)
|
||||
}
|
||||
// 最大注册用户数
|
||||
if key == "MaxUser" {
|
||||
resultMap["MaxUser"] = 0
|
||||
resultMap["MaxUser"] = neState["capability"]
|
||||
}
|
||||
// 相对容量
|
||||
if key == "RelativeCapacity" {
|
||||
resultMap["RelativeCapacity"] = 0
|
||||
resultMap["RelativeCapacity"] = neState["capability"]
|
||||
}
|
||||
// 最大支持基站数
|
||||
if key == "MaxGnbNum" {
|
||||
|
||||
Reference in New Issue
Block a user