17 Commits

Author SHA1 Message Date
richard-dds
30ef2a67ef Fix bug in application member deletion 2019-06-10 16:43:47 -04:00
dandds
bd4f2b3dde Delete unused Applications domain method and invitation service 2019-06-05 15:02:22 -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
dandds
df06d1b62f Use application_role_id on environment_roles.
In the future, an `application_invitation1 will not refer to a `user` until
someone accepts the invitation; they'll only reference an
`application_role`. When a user is invited to an application, the
inviter can specify the environments the invitee should have access to.
For this to be possible, an `environment_role` should reference an
`application_role`, because no `user` entity will be known at that time.

In addition to updating all the models and domain methods necessary for
this change, this commit deletes unused code and tests that were
dependent on `environment_roles` having a `user_id` foreign key.
2019-05-31 11:21:20 -04:00
George Drummond
9927b22783
Disable rather than delete application_roles 2019-05-14 15:26:51 -04:00
George Drummond
4aea264026
Avoid double lookup 2019-05-14 11:37:33 -04:00
George Drummond
27a4ef12c6
Delete an application member 2019-05-14 11:07:08 -04:00
dandds
8bd945d0d4 Applications.for_user returns user's portfolio applications.
The method has been updated to that, given a user and portfolio, it
returns the portfolio applications for which the user has an application
role.
2019-05-03 17:11: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
dandds
eaeeed0b05 Added BaseDomainClass with a get method.
The BaseDomainClass.get can accept any number of keyword arguments and
will add a filter to the query for each kwarg. This will allow the
caller to scope the query as needed with kwargs.
2019-04-16 14:18:53 -04:00
dandds
0bde431a70 extend soft delete functionality to app and env roles 2019-04-15 15:58:38 -04:00
dandds
b58aef2c6b domain methods for deleting apps and environments 2019-04-15 15:58:38 -04:00
dandds
1c0c5dd9c5 soft deletes available for applications and environments
- parent relation will not include applications or environments marked
  as deleted
- domain classes will exclude deleted objects from selections
- changed some test factories to use domain_word for resource names,
  because they were using person names and it bugged me
2019-04-15 15:58:38 -04:00
dandds
4a0dd2d432 remove unused domain methods and arguments 2019-03-22 06:31:20 -04:00
Patrick Smith
2c62f54b83 Remove request-related models 2019-02-25 14:54:14 -05:00
dandds
d3d36822df workspace -> portfolio everywhere 2019-01-14 16:00:17 -05:00
dandds
3fc323d785 project -> application everywhere 2019-01-14 16:00:17 -05:00