Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update file restriction fields and tabular information to the file preview #234

Conversation

ChengShi-1
Copy link
Contributor

@ChengShi-1 ChengShi-1 commented Jan 3, 2025

What this PR does / why we need it:

In collection page, some missing information is needed for every card item, including the lock icon, tags(categories), and tabular data info, so we need update in FilePreview model.

New fields include:

 restricted: boolean
 canDownloadFile: boolean
 categories?: string[]
 tabularTags?: string[]
 variables?: number
 observations?: number

In datasetPreview, new field added
image_url: string

Which issue(s) this PR closes:

Related Dataverse PRs:

Special notes for your reviewer:

Suggestions on how to test this:

Run all testcases and visually inspect

Is there a release notes update needed for this change?:

Additional documentation:

@ChengShi-1 ChengShi-1 self-assigned this Jan 3, 2025
@ChengShi-1 ChengShi-1 added FY25 Sprint 14 FY25 Sprint 14 (2025-01-02 - 2025-01-15) SPA: Collection Page SPA.Q4.2 Collection Page: Extended item cards information Size: 3 A percentage of a sprint. 2.1 hours. Original size: 3 GREI Re-arch GREI re-architecture-related labels Jan 3, 2025
@ChengShi-1 ChengShi-1 removed their assignment Jan 3, 2025
@ChengShi-1 ChengShi-1 marked this pull request as ready for review January 3, 2025 19:06
@ChengShi-1 ChengShi-1 marked this pull request as draft January 3, 2025 19:09
@ChengShi-1 ChengShi-1 marked this pull request as ready for review January 3, 2025 20:37
@ekraffmiller ekraffmiller self-assigned this Jan 6, 2025
@jggautier jggautier changed the title Update file restriction fileds and tabular information to the file preview Update file restriction fields and tabular information to the file preview Jan 6, 2025
Copy link
Contributor

@ekraffmiller ekraffmiller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! I just had some suggestions for the CollectionRespository tests

@ChengShi-1 ChengShi-1 added Size: 10 A percentage of a sprint. 7 hours. and removed Size: 3 A percentage of a sprint. 2.1 hours. labels Jan 8, 2025
@ChengShi-1 ChengShi-1 removed their assignment Jan 8, 2025
Copy link
Contributor

@ekraffmiller ekraffmiller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good, approved!

@ofahimIQSS
Copy link
Contributor

Visually inspected code, tests are passing. Merging PR

@ofahimIQSS ofahimIQSS merged commit d9a70a2 into develop Jan 10, 2025
5 checks passed
@ofahimIQSS ofahimIQSS deleted the 221-add-file-accessrestricted-and-permission-candownloadfile-check-to-filepreview branch January 10, 2025 18:17
@ofahimIQSS ofahimIQSS removed their assignment Jan 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FY25 Sprint 14 FY25 Sprint 14 (2025-01-02 - 2025-01-15) GREI Re-arch GREI re-architecture-related Original size: 3 Size: 10 A percentage of a sprint. 7 hours. SPA: Collection Page SPA.Q4.2 Collection Page: Extended item cards information
Projects
None yet
Development

Successfully merging this pull request may close these issues.

add file access(restricted) and permission canDownloadFile check to FilePreview
3 participants