Back to portfolio
SaaS · Management

Minas Gás

Management system for a gas distributor: orders, stock and cylinders, deliveries, cash register and finances in one web app, with an app for drivers

My role
Full Stack Developer · UX/UI Designer
Minas GásMinas Gás
01

Context

Minas Gás is a system built for the daily routine of a gas distributor. Following the company up close made it clear that the problem went far beyond recording sales: orders had to be organized, stock and cylinders controlled, deliveries tracked, the register closed and debtors known. I designed and built the application end to end, from the interface to the database.

Client
Minas Gás
Category
SaaS · Management
Roles
Full Stack Developer, UX/UI Designer
Stack
React, TypeScript, Vite, Supabase, PostgreSQL, Vitest, Vercel
02

Challenge

The operation ran on notebooks, spreadsheets and memory: orders came in by phone, cylinders left with no record, credit sales were noted separately and the register only closed at the end of the day, when it closed at all. Besides bringing everything into one place, the system had to respect who can do what. Drivers shouldn't see the finances, attendants shouldn't see cost prices, and those rules can't depend only on hiding a button on screen.

03

The system, module by module

Twelve modules with the same structure: a fixed petrol-green side menu, the day's numbers at the top of every screen, tables with color-coded status and a single orange button for the main action.

  1. 01 / 15

    Access by profile

    The login screen states the system's purpose up front (“Your operation, under control.”) and each person signs in with their own user. What they see next depends on their profile: admin, attendant or driver.

  2. 02 / 15

    Overview

    The operations hub opens with the day's numbers in cards: sales, revenue, average ticket, open orders, receivables, current cash and critical stock. Below, the best-selling products and recent activity, with each order's status.

  3. 03 / 15

    New sale

    The attendant finds the customer (or adds a new one), confirms the delivery address, adds the products and chooses the payment method: Pix, cash, card or store credit. The summary with the total stays fixed alongside until confirmation.

  4. 04 / 15

    Order confirmed

    The confirmation shows the order number, customer, address, items and total, and goes straight to picking. An idempotency key keeps a double click from creating the same order twice.

  5. 05 / 15

    Picking

    Before releasing it to the driver, the team checks the items plus each cylinder's seal and container. Only with the checklist complete does the order move on to delivery.

  6. 06 / 15

    Order management

    Every order in one list with search and filters by period and status (confirmed, picking, delivered), with customer, items, total and payment method on each row.

  7. 07 / 15

    Scheduling

    Deliveries scheduled for the day, with time, customer, neighborhood, driver and confirmation, plus today's, confirmed and pending counts.

  8. 08 / 15

    Delivery board

    Tracking the street: what's queued, on the road and completed, with each delivery's flow (order confirmed, picking, on the road, delivered) and any incidents.

  9. 09 / 15

    Customers

    The customer base with phone, neighborhood, last purchase, open balance and status, so the attendant knows right away who owes money before selling on credit.

  10. 10 / 15

    Products

    The catalog with each item's code, category, sale price and minimum stock. The cost price exists in the database, but only admins can see it.

  11. 11 / 15

    Stock and cylinders

    Each product's position with full, empty and container counts, and a red critical-stock alert when an item drops below the minimum. At a gas distributor, cylinders are assets and the numbers have to add up.

  12. 12 / 15

    Cash register

    Opening, movements and closing of the register by operator: current balance, inflows, outflows and difference, with each sale and expense recorded as it happens.

  13. 13 / 15

    Accounts receivable

    Store credit, organized: open invoices with due date and status (pending, overdue, paid) and the payment record, which goes into the register.

  14. 14 / 15

    Purchases and expenses

    Gas and water purchases, fuel, power and maintenance, with supplier, due date and status, to close the month knowing what came in and what went out.

  15. 15 / 15

    Users and permissions

    The team with profile and last access, and the permissions matrix showing what each profile can do across sales, financial data, cost prices and deliveries.

04

The driver app

Drivers use the system on their phones, with an interface of its own: the day's deliveries with the next one highlighted, the details with address, items and amount, a checklist to confirm delivery and payment, and incident reporting when something goes off plan.

Login, today's deliveries, delivery details and payment recorded
05

Architecture

The interface is a React application; the business rules live in the database, where no screen can bypass them.

Front end
React 19, TypeScript and Vite, with React Router and custom CSS
Back end
Supabase with PostgreSQL 17; business rules in database functions, split between the api and private schemas
Quality
Automated tests with Vitest and Testing Library, plus lint and build on every review
Deliverable
Version control with Git and GitHub and web app deployment on Vercel
06

Data security and integrity

The main concern was making sure permissions held at the database level, not just in the interface. These mechanisms were implemented and verified in a technical audit:

Row Level Security
RLS policies on the tables: each profile only reads and writes what it's allowed to
Profiles
Separate permissions for admin, attendant and driver
Sensitive data
Financial information, such as cost prices, restricted to those with permission
Exposed functions
Every database function checks the caller's permission before running
Idempotency
Keys that prevent duplicate orders and entries
Audit trail
History of changes made to orders
07

Testing and quality

In the latest technical review, on 09/29/2026, the entire test suite passed, along with lint and build checks. The system keeps evolving, with interface improvements, new features and security and infrastructure checks.

358

automated tests run successfully

12

modules integrated into a single application

3

access profiles with database-level rules (RLS)

08

Design system

A component library to keep the modules consistent: primary, secondary and disabled action buttons, statuses (confirmed, in progress, attention) and spacing, border and text hierarchy standards.

Components and states

Visual System

A professional look with colors tied to the industry: petrol green gives structure and trust to the menu and main areas, operational green marks what's right, and orange appears only where there's an action or alert, so the team can tell at a glance what needs attention.

Palette

Petrol Green

#123D35

Side menu, driver app header and brand areas

Operational Green

#16856B

Confirmed statuses, amounts received and positive highlights

Orange

#F0782B

Main action, active menu item and alerts

Light Gray

#F5F7F8

Screen and workspace backgrounds

Graphite

#17212B

Headings, text and tables

Typography

Inter

400 / 500 / 700

A single typeface: 28–32 px headings, 16–18 px sections and 12–14 px body

09

Takeaways

Building software goes far beyond writing code. I had to understand the distributor's processes, model the data, define business rules and permissions, handle day-to-day exceptions and build screens that make sense both for whoever answers the phone and for whoever is out on the street with the cylinder. It's the project that brings together everything I've been deepening as a developer: front-end, back-end, databases, architecture, security and testing.

Your turn

Got a digital problem to solve?