No More Posting New Topics!

If you have a question or an issue, please start a thread in our Github Discussions Forum.
This forum is closed for new threads/ topics.

Navigation

    Quasar Framework

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    QTable Clicking an action button on clickable row

    Help
    2
    4
    885
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      mecjos last edited by mecjos

      Hi, I have a problem on qtable component. I made table rows clickable by @row-click event. That’s works fine but I have some action buttons cell on my table and when I click any action button, first @row-click event triggered… I need to give an exception acitons body cell… How can I do that? Thank you…

      1 Reply Last reply Reply Quote 1
      • metalsadman
        metalsadman last edited by

        Try with one of the event modifiers stop or prevent.

        M 1 Reply Last reply Reply Quote 0
        • M
          mecjos @metalsadman last edited by mecjos

          @metalsadman thanks for your answer… I tried, at that time it seems like rows are not clickable and when I prevent click affect I call a function to navigate and this fucntion works again by clicking action buttons. Actually it must be like checkbox cells at rows… I can click check boxes without problem.

          1 Reply Last reply Reply Quote 0
          • M
            mecjos last edited by

            I solved with following method… All clicks comes from TD element when used @row-click event except my action buttons.

                      <q-table :data="listProjects(this.$route.params.id)" :columns="columns" row-key="id" @row-click="rowClicker" selection="multiple" :selected.sync="selectedItems">
            
            rowClicker (e, row) {
                  if (e.target.nodeName === 'TD') {
                    this.$router.push('project/parts/' + row.id)
                  }
                }
            
            1 Reply Last reply Reply Quote 1
            • First post
              Last post