Skip to content
Snippets Groups Projects

Fix Approval UI showing up for free plan

Merged Mark Chao requested to merge 9908-hide-approver-ui-in-free into master
  1. Mar 06, 2019
    • Paul Slaughter's avatar
      Cleanup has approvals available check in MR widget · 1ca1c452
      Paul Slaughter authored and Mark Chao's avatar Mark Chao committed
      - Removes `requires_approve?`. This was only being used
         in `merge_request_presenter` to hide/show the API paths.
      - Adds `approval_feature_available?`
         The API path checks have been updated to use this call.
      - Replaces `approvalsRequired` in the mr_widget_store with
         `hasApprovalsAvailable`. The previous property actually
         only checked if the `approvalsPath` was truthy or not. It
         looked like it checked the `approvalsRequired` from the
         server, but since this was camel case, this value never existed.
      1ca1c452
    • Mark Chao's avatar
      Hide rules when approval feature is unavailable · f150b0ee
      Mark Chao authored
      This means existing unapproved rules would have no effect on MR
      merging process.
      f150b0ee
    • Mark Chao's avatar
      Fix MR approval form showing in free plan · 502d4014
      Mark Chao authored
      `requires_approve?` went through several iterations,
      earliest one implies license by checking `approvals_required.nonzero?`.
      This was however set to true so caused EE specific UI to appear by
      mistake.
      502d4014
Loading