Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 19 additions & 1 deletion src/pages/sponsors/show-pages-list-page/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ import CustomAlert from "../../../components/mui/custom-alert";
import MuiTable from "../../../components/mui/table/mui-table";
import GlobalPagePopup from "./components/global-page/global-page-popup";
import PageTemplatePopup from "../../sponsors-global/page-templates/page-template-popup";
import SearchInput from "../../../components/mui/search-input";
import { DEFAULT_CURRENT_PAGE, MAX_PER_PAGE } from "../../../utils/constants";

const ShowPagesListPage = ({
Expand Down Expand Up @@ -104,6 +105,17 @@ const ShowPagesListPage = ({
);
};

const handleSearch = (searchTerm) => {
getShowPages(
searchTerm,
DEFAULT_CURRENT_PAGE,
perPage,
order,
orderDir,
hideArchived
);
};

const handleSaveShowPage = (entity) => {
saveShowPage(entity).then(() => {
setOpenPopup(null);
Expand Down Expand Up @@ -199,7 +211,13 @@ const ShowPagesListPage = ({
/>
</FormGroup>
</Grid2>
<Grid2 size={2} />
<Grid2 size={2}>
<SearchInput
term={term}
onSearch={handleSearch}
placeholder={T.translate("show_pages.placeholders.search")}
/>
</Grid2>
<Grid2 size={3}>
<Button
variant="contained"
Expand Down
Loading