Fix: send naver mail test code
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
function sendRequestServer(url, sendParams, onSuccess, onFail, isDebugMode) {
|
||||
// console.log(url);
|
||||
// console.log(sendParams);
|
||||
console.log(url);
|
||||
console.log(sendParams);
|
||||
// console.log(onSuccess);
|
||||
// console.log(onFail);
|
||||
// console.log(isDebugMode);
|
||||
|
||||
@@ -9,6 +9,7 @@ include "./mail_setting.php";
|
||||
// include "./send_mail.php";
|
||||
include "./send_naver_mail.php";
|
||||
|
||||
/*
|
||||
$type = $_POST["type"];
|
||||
$maestro_id = $_POST["maestro_id"];
|
||||
$maestro_name = $_POST["maestro_name"];
|
||||
@@ -21,30 +22,34 @@ $upgrade_account_type = $_POST["upgrade_account_type"];
|
||||
$registered_account_type = $_POST["registered_account_type"];
|
||||
$maestro_name_prev = $_POST["maestro_name_prev"];
|
||||
$maestro_email_prev = $_POST["email_prev"];
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
if($type == "sendMailRegisterBankInfo") {
|
||||
sendMailRegisterBankInfo($maestro_name, $maestro_email, $account_type);
|
||||
$result = sendMailRegisterBankInfo($maestro_name, $maestro_email, $account_type);
|
||||
} else if($type == "sendMailRegistered") {
|
||||
sendMailRegisterDone($maestro_name, $maestro_email);
|
||||
$result = sendMailRegisterDone($maestro_name, $maestro_email);
|
||||
} else if($type == "sendMailUpgradeBankInfo") {
|
||||
sendMailUpgradeBankInfo($maestro_name, $maestro_email, $account_type, $upgrade_account_type);
|
||||
$result = sendMailUpgradeBankInfo($maestro_name, $maestro_email, $account_type, $upgrade_account_type);
|
||||
} else if($type == "sendMailUpgradeDone") {
|
||||
sendMailUpgradeDone($maestro_name, $maestro_email, $account_type, $upgrade_account_type);
|
||||
$result = sendMailUpgradeDone($maestro_name, $maestro_email, $account_type, $upgrade_account_type);
|
||||
} else if($type == "sendMailUpdateMaestroName") {
|
||||
sendMailUpdateMaestroName($maestro_name, $maestro_name_prev, $maestro_email);
|
||||
$result = sendMailUpdateMaestroName($maestro_name, $maestro_name_prev, $maestro_email);
|
||||
} else if($type == "sendMailUpdateMaestroEmail") {
|
||||
sendMailUpdateMaestroEmail($maestro_name, $maestro_email, $maestro_email_prev);
|
||||
$result = sendMailUpdateMaestroEmail($maestro_name, $maestro_email, $maestro_email_prev);
|
||||
} else if($type == "sendMailExtensionBankInfo") {
|
||||
sendMailExtensionBankInfo($maestro_name, $available_date, $new_available_date, $maestro_email, $registered_account_type);
|
||||
$result = sendMailExtensionBankInfo($maestro_name, $available_date, $new_available_date, $maestro_email, $registered_account_type);
|
||||
} else if($type == "sendMailExtensionDone") {
|
||||
sendMailExtensionDone($maestro_name, $new_available_date, $maestro_email);
|
||||
$result = sendMailExtensionDone($maestro_name, $new_available_date, $maestro_email);
|
||||
} else if($type == "get_maestro_data") {
|
||||
// maestro data
|
||||
$maestro_data = get_maestro_data($maestro_id);
|
||||
set_data("maestroData", $maestro_data);
|
||||
}
|
||||
*/
|
||||
|
||||
$return = true;
|
||||
set_data("sendMailResult", $return);
|
||||
send_result_success();
|
||||
|
||||
exit;
|
||||
|
||||
@@ -11,17 +11,21 @@ require './mail_contents.php';
|
||||
require './../lib/maestro_account_info.php';
|
||||
|
||||
|
||||
|
||||
// Register
|
||||
function sendMailRegisterBankInfo($maestro_name, $maestro_email, $account_type) {
|
||||
global $subjectMap, $bodyMap;
|
||||
|
||||
// closed beta
|
||||
/*
|
||||
$subject = str_replace("{{maestro_name}}", $maestro_name, $subjectMap['closedBetaRegistrationBankInfo']);
|
||||
|
||||
$body = str_replace("{{maestro_name}}", $maestro_name, $bodyMap['closedBetaRegistrationBankInfo']);
|
||||
$body = str_replace("{{student_count}}", get_max_player_count($account_type), $body);
|
||||
$body = str_replace("{{price}}", get_price($account_type), $body);
|
||||
*/
|
||||
|
||||
$subject = "Naver 메일 발신 테스트";
|
||||
$body = "sendMailRegisterBankInfo";
|
||||
|
||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||
}
|
||||
@@ -30,9 +34,14 @@ function sendMailRegisterDone($maestro_name, $maestro_email) {
|
||||
global $subjectMap, $bodyMap;
|
||||
|
||||
// closed beta
|
||||
/*
|
||||
$subject = str_replace("{{maestro_name}}", $maestro_name, $subjectMap['closedBetaRegistrationDone']);
|
||||
|
||||
$body = str_replace("{{maestro_name}}", $maestro_name, $bodyMap['closedBetaRegistrationDone']);
|
||||
*/
|
||||
|
||||
$subject = "Naver 메일 발신 테스트";
|
||||
$body = "sendMailRegisterDone";
|
||||
|
||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||
}
|
||||
@@ -40,53 +49,56 @@ function sendMailRegisterDone($maestro_name, $maestro_email) {
|
||||
|
||||
// Extend
|
||||
function sendMailExtensionBankInfo($maestro_name, $available_date, $new_available_date, $maestro_email, $registered_account_type) {
|
||||
$subject = "Naver 메일 발신 테스트";
|
||||
$body = "sendMailExtensionBankInfo";
|
||||
|
||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||
}
|
||||
|
||||
function sendMailExtensionDone($maestro_name, $new_available_date, $maestro_email) {
|
||||
$subject = "Naver 메일 발신 테스트";
|
||||
$body = "sendMailExtensionDone";
|
||||
|
||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||
}
|
||||
|
||||
|
||||
// Upgrade
|
||||
function sendMailUpgradeBankInfo($maestro_name, $maestro_email, $account_type, $upgrade_account_type) {
|
||||
$subject = "Naver 메일 발신 테스트";
|
||||
$body = "sendMailUpgradeBankInfo";
|
||||
|
||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||
}
|
||||
|
||||
function sendMailUpgradeDone($maestro_name, $maestro_email, $account_type, $upgrade_account_type) {
|
||||
$subject = "Naver 메일 발신 테스트";
|
||||
$body = "sendMailUpgradeDone";
|
||||
|
||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||
}
|
||||
|
||||
|
||||
// Update
|
||||
function sendMailUpdateMaestroName($maestro_name, $maestro_name_prev, $maestro_email) {
|
||||
$subject = "Naver 메일 발신 테스트";
|
||||
$body = "sendMailUpdateMaestroName";
|
||||
|
||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||
}
|
||||
|
||||
function sendMailUpdateMaestroEmail($maestro_name, $maestro_email, $maestro_email_prev) {
|
||||
$subject = "Naver 메일 발신 테스트";
|
||||
$body = "sendMailUpdateMaestroEmail";
|
||||
|
||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||
}
|
||||
|
||||
// experation
|
||||
function sendMailExperation30days(maestro_name, $maestro_email, $maestro_email_prev) {
|
||||
$body = "안녕하세요.
|
||||
function sendMailExperation30days($maestro_name, $maestro_email, $maestro_email_prev) {
|
||||
$subject = "Naver 메일 발신 테스트";
|
||||
$body = "sendMailExperation30days";
|
||||
|
||||
[초코마에] 마에스트로 계정을 이용해 주셔서 감사합니다.
|
||||
|
||||
|
||||
현재 이용중이신 마에스트로 계정의 유효기간이 30일밖에 남지 않았습니다.
|
||||
* 유효 기간 : ~ 2020년 09월 02일
|
||||
|
||||
아래에 준비된 여러가지 방법 중 하나를 골라, 유효기간을 연장하실 수 있습니다.
|
||||
|
||||
1) 마에스트로 관리 화면에서 [유효기간 연장] 버튼을 클릭
|
||||
: 현재 사용중이신 요금제를 유지하며, 남은 기간에 +1년을 추가로 사용하실 수 있습니다.
|
||||
|
||||
2) 마에스트로 관리 화면에서 [업그레이드] 버튼을 클릭
|
||||
: 좀 더 많은 학생수로 업그레이드하고, 업그레이드한 날짜로부터 +1년을 추가로 사용하실 수 있습니다.
|
||||
|
||||
|
||||
만약 연장, 업데이트하지 않고 유효기간이 만료되면 휴면 계정으로 전환됩니다.
|
||||
학생 계정의 로그인이 안되고 서비스를 사용하실 수 없게 되는데요. 계정 정보 및 학생 정보는 6개월가량 유지됩니다.
|
||||
|
||||
남은 기간동안 연장 신청 여부를 생각해봐주세요.
|
||||
그리고 연장 신청을 원하신다면 기한 안에 꼭 신청 부탁드릴게요.
|
||||
|
||||
감사합니다.";
|
||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user