From 503d02641180f8834af893f3181aebb60935d06a Mon Sep 17 00:00:00 2001 From: Steve Sutton Date: Mon, 7 Jan 2019 12:46:50 -0500 Subject: [PATCH] add invoice types first --- models/admin/management/importAccounts.php | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/models/admin/management/importAccounts.php b/models/admin/management/importAccounts.php index 24b0764..858da6e 100644 --- a/models/admin/management/importAccounts.php +++ b/models/admin/management/importAccounts.php @@ -114,17 +114,17 @@ if ( isset( $_REQUEST['start'] ) && $start = filter_var( $_REQUEST['start'], FIL $importResults = ''; // Get all payment types here. -// $sql = " -// SELECT * -// FROM members.payment_types -// ORDER BY id"; -// -// $paymentTypes = $dbh->query( $sql )->fetchAll(); -// foreach ( $paymentTypes as $pType ) { -// $pid = addPaymentType( $this->wpdb, $pType ); -// $importResults .= '
$pid: ' . print_r( $pid, true ) . '
'; -// } -// $importResults .= '
$paymentTypes: ' . print_r( $paymentTypes, true ) . '
'; +$sql = " +SELECT * + FROM members.payment_types +ORDER BY id"; + +$paymentTypes = $dbh->query( $sql )->fetchAll(); +foreach ( $paymentTypes as $pType ) { + $pid = addPaymentType( $this->wpdb, $pType ); + $importResults .= '
$pid: ' . print_r( $pid, true ) . '
'; +} +$importResults .= '
$paymentTypes: ' . print_r( $paymentTypes, true ) . '
'; // Get total number of members. $sql = " -- 2.17.1