Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Janblack07/OxygenDispatch/llms.txt

Use this file to discover all available pages before exploring further.

This guide walks you through getting a fully functional local instance of OxygenDispatch running on your machine and completing the end-to-end workflow — from registering a catalog entry and creating a batch all the way to dispatching approved cylinders to a client. The entire process takes about five minutes on a machine that already has PHP and Node installed.
Prerequisites — make sure the following are available on your machine before you begin:
  • PHP 8.2 or higher with the extensions: mbstring, pdo, openssl, tokenizer, xml, ctype, json, bcmath, fileinfo
  • Composer (latest stable)
  • Node.js 18+ and npm
  • MySQL 8+ (recommended for parity with production) or SQLite (zero-config for local dev)

Set up the project

1

Clone the repository

Clone the OxygenDispatch repository from GitHub and change into the project directory.
git clone https://github.com/Janblack07/OxygenDispatch.git
cd OxygenDispatch
2

Install dependencies

Install both PHP and JavaScript dependencies.
composer install
3

Configure the environment

Copy the example environment file and generate your application key. Then open .env and set your database connection values.
cp .env.example .env
php artisan key:generate
Edit .env and update the database block to match your local setup:
.env (MySQL example)
APP_NAME=OxygenDispatch
APP_ENV=local
APP_URL=http://localhost:8000

DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=oxygen_dispatch
DB_USERNAME=root
DB_PASSWORD=secret
For a zero-config SQLite setup, use:
.env (SQLite)
DB_CONNECTION=sqlite
# DB_HOST, DB_PORT, DB_DATABASE, DB_USERNAME, DB_PASSWORD can be left blank
4

Run migrations

Create all database tables — users, batches, tank units, technical receptions, dispatches, and more.
php artisan migrate
5

Build frontend assets

Compile Tailwind CSS and all JavaScript bundles for production use.
npm run build
6

Start the development server

The composer dev script uses concurrently to spin up four processes in a single terminal: the HTTP server, the queue worker, the Pail log viewer, and the Vite hot-reload watcher.
composer dev
This executes the following processes in parallel:
ProcessCommand
HTTP serverphp artisan serve
Queue workerphp artisan queue:listen --tries=1 --timeout=0
Log viewerphp artisan pail --timeout=0
Vite dev servernpm run dev
Open http://localhost:8000 in your browser. You will be redirected to the login page.

Your first workflow

Once the application is running and you have logged in, follow these steps to register inventory and complete your first dispatch.
1

Log in and open the dashboard

Navigate to http://localhost:8000. Log in with your credentials. The dashboard displays real-time counts of available cylinders, dispatches today, cylinders in quarantine, and more — all sourced live from the database.
2

Create catalog entries

The system requires at least one gas type and one cylinder capacity before you can register a batch.
  • Go to /catalog/gas-types and create a gas type (for example: Oxygen Medical Grade).
  • Go to /catalog/capacities and create a capacity (for example: 10 L).
You can also configure warehouse areas at /catalog/warehouse-areas and technical statuses at /catalog/technical-statuses to match your facility’s layout.
3

Create a batch

Navigate to /batches/create. Fill in the batch number, select the gas type and capacity you just created, and provide supplier details (name, supplier code, voucher type and number, voucher date, sanitary registry, manufactured and expiry dates). Save the batch.
4

Generate tank units

Open the batch you created and click Generate Tanks. Enter the number of cylinder units to create. The system will generate individual tank_unit records, each with a unique serial number derived from the batch, with their status set to available (status 1) and assigned to the default warehouse area.
5

Create a technical reception and review tanks

Navigate to /technical-receptions/create and create a reception record linked to your batch’s document number. Fill in the supplier, invoice number, remission guide, received quantity, and responsible officer fields.Once the reception is saved, open it and go to its Tank Reviews section (/technical-receptions/{id}/tank-reviews). Process each cylinder — recording the review result as approved or rejected along with any anomaly type and observation. When all units are reviewed, set the reception’s final result to aprobado.
6

Dispatch approved cylinders to a client

First, create a client at /clients if one does not already exist (the system can look up an existing client by document number using the /clients/find-by-document endpoint).Then navigate to /dispatches/create to dispatch cylinders by serial number, or /dispatches/create-by-quantity to dispatch a set quantity of available tanks. Select the client, fill in the dispatch document number, remission plate, voucher details, and notes — then submit. The cylinders’ status is updated to dispatched (status 2) and an inventory movement record is created automatically.
Want to skip the manual setup steps? The composer.json defines a setup script that chains the entire installation sequence in one command: composer install, copy .env.example to .env (only if .env does not already exist), php artisan key:generate, php artisan migrate --force, npm install, and npm run build. Just run:
composer setup
This is ideal for onboarding new team members or resetting a development environment quickly.

Build docs developers (and LLMs) love