Replace BPS Excel stub with multi-client calendar template.
Official download now generates a blank workbook with catalog autofill, notas_internas ignored on import, and the same template for every tenant. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -9,11 +9,11 @@ import {
|
||||
} from '@/lib/agency';
|
||||
import {
|
||||
parseJsonCalendar,
|
||||
SAMPLE_CSV,
|
||||
sheetsToPlans,
|
||||
type ImportResult,
|
||||
type SheetRows,
|
||||
} from '@/lib/calendar-import';
|
||||
import { buildOfficialCsv } from '@/lib/calendar-template';
|
||||
import type { RrssMonthPlan } from '@/components/RrssMonthView';
|
||||
|
||||
export const dynamic = 'force-dynamic';
|
||||
@@ -21,12 +21,14 @@ export const runtime = 'nodejs';
|
||||
|
||||
const MAX_BYTES = 8 * 1024 * 1024;
|
||||
|
||||
/** @deprecated Prefer GET /api/calendar/template?format=csv */
|
||||
export async function GET() {
|
||||
return new NextResponse(SAMPLE_CSV, {
|
||||
return new NextResponse(buildOfficialCsv('CLIENTE'), {
|
||||
headers: {
|
||||
'Content-Type': 'text/csv; charset=utf-8',
|
||||
'Content-Disposition':
|
||||
'attachment; filename="plantilla-calendario-4ventures.csv"',
|
||||
'Cache-Control': 'no-store',
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user