Count awaiting users on checkout free groups
This changes how we calculate the billable members for free plans on the `free_user_cap` when they purchase a plan. Example: A free group where `free_user_cap` is enabled has 7 users. 2 users get their memberships set to `awaiting` when `free_user_cap` applies. When they want to purchase a plan it's likely that they want to purchase seats for these 2 users. We therefore need to count them in the checkout process as `billable` members. We also have to change the way how we calculate `seats_in_use` as it was using `billable_members_count`. It's now using directly `billed_user_ids` and we therefore distinguish between billable (potentially billable) and billed users (actually billed users).
显示
- ee/app/models/ee/group.rb 5 个添加, 1 个删除ee/app/models/ee/group.rb
- ee/app/models/gitlab_subscription.rb 1 个添加, 1 个删除ee/app/models/gitlab_subscription.rb
- ee/spec/models/ee/group_spec.rb 22 个添加, 0 个删除ee/spec/models/ee/group_spec.rb
- ee/spec/models/gitlab_subscription_spec.rb 16 个添加, 0 个删除ee/spec/models/gitlab_subscription_spec.rb
加载中
想要评论请 注册 或 登录