-
-
Notifications
You must be signed in to change notification settings - Fork 515
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
Add delivery address to distribution "receipt" #4138
Comments
It is. I would add it under the "Issued to:" section. There's room there, and the flow works. |
@kannans5 I'm assuming that question means you want to work on this one, so I'm assigning you (so no one else takes it). |
yeah sure, I will work on it. One question
|
Yup, that looks about right. |
opened a PR, please review when you get a chance. |
Reopening this because in the pre-release testing on staging, a delivery distribution did not have an address on print out. |
This issue is marked as stale due to no activity within 30 days. If no further activity is detected within 7 days, it will be unassigned. |
Automatically unassigned after 7 days of inactivity. |
This would be my first issue. I want to try this one, but I'm very, very new. I've been programming for a long time. I've just never worked on a GitHub issue before. I read the README, and I think I understand how to get started as far as the branch and the pull request. What else would I need to do to try this? I think: I would clone the code down to my environment, then host it myself? Then try to fix the issue on my own version, apply testing, get a code review, then do a pull request? How can I pull up these reports though? Also, the README mentions using linux for development. Do you really need to use linux to work on this project? Or is that just a joke? Anyways, any help, or clue to the right direction would help. Should I take this to the slack channel? How do I get there? |
Thanks for your interest! Here's the overall approach.
You do not need to work on Linux! Plenty of folks have it working on Mac or Windows. If you have any further questions, you can get to the Slack channel here: https://join.slack.com/t/rubyforgood/shared_invite/zt-21pyz2ab8-H6JgQfGGI0Ab6MfNOZRIQA |
Thank you! I feel like I can accomplish this task. The previous user showed a picture of a document containing delivery information. How do I get this data for testing? Does it come with the repo as example data? |
@ShepherdXAutomation yes, when you set up your database you'll get a bunch of seed data for free. :) You can see the document by:
|
@ShepherdXAutomation Fair warning - it might just be that there is some weird case that I saw on staging to yank it back. I've also seen it work there |
Thank you all so much for the guidance. I’ll see how it goes. Even if I don’t solve it, getting the app setup and the seed data in place, will be good thing. |
Definitely! |
I'm happy to take this one, I think it's just a typo. Also, I can try to write tests using the pdf-inspector gem |
It's yours. I think it would be cool to test the pdf if that gem is solid -- @dorner - do you have knowledge/ an opinion on it? |
The gem was written to test the prawn gem which is what the human-essentials app uses to generate pdfs |
Might be overkill for this PR. The approach I tend to use when trying to test generated documents is to freeze time or any other randomized element that might be used, generate the document, save it to the test directory, and update the test to compare the generated file against the one in the repo. |
Automatically unassigned after 7 days of inactivity. |
…ethod * Address output prints delivery address if filled in, otherwise partner address * Only does this for delivery/shipped method
…ethod * Address output prints delivery address if filled in, otherwise partner address * Only does this for delivery/shipped method
This issue is marked as stale due to no activity within 30 days. If no further activity is detected within 7 days, it will be unassigned. |
Automatically unassigned after 7 days of inactivity. |
* REFACTOR group examples, remove rubocop disable lines, * group examples together with variables * rubocop -A passes on this file without needing to disable ArrayAlignment * RED add rspec to test address output in distribution PDFs * Compare generated against expected PDFs * Add helper test to regenerate expected PDFs * Add helper module * GREEN Fix #4138 address output changes based on delivery method * Address output prints delivery address if filled in, otherwise partner address * Only does this for delivery/shipped method * BUGFIX pdf now writes when test fails * RED add rspec for when partner has no addresses * REFACTOR out profile name and email * GREEN don't print address if no address or delivery address * Add comments clarifying gitignore and comparison pdf helper rspec * Update bundler version * REFACTOR replace helper test with environment variable * Use environment variable for regenerating comparison pdfs * update schema date and bundler version * RED remove env variable code, stub out console helper method * GREEN add Rails console method for generating comparison pdfs, update comparison PDFs * Replace instance vars with structs and let * FIX destroy request so db is clean, use destroy! instead so exceptions fire * Replace FactoryBot with calling ActiveModel.create, move methods to lib/ * Fix formatting when address is incomplete, add rspecs, create and delete item units correctly when generating test files * FIX replace with space if partner primary contact name/email/phone is blank * Add rspec * Other comparison pdfs change because previously blank phone # skipped line, now blank phone # adds a blank line * Move instance_method call inside function * FIX spacing between issued to and delivery address * RED Make methods module instead of instance * Move helper compare_pdf method into Rspec group * Failing tests are due to Items received year to date being inaccurate in new year * GREEN fix test and comparison pdf generation errors * travel_to time when creating distribution so Items received YTD is always the same * use public_send * regenerate comparison PDFs, contents are identical, only binaries differ (possibly because of prawn-rails update to 1.6.0?) * write expected_file_path to filename when outputting non matching PDF * Fix linting, use block for travel_to * Switch to using transactions with rollback to clean up * Remove accidental duped tests on merge, move merged test into example group
Summary
Add the address for the partner/program on the distribution printout, In addition change the prompt on program address to program / delivery address
Why?
For delivered items, having the address of the partner on this sheet will be a great help for the drop off volunteers
Details
-- this will be the program/delivery address if it is filled in, otherwise it will be the partner's address
Criteria for completion
The text was updated successfully, but these errors were encountered: