3TE/data/seeds/regulation-characteristics-seeds.json
Nicolas Cantu 5c7137f3d2 Add administrative procedures to module components and centralized regulation characteristics configuration
**Motivations :**
* Allow associating administrative procedures to module components with status tracking
* Centralize regulation characteristics configuration for better data consistency
* Link regulation characteristics to wastes, regulators, ecosystems, and module components

**Root causes :**
* Need to track administrative procedures per module component
* Regulation characteristics were hardcoded in multiple places, causing inconsistency
* No centralized way to manage and reference regulation characteristics

**Correctifs :**
* Added ModuleComponentProcedureAssociation interface with procedureId, status, and notes
* Created RegulationCharacteristic entity with name, code, category, description, unit, isBoolean, minValue, maxValue
* Added regulationCharacteristicIds field to Waste, NaturalRegulator, Ecosystem, and ModuleComponent
* Updated all configuration pages to use regulation characteristics from centralized configuration
* Created RegulationCharacteristicsConfigurationPage for managing characteristics
* Added seeds for regulation characteristics (31 characteristics covering all categories)
* Added seeds for companies (4NK Water & Waste default company)

**Evolutions :**
* Module components can now have associated administrative procedures with status (toDo, done, na)
* Regulation characteristics are now centralized and can be referenced by multiple entities
* All regulation needs and characteristics are now managed through a single configuration page
* Business plans can be added to all entities (already implemented, documented in data_schemas.md)
* Updated data_schemas.md with complete documentation of all entities, relations, and validation rules

**Page affectées :**
* src/pages/configuration/ModuleComponentsConfigurationPage.tsx - Added administrative procedures section
* src/pages/configuration/RegulationCharacteristicsConfigurationPage.tsx - New page for managing characteristics
* src/pages/configuration/WasteConfigurationPage.tsx - Updated to use regulation characteristics
* src/pages/configuration/RegulatorsConfigurationPage.tsx - Updated to use regulation characteristics
* src/pages/configuration/EcosystemsConfigurationPage.tsx - Updated to use regulation characteristics
* src/types/index.ts - Added new interfaces and fields
* src/utils/storage.ts - Added regulation characteristics and companies to storage
* data_schemas.md - Complete documentation update
* data/seeds/regulation-characteristics-seeds.json - New seed file
* data/seeds/companies-seeds.json - New seed file
2025-12-10 08:27:52 +01:00

297 lines
8.6 KiB
JSON

{
"regulationCharacteristics": [
{
"id": "reg-char-001",
"name": "Pathogen Elimination",
"code": "pathogenElimination",
"category": "biological",
"description": "Elimination of pathogens and harmful microorganisms",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-002",
"name": "Heavy Metals Elimination",
"code": "heavyMetalsElimination",
"category": "heavyMetal",
"description": "Elimination of heavy metals (As, Zn, Al, Cu, etc.)",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-003",
"name": "Arsenic Elimination",
"code": "arsenicElimination",
"category": "heavyMetal",
"description": "Elimination of arsenic (As)",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-004",
"name": "Zinc Elimination",
"code": "zincElimination",
"category": "heavyMetal",
"description": "Elimination of zinc",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-005",
"name": "Aluminum Elimination",
"code": "aluminumElimination",
"category": "heavyMetal",
"description": "Elimination of aluminum",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-006",
"name": "Copper Elimination",
"code": "copperElimination",
"category": "heavyMetal",
"description": "Elimination of copper",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-007",
"name": "Metal Binding",
"code": "metalBinding",
"category": "heavyMetal",
"description": "General metal binding capability",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-008",
"name": "Odor Elimination",
"code": "odorElimination",
"category": "chemical",
"description": "Elimination of odors",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-009",
"name": "Oil Emulsification",
"code": "oilEmulsification",
"category": "biologicalProcess",
"description": "Oil emulsification capability",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-010",
"name": "Sodium Reduction",
"code": "sodiumReduction",
"category": "chemical",
"description": "Reduction of sodium (Na⁺) concentration",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-011",
"name": "Chlorine Reduction",
"code": "chlorineReduction",
"category": "chemical",
"description": "Reduction of chlorine (Cl⁻) concentration",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-012",
"name": "Electrical Conductivity Reduction",
"code": "electricalConductivityReduction",
"category": "chemical",
"description": "Reduction of electrical conductivity",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-013",
"name": "Turbidity Reduction",
"code": "turbidityReduction",
"category": "chemical",
"description": "Reduction of turbidity",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-014",
"name": "Medication Elimination",
"code": "medicationElimination",
"category": "chemical",
"description": "Elimination of medications and pharmaceutical residues",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-015",
"name": "Deposit Elimination",
"code": "depositElimination",
"category": "chemical",
"description": "Elimination of deposits",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-016",
"name": "Sulfide Elimination",
"code": "sulfideElimination",
"category": "chemical",
"description": "Elimination of sulfides",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-017",
"name": "Methane Elimination",
"code": "methaneElimination",
"category": "chemical",
"description": "Elimination of methane",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-018",
"name": "CO₂ Elimination",
"code": "co2Elimination",
"category": "chemical",
"description": "Elimination of CO₂",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-019",
"name": "Polyphenol Elimination",
"code": "polyphenolElimination",
"category": "chemical",
"description": "Elimination of polyphenols",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-020",
"name": "Refractory Fractions Elimination",
"code": "refractoryFractionsElimination",
"category": "chemical",
"description": "Elimination of refractory structural fractions (lignin, alginates, fucoidans, crystalline cellulose, and insoluble fibers)",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-021",
"name": "Low C:N Ratio Enrichment",
"code": "lowCNRatioEnrichment",
"category": "chemical",
"description": "Enrichment for low C:N ratio",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-022",
"name": "Microbiological Competition",
"code": "microbiologicalCompetition",
"category": "biologicalProcess",
"description": "Microbiological competition capability",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-023",
"name": "Acidity Reduction",
"code": "acidityReduction",
"category": "ph",
"description": "Reduction of acidity",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-024",
"name": "pH Increase",
"code": "phIncrease",
"category": "ph",
"description": "Increase of pH level",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-025",
"name": "pH Reduction",
"code": "phReduction",
"category": "ph",
"description": "Reduction of pH level",
"isBoolean": true,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-026",
"name": "Total Nitrogen (N or NTK)",
"code": "nitrogen",
"category": "nutrient",
"description": "Total Nitrogen content",
"unit": "kg/t",
"isBoolean": false,
"minValue": 0,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-027",
"name": "Ammoniacal Nitrogen (N-NH₄)",
"code": "ammoniacalNitrogen",
"category": "nutrient",
"description": "Ammoniacal Nitrogen - Indicator of rapid effect",
"unit": "kg/t",
"isBoolean": false,
"minValue": 0,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-028",
"name": "Total Phosphorus (P)",
"code": "phosphorus",
"category": "nutrient",
"description": "Total Phosphorus content",
"unit": "kg/t",
"isBoolean": false,
"minValue": 0,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-029",
"name": "Total Potassium (K)",
"code": "potassium",
"category": "nutrient",
"description": "Total Potassium content",
"unit": "kg/t",
"isBoolean": false,
"minValue": 0,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-030",
"name": "Carbon:Nitrogen Ratio (C:N)",
"code": "carbonNitrogenRatio",
"category": "nutrient",
"description": "Carbon to Nitrogen ratio",
"isBoolean": false,
"minValue": 0,
"createdAt": "2025-01-15T00:00:00.000Z"
},
{
"id": "reg-char-031",
"name": "pH Adjustment",
"code": "phAdjustment",
"category": "ph",
"description": "Direct pH adjustment value (-14 to 14). Negative values reduce pH, positive values increase pH",
"unit": "pH",
"isBoolean": false,
"minValue": -14,
"maxValue": 14,
"createdAt": "2025-01-15T00:00:00.000Z"
}
]
}