New sharer field: Creation time
This commit is contained in:
parent
3dd82178f5
commit
19b576e795
2 changed files with 7 additions and 4 deletions
|
@ -19,6 +19,7 @@
|
|||
Sharer
|
||||
ident ShrIdent
|
||||
name Text Maybe
|
||||
created UTCTime default='now()'
|
||||
|
||||
UniqueSharer ident
|
||||
|
||||
|
|
|
@ -50,10 +50,12 @@ postPeopleR = do
|
|||
((result, widget), enctype) <- runFormPost formPersonNew
|
||||
case result of
|
||||
FormSuccess pn -> do
|
||||
now <- liftIO getCurrentTime
|
||||
runDB $ do
|
||||
let sharer = Sharer
|
||||
{ sharerIdent = text2shr $ uLogin pn
|
||||
, sharerName = uName pn
|
||||
, sharerCreated = now
|
||||
}
|
||||
sid <- insert sharer
|
||||
let person = Person
|
||||
|
|
Loading…
Reference in a new issue