bcgov / bcgov/foi-flow

Applying Withheld in Full Page Flag in Left Pane - Reapplying Page Flag When Not Selected

Open
#4,454 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Python
Stars
8
Forks
2
Avg merge
14h 34m
Merged PRs (30d)
46

Description

**Describe the bug in current situation**
When you apply a the 'Withheld in Full' page flag in the left navigation pane to one or more pages, and then delete the full page redaction, the redaction is removed and the 'Withheld in Full' page flag is correctly removed. However, when applying the 'Withheld in Full' page flag to a new page in the left pane, it we reflag previous pages that had the 'Withheld in Full' page flag applied and removed.

Similar bug in #4398, where pages are reflagged with a page flag when not selected. But #4398 is when using the 'Redact Page(s)' feature.

**Link bug to the User Story**

**Impact of this bug**
Describe the impact, i.e. what the impact is, and number of users impacted.

Medium

**Chance of Occurring (high/medium/low/very low)**

Medium

**Pre Conditions: which Env, any pre-requesites or assumptions to execute steps?**
Test-Marshal

**Steps to Reproduce**
Steps to reproduce the behavior:
1. Apply the 'Withheld in Full' page flag to several pages in the left pane

[Private Zenhub Image](https://api.zenhub.com/attachedFiles/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBBdCtuIiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--4c2d79a67e67ae59bae22cebaa0cac2ea112a33a/image.png)

2. Delete the redactions from the pages flagged as 'Withheld in Full', which will also remove the 'Withheld in Full' page flag from the pages

[Private Zenhub Image](https://api.zenhub.com/attachedFiles/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBBdUNuIiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--59d0a07cf9a88415bae71a559db1fa05f36b31a3/image.png)

[Private Zenhub Image](https://api.zenhub.com/attachedFiles/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBBdUduIiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--6bcb6bab5d711d2575070f93831a1fea1d83a75d/image.png)

3. Select a new page or pages in the left pane, and apply the 'Withheld in Full' page flag to them

[Private Zenhub Image](https://api.zenhub.com/attachedFiles/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBBdUtuIiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--05e402a9cc82c8cec3fd8047445fa34a1f05178c/image.png)

![image](https://github.com/bcgov/foi-flow/assets/117312323/87a9ca18-c846-4b83-a641-3a8a65533478)

4. See error, where the former pages that were flagged as 'Withheld in Full' are all reflagged

![image](https://github.com/bcgov/foi-flow/assets/117312323/fbe19182-7252-4257-be5b-00f726cde6a2)

**Actual/ observed behaviour/ results**

Old page that were previous flagged as 'Withheld in Full' are being reflagged as 'Withheld in Full' when not selected.

**Expected behaviour**

GIVEN a user has applied the 'Withheld in Full' page flag to pages in the left pane
AND subsequently deleted one or more of the full page redactions
WHEN the user applies the 'Withheld in Full' page flag to a new page or range of pages
THEN only the new pages that were selected and flagged with 'Withheld in Full' will be flagged and redacted in full
AND previous pages that had the 'Withheld in Full' page flag applied, and had the full page redaction removed, will not be reflagged

**Screenshots/ Visual Reference/ Source**
If applicable, add screenshots to help explain your problem. You an use screengrab.

Contributor guide

Open the contributing guide

Research direction

Reproduce the issue in the Test-Marshal environment using the listed left-pane steps, then trace the action that applies the 'Withheld in Full' page flag. Compare its selection handling with the related behavior in #4398. Done means applying the flag to new pages does not reflag previously cleared pages, while selected pages are still flagged and fully redacted.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.