2017-03-09 03:39:06 +00:00
|
|
|
package web
|
|
|
|
|
2017-06-29 07:15:33 +00:00
|
|
|
import "github.com/shunfei/cronsun/conf"
|
2017-03-09 03:39:06 +00:00
|
|
|
|
2017-03-16 02:19:57 +00:00
|
|
|
type Configuration struct{}
|
2017-03-09 03:39:06 +00:00
|
|
|
|
2017-06-29 07:15:33 +00:00
|
|
|
func (cnf *Configuration) Configuratios(ctx *Context) {
|
|
|
|
outJSON(ctx.W, struct {
|
2017-03-16 02:19:57 +00:00
|
|
|
Security *conf.Security `json:"security"`
|
2017-04-07 08:28:41 +00:00
|
|
|
Alarm bool `json:"alarm"`
|
2017-03-16 02:19:57 +00:00
|
|
|
}{
|
|
|
|
Security: conf.Config.Security,
|
2017-04-07 08:28:41 +00:00
|
|
|
Alarm: conf.Config.Mail.Enable,
|
2017-03-16 02:19:57 +00:00
|
|
|
})
|
2017-03-09 03:39:06 +00:00
|
|
|
}
|