Horizon orchestration pop-up shows redundant error
When you try to create an orchestration Strategy and it failed, the pop-up showed the same error message in the main and details section. This change fixes this issue. In addition, has been fixed for the Apply Strategy action too. Test Plan: PASS: Create an invalid strategy and verify the pop-up error message is displayed properly for example: Error: Strategy creation failed. Details: The server could not comply with the request since its either malformed or otherwise incorrect. Invalid groud_id PASS: Apply strategy and verify the pop-up error message is displayed properly. Closes-bug: 2018625 Change-Id: I805cc051a843af07f2dba1701aef8bc791b9450a Signed-off-by: Rafael Moyano <rafael.moyano@windriver.com>
This commit is contained in:
parent
db9bb2cf03
commit
694bd0fbc6
|
@ -33,7 +33,7 @@ class ApplyCloudStrategyForm(forms.SelfHandlingForm):
|
|||
except Exception as ex:
|
||||
LOG.exception(ex)
|
||||
redirect = reverse(self.failure_url)
|
||||
msg = _('Strategy apply failed: "%s".') % str(ex)
|
||||
msg = _('Strategy apply failed.')
|
||||
exceptions.handle(request, msg,
|
||||
redirect=redirect)
|
||||
return True
|
||||
|
@ -273,8 +273,9 @@ class CreateCloudStrategyForm(forms.SelfHandlingForm):
|
|||
if not response:
|
||||
messages.error(request, "Strategy creation failed")
|
||||
except Exception as ex:
|
||||
LOG.exception(ex)
|
||||
redirect = reverse(self.failure_url)
|
||||
msg = _('Strategy creation failed: "%s".') % str(ex)
|
||||
msg = _('Strategy creation failed.')
|
||||
exceptions.handle(request, msg,
|
||||
redirect=redirect)
|
||||
return True
|
||||
|
|
Loading…
Reference in New Issue