接口调整,对接后端部分的v2版本

This commit is contained in:
禾几海
2020-05-27 16:41:06 +08:00
parent deb8646bda
commit dba21730ca
22 changed files with 153 additions and 148 deletions

View File

@@ -38,8 +38,8 @@ export class CategoryComponent implements OnInit {
getCategories(needGetArticle: boolean) {
this.apiService.categories().subscribe(data => {
this.categoryList = data.result;
this.category = data.result[0];
this.categoryList = data.result.list;
this.category = this.categoryList[0];
if (needGetArticle) {
this.getArticles(this.category.name);
this.name = this.category.name;