|
@@ -29,8 +29,13 @@ var vm = new Vue({
|
|
|
},
|
|
|
methods: {
|
|
|
init () {
|
|
|
- this.activeName = '-1'
|
|
|
- this.getList()
|
|
|
+ if (getParam('type')) {
|
|
|
+ this.activeName = getParam('type')
|
|
|
+ window.history.replaceState({}, document.title, location.pathname);
|
|
|
+ } else {
|
|
|
+ this.activeName = '-1'
|
|
|
+ }
|
|
|
+ this.getList(this.activeName)
|
|
|
},
|
|
|
// 获取所有栏目列表数据(包括未读数量)
|
|
|
getList (msgType) {
|
|
@@ -109,6 +114,7 @@ var vm = new Vue({
|
|
|
},
|
|
|
tabClick(val) {
|
|
|
this.tabsList.offset = 1
|
|
|
+ this.activeName = val.name
|
|
|
this.getList(val.name)
|
|
|
},
|
|
|
onPageChange(page) {
|
|
@@ -176,7 +182,7 @@ var vm = new Vue({
|
|
|
url: '/jyapi/messageCenter/ClearUnreadMsg',
|
|
|
type: 'POST',
|
|
|
success:function () {
|
|
|
- this.activeName = '-1'
|
|
|
+ _this.activeName = '-1'
|
|
|
_this.getList()
|
|
|
if(message){
|
|
|
message.getMessageList()
|