Bug 1651241

Summary: Emails not validated on Schedules and Alerts add/edit form
Product: Red Hat CloudForms Management Engine Reporter: Parthvi Vala <pvala>
Component: UI - OPSAssignee: Richard Vsiansky <rvsiansk>
Status: CLOSED ERRATA QA Contact: Parthvi Vala <pvala>
Severity: medium Docs Contact: Red Hat CloudForms Documentation <cloudforms-docs>
Priority: medium    
Version: 5.9.6CC: bmidwood, hkataria, lavenel, mfeifer, mpovolny, obarenbo, simaishi, smallamp
Target Milestone: GA   
Target Release: 5.10.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 5.10.0.26 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-02-07 23:03:59 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: CFME Core Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Video Demo none

Description Parthvi Vala 2018-11-19 14:06:50 UTC
Created attachment 1507229 [details]
Video Demo

Description of problem:
Email pattern is not validated in Add/Edit Schedules and Alerts form.

Version-Release number of selected component (if applicable):
5.9.6.1

How reproducible:
Always

Steps to Reproduce:
1. Navigate to `Cloud Intel` > `Reports`.
2. Click on Schedules Accordion, then on `Configuration` and select `Add a new Schedule`.
3. Check `Send an Email` and fill any non-email pattern in the `Add (enter manually)` field, say `XYZ` and click on plus icon.

Same thing can be reproduced with Alert Add/Edit forms.

Actual results:
Any email pattern is added.

Expected results:
Email pattern must be validated before adding.

Additional info:
The issue exists on earlier version of 5.9 and 5.10 as well.

Comment 3 CFME Bot 2018-11-22 16:23:11 UTC
New commit detected on ManageIQ/manageiq-ui-classic/master:

https://github.com/ManageIQ/manageiq-ui-classic/commit/fca5c8d8c684f0fff48a2bfdcd34268bee971624
commit fca5c8d8c684f0fff48a2bfdcd34268bee971624
Author:     Richard Vsiansky <r.vsia>
AuthorDate: Tue Nov 20 09:54:46 2018 -0500
Commit:     Richard Vsiansky <r.vsia>
CommitDate: Tue Nov 20 09:54:46 2018 -0500

    Adds validation for email fields in schedules/add

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1651241

 app/controllers/report_controller/schedules.rb | 18 +-
 1 file changed, 13 insertions(+), 5 deletions(-)

Comment 4 CFME Bot 2018-11-22 16:23:19 UTC
New commit detected on ManageIQ/manageiq-ui-classic/master:

https://github.com/ManageIQ/manageiq-ui-classic/commit/fca5c8d8c684f0fff48a2bfdcd34268bee971624
commit fca5c8d8c684f0fff48a2bfdcd34268bee971624
Author:     Richard Vsiansky <r.vsia>
AuthorDate: Tue Nov 20 09:54:46 2018 -0500
Commit:     Richard Vsiansky <r.vsia>
CommitDate: Tue Nov 20 09:54:46 2018 -0500

    Adds validation for email fields in schedules/add

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1651241

 app/controllers/report_controller/schedules.rb | 18 +-
 1 file changed, 13 insertions(+), 5 deletions(-)

Comment 5 CFME Bot 2018-11-26 15:21:56 UTC
New commit detected on ManageIQ/manageiq-ui-classic/hammer:

https://github.com/ManageIQ/manageiq-ui-classic/commit/e7c1298baebbb792750be31783b2eb840109db1e
commit e7c1298baebbb792750be31783b2eb840109db1e
Author:     Milan Zázrivec <mzazrivec>
AuthorDate: Thu Nov 22 02:57:30 2018 -0500
Commit:     Milan Zázrivec <mzazrivec>
CommitDate: Thu Nov 22 02:57:30 2018 -0500

    Merge pull request #4947 from rvsia/schedule-email

    Adds email validation for schedule and alerts forms

    (cherry picked from commit fedb4d2b9eb51643deec471bdb0a8090017dbeeb)

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1651241

 app/controllers/miq_policy_controller/alerts.rb | 6 +
 app/controllers/report_controller/schedules.rb | 18 +-
 spec/controllers/miq_policy_controller/alerts_spec.rb | 2 +-
 3 files changed, 20 insertions(+), 6 deletions(-)

Comment 6 Parthvi Vala 2018-11-28 12:39:25 UTC
FIXED. Verified on 5.10.0.26.20181127164839_ee46c90.

Comment 7 errata-xmlrpc 2019-02-07 23:03:59 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2019:0212