pro-components icon indicating copy to clipboard operation
pro-components copied to clipboard

🐛[BUG]ProTable删除第二页最后一条数据,页码跳转了上一页

Open dmhxdtl opened this issue 1 year ago • 3 comments

3031712712734_ pic

dmhxdtl avatar Apr 10 '24 01:04 dmhxdtl

我也遇到了同样的问题

yxf168 avatar May 13 '24 09:05 yxf168

将最后一页数据全部删掉后,页面未自动显示最新的最后一页数据, 期望: 删除最后一页最后一条数据时,自动跳转到前一页,请求前一页的数据

yxf168 avatar May 13 '24 09:05 yxf168

<Popconfirm
  placement="topRight"
  title="确定删除?"
  description="删除后不可恢复"
  onConfirm={async () => {
    await serviceClient.connectMG.delRabbitMq(record.id);
    // action?.reloadAndRest?.();
    console.log('[ action?.pageInfo1 ]', action?.pageInfo)
    action?.reload();
    console.log('[ action?.pageInfo2 ]', action?.pageInfo)
    // setTimeout(() => {
    // action?.reload();
    // }, 3000);
    message.success("操作成功");
  }}
  >
  <Button type="link" danger>
    删除
  </Button>
  </Popconfirm>

yxf168 avatar May 13 '24 09:05 yxf168