diff --git a/src/app/app-routing.module.ts b/src/app/app-routing.module.ts
index c826994cf..07c7d09ca 100644
--- a/src/app/app-routing.module.ts
+++ b/src/app/app-routing.module.ts
@@ -125,6 +125,14 @@ import { DelegatedUserActivationComponent } from './pages/manage-delegated/landi
import { DelegatedOrganisationComponent } from './pages/manage-delegated/user/delegated-organisation/delegated-organisation.component';
import { TermsConditionsComponent } from './components/terms-conditions/terms-conditions.component';
import { ForgotPasswordErrorComponent } from './pages/forgot-password-error/forgot-password-error.component';
+import { BuyerBothRequestsComponent } from './pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component';
+import { ConfirmDeclineComponent } from './pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component';
+import { BuyerBothRequestsSuccessComponent } from './pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component';
+import { ConfirmAcceptComponent } from './pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component';
+import { ViewPendingVerificationComponent } from './pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component';
+import { ViewVerifiedOrgComponent } from './pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component';
+import { RemoveRightToBuyComponent } from './pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component';
+import { SuccessRightToBuyComponent } from './pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component';
const routes: Routes = [
{ path: '', redirectTo: 'home', pathMatch: 'full' },
@@ -1009,6 +1017,53 @@ const routes: Routes = [
pathMatch: 'full',
component: DelegatedErrorComponent,
},
+ {
+ path: 'manage-buyer-both',
+ data: { title: 'Manage Buyer status Requests' },
+ pathMatch: 'full',
+ component: BuyerBothRequestsComponent,
+ },
+ {
+ path: 'confirm-decline',
+ data: { title: 'Decline right to buy status' },
+ pathMatch: 'full',
+ component: ConfirmDeclineComponent,
+ },
+ {
+ path: 'confirm-accept',
+ data: { title: 'Approve right to buy status' },
+ pathMatch: 'full',
+ component: ConfirmAcceptComponent,
+ },
+ {
+ path: 'pending-verification',
+ data: { title: 'Manage Buyer status requests - View request' },
+ pathMatch: 'full',
+ component: ViewPendingVerificationComponent,
+ },
+ {
+ path: 'verified-organisations',
+ data: { title: 'Manage Buyer status requests - View Buyer status for the organisation' },
+ pathMatch: 'full',
+ component: ViewVerifiedOrgComponent,
+ },
+ {
+ path: 'remove-right-to-buy',
+ data: { title: 'Remove right to buy status' },
+ pathMatch: 'full',
+ component: RemoveRightToBuyComponent,
+ },
+ {
+ path: 'remove-right-to-buy-success',
+ data: { title: 'Remove right to buy status – success' },
+ pathMatch: 'full',
+ component: SuccessRightToBuyComponent,
+ },
+ {
+ path: 'buyer-and-both-success',
+ pathMatch: 'full',
+ component: BuyerBothRequestsSuccessComponent,
+ },
{
path: 'terms-of-use',
data: { title: 'Terms of Use' },
diff --git a/src/app/app.module.ts b/src/app/app.module.ts
index 814e54f95..b909ac681 100644
--- a/src/app/app.module.ts
+++ b/src/app/app.module.ts
@@ -175,6 +175,14 @@ import { DelegatedUserActivationComponent } from './pages/manage-delegated/landi
import { DelegatedOrganisationComponent } from './pages/manage-delegated/user/delegated-organisation/delegated-organisation.component';
import { TermsConditionsComponent } from './components/terms-conditions/terms-conditions.component';
import { ForgotPasswordErrorComponent } from './pages/forgot-password-error/forgot-password-error.component';
+import { BuyerBothRequestsComponent } from './pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component';
+import { ConfirmDeclineComponent } from './pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component';
+import { BuyerBothRequestsSuccessComponent } from './pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component';
+import { ConfirmAcceptComponent } from './pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component';
+import { ViewPendingVerificationComponent } from './pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component';
+import { ViewVerifiedOrgComponent } from './pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component';
+import { RemoveRightToBuyComponent } from './pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component';
+import { SuccessRightToBuyComponent } from './pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component';
export function HttpLoaderFactory(http: HttpClient) {
return new TranslateHttpLoader(http);
@@ -315,7 +323,15 @@ export function createTranslateLoader(http: HttpClient) {
DelegatedUserActivationComponent,
DelegatedOrganisationComponent,
TermsConditionsComponent,
- ForgotPasswordErrorComponent
+ ForgotPasswordErrorComponent,
+ BuyerBothRequestsComponent,
+ ConfirmDeclineComponent,
+ BuyerBothRequestsSuccessComponent,
+ ConfirmAcceptComponent,
+ ViewPendingVerificationComponent,
+ ViewVerifiedOrgComponent,
+ RemoveRightToBuyComponent,
+ SuccessRightToBuyComponent
],
imports: [
// BrowserModule,
diff --git a/src/app/components/govuk-table/govuk-table.component.html b/src/app/components/govuk-table/govuk-table.component.html
index 23eae8651..bd1f2af41 100644
--- a/src/app/components/govuk-table/govuk-table.component.html
+++ b/src/app/components/govuk-table/govuk-table.component.html
@@ -20,7 +20,7 @@
? 'navigation-text'
: ''
]">
- {{ dataKey == 'endDate' ? (dataRow[dataKey] | date: 'dd/MM/yyyy') : dataRow[dataKey] }}
+ {{ dataKey == 'endDate' ? (dataRow[dataKey] | date: 'dd/MM/yyyy') : dataKey == 'dateofRegistration' ? (dataRow[dataKey] | date: 'dd/MM/yyyy') : dataRow[dataKey] }}
@@ -29,7 +29,7 @@
diff --git a/src/app/pages/home/home.component.ts b/src/app/pages/home/home.component.ts
index 96aca7572..fdfd825cc 100644
--- a/src/app/pages/home/home.component.ts
+++ b/src/app/pages/home/home.component.ts
@@ -202,9 +202,13 @@ export class HomeComponent extends BaseComponent implements OnInit {
description: 'Support for users of other organisations',
route: '/org-support/search',
});
+ this.otherModules.push({
+ name: 'Manage Buyer status requests',
+ description: 'Verify and approve or decline Buyer status requests',
+ route: '/manage-buyer-both',
+ });
}
}
-
}
getModuleElementId(moduleName: string) {
diff --git a/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.html b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.html
new file mode 100644
index 000000000..fae05b78e
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.html
@@ -0,0 +1,28 @@
+
+
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.scss b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.scss
new file mode 100644
index 000000000..0508548eb
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.scss
@@ -0,0 +1,16 @@
+.header-bread-align {
+ margin-bottom: 30px !important;
+ margin-top: 30px !important;
+ }
+ .header-bread-align {
+ margin-bottom: 30px !important;
+ margin-top: 30px !important;
+ }
+ .navigation-text{
+ margin-bottom: 100px;
+ font-size: 19px;
+ color: #005ea5;
+}
+a {
+ text-decoration: underline;
+}
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.spec.ts b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.spec.ts
new file mode 100644
index 000000000..39d278eef
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.spec.ts
@@ -0,0 +1,25 @@
+import { ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { BuyerBothRequestsSuccessComponent } from './buyer-both-requests-success.component';
+
+describe('BuyerBothRequestsSuccessComponent', () => {
+ let component: BuyerBothRequestsSuccessComponent;
+ let fixture: ComponentFixture
;
+
+ beforeEach(async () => {
+ await TestBed.configureTestingModule({
+ declarations: [ BuyerBothRequestsSuccessComponent ]
+ })
+ .compileComponents();
+ });
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(BuyerBothRequestsSuccessComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
diff --git a/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.ts b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.ts
new file mode 100644
index 000000000..6504bbe46
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests-success/buyer-both-requests-success.component.ts
@@ -0,0 +1,46 @@
+import { Component, OnInit } from '@angular/core';
+import { Title } from '@angular/platform-browser';
+import { ActivatedRoute, Router } from '@angular/router';
+
+@Component({
+ selector: 'app-buyer-both-requests-success',
+ templateUrl: './buyer-both-requests-success.component.html',
+ styleUrls: ['./buyer-both-requests-success.component.scss'],
+})
+export class BuyerBothRequestsSuccessComponent implements OnInit {
+ public routeDetails:any;
+ constructor(private route: ActivatedRoute, private router: Router, private titleService: Title) {
+ this.route.queryParams.subscribe((para: any) => {
+ this.routeDetails = JSON.parse(atob(para.data));
+ console.log("this.routeDetails",this.routeDetails)
+ switch (this.routeDetails.status) {
+ case "accept": {
+ this.titleService.setTitle(
+ `${ 'Accept right to buy status – success' } - CCS`
+ );
+ break;
+ }
+ case 'decline': {
+ this.titleService.setTitle(
+ `${ 'Decline right to buy status – success' } - CCS`
+ );
+ break;
+ }
+ default: {
+ //statements;
+ break;
+ }
+ }
+ });
+ }
+
+ ngOnInit(): void {}
+
+ public returnToRequests() {
+ this.router.navigateByUrl('manage-buyer-both');
+ }
+
+ public returnToDashBoard() {
+ this.router.navigateByUrl('home');
+ }
+}
diff --git a/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.html b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.html
new file mode 100644
index 000000000..af74ed29f
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.html
@@ -0,0 +1,67 @@
+
+
+
+
+
+
+
This page allows you to approve or decline the Buyer status requests for organisations
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.scss b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.scss
new file mode 100644
index 000000000..7ff372e4b
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.scss
@@ -0,0 +1,4 @@
+.header-bread-align {
+ margin-bottom: 30px !important;
+ margin-top: 30px !important;
+ }
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.spec.ts b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.spec.ts
new file mode 100644
index 000000000..bff1ec627
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.spec.ts
@@ -0,0 +1,25 @@
+import { ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { BuyerBothRequestsComponent } from './buyer-both-requests.component';
+
+describe('BuyerBothRequestsComponent', () => {
+ let component: BuyerBothRequestsComponent;
+ let fixture: ComponentFixture;
+
+ beforeEach(async () => {
+ await TestBed.configureTestingModule({
+ declarations: [ BuyerBothRequestsComponent ]
+ })
+ .compileComponents();
+ });
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(BuyerBothRequestsComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
diff --git a/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.ts b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.ts
new file mode 100644
index 000000000..2b52197e1
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/buyer-both-requests/buyer-both-requests.component.ts
@@ -0,0 +1,173 @@
+import { Component, OnInit } from '@angular/core';
+import { Router } from '@angular/router';
+import { UserListResponse } from 'src/app/models/user';
+import { WrapperBuyerBothService } from 'src/app/services/wrapper/wrapper-buyer-both.service';
+import { environment } from 'src/environments/environment';
+
+@Component({
+ selector: 'app-buyer-both-requests',
+ templateUrl: './buyer-both-requests.component.html',
+ styleUrls: ['./buyer-both-requests.component.scss'],
+})
+export class BuyerBothRequestsComponent implements OnInit {
+ public searchText: string = '';
+ public searchSumbited: boolean = false;
+ public tabConfig = {
+ pendingOrg: true,
+ verifiedOrg: false,
+ };
+ private organisationId: string = '';
+ public pendingVerificationBuyerAndBoth: any = {
+ currentPage: 1,
+ pageCount: 0,
+ pageSize: environment.listPageSize,
+ usersTableHeaders: ['Organisation name ', 'Organisation type ', 'Date of registration'],
+ usersColumnsToDisplay: [
+ 'organisatioName',
+ 'organisationType',
+ 'dateofRegistration',
+ ],
+ userList: '',
+ pageName: 'Contactadmin',
+ hyperTextrray: ['Decline', 'Accept', 'View'],
+ };
+
+ public verifiedBuyerAndBoth: any = {
+ currentPage: 1,
+ pageCount: 0,
+ pageSize: environment.listPageSize,
+ usersTableHeaders: ['Organisation name ', 'Organisation type ', 'Date of registration'],
+ usersColumnsToDisplay: [
+ 'organisatioName',
+ 'organisationType',
+ 'dateofRegistration',
+ ],
+ userList: '',
+ pageName: 'Contactadmin',
+ hyperTextrray: ['View'],
+ };
+ constructor(
+ private router: Router,
+ private wrapperBuyerAndBothService:WrapperBuyerBothService,
+ ) {
+ this.organisationId = localStorage.getItem('cii_organisation_id') || '';
+ this.pendingVerificationBuyerAndBoth.userList = {
+ currentPage: this.pendingVerificationBuyerAndBoth.currentPage,
+ pageCount: 0,
+ rowCount: 0,
+ organisationId: this.organisationId,
+ userList: [],
+ };
+ this.verifiedBuyerAndBoth.userList = {
+ currentPage: this.pendingVerificationBuyerAndBoth.currentPage,
+ pageCount: 0,
+ rowCount: 0,
+ organisationId: this.organisationId,
+ userList: [],
+ };
+ }
+
+ ngOnInit() {
+ this.tabChanged(sessionStorage.getItem('activetab') || 'pendingOrg');
+ this.getPendingVerificationOrg();
+ }
+
+ public onSearchClick(): void {
+ this.searchSumbited = true;
+ this.getPendingVerificationOrg();
+ }
+
+ public onLinkClick(data: any): void {
+ if (data.event.target.innerText === 'Decline') {
+ this.router.navigateByUrl(
+ 'confirm-decline?data=' + btoa(JSON.stringify(data))
+ );
+ } else if (data.event.target.innerText === 'Accept') {
+ this.router.navigateByUrl(
+ 'confirm-accept?data=' + btoa(JSON.stringify(data))
+ );
+ } else {
+ this.router.navigateByUrl(
+ 'pending-verification?data=' + btoa(JSON.stringify(data))
+ );
+ }
+ }
+
+ public OnClickView(event: any) {
+ let data = {
+ header: 'View expired delegated access',
+ Description: '',
+ Breadcrumb: 'View expired delegated access',
+ status: '003',
+ event: event,
+ };
+ this.router.navigateByUrl(
+ 'verified-organisations?data=' + btoa(JSON.stringify(data))
+ );
+ }
+
+ setPagecurrentUsers(pageNumber: any) {
+ this.pendingVerificationBuyerAndBoth.currentPage = pageNumber;
+ this.getPendingVerificationOrg();
+ }
+
+ setPageexpiredUsers(pageNumber: any) {
+ this.verifiedBuyerAndBoth.currentPage = pageNumber;
+ this.geVerifiedOrg();
+ }
+
+ getPendingVerificationOrg() {
+ this.wrapperBuyerAndBothService.getpendingVerificationOrg(
+ this.organisationId,
+ this.searchText,
+ this.pendingVerificationBuyerAndBoth.currentPage,
+ this.pendingVerificationBuyerAndBoth.pageSize
+ ).subscribe({
+ next: (userListResponse: UserListResponse) => {
+ if (userListResponse != null) {
+ this.pendingVerificationBuyerAndBoth.userList = userListResponse;
+ this.pendingVerificationBuyerAndBoth.pageCount =
+ this.pendingVerificationBuyerAndBoth.userList.pageCount;
+ }
+ this.geVerifiedOrg()
+ },
+ error: (error: any) => {
+ // this.router.navigateByUrl('delegated-error');
+ },
+ });
+ }
+
+ geVerifiedOrg() {
+ this.wrapperBuyerAndBothService.getVerifiedOrg(
+ this.organisationId,
+ this.searchText,
+ this.verifiedBuyerAndBoth.currentPage,
+ this.verifiedBuyerAndBoth.pageSize
+ ).subscribe({
+ next: (userListResponse: UserListResponse) => {
+ if (userListResponse != null) {
+ this.verifiedBuyerAndBoth.userList = userListResponse;
+ this.verifiedBuyerAndBoth.pageCount =
+ this.verifiedBuyerAndBoth.userList.pageCount;
+ }
+ },
+ error: (error: any) => {
+ this.router.navigateByUrl('delegated-error');
+ },
+ });
+ }
+
+ public tabChanged(activetab: string): void {
+ if (activetab === 'verifiedOrg') {
+ this.tabConfig.pendingOrg = false;
+ this.tabConfig.verifiedOrg = true;
+ } else {
+ this.tabConfig.pendingOrg = true;
+ this.tabConfig.verifiedOrg = false;
+ }
+ }
+
+ ngOnDestroy(): void {
+ sessionStorage.removeItem('activetab');
+ }
+}
diff --git a/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.html b/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.html
new file mode 100644
index 000000000..03744952e
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.html
@@ -0,0 +1,37 @@
+
+
+
+
+
+
+
+ The organisation administrator(s) will be notified that the right to buy status was approved for the organisation
+
+
+
+ Approve
+
+
+ Cancel
+
+
+
+
+
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.scss b/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.scss
new file mode 100644
index 000000000..7ff372e4b
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.scss
@@ -0,0 +1,4 @@
+.header-bread-align {
+ margin-bottom: 30px !important;
+ margin-top: 30px !important;
+ }
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.spec.ts b/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.spec.ts
new file mode 100644
index 000000000..223a9d2fa
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.spec.ts
@@ -0,0 +1,25 @@
+import { ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { ConfirmAcceptComponent } from './confirm-accept.component';
+
+describe('ConfirmAcceptComponent', () => {
+ let component: ConfirmAcceptComponent;
+ let fixture: ComponentFixture
;
+
+ beforeEach(async () => {
+ await TestBed.configureTestingModule({
+ declarations: [ ConfirmAcceptComponent ]
+ })
+ .compileComponents();
+ });
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(ConfirmAcceptComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
diff --git a/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.ts b/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.ts
new file mode 100644
index 000000000..458cfbfd5
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/confirm-accept/confirm-accept.component.ts
@@ -0,0 +1,45 @@
+import { Component, OnInit } from '@angular/core';
+import { ActivatedRoute, Router } from '@angular/router';
+
+@Component({
+ selector: 'app-confirm-accept',
+ templateUrl: './confirm-accept.component.html',
+ styleUrls: ['./confirm-accept.component.scss']
+})
+export class ConfirmAcceptComponent implements OnInit {
+
+ private organisationId: string;
+
+ constructor(private route: ActivatedRoute, private router: Router) {
+ this.organisationId = localStorage.getItem('cii_organisation_id') || '';
+ }
+
+ ngOnInit(): void {
+ this.route.queryParams.subscribe((para: any) => {
+ let RouteData = JSON.parse(atob(para.data));
+ });
+ }
+
+ public confirm(): void {
+ // let UserSelectedinfo:any;
+ // this.DelegatedService.createDelegatedUser(UserSelectedinfo).subscribe({
+ // next: (roleListResponse: any) => {
+ // this.router.navigateByUrl('buyer-and-both-success');
+ // },
+ // error: (error: any) => {
+ // this.route.navigateByUrl('delegated-error')
+ // },
+ // });
+ let data = {
+ status: 'accept',
+ };
+ this.router.navigateByUrl(
+ 'buyer-and-both-success?data=' + btoa(JSON.stringify(data))
+ );
+ }
+
+ public Back(): void {
+ window.history.back();
+ }
+
+}
diff --git a/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.html b/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.html
new file mode 100644
index 000000000..84a41b2c0
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.html
@@ -0,0 +1,37 @@
+
+
+
+
+
+
+
+ The organisation’s administrator(s) will be notified that the right to buy status was declined.
+
+
+
+ Decline
+
+
+ Cancel
+
+
+
+
+
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.scss b/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.scss
new file mode 100644
index 000000000..7ff372e4b
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.scss
@@ -0,0 +1,4 @@
+.header-bread-align {
+ margin-bottom: 30px !important;
+ margin-top: 30px !important;
+ }
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.spec.ts b/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.spec.ts
new file mode 100644
index 000000000..fec4712f4
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.spec.ts
@@ -0,0 +1,25 @@
+import { ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { ConfirmDeclineComponent } from './confirm-decline.component';
+
+describe('ConfirmDeclineComponent', () => {
+ let component: ConfirmDeclineComponent;
+ let fixture: ComponentFixture
;
+
+ beforeEach(async () => {
+ await TestBed.configureTestingModule({
+ declarations: [ ConfirmDeclineComponent ]
+ })
+ .compileComponents();
+ });
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(ConfirmDeclineComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
diff --git a/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.ts b/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.ts
new file mode 100644
index 000000000..0759e3893
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/confirm-decline/confirm-decline.component.ts
@@ -0,0 +1,48 @@
+import { Component, OnInit } from '@angular/core';
+import { FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { Title } from '@angular/platform-browser';
+import { ActivatedRoute, Router } from '@angular/router';
+import { Role } from 'src/app/models/organisationGroup';
+import { WrapperOrganisationGroupService } from 'src/app/services/wrapper/wrapper-org--group-service';
+import { WrapperUserDelegatedService } from 'src/app/services/wrapper/wrapper-user-delegated.service';
+
+@Component({
+ selector: 'app-confirm-decline',
+ templateUrl: './confirm-decline.component.html',
+ styleUrls: ['./confirm-decline.component.scss'],
+})
+export class ConfirmDeclineComponent implements OnInit {
+ private organisationId: string;
+
+ constructor(private route: ActivatedRoute, private router: Router) {
+ this.organisationId = localStorage.getItem('cii_organisation_id') || '';
+ }
+
+ ngOnInit(): void {
+ this.route.queryParams.subscribe((para: any) => {
+ let RouteData = JSON.parse(atob(para.data));
+ });
+ }
+
+ public confirmAndDecline(): void {
+ // let UserSelectedinfo:any;
+ // this.DelegatedService.createDelegatedUser(UserSelectedinfo).subscribe({
+ // next: (roleListResponse: any) => {
+ // this.router.navigateByUrl('buyer-and-both-success');
+ // },
+ // error: (error: any) => {
+ // this.route.navigateByUrl('delegated-error')
+ // },
+ // });
+ let data = {
+ status: 'decline',
+ };
+ this.router.navigateByUrl(
+ 'buyer-and-both-success?data=' + btoa(JSON.stringify(data))
+ );
+ }
+
+ public Back(): void {
+ window.history.back();
+ }
+}
diff --git a/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.html b/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.html
new file mode 100644
index 000000000..f7ecf0582
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.html
@@ -0,0 +1,37 @@
+
+
+
+
+
+
+
+ The organisation administrator(s) will be notified that the right to buy status was removed for the organisation.
+
+
+
+ Confirm
+
+
+ Cancel
+
+
+
+
+
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.scss b/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.scss
new file mode 100644
index 000000000..7ff372e4b
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.scss
@@ -0,0 +1,4 @@
+.header-bread-align {
+ margin-bottom: 30px !important;
+ margin-top: 30px !important;
+ }
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.spec.ts b/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.spec.ts
new file mode 100644
index 000000000..538ceb476
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.spec.ts
@@ -0,0 +1,25 @@
+import { ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { RemoveRightToBuyComponent } from './remove-right-to-buy.component';
+
+describe('RemoveRightToBuyComponent', () => {
+ let component: RemoveRightToBuyComponent;
+ let fixture: ComponentFixture
;
+
+ beforeEach(async () => {
+ await TestBed.configureTestingModule({
+ declarations: [ RemoveRightToBuyComponent ]
+ })
+ .compileComponents();
+ });
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(RemoveRightToBuyComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
diff --git a/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.ts b/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.ts
new file mode 100644
index 000000000..e7f53170a
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/remove-right-to-buy/remove-right-to-buy.component.ts
@@ -0,0 +1,27 @@
+import { Component, OnInit } from '@angular/core';
+import { Router } from '@angular/router';
+
+@Component({
+ selector: 'app-remove-right-to-buy',
+ templateUrl: './remove-right-to-buy.component.html',
+ styleUrls: ['./remove-right-to-buy.component.scss']
+})
+export class RemoveRightToBuyComponent implements OnInit {
+
+ constructor(private router:Router) { }
+
+ ngOnInit(): void {
+ }
+
+ public Back():void {
+ window.history.back();
+ }
+ public confirm(){
+ let data = {
+ status: 'remove',
+ };
+ this.router.navigateByUrl(
+ 'remove-right-to-buy-success?data=' + btoa(JSON.stringify(data))
+ );
+ }
+}
diff --git a/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.html b/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.html
new file mode 100644
index 000000000..731bb2929
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.html
@@ -0,0 +1,29 @@
+
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.scss b/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.scss
new file mode 100644
index 000000000..4bb89446c
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.scss
@@ -0,0 +1,12 @@
+.header-bread-align {
+ margin-bottom: 30px !important;
+ margin-top: 30px !important;
+ }
+ .navigation-text{
+ margin-bottom: 100px;
+ font-size: 19px;
+ color: #005ea5;
+}
+a {
+ text-decoration: underline;
+}
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.spec.ts b/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.spec.ts
new file mode 100644
index 000000000..3f6b0a307
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.spec.ts
@@ -0,0 +1,25 @@
+import { ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { SuccessRightToBuyComponent } from './success-right-to-buy.component';
+
+describe('SuccessRightToBuyComponent', () => {
+ let component: SuccessRightToBuyComponent;
+ let fixture: ComponentFixture;
+
+ beforeEach(async () => {
+ await TestBed.configureTestingModule({
+ declarations: [ SuccessRightToBuyComponent ]
+ })
+ .compileComponents();
+ });
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(SuccessRightToBuyComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
diff --git a/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.ts b/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.ts
new file mode 100644
index 000000000..131cf528e
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/success-right-to-buy/success-right-to-buy.component.ts
@@ -0,0 +1,15 @@
+import { Component, OnInit } from '@angular/core';
+
+@Component({
+ selector: 'app-success-right-to-buy',
+ templateUrl: './success-right-to-buy.component.html',
+ styleUrls: ['./success-right-to-buy.component.scss']
+})
+export class SuccessRightToBuyComponent implements OnInit {
+
+ constructor() { }
+
+ ngOnInit(): void {
+ }
+
+}
diff --git a/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.html b/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.html
new file mode 100644
index 000000000..ccb50956f
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.html
@@ -0,0 +1,101 @@
+
+
+
+
+
+
+
+ View the details of the organisation that is pending the manual verification process for buyer status. If you want to accept this organisation as a verified buyer, please use ‘Accept buyer status’ button on the bottom of this page.
+
+
+
+
Organisation details
+
+ Organisation name:Dream Guys
+
+
+ Organisation type:Both
+
+
+ Date of registration:30-01-1997
+
+
+
+
+
Organisation Administrator(s)
+
+
+
+
Organisation registries
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 10745577
+ Primary
+
+
+
+
+
+
+
+
+
+ Accept right to buy status
+ Decline right to buy status
+
+
Cancel
+
+
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.scss b/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.scss
new file mode 100644
index 000000000..fe6cca1ea
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.scss
@@ -0,0 +1,12 @@
+.header-bread-align {
+ margin-bottom: 30px !important;
+ margin-top: 30px !important;
+ }
+ .remove_element {
+ color: transparent;
+}
+
+.navigation-text{
+ text-decoration: underline;
+ color: #005ea5;
+}
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.spec.ts b/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.spec.ts
new file mode 100644
index 000000000..e460381fa
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.spec.ts
@@ -0,0 +1,25 @@
+import { ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { ViewPendingVerificationComponent } from './view-pending-verification.component';
+
+describe('ViewPendingVerificationComponent', () => {
+ let component: ViewPendingVerificationComponent;
+ let fixture: ComponentFixture
;
+
+ beforeEach(async () => {
+ await TestBed.configureTestingModule({
+ declarations: [ ViewPendingVerificationComponent ]
+ })
+ .compileComponents();
+ });
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(ViewPendingVerificationComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
diff --git a/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.ts b/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.ts
new file mode 100644
index 000000000..7eee5f0be
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/view-pending-verification/view-pending-verification.component.ts
@@ -0,0 +1,142 @@
+import { Component, OnInit } from '@angular/core';
+import { Router } from '@angular/router';
+import { WrapperOrganisationGroupService } from 'src/app/services/wrapper/wrapper-org--group-service';
+import { environment } from 'src/environments/environment';
+
+@Component({
+ selector: 'app-view-pending-verification',
+ templateUrl: './view-pending-verification.component.html',
+ styleUrls: ['./view-pending-verification.component.scss'],
+})
+export class ViewPendingVerificationComponent implements OnInit {
+ private organisationId: string = '';
+ pageName = 'Contactadmin';
+ public organisationAdministrator = {
+ usersTableHeaders: ['Name', 'Email address', 'Role'],
+ usersColumnsToDisplay: ['name', 'email', 'role'],
+ currentPage: 1,
+ pageCount: 0,
+ pageSize: environment.listPageSize,
+ userListResponse: {
+ currentPage: 0,
+ pageCount: 0,
+ rowCount: 0,
+ organisationId: this.organisationId,
+ userList: [],
+ },
+ };
+
+ public eventLog = {
+ usersTableHeaders: ['Owner', 'Event', 'Date'],
+ usersColumnsToDisplay: ['name', 'email', 'role'],
+ currentPage: 1,
+ pageCount: 0,
+ pageSize: environment.listPageSize,
+ userListResponse: {
+ currentPage: 0,
+ pageCount: 0,
+ rowCount: 0,
+ organisationId: this.organisationId,
+ userList: [],
+ },
+ };
+
+ constructor(
+ private WrapperOrganisationGroupService: WrapperOrganisationGroupService,private router:Router
+ ) {
+ this.organisationId = localStorage.getItem('cii_organisation_id') || '';
+ this.organisationAdministrator.userListResponse = {
+ currentPage: this.organisationAdministrator.currentPage,
+ pageCount: 0,
+ rowCount: 0,
+ organisationId: this.organisationId,
+ userList: [],
+ };
+ this.eventLog.userListResponse = {
+ currentPage: this.eventLog.currentPage,
+ pageCount: 0,
+ rowCount: 0,
+ organisationId: this.organisationId,
+ userList: [],
+ };
+ }
+
+ ngOnInit() {
+ this.getOrganisationUsers();
+ }
+
+ public openEmailWindow(data: any): void {
+ let AdminEmail = 'mailto:' + data.userName;
+ window.location.href = AdminEmail;
+ }
+
+ public getOrganisationUsers() {
+ this.WrapperOrganisationGroupService.getUsersAdmin(
+ this.organisationId,
+ this.organisationAdministrator.currentPage,
+ this.organisationAdministrator.pageSize
+ ).subscribe({
+ next: (response: any) => {
+ if (response != null) {
+ this.organisationAdministrator.userListResponse = response;
+ this.organisationAdministrator.userListResponse.userList.forEach(
+ (f: any) => {
+ f.role = 'Admin';
+ f.email = f.userName; // the common component expect the field as email
+ }
+ );
+ this.organisationAdministrator.pageCount =
+ this.organisationAdministrator.userListResponse.pageCount;
+ this.getEventLogDetails()
+
+ }
+ },
+ error: (error: any) => {},
+ });
+ }
+
+ public setPageOrganisationAdministrator(pageNumber: any) {
+ this.organisationAdministrator.currentPage = pageNumber;
+ this.getOrganisationUsers();
+ }
+
+ public getEventLogDetails():void{
+ this.WrapperOrganisationGroupService.getUsersAdmin(
+ this.organisationId,
+ this.eventLog.currentPage,
+ this.eventLog.pageSize
+ ).subscribe({
+ next: (response: any) => {
+ if (response != null) {
+ this.eventLog.userListResponse = response;
+ this.eventLog.userListResponse.userList.forEach(
+ (f: any) => {
+ f.role = 'Admin';
+ f.email = f.userName; // the common component expect the field as email
+ }
+ );
+ this.eventLog.pageCount =
+ this.eventLog.userListResponse.pageCount;
+ }
+ },
+ error: (error: any) => {},
+ });
+ }
+
+ goBack() {
+ window.history.back();
+ }
+
+ public acceptRightToBuy(){
+ let data = {}
+ this.router.navigateByUrl(
+ 'confirm-accept?data=' + btoa(JSON.stringify(data))
+ );
+ }
+ public declineRightToBuy(){
+ let data = {}
+ this.router.navigateByUrl(
+ 'confirm-decline?data=' + btoa(JSON.stringify(data))
+ );
+ }
+}
diff --git a/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.html b/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.html
new file mode 100644
index 000000000..36d34eef8
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.html
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+ View details of organisations’ Buyer status
+
+
+
+
Organisation details
+
+ Organisation name:Dream Guys
+
+
+ Organisation type:Both
+
+
+ Date of registration:30-01-1997
+
+
+
+
Organisation Administrator(s)
+
+
+
+
Organisation registries
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 10745577
+ Primary
+
+
+
+
+
+
+
+
+
+ Remove right to buy status
+ Back
+
+
+
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.scss b/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.scss
new file mode 100644
index 000000000..1ca27997d
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.scss
@@ -0,0 +1,15 @@
+.header-bread-align {
+ margin-bottom: 30px !important;
+ margin-top: 30px !important;
+ }
+ .remove_element {
+ color: transparent;
+}
+
+.navigation-text{
+ text-decoration: underline;
+ color: #005ea5;
+}
+a {
+ text-decoration: underline;
+}
\ No newline at end of file
diff --git a/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.spec.ts b/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.spec.ts
new file mode 100644
index 000000000..9d0dfb697
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.spec.ts
@@ -0,0 +1,25 @@
+import { ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { ViewVerifiedOrgComponent } from './view-verified-org.component';
+
+describe('ViewVerifiedOrgComponent', () => {
+ let component: ViewVerifiedOrgComponent;
+ let fixture: ComponentFixture
;
+
+ beforeEach(async () => {
+ await TestBed.configureTestingModule({
+ declarations: [ ViewVerifiedOrgComponent ]
+ })
+ .compileComponents();
+ });
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(ViewVerifiedOrgComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
diff --git a/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.ts b/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.ts
new file mode 100644
index 000000000..30f1b6c19
--- /dev/null
+++ b/src/app/pages/manage-buyer-and-both-requests/view-verified-org/view-verified-org.component.ts
@@ -0,0 +1,140 @@
+import { Component, OnInit } from '@angular/core';
+import { Router } from '@angular/router';
+import { WrapperOrganisationGroupService } from 'src/app/services/wrapper/wrapper-org--group-service';
+import { environment } from 'src/environments/environment';
+
+@Component({
+ selector: 'app-view-verified-org',
+ templateUrl: './view-verified-org.component.html',
+ styleUrls: ['./view-verified-org.component.scss']
+})
+export class ViewVerifiedOrgComponent implements OnInit {
+ private organisationId: string = '';
+ pageName = 'Contactadmin';
+ public organisationAdministrator = {
+ usersTableHeaders: ['Name', 'Email address', 'Role'],
+ usersColumnsToDisplay: ['name', 'email', 'role'],
+ currentPage: 1,
+ pageCount: 0,
+ pageSize: environment.listPageSize,
+ userListResponse: {
+ currentPage: 0,
+ pageCount: 0,
+ rowCount: 0,
+ organisationId: this.organisationId,
+ userList: [],
+ },
+ };
+
+ public eventLog = {
+ usersTableHeaders: ['Owner', 'Event', 'Date'],
+ usersColumnsToDisplay: ['name', 'email', 'role'],
+ currentPage: 1,
+ pageCount: 0,
+ pageSize: environment.listPageSize,
+ userListResponse: {
+ currentPage: 0,
+ pageCount: 0,
+ rowCount: 0,
+ organisationId: this.organisationId,
+ userList: [],
+ },
+ };
+
+ constructor(
+ private WrapperOrganisationGroupService: WrapperOrganisationGroupService,
+ private router:Router
+ ) {
+ this.organisationId = localStorage.getItem('cii_organisation_id') || '';
+ this.organisationAdministrator.userListResponse = {
+ currentPage: this.organisationAdministrator.currentPage,
+ pageCount: 0,
+ rowCount: 0,
+ organisationId: this.organisationId,
+ userList: [],
+ };
+ this.eventLog.userListResponse = {
+ currentPage: this.eventLog.currentPage,
+ pageCount: 0,
+ rowCount: 0,
+ organisationId: this.organisationId,
+ userList: [],
+ };
+ }
+
+ ngOnInit() {
+ this.getOrganisationUsers();
+ }
+
+ public openEmailWindow(data: any): void {
+ let AdminEmail = 'mailto:' + data.userName;
+ window.location.href = AdminEmail;
+ }
+
+ public getOrganisationUsers() {
+ this.WrapperOrganisationGroupService.getUsersAdmin(
+ this.organisationId,
+ this.organisationAdministrator.currentPage,
+ this.organisationAdministrator.pageSize
+ ).subscribe({
+ next: (response: any) => {
+ if (response != null) {
+ this.organisationAdministrator.userListResponse = response;
+ this.organisationAdministrator.userListResponse.userList.forEach(
+ (f: any) => {
+ f.role = 'Admin';
+ f.email = f.userName; // the common component expect the field as email
+ }
+ );
+ this.organisationAdministrator.pageCount =
+ this.organisationAdministrator.userListResponse.pageCount;
+ this.getEventLogDetails()
+
+ }
+ },
+ error: (error: any) => {},
+ });
+ }
+
+ public setPageOrganisationAdministrator(pageNumber: any) {
+ this.organisationAdministrator.currentPage = pageNumber;
+ this.getOrganisationUsers();
+ }
+
+ public getEventLogDetails():void{
+ this.WrapperOrganisationGroupService.getUsersAdmin(
+ this.organisationId,
+ this.eventLog.currentPage,
+ this.eventLog.pageSize
+ ).subscribe({
+ next: (response: any) => {
+ if (response != null) {
+ this.eventLog.userListResponse = response;
+ this.eventLog.userListResponse.userList.forEach(
+ (f: any) => {
+ f.role = 'Admin';
+ f.email = f.userName; // the common component expect the field as email
+ }
+ );
+ this.eventLog.pageCount =
+ this.eventLog.userListResponse.pageCount;
+ }
+ },
+ error: (error: any) => {},
+ });
+ }
+
+
+ public removeRightToBuy():void{
+ let data = {
+ id:'123456'
+ }
+ this.router.navigateByUrl(
+ 'remove-right-to-buy?data=' + btoa(JSON.stringify(data))
+ );
+ }
+ goBack() {
+ sessionStorage.setItem('activetab','verifiedOrg')
+ window.history.back();
+ }
+}
diff --git a/src/app/services/wrapper/wrapper-buyer-both.service.ts b/src/app/services/wrapper/wrapper-buyer-both.service.ts
new file mode 100644
index 000000000..f9400c467
--- /dev/null
+++ b/src/app/services/wrapper/wrapper-buyer-both.service.ts
@@ -0,0 +1,95 @@
+import { HttpClient, HttpHeaders } from '@angular/common/http';
+import { Injectable } from '@angular/core';
+import { Observable, throwError } from 'rxjs';
+import { catchError, map } from 'rxjs/operators';
+import { delegateduser } from 'src/app/models/delegated.model';
+import { UserListResponse } from 'src/app/models/user';
+import { environment } from 'src/environments/environment';
+
+
+@Injectable({
+ providedIn: 'root'
+})
+export class WrapperBuyerBothService {
+ private org=`${environment.uri.api.isApiGateWayEnabled ?
+ environment.uri.api.wrapper.apiGatewayEnabled.organisation : environment.uri.api.wrapper.apiGatewayDisabled.organisation}`;
+ private users=`${environment.uri.api.isApiGateWayEnabled ?
+ environment.uri.api.wrapper.apiGatewayEnabled.user : environment.uri.api.wrapper.apiGatewayDisabled.user}`
+
+
+ constructor(private http: HttpClient) { }
+
+
+ public pendingVerification = {
+ "organisationId": "474281654063910288",
+ "userList": [
+ {
+ organisatioName : "Dreams Tech",
+ organisationType : "buyer",
+ dateofRegistration: "2022-10-11T00:00:00"
+ },
+ {
+ organisatioName : "Dreams Guys",
+ organisationType : "Both",
+ dateofRegistration: "2022-10-11T00:00:00"
+ },
+ {
+ organisatioName: "Brickendon",
+ organisationType: "Both",
+ dateofRegistration: "2022-10-11T00:00:00"
+ }
+ ],
+ "currentPage": 1,
+ "pageCount": 1,
+ "rowCount": 1
+ }
+
+ public VerifiedOrg = {
+ "organisationId": "474281654063910288",
+ "userList": [
+ {
+ organisatioName : "srishit innovative",
+ organisationType : "buyer",
+ dateofRegistration: "2022-10-11T00:00:00"
+ },
+ {
+ organisatioName : "sunvis softwares",
+ organisationType : "Both",
+ dateofRegistration: "2022-10-11T00:00:00"
+ },
+ {
+ organisatioName: "rounds edge",
+ organisationType: "Both",
+ dateofRegistration: "2022-10-11T00:00:00"
+ }
+ ],
+ "currentPage": 1,
+ "pageCount": 1,
+ "rowCount": 1
+ }
+
+ getpendingVerificationOrg(organisationId: string, searchString: string, currentPage: number, pageSize: number, includeSelf: boolean = false): Observable {
+ pageSize = pageSize <= 0 ? 10 : pageSize;
+ const url = `${this.org}/${organisationId}/users?currentPage=${currentPage}&pageSize=${pageSize}&search-string=${encodeURIComponent(searchString)}&include-self=${includeSelf}&delegated-only=${true}&delegated-expired-only=${false}`;
+ return this.http.get(url).pipe(
+ map((data: UserListResponse) => {
+ return this.pendingVerification
+ }), catchError(error => {
+ return throwError(error);
+ })
+ );
+ }
+
+ getVerifiedOrg(organisationId: string, searchString: string, currentPage: number, pageSize: number, includeSelf: boolean = false): Observable {
+ pageSize = pageSize <= 0 ? 10 : pageSize;
+ const url = `${this.org}/${organisationId}/users?currentPage=${currentPage}&pageSize=${pageSize}&search-string=${encodeURIComponent(searchString)}&include-self=${includeSelf}&delegated-only=${true}&delegated-expired-only=${false}`;
+ return this.http.get(url).pipe(
+ map((data: UserListResponse) => {
+ return this.VerifiedOrg
+ }), catchError(error => {
+ return throwError(error);
+ })
+ );
+ }
+
+}
diff --git a/src/index.html b/src/index.html
index 80a515be5..0c56f7b9f 100644
--- a/src/index.html
+++ b/src/index.html
@@ -354,4 +354,4 @@