Commit Graph

79 Commits

Author SHA1 Message Date
leigh-mil
4f345b462f Add resend invite form/modal, update routes and tests as necessary. 2020-01-17 10:49:05 -05:00
leigh-mil
56c213285f Add route to update portfolio manager perms, add modal form to update in the UI 2020-01-17 10:49:05 -05:00
dandds
0731b0519c Use simple string formatting for flash messages.
This addresses an SSTI vulnerability in Flask's `render_template_string`
function, which we were using for rendering flash messages. The
implementation I'd built was too complicated, so I removed its reliance
on Jinja template rendering. Instead, all parts of the flash message
should be keys in the translations file. The `flash` wrapper in
`atst.utils.flash` is just a thin wrapper over our `translate` function.
The `translate` function relies on Python string formatting, which does
not evaluate expressions and so isn't vulnerable to SSTI.
2020-01-11 15:27:34 -05:00
leigh-mil
63a5d9274b Update route to handle error when env names are duplicated 2019-12-18 10:54:17 -05:00
leigh-mil
ffbf612290 Update route to catch error when app name uniqueness is violated and display a error message 2019-12-16 14:39:32 -05:00
leigh-mil
78ef47f649 Update TO route helper function to catch error and display flash message when a user tries to save a TO with an existing number.
Update TaskOrderForm so that it converts empty string for number into None, this was causing an issue where new TOs were being saved with an empty string for the number, which violated the unique constraint.
2019-12-13 14:53:58 -05:00
graham-dds
3b265b0eb6 Flash message for insufficient funding 2019-12-10 11:23:53 -05:00
leigh-mil
4cba564c97 Catch CSP exceptions and display a flash message with the error 2019-11-22 08:49:16 -05:00
leigh-mil
1eecf19459 Update flash message for resending an invite 2019-10-15 14:35:13 -04:00
graham-dds
8e6a4101ff Update copy in headers / flash 2019-10-14 14:46:00 -04:00
graham-dds
24be9a6a61 Update copy for new app provisioning
- change flashed message for adding members
- use the correct helper text for the app name input
- a few other updates to text in translations
2019-10-14 10:10:22 -04:00
leigh-mil
4d043363a7 Create route for resending an app invite
Replace ApplicationInvitations._update_status() with revoke() because multiple functions used _update_status() and it was causing app roles to be disabled when they shouldn't have. Now app roles are disabled within the revoke function.
Updated Invitations.resend() to accept user details so the invite info
can be changed in the new invite
2019-10-08 15:59:16 -04:00
graham-dds
4a4e20534f Flashed message after step 1 of app provisioning
- add flash for updating application
- add to route logic
2019-10-08 13:15:28 -04:00
leigh-mil
05aca75679 Fix typo and add flash message for when invite can't be revoked 2019-09-26 09:53:20 -04:00
leigh-mil
a03ff56017 Invites are revokable if they are not expired, and add success flash message 2019-09-26 09:46:24 -04:00
graham-dds
83479f60af Flash messages for saving/ submitting applications 2019-09-24 10:16:39 -04:00
dandds
7bb9400ea7 Update the flash message for when a new application member is added. 2019-09-19 09:34:00 -04:00
leigh-mil
93530e903f Create route for updating app member 2019-09-18 11:16:54 -04:00
leigh-mil
e35399d8f5 Update route function to revoke CCPO superuser status 2019-08-13 10:32:26 -04:00
leigh-mil
fa83dfe6bd When user not found, redirect to users page and show flash message 2019-08-09 11:08:23 -04:00
leigh-mil
811a498bf4 Finish route for confirming CCPO user, add function to update user's ccpo perms, and add success flash message to template 2019-08-09 10:50:34 -04:00
George Drummond
3740291662 Delete unused flash messages 2019-06-13 10:11:29 -04:00
dandds
06f4aeb74d Merge pull request #880 from dod-ccpo/to-review-modal
TO Review Submit Modal
2019-06-11 13:10:17 -04:00
George Drummond
c08f14382f Add in success flash message 2019-06-11 11:30:37 -04:00
Montana
99ab0c22bc Add Success banner on submit 2019-06-11 09:31:08 -04:00
dandds
fa50c01e48 New backend flow for application invitations.
Like portfolio invitations, now a user is not associated with an
application role until they accept the associated invitation.
- domain method for inviting user to application
- change application route for inviting a member
- ApplicationRole model knows user name from invitation
2019-06-05 15:02:22 -04:00
leigh-mil
d7d239d406 Alphabetize flash messages 2019-06-05 12:58:33 -04:00
dandds
c085db23d7 New invitation backend for portfolio invitations.
Portfolio invitations do not associate a user entity until the
invitation has been accepted. User info, including DOD ID, is held on
the invitation itself. When a user accepts and invitation, their user
entry is associated with the corresponding `portfolio_role` entry.

The same change will be applied to `application_role` and application
invitations. For now, small changes have been made to
application-related methods so that that flow works as-is.
2019-06-03 15:57:49 -04:00
richard-dds
c653cf2dbf Display a flash message when a user logs out 2019-05-28 16:55:52 -04:00
George Drummond
6487fe91ba Applications users were invited to were not showing in the portfolios
sidebar
2019-05-22 11:19:13 -04:00
dandds
0dc0397702 Update user's environment role on the team page.
- Includes adjustments to the applications.update_team route
- Adds hidden environment ID to the HTML form
2019-05-17 14:00:45 -04:00
rachel-dtr
c6790e5d7a Updating alert language 2019-05-15 13:28:46 -04:00
montana-mil
1c4725840c Merge pull request #815 from dod-ccpo/add-new-env-app-settings
Add New Environment via app settings
2019-05-15 11:30:29 -04:00
George Drummond
b8ea1349b2 Merge pull request #817 from dod-ccpo/delete-user-from-application
Delete an application member
2019-05-14 15:45:32 -04:00
Montana
caf3a47c68 Update banners
- Adds "Create a new environment" title to info banner
- Adds a new "environment added" success banner
2019-05-14 11:51:10 -04:00
George Drummond
27a4ef12c6 Delete an application member 2019-05-14 11:07:08 -04:00
leigh-mil
060c6834bf Add save button and temp member role toggle to env member form 2019-05-14 10:58:22 -04:00
Montana
74422c57aa Use common "View" for translations
-also pipe translate in injected html for a flash
2019-05-13 09:28:47 -04:00
rachel-dtr
39a0716028 Updating content across the site 2019-05-10 10:28:02 -04:00
montana-mil
fb7efc6057 Merge pull request #801 from dod-ccpo/app-team-permissions
Application Team Table Permissions
2019-05-07 16:27:23 -04:00
Montana
1759732d38 Add success banner
- The banner does not display which members were updated
2019-05-06 15:17:48 -04:00
George Drummond
037fe09163 Delete environments from an application 2019-05-06 13:51:57 -04:00
dandds
ade77e6b91 Route for adding new application member
- domain method for creating a new application member
- ApplicationInvitations domain class
- nested form for adding a new user that holds user data, application
  permission sets, and environment roles
- Invitation service can infer invitation type based on role it's given
- new invitation email templates
2019-04-30 14:41:55 -04:00
George Drummond
079672c818 Update application environments 2019-04-29 10:46:21 -04:00
dandds
a2e815afd9 move application deletion alert content into translations file 2019-04-15 16:03:32 -04:00
dandds
dac764ab82 route for deleting an application 2019-04-15 15:58:38 -04:00
rachel-dtr
6d4cd59e0b Updating PPoC language 2019-04-10 10:13:47 -04:00
George Drummond
090e13f083 Update Point of Contact 2019-04-08 13:31:00 -04:00
Montana
48d7918b66 Use translate function directly 2019-04-05 11:47:58 -04:00
rachel-dtr
5401fd4769 Updating translation file 2019-04-05 11:22:06 -04:00