From: Anthony Talarico Date: Mon, 17 Jul 2017 19:09:51 +0000 (-0400) Subject: adding shortcodes , models, actions and views for registrationSummary and accountSummary X-Git-Tag: v1.0.0^2~476 X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/index.cgi?a=commitdiff_plain;h=a5ad7566bada97667fb291fd1abc1caa24906f84;p=WP-Plugins%2Fglm-member-db-registrations.git adding shortcodes , models, actions and views for registrationSummary and accountSummary created the model files, view files, shortcodes and actions to hook up the registrationSummary and accountSummary parts of the front end. Tested that the files are hooked up properly by echoing a string --- diff --git a/models/front/registrations/registrationAccountSummary.php b/models/front/registrations/registrationAccountSummary.php new file mode 100644 index 0000000..bfaef29 --- /dev/null +++ b/models/front/registrations/registrationAccountSummary.php @@ -0,0 +1,59 @@ +accountID = ($_REQUEST['account'] - 0); + + if ($this->accountID <= 0) { + $this->accountID = false; + } + + } + + $view = 'registrationAccountSummary'; + + switch ( $option ) { + + } + + // Compile template data + $templateData = array( + + ); + // Return status, any suggested view, and any data to controller + return array( + 'status' => true, + 'modelRedirect' => false, + 'view' => 'front/registrations/' . $view . '.html', + 'data' => $templateData + ); + + } + } diff --git a/models/front/registrations/registrationSummary.php b/models/front/registrations/registrationSummary.php new file mode 100644 index 0000000..5b9a0dd --- /dev/null +++ b/models/front/registrations/registrationSummary.php @@ -0,0 +1,58 @@ +accountID = ($_REQUEST['account'] - 0); + + if ($this->accountID <= 0) { + $this->accountID = false; + } + } + + $view = 'registrationSummary'; + + switch ( $option ) { + + } + + // Compile template data + $templateData = array( + + ); + // Return status, any suggested view, and any data to controller + return array( + 'status' => true, + 'modelRedirect' => false, + 'view' => 'front/registrations/' . $view . '.html', + 'data' => $templateData + ); + + } + } diff --git a/setup/shortcodes.php b/setup/shortcodes.php index 69d2b5d..99300e7 100644 --- a/setup/shortcodes.php +++ b/setup/shortcodes.php @@ -87,6 +87,26 @@ */ $glmMembersRegistrationsShortcodes = array( + 'glm-registration-summary' => array( + 'plugin' => GLM_MEMBERS_REGISTRATIONS_PLUGIN_SLUG, + 'menu' => 'registrations', + 'action' => 'registrationSummary', + 'table' => false, + 'attributes' => array( + 'id' => false, + 'member_only' => false, + ) + ), + 'glm-registration-account-summary' => array( + 'plugin' => GLM_MEMBERS_REGISTRATIONS_PLUGIN_SLUG, + 'menu' => 'registrations', + 'action' => 'registrationAccountSummary', + 'table' => false, + 'attributes' => array( + 'id' => false, + 'member_only' => false, + ) + ), ); $glmMembersRegistrationsShortcodesDescription = ''; diff --git a/setup/validActions.php b/setup/validActions.php index 6913195..3bf8364 100644 --- a/setup/validActions.php +++ b/setup/validActions.php @@ -76,7 +76,11 @@ $glmMembersRegistrationsAddOnValidActions = array( ), ), 'frontActions' => array( - ) + 'registrations' => array( + 'registrationSummary' => GLM_MEMBERS_REGISTRATIONS_PLUGIN_SLUG, + 'registrationAccountSummary' => GLM_MEMBERS_REGISTRATIONS_PLUGIN_SLUG, + ) + ), ); ?> diff --git a/views/front/registrations/registrationAccountSummary.html b/views/front/registrations/registrationAccountSummary.html new file mode 100644 index 0000000..e69de29 diff --git a/views/front/registrations/registrationSummary.html b/views/front/registrations/registrationSummary.html new file mode 100644 index 0000000..e69de29