| | |
| | | </view> |
| | | <view class="m-t-12" @click="getNoticeMore"> |
| | | <uni-notice-bar class="notice-bar" color="#333" background-color="#fff" show-get-more show-icon |
| | | :scrollable="scrollable" :text="currentNotice.title||'暂无公共'" :key="currentNotice.id" /> |
| | | :scrollable="scrollable" :text="currentNotice.title||'暂无公告'" :key="currentNotice.id" /> |
| | | <span v-if="!currentNotice||!currentNotice.id"> </span> |
| | | </view> |
| | | <view class="item-container"> |
| | |
| | | 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) |
| | | // } |
| | | |
| | | } |
| | | } |