Skip to content

Fix storage filling calculations#465

Open
lilbit-prun wants to merge 1 commit into
PRUNplanner:mainfrom
lilbit-prun:storage_filled_calculations
Open

Fix storage filling calculations#465
lilbit-prun wants to merge 1 commit into
PRUNplanner:mainfrom
lilbit-prun:storage_filled_calculations

Conversation

@lilbit-prun
Copy link
Copy Markdown
Contributor

Sorry if I misunderstand, but I'm looking at this plan

Screenshot 2026-05-18 at 9 52 09 PM

It has 6500/6500 storage, so I can bring 30 days of input mats which will completely pack the base, then I can wait 30 days and it will be only 1/3 full and everything is fine. The Filled row implies to me it would take 22.31 days.

I think the 3rd row should be "which is the bottleneck?" and the filled row should be "how many days can this base go between visitations?" I'm not super convinced the 3rd row is useful to show and Filled isn't the right word for it (maybe "Storage Maximum") , but I'll leave those decisions up to you and also because of localization.

@netlify
Copy link
Copy Markdown

netlify Bot commented May 19, 2026

👷 Deploy request for prunplanner-preview pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 240838b

@codacy-production
Copy link
Copy Markdown

codacy-production Bot commented May 19, 2026

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 0 duplication

Metric Results
Duplication 0

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@jplacht
Copy link
Copy Markdown
Contributor

jplacht commented May 19, 2026

Hej @lilbit-prun, lets stay with your weight measurement on this. The logic is as follows:

  • You need 213.58 t of materials per day imported that you need to produce (you don't produce it yourself, delta is negative)
  • You produce 77.75 t of materials as outputs of your recipes (CL, EPO and NA in this plan)

So your're right, there is a flaw in how it is currently done. But in the visitation frequency in general, because all you import will be used on a single day to produce the output, so the max of each import/export is relevant.

You're however only fixing the Storage overview info and not the Visitation Frequency, the same should be applied to function calculateDailyData(data: IMaterialIO[]) (L 76) in /src/features/planning/components/tools/PlanVisitationFrequency.vue.

Could you make this change there as well, then I'll happily approve and merge!

Screenshot 2026-05-19 at 11 25 41

@jplacht jplacht added the improve Improves existing functionalities label May 19, 2026
@lilbit-prun lilbit-prun force-pushed the storage_filled_calculations branch from 4e1774e to 2f5f2d7 Compare May 19, 2026 19:43
If a base produces 100t and consumes 50t with 1500t of storage, then you
can deliver 15 days worth of input mats and 15 days later the base will
be full of output mats. So to me that means that filled should be 15 days,
not 10 days.
@lilbit-prun lilbit-prun force-pushed the storage_filled_calculations branch from 2f5f2d7 to 240838b Compare May 19, 2026 22:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

improve Improves existing functionalities

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants