| | |
| | | this.scrollable = false |
| | | } |
| | | let that = this |
| | | if (this.noticeList.length >= 1) { |
| | | setInterval(() => { |
| | | console.log('interval,1') |
| | | that.currentNoticeIndex += 1 |
| | | that.currentNoticeIndex %= that.noticeList.length |
| | | that.currentNotice = that.noticeList[that.currentNoticeIndex] |
| | | that.scrollable = false |
| | | that.$nextTick(() => { |
| | | if (that.currentNotice.title && that.currentNotice.title |
| | | .length >= 30) { |
| | | that.scrollable = true |
| | | } else { |
| | | that.scrollable = false |
| | | } |
| | | }) |
| | | // if (this.noticeList.length >= 1) { |
| | | // setInterval(() => { |
| | | // console.log('interval,1') |
| | | // that.currentNoticeIndex += 1 |
| | | // that.currentNoticeIndex %= that.noticeList.length |
| | | // that.currentNotice = that.noticeList[that.currentNoticeIndex] |
| | | // that.scrollable = false |
| | | // that.$nextTick(() => { |
| | | // if (that.currentNotice.title && that.currentNotice.title |
| | | // .length >= 30) { |
| | | // that.scrollable = true |
| | | // } else { |
| | | // that.scrollable = false |
| | | // } |
| | | // }) |
| | | |
| | | }, 8000) |
| | | } |
| | | // }, 8000) |
| | | // } |
| | | |
| | | } |
| | | } |