b-table 和行元素函数
b-table and row elements functions
我是 Vue 和 bootstrap-vue 的新手,我有以下 table,我在其中传递以下函数以在单击行时执行:
<b-table
striped
:items="currentCareerReactive.assessmentApplicationsInfo"
:fields="tableFields"
@row-clicked="clickTableRow"
>
</b-table>
...
clickTableRow( item, index ) {
console.log('[dashboard.vue] clickTableRow()');
this.goToDetailsPage(
this.currentCareerReactive.lastAssessmentApplicationResult.assessmentApplicationPublicId );
},
goToDetailsPage( dId ) {
this.$router.push( { name: 'details', params: { dId, id: this.$route.params.id } } );
},
但是在我点击该行后,this error出现了。
下一页加载没有任何缺陷,但这个错误让我很烦恼。它发生在旧页面的 destroy() 之后和新页面的 beforeCreate() 之前。
如果我通过按钮调用此函数,页面会正常加载而不会出现任何错误,所以我猜测是 b-table 上的某些内容导致了此问题。
有人知道会发生什么吗?
我假设您使用的是 BootstrapVue 2.1.0,它在 <b-table>
和 <b-table-lite>
中的行悬停事件处理程序中存在错误。升级到最新的 BootstrapVue v2.2.0+,它修复了这个问题。
请参阅 https://bootstrap-vue.js.org/docs/misc/changelog#bug-fixes-v220
处的更新日志
我是 Vue 和 bootstrap-vue 的新手,我有以下 table,我在其中传递以下函数以在单击行时执行:
<b-table
striped
:items="currentCareerReactive.assessmentApplicationsInfo"
:fields="tableFields"
@row-clicked="clickTableRow"
>
</b-table>
...
clickTableRow( item, index ) {
console.log('[dashboard.vue] clickTableRow()');
this.goToDetailsPage(
this.currentCareerReactive.lastAssessmentApplicationResult.assessmentApplicationPublicId );
},
goToDetailsPage( dId ) {
this.$router.push( { name: 'details', params: { dId, id: this.$route.params.id } } );
},
但是在我点击该行后,this error出现了。
下一页加载没有任何缺陷,但这个错误让我很烦恼。它发生在旧页面的 destroy() 之后和新页面的 beforeCreate() 之前。
如果我通过按钮调用此函数,页面会正常加载而不会出现任何错误,所以我猜测是 b-table 上的某些内容导致了此问题。
有人知道会发生什么吗?
我假设您使用的是 BootstrapVue 2.1.0,它在 <b-table>
和 <b-table-lite>
中的行悬停事件处理程序中存在错误。升级到最新的 BootstrapVue v2.2.0+,它修复了这个问题。
请参阅 https://bootstrap-vue.js.org/docs/misc/changelog#bug-fixes-v220
处的更新日志