Sign in

How to implement Vue element UI El table column custom component and pass a column value?

bckygldstn edited in Thu, 21 Jul 2022

Then do a timetable implementation, from Monday to Sunday, each column transmits the corresponding course ID and information. For example, Tuesd is the course ID and tusedm is the course information. And each data needs to be processed and rendered into the desired effect

Because the data that needs to be processed is different every day, it is written as a component, and the corresponding information in row is passed for processing. However, if it is written in the slot scope = "scope" attribute, the component cannot be loaded, and the current line information cannot be obtained without writing. What else can I do to solve the problem

Related codes


       <template slot-scope="scope">
                 <div v-if="scope.row.tuseD">
                          <weekday :msg="scope.row.tuseDM"></weekday>

</ el - table - column >

1 Replies
commented on Fri, 22 Jul 2022

Component causes. Components in scope can be normal causes. Just write the component again

lock This question has been locked and the reply function has been disabled.