first commit

This commit is contained in:
Rutra committed 2026-10-12 14:25:22 +02:00
commit 3c0479faf0
169 files changed
+27617

No files matched your search

+15
View File
@@ -0,0 +1,15 @@
import { SiteSchema } from '#database/schema'
import { column } from '@adonisjs/lucid/orm'
/**
* SQLite stores booleans as 0/1: convert them back when reading.
*/
const toBoolean = (value: unknown) => (value === null ? null : Boolean(value))
export default class Site extends SiteSchema {
@column({ consume: toBoolean })
declare active: boolean
@column({ consume: toBoolean })
declare lastOk: boolean | null
}