This commit is contained in:
rogeecn
2025-03-22 16:39:52 +08:00
commit 306491168c
127 changed files with 17865 additions and 0 deletions

View File

@@ -0,0 +1,21 @@
//
// Code generated by go-jet DO NOT EDIT.
//
// WARNING: Changes to this file may cause incorrect behavior
// and will be lost if the code is regenerated
//
package model
import (
"time"
)
type Medias struct {
ID int64 `sql:"primary_key" json:"id"`
CreatedAt time.Time `json:"created_at"`
Name string `json:"name"`
MimeType string `json:"mime_type"`
Size int64 `json:"size"`
Path string `json:"path"`
}

View File

@@ -0,0 +1,19 @@
//
// Code generated by go-jet DO NOT EDIT.
//
// WARNING: Changes to this file may cause incorrect behavior
// and will be lost if the code is regenerated
//
package model
import (
"time"
)
type Migrations struct {
ID int32 `sql:"primary_key" json:"id"`
VersionID int64 `json:"version_id"`
IsApplied bool `json:"is_applied"`
Tstamp time.Time `json:"tstamp"`
}

View File

@@ -0,0 +1,73 @@
//
// Code generated by go-jet DO NOT EDIT.
//
// WARNING: Changes to this file may cause incorrect behavior
// and will be lost if the code is regenerated
//
package model
import "errors"
type RiverJobState string
const (
RiverJobState_Available RiverJobState = "available"
RiverJobState_Cancelled RiverJobState = "cancelled"
RiverJobState_Completed RiverJobState = "completed"
RiverJobState_Discarded RiverJobState = "discarded"
RiverJobState_Pending RiverJobState = "pending"
RiverJobState_Retryable RiverJobState = "retryable"
RiverJobState_Running RiverJobState = "running"
RiverJobState_Scheduled RiverJobState = "scheduled"
)
var RiverJobStateAllValues = []RiverJobState{
RiverJobState_Available,
RiverJobState_Cancelled,
RiverJobState_Completed,
RiverJobState_Discarded,
RiverJobState_Pending,
RiverJobState_Retryable,
RiverJobState_Running,
RiverJobState_Scheduled,
}
func (e *RiverJobState) Scan(value interface{}) error {
var enumValue string
switch val := value.(type) {
case string:
enumValue = val
case []byte:
enumValue = string(val)
default:
return errors.New("jet: Invalid scan value for AllTypesEnum enum. Enum value has to be of type string or []byte")
}
switch enumValue {
case "available":
*e = RiverJobState_Available
case "cancelled":
*e = RiverJobState_Cancelled
case "completed":
*e = RiverJobState_Completed
case "discarded":
*e = RiverJobState_Discarded
case "pending":
*e = RiverJobState_Pending
case "retryable":
*e = RiverJobState_Retryable
case "running":
*e = RiverJobState_Running
case "scheduled":
*e = RiverJobState_Scheduled
default:
return errors.New("jet: Invalid scan value '" + enumValue + "' for RiverJobState enum")
}
return nil
}
func (e RiverJobState) String() string {
return string(e)
}