Add PayPal button to Home for new member subscriptions

This commit is contained in:
2020-02-21 06:10:52 +00:00
parent 87b71c00b9
commit de09975286
3 changed files with 68 additions and 4 deletions
+2 -2
View File
@@ -6,7 +6,7 @@ import moment from 'moment';
import { isAdmin, isInstructor, BasicTable, requester } from './utils.js';
import { NotFound, PleaseLogin } from './Misc.js';
import { InstructorClassDetail, InstructorClassAttendance } from './InstructorClasses.js';
import { PayPal } from './PayPal.js';
import { PayPalPayNow } from './PayPal.js';
function ClassTable(props) {
const { classes } = props;
@@ -211,7 +211,7 @@ export function ClassDetail(props) {
{userTraining.attendance_status === 'Waiting for payment' &&
<div>
<p>Please pay the course fee of ${clazz.cost} to confirm your attendance.</p>
<PayPal
<PayPalPayNow
amount={clazz.cost}
name={clazz.course_name}
custom={JSON.stringify({ training: userTraining.id })}