Add the event service
This commit is contained in:
@@ -9,6 +9,20 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
// EventsColumns holds the columns for the "events" table.
|
||||
EventsColumns = []*schema.Column{
|
||||
{Name: "id", Type: field.TypeInt, Increment: true},
|
||||
{Name: "name", Type: field.TypeString},
|
||||
{Name: "data", Type: field.TypeJSON},
|
||||
{Name: "created_at", Type: field.TypeTime},
|
||||
{Name: "user_id", Type: field.TypeInt},
|
||||
}
|
||||
// EventsTable holds the schema information for the "events" table.
|
||||
EventsTable = &schema.Table{
|
||||
Name: "events",
|
||||
Columns: EventsColumns,
|
||||
PrimaryKey: []*schema.Column{EventsColumns[0]},
|
||||
}
|
||||
// GeneralQueueColumns holds the columns for the "generalQueue" table.
|
||||
GeneralQueueColumns = []*schema.Column{
|
||||
{Name: "id", Type: field.TypeInt, Increment: true},
|
||||
@@ -23,6 +37,7 @@ var (
|
||||
{Name: "created_at", Type: field.TypeTime},
|
||||
{Name: "updated_at", Type: field.TypeTime},
|
||||
{Name: "processed_at", Type: field.TypeTime, Nullable: true},
|
||||
{Name: "user_id", Type: field.TypeInt},
|
||||
}
|
||||
// GeneralQueueTable holds the schema information for the "generalQueue" table.
|
||||
GeneralQueueTable = &schema.Table{
|
||||
@@ -45,6 +60,7 @@ var (
|
||||
}
|
||||
// Tables holds all the tables in the schema.
|
||||
Tables = []*schema.Table{
|
||||
EventsTable,
|
||||
GeneralQueueTable,
|
||||
GeneralQueueStateTable,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user