1. Which columns we read from your file
From your CSV, XLSX or XLS we only read what is strictly necessary: the date column, the value column and, optionally, a third column that marks which days your business was open. Any other column in the file is silently ignored; if we detect extra columns we warn you right on the upload screen.
Exact rules:
- Headers we recognise for the third column (uppercase, lowercase and accents are indifferent): is_open, is open, isopen, open, abierto, abierta, estado, status.
- Values we interpret as open: true, 1, sí, si, yes, y, abierto, abierta, open, opened, activo, active.
- Values we interpret as closed: false, 0, no, n, cerrado, cerrada, closed, close, inactivo, inactive.
- An empty cell is interpreted as closed. Any other unrecognised text is interpreted as open by conservative default (we prefer not to discard an ambiguous day because of a typo).
src/lib/file-parser/is-open.ts