addTimestamps property
Whether to automatically add created_at and updated_at timestamp columns.
When true, the generator will automatically add:
created_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP
updated_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP
It will also create a trigger to automatically update updated_at
when rows are modified.
Example:
@DatabaseTable(addTimestamps: true)
class Product { ... }
// Automatically adds created_at and updated_at columns
@DatabaseTable(addTimestamps: false)
class Configuration { ... }
// No automatic timestamp columns
Implementation
final bool addTimestamps;