Navigate to "Projects" Page Should Display Only Message When No Projects Are Assigned. #237

Merged
vikas.nale merged 2 commits from Kartik_Bug#650 into Issues_July_2W 2025-07-10 05:22:26 +00:00
3 changed files with 146 additions and 136 deletions
Showing only changes of commit 588104a9dd - Show all commits

View File

@ -2553,7 +2553,7 @@ progress {
} }
.table-responsive { .table-responsive {
overflow-x: auto; /* overflow-x: auto; */
-webkit-overflow-scrolling: touch; -webkit-overflow-scrolling: touch;
} }

View File

@ -2436,7 +2436,7 @@ progress {
} }
.table-responsive { .table-responsive {
overflow-x: auto; /* overflow-x: auto; */
-webkit-overflow-scrolling: touch; -webkit-overflow-scrolling: touch;
} }

View File

@ -316,13 +316,8 @@ const ProjectList = () => {
)} )}
{listView ? ( {listView ? (
currentItems.length === 0 ? (
<div className="text-center text-muted mt-4">
No projects found.
</div>
) : (
<div className="card cursor-pointer"> <div className="card cursor-pointer">
<div className="card-body p-2"> <div className="card-body p-2" style={{ minHeight: "200px" }}>
<div className="table-responsive text-nowrap py-2"> <div className="table-responsive text-nowrap py-2">
<table className="table m-3"> <table className="table m-3">
<thead> <thead>
@ -379,27 +374,46 @@ const ProjectList = () => {
</div> </div>
</th> </th>
<th <th
className={`mx-2 ${HasManageProject ? "d-sm-table-cell" : "d-none" className={`mx-2 ${
HasManageProject ? "d-sm-table-cell" : "d-none"
}`} }`}
> >
Action Action
</th> </th>
</tr> </tr>
</thead> </thead>
<tbody className="table-border-bottom-0 overflow-auto"> <tbody className="table-border-bottom-0" style={{ height: "200px" }}>
{currentItems.map((project) => ( {currentItems.length === 0 ? (
<tr>
<td
colSpan="12"
className="text-center"
style={{
verticalAlign: "middle",
height: "200px",
paddingTop: 0,
paddingBottom: 0,
}}
>
<div className="d-flex flex-column justify-content-center align-items-center h-100">
<p className="mb-0">No projects found</p>
</div>
</td>
</tr>
) : (
currentItems.map((project) => (
<ProjectListView <ProjectListView
key={project.id} key={project.id}
projectData={project} projectData={project}
recall={sortingProject} recall={sortingProject}
/> />
))} ))
)}
</tbody> </tbody>
</table> </table>
</div> </div>
</div> </div>
</div> </div>
)
) : ( ) : (
<div className="row"> <div className="row">
{currentItems.map((project) => ( {currentItems.map((project) => (
@ -412,7 +426,6 @@ const ProjectList = () => {
</div> </div>
)} )}
{!loading && totalPages > 1 && ( {!loading && totalPages > 1 && (
<nav> <nav>
<ul className="pagination pagination-sm justify-content-end py-2"> <ul className="pagination pagination-sm justify-content-end py-2">
@ -437,11 +450,7 @@ const ProjectList = () => {
</button> </button>
</li> </li>
))} ))}
<li <li className={`page-item ${currentPage === totalPages && "disabled"}`}>
className={`page-item ${
currentPage === totalPages && "disabled"
}`}
>
<button <button
className="page-link" className="page-link"
onClick={() => onClick={() =>
@ -454,6 +463,7 @@ const ProjectList = () => {
</ul> </ul>
</nav> </nav>
)} )}
</div> </div>
</> </>
); );