Have got first run working and publishing to Netlify
This commit is contained in:
parent
b7e0269e9d
commit
30d99eeb9e
22 changed files with 472 additions and 47 deletions
|
|
@ -1,5 +1,7 @@
|
|||
package models
|
||||
|
||||
import "time"
|
||||
|
||||
type PublishTargetType int
|
||||
|
||||
const (
|
||||
|
|
@ -11,10 +13,10 @@ const (
|
|||
type Site struct {
|
||||
ID int64
|
||||
OwnerID int64
|
||||
Created time.Time
|
||||
|
||||
Title string
|
||||
Tagline string
|
||||
//Meta SiteMeta
|
||||
//Posts []*Post
|
||||
}
|
||||
|
||||
type SitePublishTarget struct {
|
||||
|
|
|
|||
|
|
@ -1,16 +1,20 @@
|
|||
package models
|
||||
|
||||
import (
|
||||
"regexp"
|
||||
"time"
|
||||
|
||||
"golang.org/x/crypto/bcrypt"
|
||||
)
|
||||
|
||||
var ValidUserName = regexp.MustCompile(`^[a-zA-Z0-9_-]+$`)
|
||||
|
||||
type User struct {
|
||||
ID int64
|
||||
Username string
|
||||
PasswordHashed []byte
|
||||
TimeZone string
|
||||
Created time.Time
|
||||
}
|
||||
|
||||
func (u *User) SetPassword(pwd string) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue