DH-IT-Portal-Development / ethics

Ethical Committee web application in Django
http://fetc.hum.uu.nl
MIT License
2 stars 1 forks source link

Non-standard proposals using the wrong PDF template #572

Closed tymees closed 1 year ago

tymees commented 1 year ago

At least pre-approved PDF's still use the old templates on the latest develop, using horrible tables. I didn't test, but it's highly likely the same thing happens with pre-assesments (as the logic that controls the used template is the same).

I think during the manual merge of the new PDF code the template-select logic was overlooked. The canonical-PDF change moved the logic to outside the main PDF logic, to the proposal model. As that would not have caused conflicts, it's probable that nobody noticed it.

EdoStorm96 commented 1 year ago

I can confirm that pre-assessment proposals do indeed use the old template. I'm also thinking now, that pre-assessments proposals have really been accounted for in the new PDF workflow, so that should also happen probably. Woops ... Where is the PDF logic you are talking about here located?

tymees commented 1 year ago

In the Proposal model, there's a method called pdf_template_name

EdoStorm96 commented 1 year ago

Ahh ok. I guess it should be a fairly easy fix then? I will have a look.

EdoStorm96 commented 1 year ago

I propose that we also get rid of these unused templates, like proposal_pdf_empty.html, proposal_pdf_pre_assessment.html and proposal_pdf_pre_approved.html. As they are no longer neccessary/ cause confusion. I guess I should have done that already in the new pdf PR ... but better late than never

tymees commented 1 year ago

Yeah, it should be an easy fix. Those templates probably just need to go. Didn't do it myself because 1) I wasn't entirely sure what was the cause and 2) I was busy testing something else