Skip to content

Commit

Permalink
show milestone approved modals disregard if there is any pending appr…
Browse files Browse the repository at this point in the history
…ovals
  • Loading branch information
tasqat committed Sep 14, 2021
1 parent 2edd2cd commit d77ff68
Showing 1 changed file with 2 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,16 +50,13 @@ class MilestonesApprovalNotification extends React.Component {
const { milestones } = this.props

console.log('milestones', milestones)

const inReviews = milestones.find(
(ms) => ms.status === PHASE_STATUS_IN_REVIEW
)

const revieweds = milestones.filter(
(ms) => ms.status === PHASE_STATUS_REVIEWED
).map( ms => {ms.currentApproval = this.findLatest(ms.approvals); return ms})

const showAllApproved =
!inReviews && revieweds.length > 0 &&
revieweds.length > 0 &&
!revieweds.find(
(rd) =>
!!(
Expand Down

0 comments on commit d77ff68

Please sign in to comment.