mostly finished db pages
This commit is contained in:
parent
c5d41b0965
commit
38f7c31517
10 changed files with 278 additions and 125 deletions
|
|
@ -3,6 +3,7 @@ package main
|
|||
import (
|
||||
"fmt"
|
||||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
)
|
||||
|
||||
|
|
@ -34,3 +35,13 @@ func since(t time.Time) string {
|
|||
return fmt.Sprintf("%.fms", f)
|
||||
}
|
||||
}
|
||||
func storeTitle(section, title string) string {
|
||||
return section + "/" + title
|
||||
}
|
||||
|
||||
func unstoreTitle(title string) (section, title string) {
|
||||
if a := strings.Split(title, "/"); len(a) == 2 {
|
||||
return a[0], a[1]
|
||||
}
|
||||
return
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue