Compare commits
6 commits
Author | SHA1 | Date | |
---|---|---|---|
32aa753452 | |||
ce17741e72 | |||
af90108b3b | |||
cf42e725cc | |||
c42c5577cf | |||
|
75d9a4e2fb |
2 changed files with 22 additions and 2 deletions
14
README.md
14
README.md
|
@ -90,6 +90,20 @@ npm run dev
|
||||||
|
|
||||||
The frontend will be available at http://localhost:4200
|
The frontend will be available at http://localhost:4200
|
||||||
|
|
||||||
|
### Local Stripe integration
|
||||||
|
1. Install the Stripe CLI
|
||||||
|
https://stripe.com/docs/stripe-cli
|
||||||
|
|
||||||
|
2. Login to the casino stripe account
|
||||||
|
```
|
||||||
|
stripe login --api-key <casino-stripe-secret-key>
|
||||||
|
```
|
||||||
|
|
||||||
|
3. Start webhook forwarding
|
||||||
|
```
|
||||||
|
stripe listen --forward-to localhost:8080/webhook
|
||||||
|
```
|
||||||
|
|
||||||
## Database Management
|
## Database Management
|
||||||
|
|
||||||
### Postgres Management
|
### Postgres Management
|
||||||
|
|
|
@ -5,7 +5,7 @@ import { Game } from '../../model/Game';
|
||||||
import { Transaction } from '../../model/Transaction';
|
import { Transaction } from '../../model/Transaction';
|
||||||
import { DepositComponent } from '../deposit/deposit.component';
|
import { DepositComponent } from '../deposit/deposit.component';
|
||||||
import { ConfirmationComponent } from '../../shared/components/confirmation/confirmation.component';
|
import { ConfirmationComponent } from '../../shared/components/confirmation/confirmation.component';
|
||||||
import { ActivatedRoute } from '@angular/router';
|
import { ActivatedRoute, Router } from '@angular/router';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-homepage',
|
selector: 'app-homepage',
|
||||||
|
@ -18,10 +18,16 @@ export default class HomeComponent implements OnInit {
|
||||||
isDepositModalOpen = false;
|
isDepositModalOpen = false;
|
||||||
isDepositSuccessful = false;
|
isDepositSuccessful = false;
|
||||||
|
|
||||||
constructor(public route: ActivatedRoute) {}
|
constructor(
|
||||||
|
public route: ActivatedRoute,
|
||||||
|
public router: Router
|
||||||
|
) {}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
this.isDepositSuccessful = this.route.snapshot.queryParams['success'] == 'true';
|
this.isDepositSuccessful = this.route.snapshot.queryParams['success'] == 'true';
|
||||||
|
|
||||||
|
this.router.navigate([], { queryParams: {} });
|
||||||
|
|
||||||
if (this.isDepositSuccessful) {
|
if (this.isDepositSuccessful) {
|
||||||
this.openDepositConfirmationModal();
|
this.openDepositConfirmationModal();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue