<?php

return [
    'name' => 'MedBloodBank',

    /*
    | Module version — written into the core `system` table as the
    | `medbloodbank_version` property by the InstallController (LOWERCASE key,
    | matching ModuleUtil::isModuleInstalled which reads strtolower(name).'_version').
    */
    'module_version' => '1.0.0',

    /*
    |--------------------------------------------------------------------------
    | Shelf life (days) per blood product, from collected_at.
    |--------------------------------------------------------------------------
    | Applied by BloodBankService::expiryFor(). A host can tune these without
    | code edits. whole_blood / prbc → 35d, ffp / cryo → 365d, platelets → 5d.
    */
    'shelf_life_days' => [
        'whole_blood' => 35,
        'prbc'        => 35,
        'ffp'         => 365,
        'platelets'   => 5,
        'cryo'        => 365,
    ],

    /*
    |--------------------------------------------------------------------------
    | Donor eligibility
    |--------------------------------------------------------------------------
    | Minimum days between whole-blood donations. A donor whose last donation was
    | more recent than this is blocked at donation entry (unless deferred, which
    | blocks separately).
    */
    'min_days_between_donations' => 90,

    /*
    |--------------------------------------------------------------------------
    | Stock alert thresholds
    |--------------------------------------------------------------------------
    | Per blood-group minimum count of AVAILABLE bags. When available stock for a
    | group drops to/below its threshold the dashboard flags it and (fail-soft)
    | a MedNotify `bloodbank.stock_low` event is fired. `default` applies to any
    | group not listed. Expiry ladder (days) drives the "expiring soon" panel.
    */
    'min_stock' => [
        'default' => 2,
        'O-'      => 4,
        'O+'      => 4,
    ],

    'expiry_ladder_days' => [7, 15, 30],
];
