func GetArticleList(page, size int) ([]*Content, *utils.Pager) {
	index := contentsIndex["article"]
	pager := utils.NewPager(page, size, len(index))
	articles := make([]*Content, 0)
	if len(index) < 1 {
		return articles, pager
	}
	if page > pager.Pages {
		return articles, pager
	}
	for i := pager.Begin; i <= pager.End; i++ {
		articles = append(articles, GetContentById(index[i-1]))
	}
	return articles, pager
}
GetArticleList gets articles list and pager no matter article status.
package model
import "github.com/fuxiaohei/GoBlog/app/utils"
func generatePublishArticleIndex() {
	arr := make([]int, 0)
	for _, id := range contentsIndex["article"] {
		c := GetContentById(id)
		if c.Status == "publish" {
			arr = append(arr, id)
		}
	}
	contentsIndex["article-publish"] = arr
}
func GetPublishArticleList(page, size int) ([]*Content, *utils.Pager) {
	index := contentsIndex["article-publish"]
	pager := utils.NewPager(page, size, len(index))
	articles := make([]*Content, 0)
	if len(index) < 1 {
		return articles, pager
	}
	if page > pager.Pages {
		return articles, pager
	}
	for i := pager.Begin; i <= pager.End; i++ {
		articles = append(articles, GetContentById(index[i-1]))
	}
	return articles, pager
}