Hours by client: add search and CSV filtering; add alerts cron (BRT 08:00 guard) + alerts panel filters; admin companies shows last alert; PDF Inter font from public/fonts; fix Select empty value; type cleanups; tests for CSV/TZ; remove Knowledge Base nav
This commit is contained in:
parent
2cf399dcb1
commit
08cc8037d5
151 changed files with 1404 additions and 214 deletions
|
|
@ -6,6 +6,12 @@ const envSchema = z.object({
|
|||
NEXT_PUBLIC_CONVEX_URL: z.string().url().optional(),
|
||||
DATABASE_URL: z.string().min(1).optional(),
|
||||
NEXT_PUBLIC_APP_URL: z.string().url().optional(),
|
||||
SMTP_ADDRESS: z.string().optional(),
|
||||
SMTP_PORT: z.coerce.number().optional(),
|
||||
SMTP_USERNAME: z.string().optional(),
|
||||
SMTP_PASSWORD: z.string().optional(),
|
||||
SMTP_TLS: z.string().optional(),
|
||||
MAILER_SENDER_EMAIL: z.string().optional(),
|
||||
})
|
||||
|
||||
const parsed = envSchema.safeParse(process.env)
|
||||
|
|
@ -21,4 +27,14 @@ export const env = {
|
|||
NEXT_PUBLIC_CONVEX_URL: parsed.data.NEXT_PUBLIC_CONVEX_URL,
|
||||
DATABASE_URL: parsed.data.DATABASE_URL,
|
||||
NEXT_PUBLIC_APP_URL: parsed.data.NEXT_PUBLIC_APP_URL,
|
||||
SMTP: parsed.data.SMTP_ADDRESS && parsed.data.SMTP_USERNAME && parsed.data.SMTP_PASSWORD
|
||||
? {
|
||||
host: parsed.data.SMTP_ADDRESS,
|
||||
port: parsed.data.SMTP_PORT ?? 465,
|
||||
username: parsed.data.SMTP_USERNAME,
|
||||
password: parsed.data.SMTP_PASSWORD,
|
||||
tls: (parsed.data.SMTP_TLS ?? "true").toLowerCase() === "true",
|
||||
from: parsed.data.MAILER_SENDER_EMAIL ?? "no-reply@example.com",
|
||||
}
|
||||
: null,
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue