解决勾选记录后,点击 导入/导出 按钮,触发 action 请求,导致 导入/导出 请求中断,并提示 未选择动作 #509
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
问题描述
在当前版本中,用户在勾选记录后点击"导入"或"导出"按钮时,会触发一个不必要的 action 请求。这导致了以下问题:
原因分析
经过代码审查,发现问题出在
actions.html
文件中的 JavaScript 代码。当前实现对所有操作按钮使用了统一的事件处理逻辑,没有对导入/导出操作进行特殊处理。解决方案
修改内容
actions.html
文件中的 JavaScript 代码:对导入导出操作,不进行 action 请求收益
测试