Skip to main content

Overview

The Equipment module manages all physical assets including vehicles, sanitary equipment, water treatment plants, and storage tanks. Each item tracks its technical specifications, availability status, and certification requirements.

Resource Items

Equipment Types

Mantis supports a wide range of equipment types:

Sanitary Equipment

  • LVMNOS: Lavamanos (Handwashing stations)
  • BTSNHM: Batería sanitaria hombre (Men’s bathroom)
  • BTSNMJ: Batería sanitaria mujer (Women’s bathroom)
  • EST4UR: Estación cuádruple urinario (4-urinal station)
  • CMPRBN: Camper baño (Bathroom camper)

Treatment Plants

  • PTRTAP: Planta de tratamiento de agua potable (Drinking water)
  • PTRTAR: Planta de tratamiento de agua residual (Wastewater)

Storage Tanks

  • TNQAAC: Tanques de almacenamiento agua cruda (Raw water)
  • TNQAAR: Tanques de almacenamiento agua residual (Wastewater)

Services

  • SERVIC: Generic services (no physical equipment)

ResourceItem Model

The ResourceItem model provides flexible field management based on equipment type:
class ResourceItem(BaseModel):
    id = AutoField(primary_key=True)
    name = CharField(max_length=255)
    code = CharField(max_length=50, unique=True)
    type_equipment = CharField(
        max_length=255,
        choices=TYPE_EQUIPMENT  # LVMNOS, BTSNHM, etc.
    )
    brand = CharField(max_length=255)
    model = CharField(max_length=255)
    serial_number = CharField(max_length=255)
    date_purchase = DateField()
    
    # Dimensions
    height = PositiveSmallIntegerField()  # cm
    width = PositiveSmallIntegerField()   # cm
    depth = PositiveSmallIntegerField()   # cm
    weight = PositiveSmallIntegerField()  # kg
    capacity_gallons = DecimalField(max_digits=10, decimal_places=2)
    
    # Status tracking
    stst_status_equipment = CharField(
        choices=STATUS_EQUIPMENT,
        default='FUNCIONANDO'
    )
    stst_status_disponibility = CharField(
        choices=DISPONIBILITY_STATUS,
        default='DISPONIBLE'
    )
    stst_current_location = CharField(max_length=255)
    stst_current_project_id = SmallIntegerField()
    stst_commitment_date = DateField()
    stst_release_date = DateField()

Status Management

Equipment Status (Technical Condition)

FUNCIONANDO

Equipment is operational and ready for use

DAÑADO

Equipment is damaged and cannot operate

INCOMPLETO

Equipment is missing parts or accessories

EN REPARACION

Equipment is undergoing repair

Availability Status

DISPONIBLE

Available for rental or assignment to projects

RENTADO

Currently rented and assigned to a project
When stst_status_equipment = 'EN REPARACION', the stst_repair_reason field should document the reason for repair.

Equipment-Specific Features

Sanitary Equipment Fields

For bathroom and handwashing equipment, track component availability:
# Boolean fields for component tracking
have_foot_pumps = BooleanField(default=False)
have_paper_dispenser = BooleanField(default=False)
have_soap_dispenser = BooleanField(default=False)
have_napkin_dispenser = BooleanField(default=False)
have_paper_towels = BooleanField(default=False)
have_urinals = BooleanField(default=False)  # Men's bathrooms only
have_seat = BooleanField(default=False)
have_toilet_pump = BooleanField(default=False)
have_sink_pump = BooleanField(default=False)
have_toilet_lid = BooleanField(default=False)
have_bathroom_bases = BooleanField(default=False)
have_ventilation_pipe = BooleanField(default=False)

Treatment Plant Components

For water treatment plants (PTRTAP and PTRTAR):
engine_brand = CharField(max_length=255)
engine_model = CharField(max_length=255)
engine_fases = CharField(choices=[('1', '1 FASE'), ('2', '2 FASES'), ('3', '3 FASES')])
blower_brand = CharField(max_length=255)
blower_model = CharField(max_length=255)
have_engine = BooleanField(default=False)
have_blower_brand = BooleanField(default=False)
belt_brand = CharField(max_length=255)
belt_model = CharField(max_length=255)
belt_type = CharField(choices=[('A', 'A'), ('B', 'B')])
blower_pulley_brand = CharField(max_length=255)
blower_pulley_model = CharField(max_length=255)
motor_pulley_brand = CharField(max_length=255)
motor_pulley_model = CharField(max_length=255)
have_belt_brand = BooleanField(default=False)
have_blower_pulley = BooleanField(default=False)
have_motor_pulley = BooleanField(default=False)
electrical_panel_brand = CharField(max_length=255)
electrical_panel_model = CharField(max_length=255)
engine_guard_brand = CharField(max_length=255)
engine_guard_model = CharField(max_length=255)
relay_engine = CharField(max_length=255)
relay_blower = CharField(max_length=255)
have_electrical_panel = BooleanField(default=False)
have_motor_guard = BooleanField(default=False)
have_relay_engine = BooleanField(default=False)
have_relay_blower = BooleanField(default=False)
pump_filter = CharField(max_length=255)
pump_pressure = CharField(max_length=255)
pump_dosing = CharField(max_length=255)
sand_carbon_filter = CharField(max_length=255)
hidroneumatic_tank = CharField(max_length=255)
uv_filter = CharField(max_length=255)
have_pump_filter = BooleanField(default=False)
have_pump_pressure = BooleanField(default=False)
have_pump_dosing = BooleanField(default=False)
have_sand_carbon_filter = BooleanField(default=False)
have_hidroneumatic_tank = BooleanField(default=False)
have_uv_filter = BooleanField(default=False)

