feat(oversigt): Start/Stop alle flows + klik på flow hopper til redigering; palleskure viser paller af pladser (v1.20.0.0)
- ADRunsController.startAllRuns/stopAllRuns/hasActiveRuns (kørende flows røres ikke ved Start alle) - Oversigt: knapsæt Start alle / Stop alle / Nyt run, samlet status, klikbare rækker (hop via update) - Palleskur-statistik: kapacitet = (egne + ledige pladser) x indhold; 24/4000 paller 1 % i stedet for 600 % - Manualer da/en opdateret
This commit is contained in:
@@ -11,11 +11,18 @@ function ADStorageStats.itemStats(item, farmTotal, rate, quote)
|
||||
local capacity = item.capacity or 0
|
||||
local consumption = rate ~= nil and rate.consumption or 0
|
||||
local production = rate ~= nil and rate.production or 0
|
||||
-- palleskure: fyldning i paller af pladser (kapaciteten er et antal pladser, ikke liter)
|
||||
local percent = capacity > 0 and math.floor(100 * level / capacity + 0.5) or nil
|
||||
if item.count ~= nil and (item.slots or 0) > 0 then
|
||||
percent = math.floor(100 * item.count / item.slots + 0.5)
|
||||
end
|
||||
return {
|
||||
fillType = item.fillType,
|
||||
level = level,
|
||||
capacity = capacity,
|
||||
percent = capacity > 0 and math.floor(100 * level / capacity + 0.5) or nil,
|
||||
count = item.count,
|
||||
slots = item.slots,
|
||||
percent = percent,
|
||||
valueNow = quote ~= nil and quote.price ~= nil and math.floor(level * quote.price + 0.5) or nil,
|
||||
valueTop = quote ~= nil and quote.top ~= nil and math.floor(level * quote.top + 0.5) or nil,
|
||||
farmTotal = farmTotal or level,
|
||||
|
||||
Reference in New Issue
Block a user