Cleanup database + updates to apollo error handler to check all errors + added hash history to jobs list.
This commit is contained in:
@@ -4,12 +4,14 @@ import { useTranslation } from "react-i18next";
|
||||
import { Link } from "react-router-dom";
|
||||
import PhoneFormatter from "../../utils/PhoneFormatter";
|
||||
import { alphaSort } from "../../utils/sorters";
|
||||
import { withRouter } from "react-router-dom";
|
||||
|
||||
export default function JobsList({
|
||||
export default withRouter(function JobsList({
|
||||
loading,
|
||||
jobs,
|
||||
selectedJob,
|
||||
setSelectedJob
|
||||
setSelectedJob,
|
||||
history
|
||||
}) {
|
||||
const [state, setState] = useState({
|
||||
sortedInfo: {},
|
||||
@@ -182,6 +184,7 @@ export default function JobsList({
|
||||
if (record) {
|
||||
if (record.id) {
|
||||
setSelectedJob(record.id);
|
||||
history.push(`#${record.id}`);
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -222,4 +225,4 @@ export default function JobsList({
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user