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

    table cell multirows

    Framework
    ui component
    2
    7
    1581
    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.
    • F
      frankz last edited by

      how is it possible to build a table with column (s) with multi-row cells?

      1 Reply Last reply Reply Quote 0
      • dobbel
        dobbel last edited by dobbel

        with slots:

        https://quasar.dev/vue-components/table#Example--Virtual-scroll-with-multiple-rows-for-a-data-row

        <template v-slot:body="props">
                <q-tr :props="props" :key="`m_${props.row.index}`">
                    <q-td colspan="100%">
                        this is row 1
                     </q-td>
                </q-tr>
                <q-tr :props="props" :key="`e_${props.row.index}`">
                    <q-td colspan="100%">
                        this is row 2
                    </q-td>
                </q-tr>
        </template>
        
        F 1 Reply Last reply Reply Quote 0
        • F
          frankz @dobbel last edited by

          @dobbel
          I meant that in the cell “Frozen Yogurt " there was also " This is the second row generated from the same data”,
          keeping the column width the same.
          it was probably best that I specify a multi-line cell

          dobbel 1 Reply Last reply Reply Quote 0
          • dobbel
            dobbel @frankz last edited by dobbel

            @frankz what you need is rowspan=“2” on the ‘name’ td ( e.g. Frozen Yochurt) of a table. Like this:

            https://www.w3schools.com/code/tryit.asp?filename=GHE965NIU4JJ

            1 Reply Last reply Reply Quote 0
            • F
              frankz last edited by

              But it doesn’t wrap, I have to insert a <BR>

              1 Reply Last reply Reply Quote 0
              • F
                frankz last edited by

                I found this and will try it, it should work.
                https://forum.quasar-framework.org/topic/844/word-wrap-using-in-datatables

                dobbel 1 Reply Last reply Reply Quote 0
                • dobbel
                  dobbel @frankz last edited by

                  @frankz I found this:

                  https://stackoverflow.com/questions/1258416/word-wrap-in-an-html-table

                  https://stackoverflow.com/questions/6666532/how-to-force-table-cell-td-content-to-wrap/23761141

                  1 Reply Last reply Reply Quote 0
                  • First post
                    Last post