Skip to content

Commit

Permalink
Merge pull request #265 from sohailamjad12/issue_jul9
Browse files Browse the repository at this point in the history
conflict resolved
  • Loading branch information
vishnubansaltarento authored Jul 9, 2024
2 parents 1b42bbe + 6128ad4 commit 17e4d66
Show file tree
Hide file tree
Showing 8 changed files with 497 additions and 303 deletions.
Original file line number Diff line number Diff line change
@@ -1,143 +1,153 @@
<div class="nav-container" autosize name="auth-tool-exp">
<div class="nav-container">

<div class="dashbord-sidenav">
<h2>{{'All Request'}}</h2>
<div class="status-cards">
<mat-card class="status-card" *ngFor="let card of statusCards">
<div class="card-content">
<div class="status-title">
<span class="title-text"> {{ card?.value=== statusKey.fullfill ? 'Fulfilled' : card?.value }}</span>
<mat-icon class="info-icon cursor-pointer" [matTooltip]="card?.message" matTooltipClass="tooltip-sec">info</mat-icon>
</div>
<div class="status-value">{{ card?.count ? card?.count : 0 }}</div>
</div>
</mat-card>


</div>
<div class="nav-container" autosize name="auth-tool-exp">
<div class="nav-container">

<div class="dashbord-sidenav">
<h2>{{'All Request'}}</h2>
<div class="status-cards">
<mat-card class="status-card" *ngFor="let card of statusCards">
<div class="card-content">
<div class="status-title">
<span class="title-text"> {{ card?.value=== statusKey.fullfill ? 'Fulfilled' : card?.value }}</span>
<mat-icon class="info-icon cursor-pointer" [matTooltip]="card?.message"
matTooltipClass="tooltip-sec">info</mat-icon>
</div>
<div class="nav-container">
<div class="sidenav-content">
<div class="table-class">
<ng-container *ngIf="dataSource?.filteredData?.length > 0">
<table mat-table [dataSource]="dataSource">
<ng-container matColumnDef="RequestId">
<th mat-header-cell *matHeaderCellDef class="row-heading">Request ID </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.demand_id}}</td>
</ng-container>

<ng-container matColumnDef="title">
<th mat-header-cell *matHeaderCellDef class="row-heading">Title </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.title}}</td>
</ng-container>

<ng-container matColumnDef="requestedBy">
<th mat-header-cell *matHeaderCellDef class="row-heading">Requested By </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.ownerOrgName}}</td>
</ng-container>

<ng-container matColumnDef="requestType">
<th mat-header-cell *matHeaderCellDef class="row-heading">Request Type </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.requestType}}</td>
</ng-container>

<ng-container matColumnDef="requestStatus">
<th mat-header-cell *matHeaderCellDef class="row-heading">Request Status </th>
<td mat-cell class="title-class" *matCellDef="let element">
<span [ngClass]="getStatusClass(element?.status)">{{element?.status}}</span></td>
</ng-container>

<ng-container matColumnDef="assignee">
<th mat-header-cell *matHeaderCellDef class="row-heading">Assignee </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.assignedProvider ? element?.assignedProvider : 'Not Assigned'}}</td>
</ng-container>

<ng-container matColumnDef="requestedOn">
<th mat-header-cell *matHeaderCellDef class="row-heading">Requested On </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.createdOn | date}}</td>
</ng-container>

<ng-container matColumnDef="interests">
<th mat-header-cell *matHeaderCellDef class="row-heading">Interests</th>
<td mat-cell class="title-class" *matCellDef="let element">
<a class="action-btn-view" *ngIf="element?.interestCount!== 0"
href="javascript:void(0)" [ngStyle]="getPointerEventsStyle(element)">
<span (click)="handleClick(element)">
{{element?.interestCount}}
</span>
</a>
<a class="" *ngIf="element?.interestCount === 0"
href="javascript:void(0)">{{element?.requestType == 'Single' ? 'N/A' : element?.interestCount}}</a>
</td>
</ng-container>

<ng-container matColumnDef="details">
<th mat-header-cell *matHeaderCellDef class="row-heading">Details</th>
<td mat-cell *matCellDef="let element">
<mat-icon (click)="navigateToDetails(element?.demand_id)" class="cursor-pointer">visibility</mat-icon>
</td>
</ng-container>

<ng-container matColumnDef="action">
<th mat-header-cell *matHeaderCellDef class="row-heading"></th>
<td mat-cell *matCellDef="let element">

<!-- <a class="action-btn-view" *ngIf="element.status === 'Unassigned'" (click)="showInterestPopup()"
<div class="status-value">{{ card?.count ? card?.count : 0 }}</div>
</div>
</mat-card>


</div>
</div>
<div class="nav-container">
<div class="sidenav-content">
<div class="table-class">
<ng-container *ngIf="dataSource?.filteredData?.length > 0">
<table mat-table [dataSource]="dataSource">
<ng-container matColumnDef="RequestId">
<th mat-header-cell *matHeaderCellDef class="row-heading">Request ID </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.demand_id}}</td>
</ng-container>

<ng-container matColumnDef="title">
<th mat-header-cell *matHeaderCellDef class="row-heading">Title </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.title}}</td>
</ng-container>

<ng-container matColumnDef="requestedBy">
<th mat-header-cell *matHeaderCellDef class="row-heading">Requested By </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.ownerOrgName}}</td>
</ng-container>

<ng-container matColumnDef="requestType">
<th mat-header-cell *matHeaderCellDef class="row-heading">Request Type </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.requestType}}</td>
</ng-container>

<ng-container matColumnDef="requestStatus">
<th mat-header-cell *matHeaderCellDef class="row-heading">Request Status </th>
<td mat-cell class="title-class" *matCellDef="let element">
<span [ngClass]="getStatusClass(element?.status)">{{element?.status === statusKey.fullfill ?
'Fulfilled'
: element?.status}}</span>
</td>
</ng-container>

<ng-container matColumnDef="assignee">
<th mat-header-cell *matHeaderCellDef class="row-heading">Assignee </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.assignedProvider ?
element?.assignedProvider : 'Not Assigned'}}</td>
</ng-container>

<ng-container matColumnDef="requestedOn">
<th mat-header-cell *matHeaderCellDef class="row-heading">Requested On </th>
<td mat-cell class="title-class" *matCellDef="let element">{{element?.createdOn | date}}</td>
</ng-container>

<ng-container matColumnDef="interests">
<th mat-header-cell *matHeaderCellDef class="row-heading">Interests</th>
<td mat-cell class="title-class" *matCellDef="let element">
<a class="action-btn-view" *ngIf="element?.interestCount!== 0" href="javascript:void(0)"
[ngStyle]="getPointerEventsStyle(element)">
<span (click)="handleClick(element)">
{{element?.interestCount}}
</span>
</a>
<a class="" *ngIf="element?.interestCount === 0" href="javascript:void(0)">{{element?.requestType ==
'Single' ? 'N/A' : element?.interestCount}}</a>
</td>
</ng-container>

<ng-container matColumnDef="details">
<th mat-header-cell *matHeaderCellDef class="row-heading">Details</th>
<td mat-cell *matCellDef="let element">
<mat-icon (click)="navigateToDetails(element?.demand_id)" class="cursor-pointer">visibility</mat-icon>
</td>
</ng-container>

<ng-container matColumnDef="action">
<th mat-header-cell *matHeaderCellDef class="row-heading"></th>
<td mat-cell *matCellDef="let element">

<!-- <a class="action-btn-view" *ngIf="element.status === 'Unassigned'" (click)="showInterestPopup()"
href="javascript:void(0)">Show
Interest</a> -->


<span>
<button mat-icon-button [matMenuTriggerFor]="menu" aria-label="Example icon-button with a menu">
<mat-icon>more_vert</mat-icon>
</button>
<mat-menu #menu="matMenu">
<button mat-menu-item (click)="onClickMenu(element,'viewContent')">
<span >View</span>
</button>
<button *ngIf="element.status === statusKey.Unassigned && element.status!== statusKey.Inprogress && element.status!== statusKey.invalid" mat-menu-item (click)="onClickMenu(element,'invalidContent')">
<span>Mark as invalid</span>
</button>
<button mat-menu-item *ngIf="element.status!== statusKey.Assigned && element.interestCount >0 && element.status!== statusKey.Inprogress && element.status!== statusKey.invalid && element?.status!==statusKey.fullfill" (click)="onClickMenu(element,'assignContent')">
<span>Assign</span>
</button>
<button *ngIf="element?.status === statusKey.Assigned && element?.status!== statusKey.Inprogress && element?.status!== statusKey.invalid && element?.status!== statusKey.fullfill"
mat-menu-item (click)="onClickMenu(element,'reAssignContent')">
<span> Re-Assign</span>
</button>
<button mat-menu-item (click)="onClickMenu(element,'copyContent')">
<span>Copy</span>
</button>
</mat-menu>
</span>
</td>


</ng-container>

<tr mat-header-row *matHeaderRowDef="displayedColumns" class="table-row-data"></tr>
<tr mat-row *matRowDef="let row;columns:displayedColumns"></tr>


