mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
修复pretest界面元件溢出的问题
This commit is contained in:
1 parent
0f23611853
commit
3b9910529e
3 files changed
+47
-94
No files matched your search
@@ -59,6 +59,15 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
payload: req,
|
||||
});
|
||||
},
|
||||
loadSubmissions() {
|
||||
dispatch({
|
||||
type: 'SCRATCHPAD_RECORDS_LOAD_SUBMISSIONS',
|
||||
payload: request.get(Context.getSubmissionsUrl),
|
||||
});
|
||||
},
|
||||
handleClickRefresh() {
|
||||
this.loadSubmissions();
|
||||
},
|
||||
});
|
||||
|
||||
@connect(mapStateToProps, mapDispatchToProps)
|
||||
@@ -67,6 +76,10 @@ export default class ScratchpadToolbarContainer extends React.PureComponent {
|
||||
store: PropTypes.object,
|
||||
};
|
||||
|
||||
componentDidMount() {
|
||||
this.props.loadSubmissions();
|
||||
}
|
||||
|
||||
render() {
|
||||
return (
|
||||
<Toolbar>
|
||||
@@ -96,6 +109,18 @@ export default class ScratchpadToolbarContainer extends React.PureComponent {
|
||||
{' '}
|
||||
(F10)
|
||||
</ToolbarButton>
|
||||
<ToolbarButton
|
||||
data-tooltip={i18n('Refresh Records')}
|
||||
className="scratchpad__toolbar__refresh"
|
||||
data-global-hotkey="alt+f"
|
||||
onClick={() => this.props.handleClickRefresh()}
|
||||
>
|
||||
<Icon name="refresh" />
|
||||
{' '}
|
||||
{i18n('Refresh')}
|
||||
{' '}
|
||||
(Alt+F)
|
||||
</ToolbarButton>
|
||||
<ToolbarItem>
|
||||
<select
|
||||
className="select"
|
||||
|
||||
Reference in new issue
Block a user