work #1500
This commit is contained in:
parent
87f5ca8e1f
commit
b846f195c1
2 changed files with 28 additions and 15 deletions
|
@ -14,6 +14,8 @@ import (
|
|||
"time"
|
||||
"unicode"
|
||||
|
||||
"github.com/go-xorm/xorm"
|
||||
|
||||
"github.com/gogits/gogs/modules/base"
|
||||
"github.com/gogits/gogs/modules/git"
|
||||
"github.com/gogits/gogs/modules/log"
|
||||
|
@ -77,6 +79,13 @@ type Action struct {
|
|||
Created time.Time `xorm:"created"`
|
||||
}
|
||||
|
||||
func (a *Action) AfterSet(colName string, _ xorm.Cell) {
|
||||
switch colName {
|
||||
case "created":
|
||||
a.Created = a.Created.UTC()
|
||||
}
|
||||
}
|
||||
|
||||
func (a Action) GetOpType() int {
|
||||
return int(a.OpType)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue