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

Show PDF inputs fields appearing on work form #70

Open
3 tasks
ndroark opened this issue Jun 9, 2024 · 8 comments
Open
3 tasks

Show PDF inputs fields appearing on work form #70

ndroark opened this issue Jun 9, 2024 · 8 comments
Assignees

Comments

@ndroark
Copy link
Collaborator

ndroark commented Jun 9, 2024

Some fields (show pdf viewer, show pdf download button) are showing on work creation pages. It is unclear whether text entered in these fields affects the work display page, but the information is saved in these fields, and the presence of the fields will be confusing to users.

Image

Testing Instructions

  • EDIT a new work
  • In the work's form, click additional fields. Search for "Show PDF" and verify there are no matches.
  • There should be no input fields for show viewer or show pdf download button from this page.
  • Click on the Files tab.
  • if PDF.js is enabled (from the features settings of the admin dashboard), two checkboxes should appear to show viewer, and to show pdf download button.
  • If the PDF.js is NOT enabled, these checkboxes will not be visible
@ShanaLMoore ShanaLMoore self-assigned this Jun 19, 2024
ShanaLMoore added a commit to samvera/hyku that referenced this issue Jun 20, 2024
Show PDF Viewer and Show PDF Download Button should not render input fields on the work's form.

Issue:
- scientist-softserv/palni_palci_knapsack#70
@ShanaLMoore ShanaLMoore changed the title Extra fields appearing in work upload screen Show PDF inputs fields appearing on work form Jun 20, 2024
@ShanaLMoore
Copy link
Contributor

ShanaLMoore commented Jun 20, 2024

TODO: We need to figure out a way for get the yaml's form > display: false to actually hide the terms from the form. Right now it's getting ignored. If we completed remove the form block, then the backend won't have the term on the form and that causes other problems.

ref

@jillpe
Copy link

jillpe commented Aug 12, 2024

SoftServ QA: ❌

PDF.js not enabled

Screen.Recording.2024-08-12.at.8.32.47.AM.mov

pdf.js enabled ❌
The checkboxes are not apearing under the files tab

Screen.Recording.2024-08-12.at.8.34.30.AM.mov

@jillpe jillpe added the needs rework issue needs additional work label Aug 12, 2024
@kirkkwang
Copy link
Contributor

Hey @jillpe, can you try this with a PDF file? It looks like you tried it with a JPEG which will not show in PDF.js because it's not a PDF.

@jillpe
Copy link

jillpe commented Aug 14, 2024

SoftServ QA Observations

UV Enabled

Screen.Recording.2024-08-14.at.12.52.34.PM.mov

PDF.js enabled

The checkboxes are not appearing

Screen.Recording.2024-08-14.at.12.54.06.PM.mov

@ShanaLMoore ShanaLMoore removed their assignment Aug 14, 2024
@ShanaLMoore ShanaLMoore self-assigned this Aug 27, 2024
@ShanaLMoore
Copy link
Contributor

ShanaLMoore commented Aug 27, 2024

Looking into this. locally every work type is displaying the checkboxes when pdf.js is enabled.

Image

The same work type on Staging is not displaying it. 🤔 Same sha: c663a10

Image

@ShanaLMoore
Copy link
Contributor

ShanaLMoore commented Aug 29, 2024

Troubleshooting Staging

show_for_pdf?(show_pdf_viewer) => *** NoMethodError Exception: undefined method `first' for true:TrueClass
nil

Image

@ShanaLMoore
Copy link
Contributor

ShanaLMoore commented Aug 29, 2024

VALKYRIE_TRANSITION wasn't set 🙃

When it is:

Image

ShanaLMoore added a commit that referenced this issue Aug 29, 2024
PSD.js wasn't loading for pals knapsack staging because an env wasn't set. 🙃

Issue:
- #70
@ShanaLMoore ShanaLMoore removed the needs rework issue needs additional work label Sep 3, 2024
@laritakr
Copy link
Contributor

laritakr commented Sep 4, 2024

QA RESULTS: PASS ✅

Fields do not show on Descriptions tab

Screenshot 2024-09-04 at 1 53 12 PM

Checkboxes show when PDF.js is enabled

Screenshot 2024-09-04 at 1 53 25 PM

Checkboxes do not show when PDF.js is disabled

Screenshot 2024-09-04 at 1 54 15 PM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Client QA
Development

No branches or pull requests

5 participants