theunitedeffort / theunitedeffort.org

The United Effort Organization website
https://theunitedeffort.org
3 stars 6 forks source link

Database update: calculate e.g. "2x rent" or "30% AMI" values to dollars #27

Open trevorshannon opened 2 years ago

trevorshannon commented 2 years ago

Many numerical values are stored as references to other numbers such as "minimum income is 2x rent"

We should be able to convert these values to dollars either in the Airtable (preferred) or prior to displaying values to users in the website.

clairehubel commented 2 years ago

I just discussed this with Wei. She would like to keep the description (eg "minimum income is 2 X rent", or "max income = 50% of AMI" etc) for reference. I think the ideal hybrid would be to display the calculated $ amount most prominently, with the formula used perhaps underneath in smaller font? Or even a link saying "how this was calculated"......open to ideas here.

trevorshannon commented 2 years ago

yes, I agree @clairehubel . I think a prominent dollar amount with a hover tooltip or "info" icon (etc) that can explain where the number came from is a great solution.

trevorshannon commented 2 years ago

As this issue is mainly about how the underlying database is set up, I went ahead and made a new issue (#40) to track the addition of a tooltip or other info display to show e.g. "min income is 2x rent"

trevorshannon commented 2 years ago

This page is a good example of where some auto-calculations could come in handy. This property has rent listed and has a note that min income is "2x rent" but the actual value for min income is "Call for Info". We could save folks a call with a calculation.

ueo.netlify.app/housing/affordable-housing/981

Screen Shot 2022-05-04 at 9 28 59 PM
clairehubel commented 2 years ago

I totally agree. I think Wei wanted also to preserve the '2 times the rent' formula as well though. What is a simple, clear way to do this? I'd favor prioritizing the calculated amount, and having the formula referenced in some way, either in smaller font, or parenthetically. She was fairly adamant about including this, so the challenge is to do it in a way that's not too confusing, or cluttered visually.,

clairehubel commented 2 years ago

Oh, I see you made a great suggestion for this earlier in the thread, that I forgot about! I like the idea that you suggested 2 days ago.

trevorshannon commented 2 years ago

Yes, @clairehubel I implemented the suggestion in my commentlast night and you can try it out at e.g. ueo.netlify.app/housing/affordable-housing/901

clairehubel commented 2 years ago

I love the design of this! Thanks for making it so clear and responsive. One request is to remove the (1) and (2) from the results when the user hovers over the questions mark. I don't think these add anything. I have another question, that I will start in another thread.

trevorshannon commented 2 years ago

Yep, I have another open issue about cleaning up that text. (#45)

On Thu, May 5, 2022, 8:11 AM clairehubel @.***> wrote:

I love the design of this! Thanks for making it so clear and responsive. One request is to remove the (1) and (2) from the results when the user hovers over the questions mark. I don't think these add anything. I have another question, that I will start in another thread.

— Reply to this email directly, view it on GitHub https://github.com/philhawksworth/the-united-effort-orginization/issues/27#issuecomment-1118676307, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABDQ6KDSQFBKXUCZCEJIHMLVIPQKVANCNFSM5U2PUVSA . You are receiving this because you authored the thread.Message ID: @.*** .com>

clairehubel commented 2 years ago

👍 Thank you!

trevorshannon commented 2 years ago

Min income is now calculated in the airtable directly from rent and a multiplicative factor where applicable. Change was made to the newly imported temporary table which is pending promotion to production.

trevorshannon commented 2 years ago

The remaining todo item on this issue is to automatically calculate max income from the AMI and a current AMI lookup table.

Poul Erik had some reservations about doing that because there seem to be some properties that use older AMI tables to compute max income. I suggest we check back in with him to get a read on how important it is to auto-calculate maximum income rather than type it in manually in the database.