chore: remove Open Food Facts (OFF) integration

- Remove off-service.js and off-service.test.js
- Remove OFF import from server.js
- Simplify /api/products/search to only use CIMA
- Remove 'openfoodfacts' from valid product sources
- Update frontend-mobile Product interface to remove OFF source
- Remove OFF env vars from .env.example
- Add PARAPHARMACY_API_URL to .env.example

OFF was replaced by the new parapharmacy-api microservice.
This commit is contained in:
Antoni Nuñez Romeu
2026-07-16 12:34:08 +02:00
parent b34657c78f
commit 7274979f62
6 changed files with 11 additions and 351 deletions
+1 -6
View File
@@ -3,7 +3,7 @@ import api from './api';
export interface Product {
id: string;
_id?: string;
source: 'cima' | 'openfoodfacts' | 'promofarma' | 'pharmarket' | 'docmorris' | '1001farma' | 'primor' | 'mifarma';
source: 'cima' | 'promofarma' | 'pharmarket' | 'docmorris' | '1001farma' | 'primor' | 'mifarma';
name: string;
brand: string;
category: string;
@@ -22,10 +22,6 @@ export interface Product {
commercialized?: boolean;
photos?: { tipo: string; url: string }[];
docs?: { tipo: number; url: string }[];
nutriscore?: string;
ingredients?: string;
nova_group?: number;
eco_score?: string;
}
export interface ProductSearchResponse {
@@ -35,7 +31,6 @@ export interface ProductSearchResponse {
pages?: number;
sources?: {
cima: number;
openfoodfacts: number;
};
}