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

ZEVA - Add legacy column to the credit applications page #2324

Open
3 tasks
katerinkus opened this issue Oct 21, 2024 · 4 comments
Open
3 tasks

ZEVA - Add legacy column to the credit applications page #2324

katerinkus opened this issue Oct 21, 2024 · 4 comments
Assignees
Labels
Medium Medium Priority Task Any work that does not directly impact the user

Comments

@katerinkus
Copy link
Collaborator

Describe the task
Add legacy column "Total Eligible Sales" to the credit applications tab.

Purpose
Prior to October 22, 2024, credit application page displayed "Total Eligible Sales" and suppliers submitted eligible sales. After that date, the suppliers would be submitting supplied vehicles. These supplied numbers would display in the "Total Eligible ZEVs Supplied" column. To differentiate between sales and supplied numbers,

Acceptance Criteria

  • Legacy column added to the credit applications page.
  • Users should see dashes ("-") in the supplied column for applications made prior to October 22nd, 2024 and values in the sales column.
  • Credit applications made on October 22, 2024 and onward should have numbers in the supplied column and dashes in the sales column.

Additional context

  • Check out MYR page to see the exact same scenario the with supplied and sales (legacy column).
@ArawuSamuel1 ArawuSamuel1 added Task Any work that does not directly impact the user Medium Medium Priority labels Oct 30, 2024
@tim738745 tim738745 self-assigned this Oct 30, 2024
@emi-hi emi-hi self-assigned this Nov 14, 2024
@emi-hi
Copy link
Collaborator

emi-hi commented Nov 15, 2024

We had a meeting with Shauna and she wants to populate the fields as follows:

ZEVS Supplied:
vehicles with model years 2024 or greater AND sale date on or after oct 1

ZEV sales:
vehicles with model years 2024 or less AND sales date before oct 1

@tim738745
Copy link
Collaborator

tim738745 commented Nov 15, 2024

Hi @emi-hi and @shayjeff, I have a question: each credit application contains multiple sales records, and, as far as I know, no restriction exists on how sales records may be bundled together into a credit application. So, we could have an application with 2 sales records, "A" and "B", where:
"A" is a sales record with MY 2024 and sale date Oct.1
"B" is a sales record with MY 2023 and sale date Nov.29
In this case, under which column would we put the sales/supplied figure? ZEVs Supplied or ZEV Sales?

Also, what happens if we have an application where all sales records in it are of MY 2024, but they all have a sale date before Oct.1st? Under which column would we put the sales/supplied figure?

Lastly, it seems like even if we address the questions above and refine the logic, we would nevertheless have to look at the sales records associated with each credit application in order to determine which column to use. This may cause a significant performance issue; if there are 10 credit applications in the table, and 100 sales records in each, that means we would have to extract up to 10,000 sales records from the database and process them to determine which column to use.

Edit: It occurred to me that what they want is probably the possibility that both fields (columns) be populated for the same credit application; so, in my example above with "A" and "B", the "supplied" column will have a value of 1, and the "sales" column would have a value of 1? And for vehicles that don't fit the logic either column, we won't count them? If this is how it works, then I think it's fine and I'm not too concerned about performance; the query to get counts based on MY and sale date shouldn't be an issue, performance-wise.

@emi-hi
Copy link
Collaborator

emi-hi commented Nov 15, 2024

I believe all the records will fit in one or the other. If a vehicle is 2024, sold sept 1, it would go into the sales column. Anything less than 2024 MY also goes in sales. So there will be very few in supplied to start because it has to be MY 2024 or later and sold after oct 1; anything else is a sale.

In the meeting I hadn't really considered that we would have to look into the sales submission for the MY (but its so obvious now that you've pointed it out!)

@emi-hi emi-hi removed their assignment Nov 15, 2024
@shayjeff
Copy link
Collaborator

@tim738745 and @emi-hi - this work is on hold until I get further clarification.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Medium Medium Priority Task Any work that does not directly impact the user
Projects
None yet
Development

No branches or pull requests

5 participants