Use the 'subagency' on the cover page, not the 'subagency 2'
Matches more numbered sublist patterns for the application table
Small change to re-import logic for cover images
Adds a new image for HRSA
1. Subagency on the cover page
Betty opened a ticket asking for the subagency to be used on the cover page, not the subagency 2. This sounds reasonable to me, so let's ship it.
NOFO data
before
after
Agency, subagency, and subagency 2 for this NOFO
Before: Subagency 2 is used
After: Subagency 1 is used
2. Match more numbered sublist patterns for application table
Sometimes application tables have 'numbered sublists', typically a list of forms. I was using a pattern matching logic to assume when sublists existed and extra indent them. However, it didn't handle numbered ranges.
I've updated the logic to handle all these cases:
"1. "
"8-15."
"16 - 21."
"22 through 25."
before
after
Ranges of numbers are not indented
Ranges of numbers are indented
Note that there is no border under "Attachments"
3. Small change to re-import logic for cover images
As a 'helpful feature', I added some logic where if you import or reimport a NOFO whose opportunity number matches an image filename, the image will be automatically assigned to the NOFO. This is helpful in principle, as if a NOFO is re-imported, the image will show up.
However, if another image is selected, reimporting could potentially overwrite the first image, which isn't something that we want to happen. So now we will only add an image if:
Summary
This PR does 4 things:
1. Subagency on the cover page
Betty opened a ticket asking for the subagency to be used on the cover page, not the subagency 2. This sounds reasonable to me, so let's ship it.
2. Match more numbered sublist patterns for application table
Sometimes application tables have 'numbered sublists', typically a list of forms. I was using a pattern matching logic to assume when sublists existed and extra indent them. However, it didn't handle numbered ranges.
I've updated the logic to handle all these cases:
Note that there is no border under "Attachments"
3. Small change to re-import logic for cover images
As a 'helpful feature', I added some logic where if you import or reimport a NOFO whose opportunity number matches an image filename, the image will be automatically assigned to the NOFO. This is helpful in principle, as if a NOFO is re-imported, the image will show up.
However, if another image is selected, reimporting could potentially overwrite the first image, which isn't something that we want to happen. So now we will only add an image if: