|
@@ -34,7 +34,7 @@
|
|
|
<script>
|
|
|
import myPagination from './components/Pagination';
|
|
|
import myTable from './components/Table';
|
|
|
- import * as HYZXApi from '@/api/hangyezixun';
|
|
|
+ import * as HYZXApi from '@/api/news';
|
|
|
import * as NewsClassifyApi from '@/api/newsClassify';
|
|
|
import mySelect from './components/Select';
|
|
|
import Vue from 'vue';
|
|
@@ -230,14 +230,21 @@
|
|
|
loading.close();
|
|
|
}
|
|
|
},
|
|
|
+ clearPageData() {
|
|
|
+ selectServiceData.options = [];
|
|
|
+ selectServiceData.newsClassifyId = null;
|
|
|
+ tableServiceData.myData = [];
|
|
|
+ paginationServiceData.page = 1;
|
|
|
+ paginationServiceData.size = 10;
|
|
|
+ paginationServiceData.total = 0;
|
|
|
+ }
|
|
|
},
|
|
|
created() {
|
|
|
this.initPageService();
|
|
|
},
|
|
|
beforeDestroy() {
|
|
|
- Object.assign(tableServiceData, tableData);
|
|
|
- Object.assign(paginationServiceData, pagination);
|
|
|
- Object.assign(selectServiceData, selectData);
|
|
|
+ this.clearPageData();
|
|
|
+
|
|
|
},
|
|
|
};
|
|
|
</script>
|