|
|
@ -94,7 +94,27 @@ const BasicTable = () => { |
|
|
|
{/* search box */} |
|
|
|
{/* search box */} |
|
|
|
<GlobalFilter filter={globalFilter} setFilter={setGlobalFilter} /> |
|
|
|
<GlobalFilter filter={globalFilter} setFilter={setGlobalFilter} /> |
|
|
|
{/* pagination */} |
|
|
|
{/* pagination */} |
|
|
|
<div className="border border-blue-400 rounded p-1" style={{}}> |
|
|
|
<div |
|
|
|
|
|
|
|
className="border border-blue-400 rounded p-1 flex flex-items-center" |
|
|
|
|
|
|
|
style={{}} |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
{/* go to page */} |
|
|
|
|
|
|
|
<div> |
|
|
|
|
|
|
|
<input |
|
|
|
|
|
|
|
className="ml-1 text-xs" |
|
|
|
|
|
|
|
type="number" |
|
|
|
|
|
|
|
defaultValue={pageIndex + 1} |
|
|
|
|
|
|
|
onChange={(e) => { |
|
|
|
|
|
|
|
const pageNumber = e.target.value |
|
|
|
|
|
|
|
? Number(e.target.value) - 1 |
|
|
|
|
|
|
|
: 0; |
|
|
|
|
|
|
|
gotoPage(pageNumber); |
|
|
|
|
|
|
|
}} |
|
|
|
|
|
|
|
style={{ width: "50px" }} |
|
|
|
|
|
|
|
/> |
|
|
|
|
|
|
|
<span className="text-sm"> برو به صفحه </span> |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
{/* arrows */} |
|
|
|
<button |
|
|
|
<button |
|
|
|
className="rounded py-1 px-2 mx-1 text-xs" |
|
|
|
className="rounded py-1 px-2 mx-1 text-xs" |
|
|
|
style={{ backgroundColor: "#F5F9FF", color: "#65A9FF" }} |
|
|
|
style={{ backgroundColor: "#F5F9FF", color: "#65A9FF" }} |
|
|
@ -240,21 +260,6 @@ const BasicTable = () => { |
|
|
|
{""} |
|
|
|
{""} |
|
|
|
</span> |
|
|
|
</span> |
|
|
|
|
|
|
|
|
|
|
|
<span> |
|
|
|
|
|
|
|
| Go to Page:{" "} |
|
|
|
|
|
|
|
<input |
|
|
|
|
|
|
|
type="number" |
|
|
|
|
|
|
|
defaultValue={pageIndex + 1} |
|
|
|
|
|
|
|
onChange={(e) => { |
|
|
|
|
|
|
|
const pageNumber = e.target.value |
|
|
|
|
|
|
|
? Number(e.target.value) - 1 |
|
|
|
|
|
|
|
: 0; |
|
|
|
|
|
|
|
gotoPage(pageNumber); |
|
|
|
|
|
|
|
}} |
|
|
|
|
|
|
|
style={{ width: "50px" }} |
|
|
|
|
|
|
|
/> |
|
|
|
|
|
|
|
</span> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<select |
|
|
|
<select |
|
|
|
value={pageSize} |
|
|
|
value={pageSize} |
|
|
|
onChange={(e) => setPageSize(Number(e.target.value))} |
|
|
|
onChange={(e) => setPageSize(Number(e.target.value))} |
|
|
|