search

Home  >  Q&A  >  body text

javascript - table component implements merged cells and is paging?

Let’s first describe the scenario: the requirement is a table that can merge cells (each large piece of data contains several small pieces, the number is not necessarily determined), and it must be paging, with 10 large pieces of data per page.

Confusion:
1. Because the number of items displayed in the table is consistent with pageSize, pageSize should be the number of small items.
2. If pageSize is equal to the number of small items, each page is required to display 10 large items of data. , then the number of small strips per page (pageSize) is an uncertain value, and the calculated total number of pages will be incorrect.

Please give me some advice, thank you very much!

欧阳克欧阳克2699 days ago1240

reply all(2)I'll reply

  • 漂亮男人

    漂亮男人2017-07-05 11:03:47

    Your small piece of data is uncertain before you get the 10 pieces of big data, but after you get 10 pieces of data (you can get as many pieces of small data as there are in each big data), the pageSize will be I'm sure, but I don't understand what you want to do after getting the pageSize

    reply
    0
  • 女神的闺蜜爱上我

    女神的闺蜜爱上我2017-07-05 11:03:47

    The problem is solved. antd is currently not friendly enough to support this situation. It can be achieved by shielding the paging attribute of Table and then using the paging component. This also solves the first confusion in the above question. The number of items displayed on each page of the Table has nothing to do with pageSize.

    For details, please refer to: https://github.com/ant-design...

    reply
    0
  • Cancelreply