|
@@ -590,11 +590,19 @@ export default {
|
|
this.pageSize +
|
|
this.pageSize +
|
|
"?" +
|
|
"?" +
|
|
param;
|
|
param;
|
|
- this.$httpWithMsg.get(url).then(response => {
|
|
|
|
- console.log(response);
|
|
|
|
- this.courseTableData = response.data.content;
|
|
|
|
- this.courseTotal = response.data.totalElements;
|
|
|
|
- });
|
|
|
|
|
|
+ this.$httpWithMsg
|
|
|
|
+ .get(url)
|
|
|
|
+ .then(response => {
|
|
|
|
+ console.log(response);
|
|
|
|
+ this.courseTableData = response.data.content;
|
|
|
|
+ this.courseTotal = response.data.totalElements;
|
|
|
|
+ })
|
|
|
|
+ .then(() => {
|
|
|
|
+ if (this.courseTableData.length === 0 && this.courseTotal > 0) {
|
|
|
|
+ this.currentCoursePage = this.currentCoursePage - 1;
|
|
|
|
+ this.searchCoursePage();
|
|
|
|
+ }
|
|
|
|
+ });
|
|
},
|
|
},
|
|
getCourses(query) {
|
|
getCourses(query) {
|
|
this.courseLoading = true;
|
|
this.courseLoading = true;
|