</table>
<span>
<button mat-icon-button [matMenuTriggerFor]="menu" aria-label="Example icon-button with a menu">
<mat-icon>more_vert</mat-icon>
</button>
<mat-menu #menu="matMenu">
<button mat-menu-item (click)="onClickMenu(element,'viewContent')">
<span>View</span>
</button>
<button
*ngIf="element.status === statusKey.Unassigned && element.status!== statusKey.Inprogress && element.status!== statusKey.invalid"
mat-menu-item (click)="onClickMenu(element,'invalidContent')">
<span>Mark as invalid</span>
</button>
<button mat-menu-item
*ngIf="element.status!== statusKey.Assigned && element.interestCount >0 && element.status!== statusKey.Inprogress && element.status!== statusKey.invalid && element?.status!==statusKey.fullfill"
(click)="onClickMenu(element,'assignContent')">
<span>Assign</span>
</button>
<button
*ngIf="element?.status === statusKey.Assigned && element?.status!== statusKey.Inprogress && element?.status!== statusKey.invalid && element?.status!== statusKey.fullfill"
mat-menu-item (click)="onClickMenu(element,'reAssignContent')">
<span> Re-Assign</span>
</button>
<button mat-menu-item (click)="onClickMenu(element,'copyContent')">
<span>Copy</span>
</button>
</mat-menu>
</span>
</td>


</ng-container>
<div class="no-cbp-data" *ngIf="dataSource?.filteredData?.length === 0">
<!-- <div><img src="/spv-assets/icons/no-content-data.svg" alt="No request made yet"></div> -->
<!-- <div class="mat-subheading-1 margin-remove">No CBP plan created yet</div> -->
<div class="not-found">No request made yet</div>


</div>
<mat-paginator [pageSize]="pageSize" [length]="this.requestCount" [pageSizeOptions]="[10,20,40]"
(page)="onChangePage($event)"></mat-paginator>


</div>



</div>
</div>

<tr mat-header-row *matHeaderRowDef="displayedColumns" class="table-row-data"></tr>
<tr mat-row *matRowDef="let row;columns:displayedColumns"></tr>


</table>
</ng-container>
<div class="no-cbp-data" *ngIf="dataSource?.filteredData?.length === 0">
<!-- <div><img src="/spv-assets/icons/no-content-data.svg" alt="No request made yet"></div> -->
<!-- <div class="mat-subheading-1 margin-remove">No CBP plan created yet</div> -->
<div class="not-found">No request made yet</div>


</div>
<mat-paginator [pageSize]="pageSize" [length]="this.requestCount" [pageSizeOptions]="[10,20,40]"
(page)="onChangePage($event)"></mat-paginator>


</div>
</div>



</div>
</div>
</div>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -163,12 +163,12 @@ export class AllRequestComponent implements OnInit {

}

getPointerEventsStyle(element:any){
getPointerEventsStyle(element: any) {
return {
'pointer-events': (element.status !== this.statusKey.Inprogress &&
element.status !== this.statusKey.invalid &&
'pointer-events': (element.status !== this.statusKey.Inprogress &&
element.status !== this.statusKey.invalid &&
element.status !== this.statusKey.fullfill) ? 'auto' : 'none',

}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,6 @@ export class RequestCopyDetailsComponent implements OnInit {
this.router.navigateByUrl('/app/home/all-request')
}


valuechangeFuctions() {
if (this.requestForm.controls['providerText']) {
this.requestForm.controls['providerText'].valueChanges.pipe(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,16 @@
</div>
</div>
<ng-container>
<ws-widget-ui-user-table [tableData]='tabledata' [data]='data' isUpload=true isCreate=true
<!-- <ws-widget-ui-user-table [tableData]='tabledata' [data]='data' isUpload=true isCreate=true
[currentTabData]='currentFilter' [needCreateUser]="true" (eOnCreateClick)="onCreateClick()"
(searchByEnterKey)="onEnterkySearch($event)" (actionsClick)="menuActions($event)">
</ws-widget-ui-user-table>
</ws-widget-ui-user-table> -->

<ws-widget-org-user-table-v2 [tableData]="tabledata" [data]="dataForTable" [isUpload]=true [isCreate]=true
(eOnCreateClick)="onCreateClick()" (actionsClick)="menuActions($event)"
(searchByEnterKey)="onEnterkySearch($event)" (pageChangeClick)="onPaginateChange($event)"
[showEditOnCondition]=true [totalRecords]="userDataTotalCount" [tabChangeIndex]="pageIndex">
</ws-widget-org-user-table-v2>
</ng-container>
</mat-card-content>
</mat-card>
Expand Down
Loading

0 comments on commit 17e4d66

Please sign in to comment.