Vehicle Management

Vehicle Model

Track company vehicles with certification and documentation:
class Vehicle(BaseModel):
    id = AutoField(primary_key=True)
    brand = CharField(max_length=255, default='SIN MARCA')
    model = CharField(max_length=255)
    type_vehicle = CharField(
        max_length=255,
        choices=[
            ('CAMION', 'CAMION'),
            ('VACUUM', 'VACUUM'),
            ('CAMIONETA', 'CAMIONETA'),
            ('PLATAFORMA', 'PLATAFORMA'),
            ('AUTO', 'AUTO')
        ]
    )
    year = IntegerField()
    no_plate = CharField(max_length=10, unique=True)
    status_vehicle = CharField(
        choices=[
            ('DISPONIBLE', 'DISPONIBLE'),
            ('EN MANTENIMIENTO', 'EN MANTENIMIENTO'),
            ('STANBY', 'STANBY')
        ],
        default='DISPONIBLE'
    )
    owner_transport = CharField(max_length=255, default='PEISOL')

Certification Tracking

Vehicles require multiple certifications with expiration dates:

Operating Certificate

date_cert_operdue_date_cert_operStatus: status_cert_oper

Registration (Matrícula)

date_matriculadue_date_matricula

MTOP Authorization

date_mtopdue_date_mtop

Technical Review

date_technical_reviewdue_date_technical_review

Insurance Policy

insurance_issue_dateinsurance_expiration_datePolicy: nro_polizaCompany: insurance_company

Satellite Tracking

date_satellitedue_date_satellite

Certification Status

The status_cert_oper field tracks operating certificate status:
  • VIGENTE: Valid and current
  • VENCIDO: Expired
  • NO APLICA: Not applicable
  • POR VENCER: Expiring soon
  • EN TRAMITE: In process
  • RECHAZADO: Rejected

Vehicle Documentation

Attach PDF documents for compliance:
poliza_file = FileField(
    upload_to='vehicles/polizas/',
    validators=[validate_pdf_file]
)
matricula_file = FileField(
    upload_to='vehicles/matriculas/',
    validators=[validate_pdf_file]
)
rev_tec_file = FileField(
    upload_to='vehicles/revisiones_tecnicas/',
    validators=[validate_pdf_file]
)
vehicle_image = ImageField(
    upload_to='vehicles/images/',
    validators=[validate_image_file]
)

Code Examples

Querying Equipment by Status

from equipment.models import ResourceItem

# Get all available equipment
available = ResourceItem.objects.filter(
    stst_status_disponibility='DISPONIBLE',
    stst_status_equipment='FUNCIONANDO',
    is_active=True
)

# Get equipment currently in repair
in_repair = ResourceItem.objects.filter(
    stst_status_equipment='EN REPARACION',
    is_active=True
)

# Get equipment by code
equipment = ResourceItem.get_by_code('BT-001')

Working with Equipment Fields

# Get fields specific to equipment type
equipment = ResourceItem.objects.get(code='BT-001')

# Access type-specific fields
all_fields = equipment.all_fields_for_type
boolean_fields = equipment.boolean_fields
specific_fields = equipment.specific_fields

# Get field value with display name
status_value = equipment.get_field_value('status')
status_label = equipment.get_field_label('stst_status_equipment')

# Get checklist items for inspection
checklist = equipment.present_have_fields

Best Practices

  • Update stst_status_disponibility when assigning equipment to projects
  • Set stst_current_project_id and stst_current_location when rented
  • Record stst_commitment_date when equipment goes out
  • Record stst_release_date when equipment returns
  • Monitor vehicle certification expiration dates
  • Update status_cert_oper based on due dates
  • Attach PDF documents for all certifications
  • Set up alerts for certifications expiring within 30 days
  • Mark equipment as ‘EN REPARACION’ when maintenance is needed
  • Document repair reason in stst_repair_reason
  • Update status to ‘FUNCIONANDO’ after repairs complete
  • Track replaced parts and service history
  • Use boolean have_* fields to track component presence
  • Update checklist fields during equipment inspections
  • Document missing components before deployment
  • Track component brands and models for replacement parts

Projects

Assign equipment to project contracts

Maintenance

Schedule and track equipment maintenance

Reports

Generate equipment checklists and status reports

Custody Chains

Track equipment during field operations

Build docs developers (and LLMs) love