Add notifications
This commit is contained in:
parent
6545cbdff8
commit
e68f41445e
8 changed files with 114 additions and 63 deletions
|
@ -43,14 +43,14 @@ func storeFile(r *http.Request) error {
|
|||
}
|
||||
|
||||
type uploadData struct {
|
||||
S Status
|
||||
Msg string
|
||||
S Status
|
||||
Msg string
|
||||
}
|
||||
|
||||
func uploadHandler(coll *mgo.Collection) func(http.ResponseWriter, *http.Request) {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
var data uploadData
|
||||
data.S.User = SessionUser(r)
|
||||
data.S = GetStatus(w, r)
|
||||
data.S.Upload = true
|
||||
data.Msg = ""
|
||||
if r.Method == "POST" {
|
||||
|
|
Reference in a new issue