|
|
|
@@ -399,8 +399,10 @@ func (s *AiStorage) SaveInferDeployInstance(instanceId string, instanceName stri |
|
|
|
return insModel.Id, nil |
|
|
|
} |
|
|
|
|
|
|
|
func (s *AiStorage) UpdateInferDeployInstance(instance *models.AiInferDeployInstance) error { |
|
|
|
instance.UpdateTime = time.Now().Format(time.RFC3339) |
|
|
|
func (s *AiStorage) UpdateInferDeployInstance(instance *models.AiInferDeployInstance, needUpdateTime bool) error { |
|
|
|
if needUpdateTime { |
|
|
|
instance.UpdateTime = time.Now().Format(time.RFC3339) |
|
|
|
} |
|
|
|
tx := s.DbEngin.Table("ai_infer_deploy_instance").Updates(instance) |
|
|
|
if tx.Error != nil { |
|
|
|
logx.Errorf(tx.Error.Error()) |
|
|
|
|