Files

36 lines
693 B
Go
Raw Normal View History

2021-09-29 16:25:56 +08:00
package api
import (
2021-09-29 16:43:40 +08:00
"SciencesServer/app/basic/api"
2021-10-13 14:35:24 +08:00
"SciencesServer/app/enterprise/controller/config"
2021-09-29 16:25:56 +08:00
"github.com/gin-gonic/gin"
)
type Config struct{}
func (a *Config) Identity(c *gin.Context) {
2021-10-13 14:35:24 +08:00
data := config.NewConfig().Identity()
api.APISuccess(data)
}
func (a *Config) Transaction(c *gin.Context) {
data := config.NewConfig().Transaction()
2021-09-29 16:25:56 +08:00
api.APISuccess(data)
}
2021-10-08 17:33:19 +08:00
func (a *Config) Industry(c *gin.Context) {
}
2021-10-13 14:35:24 +08:00
func (a *Config) Area(c *gin.Context) {
form := &struct {
Key string `json:"key" form:"key"`
}{}
if err := api.Bind(form)(c); err != nil {
api.APIFailure(err.(error))(c)
return
}
data := config.NewConfig().Area(form.Key)
api.APIResponse(nil, data)(c)
}