Additional Admin Button?!?

Hello ALL! :)

Hope you are all well.

i need some assistance with adding an additional button to the member section of the admin panel - i have an APPROVE button for the applications and i also included a DECLINE button and both send out seperate emails depending on the selection.

What i need to do is add another button which is INCOMPLETE so it will send out a third email explaining that the persons account cannot be approved as the profile needs to be completed fully before it can be verified but i cannot figure out how to do this?

any and all help would be mucho appreciado :)

 

I look forward to hearing from you

 

Chris 

upload.png · 201.2K · 138 views
All for one and one for all....ah sod it who am i kidding!
Quote · 19 Jun 2014

OK, so i have copied the Reject button code and changed it to Incomplete:

// INCOMPLETE START

if(isset($_POST['adm-mp-incomplete']) && (bool)$_POST['members']) {

$GLOBALS['MySQL']->query("UPDATE `Profiles` SET `Status`='Incomplete' WHERE `ID` IN ('" . implode("','", $_POST['members']) . "')");

 $oEmailTemplate = new BxDolEmailTemplates();

foreach($_POST['members'] as $iId) {

createUserDataFile((int)$iId);

reparseObjTags('profile', (int)$iId);

 $aProfile = getProfileInfo($iId);

$aMail = $oEmailTemplate->parseTemplate('t_Incomplete', array(), $iId);

sendMail($aProfile['Email'], $aMail['subject'], $aMail['body']);

$oAlert = new BxDolAlerts('profile', 'change_status', (int)$iId, 0, array('status' => 'Active'));

$oAlert->alert();

}

echo "<script>window.parent." . BX_DOL_ADM_MP_JS_NAME . ".reload();</script>";

exit;

}

// INCOMPLETE END

 

 

I have added the button to the Admin Dashboard for profiles.php and its sending out =?UTF-8?B??= emails as the email template is NOT there to be able to edit? Any help please to make this template appear?

All for one and one for all....ah sod it who am i kidding!
Quote · 20 Jun 2014

You can login to your phpmyadmin and execute the following query. It will add the template to the database :

 

INSERT INTO `sys_email_templates` (`Name`, `Subject`, `Body`, `Desc`, `LangID`) VALUES

('t_Incomplete', 'Your Profile Is Incomplete', '<bx_include_auto:_email_header.html />\r\n\r\n<p><b>Dear <RealName></b>,</p>\r\n\r\n<p>Your profile is incomplete, you need to login and fill out the required fields!</p>\r\n\r\n<p>Your Account: <a href="<Domain>member.php"><Domain>member.php</a></p>\r\n\r\n<p>Member ID: <b><recipientID></b></p>\r\n\r\n<p>Your E-mail: <span style="color:#FF6633"><Email></span></p>\r\n\r\n<bx_include_auto:_email_footer.html />', 'Profile incomplete notification.', 0);

Paypal email is jeromemingo@gmail.com - http://www.boonex.com/market/posts/modzzz
Quote · 20 Jun 2014

Thank you so much !

That worked a treat!!

All for one and one for all....ah sod it who am i kidding!
Quote · 20 Jun 2014
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.