Skip to content

Incorrect folders/resources count when moving from the clipboard聽#3744

Description

@radinamatic

Observed behavior

While moving a folder with resources from the clipboard to the curator's channel topic tree, the title with summary always stays at 0 folders, 0 resources 馃憤馃徑

incorrect-count-move-from-clipboard

Expected behavior

Title should report the correct number of folders and resources, same as stated at origin (clipboard, 1 folder, 20 resources in the recording above)

User-facing consequences

Uncertainty and confusion about what is being moved from the clipboard.

Errors and logs

Nothing in the console or user-facing.

Steps to reproduce the issue

  1. Select folder/resource in the clipboard
  2. Click on the Move button
  3. Observe the title in the next window

Usage Details

  • OS: Ubuntu 20.04
  • Browser: both Firefox and Chromium

Activity

  1. radinamatic commented on Oct 18, 2022

    @radinamatic
    MemberAuthor
  2. bjester commented on Oct 18, 2022

    @bjester
    Member

    @radinamatic This seems to be an existing issue, so I'm going to downgrade this from P0 to remove this as a release blocker.

  3. added and removed
    P0 - criticalPriority: Release blocker or regression
    on Oct 18, 2022
  4. self-assigned this
    on Oct 18, 2022
  5. radinamatic commented on Oct 18, 2022

    @radinamatic
    MemberAuthor

    My bad for not remembering that, I thought I searched enough...
    Agreed it's not a regression then, would the fix be time demanding?

  6. changed the title [-]Hotfixes - Incorrect folders/resources count when moving fromthe clipboard[/-] [+]Incorrect folders/resources count when moving fromthe clipboard[/+] on Nov 22, 2022
  7. changed the title [-]Incorrect folders/resources count when moving fromthe clipboard[/-] [+]Incorrect folders/resources count when moving from the clipboard[/+] on Jun 7, 2023
  8. bjester commented on Jun 20, 2023

    @bjester
    Member

    This is still extant. Will take a look

  9. nucleogenesis commented on Jul 30, 2024

    @nucleogenesis
    Contributor

    @LianaHarris360 (cc @marcellamaki @rtibbles)
    I'm going to leave some notes behind here re: the clipboard issue.

    My branch: https://github.com/nucleogenesis/studio/tree/fix--clipbaord-checkboxes-and-numbers
    I fixed a problem w/ checkboxes here. Without this you'll not be able to select anything in the clipboard


    I've done a bunch of digging and have a solid lead on what the issue is but I don't know how to fix it correctly. I'd ask Blaine or Richard if I were coming back to this tomorrow, so it might be worth reaching out there.

    Issue: When you select items in your Clipboard and then select the "Move" button, the heading of the page is not calculating the number of resources correctly.

    Cause (I think): There are two Vuex modules contentNode and clipboard -- both of them keep "maps" (ie, an object mapping ids to the nodes). The id for nodes in the clipboard/clipboardNodesMap is not being loaded into the contentNode/contentNodesMap . The moveHeader is passing in the ids it gets from the clipboard Vuex module, which are used to look up the node's kind in the contentNode/contentNodesMap but... they're not there.


    Some notes:

    • The clipboard node source_node_id doesn't map to the id of the contentNode/contentNodeMap
    • The clipboard nodes are not found at all in my IndexedDB -- so perhaps there is something I'm missing altogether there w/ how the backend API would be called?
    • I think that the solution is to get those clipboard nodes' IDs loaded into the contentNode Vuex store. However I think that if you can just get the kinds for the Clipboard nodes you could do the count within the clipboard components/modules

    I hope this helps, thank you for taking this on!

  10. radinamatic commented on Aug 27, 2024

    @radinamatic
    MemberAuthor

    Still some hickups with how the folders/resources are calculated to display in the modal title: selected resources are always added into the count for folders. For example:

    • when I select 2 resources, the title reports 2 folders, 0 resources
    • when I select a folder with 22 resources, the title reports 23 folders, 0 resources
    Select Move
    move1 move2
  11. akolson commented on Aug 27, 2024

    @akolson
    Member
  12. LianaHarris360 commented on Aug 27, 2024

    @LianaHarris360
    Member

    I believe I know why this is happening, I'll reopen this issue and get it sorted.

  13. radinamatic commented on Sep 5, 2024

    @radinamatic
    MemberAuthor

    Final manual QA on the unstable branch confirms the fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions