feat: user & article: dev complete

This commit is contained in:
fallen-angle
2022-02-27 16:36:33 +08:00
parent 4f3b16ab9d
commit 80ca1cd46e
33 changed files with 2373 additions and 185 deletions

View File

@@ -12,7 +12,7 @@ import (
// @Tags Statistics
// @Produce json
// @Summary province statistics
// @Success 200 {object} models.GinResponse{data=[]models.AreaInfo}
// @Success 200 {object} utils.GinResponse{data=[]models.AreaInfo}
// @Router /statistics/province/{sort} [get]
// @Param sort path string false "data sorted by" Enums(today, total, now, default)
func ProvinceDataHandler(c *gin.Context) {
@@ -25,7 +25,7 @@ func ProvinceDataHandler(c *gin.Context) {
// @Tags Statistics
// @Produce json
// @Summary city statistics
// @Success 200 {object} models.GinResponse{data=[]models.AreaInfo}
// @Success 200 {object} utils.GinResponse{data=[]models.AreaInfo}
// @Router /statistics/city/{sort} [get]
// @Param sort path string false "data sorted by" Enums(today, total, now, default)
func CityDataHandler(c *gin.Context) {
@@ -38,7 +38,7 @@ func CityDataHandler(c *gin.Context) {
// @Tags Statistics
// @Produce json
// @Summary country statistics
// @Success 200 {object} models.GinResponse{data=[]models.AreaInfo}
// @Success 200 {object} utils.GinResponse{data=[]models.AreaInfo}
// @Router /statistics/country/child [get]
// @Router /statistics/country [get]
func CountryDataHandler(c *gin.Context) {
@@ -51,7 +51,7 @@ func CountryDataHandler(c *gin.Context) {
// @Tags Statistics
// @Produce json
// @Summary china data
// @Success 200 {object} models.GinResponse{data=models.ChinaData}
// @Success 200 {object} utils.GinResponse{data=models.ChinaData}
// @Router /statistics/china [get]
func ChinaDataHandler(c *gin.Context) {
data := service.GetChinaNCovStatistic()