Skip to content

Commit

Permalink
#18 user admin creation screen
Browse files Browse the repository at this point in the history
  • Loading branch information
WingZer0o committed Mar 16, 2024
1 parent 95a35ee commit b01c92e
Show file tree
Hide file tree
Showing 6 changed files with 54 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/app/modules/admin-home/admin-home-routing.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { PaymentSubscriptionComponent } from './payments/payment-subscription/pa
import { PaymentPricesComponent } from './payments/payment-prices/payment-prices.component';
import { PaymentProductCreateComponent } from './payments/payment-product-create/payment-product-create.component';
import { PaymentPriceCreateComponent } from './payments/payment-price-create/payment-price-create.component';
import { UsersAdminComponent } from './users-admin/users-admin.component';

const routes: Routes = [
{
Expand All @@ -17,7 +18,8 @@ const routes: Routes = [
{ path: "payment-products/create", component: PaymentProductCreateComponent, canActivate: [AdminAuthGuardService] },
{ path: "payment-prices", component: PaymentPricesComponent, canActivate: [AdminAuthGuardService] },
{ path: "payment-prices/create", component: PaymentPriceCreateComponent, canActivate: [AdminAuthGuardService] },
{ path: "payment-subscription", component: PaymentSubscriptionComponent, canActivate: [AdminAuthGuardService] }
{ path: "payment-subscription", component: PaymentSubscriptionComponent, canActivate: [AdminAuthGuardService] },
{ path: "users-admin", component: UsersAdminComponent, canActivate: [AdminAuthGuardService] }
]
}
];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
<a class="list-group-item list-group-item-action" routerLink="/admin-home/payment-subscription">
Subscription
</a>
<a class="list-group-item list-group-item-action" routerLink="/admin-home/users-admin">Users Admin</a>
</ul>
}

Expand Down
Empty file.
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<table class="table table-hover">
<thead>
<tr>
<td scope="col">Email</td>
<td scope="col">Username</td>
</tr>
</thead>
</table>
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';

import { UsersAdminComponent } from './users-admin.component';

describe('UsersAdminComponent', () => {
let component: UsersAdminComponent;
let fixture: ComponentFixture<UsersAdminComponent>;

beforeEach(async () => {
await TestBed.configureTestingModule({
imports: [UsersAdminComponent]
})
.compileComponents();

fixture = TestBed.createComponent(UsersAdminComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});

it('should create', () => {
expect(component).toBeTruthy();
});
});
19 changes: 19 additions & 0 deletions src/app/modules/admin-home/users-admin/users-admin.component.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import { Component, OnInit } from '@angular/core';
import { HttpService } from 'src/app/services/http.service';

@Component({
selector: 'app-users-admin',
templateUrl: './users-admin.component.html',
styleUrl: './users-admin.component.css'
})
export class UsersAdminComponent implements OnInit {

constructor(private httpService: HttpService) {

}

ngOnInit(): void {
this.getUsersPage();
}

}

0 comments on commit b01c92e

Please sign in to comment.