ant-design / ant-design/pro-components

🐛[BUG]两个客户同时编辑一条table里面的同一条数据,点击查询拉取最新数据,重新编辑的数据是缓存并没有更新,table的编辑form没有拉取最新的

Open
#8,697 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
4.8k
Forks
1.4k
Avg merge
10h 44m
Merged PRs (30d)
3

Description

使用Protable,通过编辑行数据方式,保存Product Status的状态Invalid 到Valid,点击保存

通过另一个客户端也将该数据从Product Status的状态Valid 切换 Invalid

点击search按钮,显示数据是正常的的,但是点击编辑的时候,Product Status的状态还是为Invalid,测试说明table的编辑行form表单使用缓存,并没有读取列表请求来的新数据
![image](https://github.com/user-attachments/assets/48637a0f-18bd-4bbd-bd5f-9850feda6046)

![image](https://github.com/user-attachments/assets/68ee6f2f-9c18-45c7-83e7-b2e9c2c3f1aa)
![image](https://github.com/user-attachments/assets/190670ad-23fb-402b-885b-de340c95bc43)
![image](https://github.com/user-attachments/assets/71111422-11ae-49b3-834f-089f599a28e4)

📷 复现步骤 | Recurrence steps
在浏览器打开两个tab,同时编辑一条数据,点击搜索刷新列表,再次编辑那一行,发现走的是缓存,并没有读取新的数据

🏞 期望结果 | Expected results
希望每次读取新的数据

💻 复现代码 | Recurrence code
© 版本信息
Ant Design Pro 版本: [e.g. 2.7.15]
umi 版本
浏览器环境
开发环境 [e.g. mac OS]
🚑 其他信息

Contributor guide

Open the contributing guide

Research direction

Start with the ProTable row-edit flow and reproduce the issue using two browser tabs: update the same row, search to refresh the list, then edit that row again. Compare the edit form's value with the refreshed list data; done means the form uses the latest fetched Product Status rather than cached data.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.