fix: 网元软件包新增找到已存在的删除后重新添加
This commit is contained in:
@@ -71,14 +71,14 @@ func (r *NeSoftwareImpl) Update(neSoftware model.NeSoftware) int64 {
|
||||
if rows > 0 {
|
||||
// 更新同类型的新包版本
|
||||
neVersions := NewNeVersionImpl.SelectList(model.NeVersion{
|
||||
NeType: neSoftware.NeType,
|
||||
NewPath: neSoftware.Path,
|
||||
Status: "3",
|
||||
NeType: neSoftware.NeType,
|
||||
Status: "3",
|
||||
})
|
||||
if len(neVersions) > 0 {
|
||||
for _, neVersion := range neVersions {
|
||||
neVersion.NewName = neSoftware.Name
|
||||
neVersion.NewVersion = neSoftware.Version
|
||||
neVersion.NewPath = neSoftware.Path
|
||||
neVersion.Status = "3"
|
||||
neVersion.UpdateBy = neSoftware.UpdateBy
|
||||
NewNeVersionImpl.Update(neVersion)
|
||||
|
||||
Reference in New Issue
Block a user