Merge branch 'pagination' into dev
This commit is contained in:
commit
ea6b661d68
2 changed files with 7 additions and 4 deletions
|
|
@ -8,6 +8,7 @@ import { fetchList as fetchSlackList } from 'Duck/integrations/slack';
|
|||
import { errors as errorsRoute, isRoute } from "App/routes";
|
||||
import DateRange from 'Components/BugFinder/DateRange';
|
||||
import withPageTitle from 'HOCs/withPageTitle';
|
||||
import cn from 'classnames';
|
||||
|
||||
import List from './List/List';
|
||||
import ErrorInfo from './Error/ErrorInfo';
|
||||
|
|
@ -78,11 +79,12 @@ export default class Errors extends React.PureComponent {
|
|||
},
|
||||
status,
|
||||
list,
|
||||
history,
|
||||
} = this.props;
|
||||
|
||||
return (
|
||||
<div className="page-margin container-90" >
|
||||
<div className="side-menu">
|
||||
<div className={cn("side-menu", {'disabled' : !isRoute(ERRORS_ROUTE, history.location.pathname)})}>
|
||||
<SideMenuSection
|
||||
title="Errors"
|
||||
onItemClick={this.onStatusItemClick}
|
||||
|
|
|
|||
|
|
@ -128,14 +128,15 @@ export const fetchList = (params = {}, clear = false) => (dispatch, getState) =>
|
|||
params.page = getState().getIn(['errors', 'currentPage']);
|
||||
params.limit = PER_PAGE;
|
||||
|
||||
const options = getState().getIn(['errors', 'options']);
|
||||
if (options.get("status") === BOOKMARK) {
|
||||
const options = getState().getIn(['errors', 'options']).toJS();
|
||||
if (options.status === BOOKMARK) {
|
||||
options.bookmarked = true;
|
||||
options.status = 'all';
|
||||
}
|
||||
|
||||
return dispatch({
|
||||
types: array(FETCH_LIST),
|
||||
call: client => client.post('/errors/search', { ...params, ...options.toJS() }),
|
||||
call: client => client.post('/errors/search', { ...params, ...options }),
|
||||
clear,
|
||||
params: cleanParams(params),
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue