weixin_39600823
weixin_39600823
2020-12-31 03:19

We need to separate the archive action between All Content and Under Review

The code attempts to check the item id for the same original item in both contexts, but for archiving it should check the nomination ID.

该提问来源于开源项目:PressForward/pressforward

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 复制链接分享
  • 邀请回答

15条回答

  • weixin_39600823 weixin_39600823 4月前

    Related to #427

    点赞 评论 复制链接分享
  • weixin_39600823 weixin_39600823 4月前

    Dupes #541

    点赞 评论 复制链接分享
  • weixin_39754831 weixin_39754831 4月前

    There isn't an archive button in All content right? Are you referring to hide in all content and archive in nominated?

    点赞 评论 复制链接分享
  • weixin_39754831 weixin_39754831 4月前

    So I think this is half working (assuming I am understanding this issue correctly). The hide functionality in All Content is still causing items to archive in Nominated but only for Administrators. For contributors it works as expected. Hiding an item does not archive it in Nominated. I think this is just a user permissions bug -- hiding an item in all content shouldn't ever archive the item in Nominated.

    It does work the other way around though. Archiving an item in Nominated does not hide the item in All Content.

    点赞 评论 复制链接分享
  • weixin_39754831 weixin_39754831 4月前

    This appears to be working in some contexts however I am encountering issues when I try to unarchive an item. Here is a breakdown: - archiving an item in Nominated removes (hides? archives? not sure which) the same item from All Content *However, according to commit ddca4c5 it should work in the reverse too. When an item in unarchived not only does it not reappear in all content, it completely disappears and never returns to nominated. It also is removed from archived in Nominated.

    点赞 评论 复制链接分享
  • weixin_39600823 weixin_39600823 4月前

    Are you trying to unarchive from the context of Under Review?

    点赞 评论 复制链接分享
  • weixin_39754831 weixin_39754831 4月前

    Yes -- that was where I was unarchiving from.

    点赞 评论 复制链接分享
  • weixin_39779739 weixin_39779739 4月前

    I've run some tests and my results are: 1) Some pieces cease to appear in nominated when archived, but do not appear under nominated. 2) Unarchiving items removes them from the archive, but does not restore them in nominated. 3) Items archived by one user no longer appear for other users, either in nominated or in the archive. 4) Items archived in nominated are hidden in all content. 5) Items hidden in all content remain visible in nominated.

    点赞 评论 复制链接分享
  • weixin_39600823 weixin_39600823 4月前

    I cannot duplicate these results at all, can you check the network tab for the ajax response on each button press?

    I'm confused what's 'the archive' referring to in 2 and 3?

    4), 5) are anticipated behaviors.

    点赞 评论 复制链接分享
  • weixin_39754831 weixin_39754831 4月前

    I think for 2 & 3 is referring to the "show archived" filter view

    点赞 评论 复制链接分享
  • weixin_39600823 weixin_39600823 4月前

    Wait, but that filters in, not out. It shows either Archived and Unarchived, or Unarchived. - So unarchiving an object disappears it from the page?

    点赞 评论 复制链接分享
  • weixin_39754831 weixin_39754831 4月前

    Sorry I used the wrong terminology -- I meant the show "only archived" filter. Unarching an object makes it disappear from that view however it never reappears in nominated

    点赞 评论 复制链接分享
  • weixin_39754831 weixin_39754831 4月前

    So to clarify the bug I'm seeing is not that unarchiving an item makes it disappear from the "only archived" filter but that when an item is unarchived it never reappears when you go back to the default nominated view.

    点赞 评论 复制链接分享
  • weixin_39600823 weixin_39600823 4月前

    Should now be resolved.

    点赞 评论 复制链接分享
  • weixin_39754831 weixin_39754831 4月前

    This is working now

    点赞 评论 复制链接分享

相关推荐