pagination.go 217 B

12345678910111213
  1. package util
  2. /*func GetPage(c *gin.Context) int {
  3. result := 0
  4. pageStr := c.Query("page")
  5. page, _ := strconv.Atoi(pageStr)
  6. if page > 0 {
  7. result = (page - 1) * setting.AppSetting.PageSize
  8. }
  9. return result
  10. }
  11. */