Fix: trial maestro account

This commit is contained in:
2022-07-03 01:06:12 +09:00
parent 9eec33cc49
commit 3d474b266c
22 changed files with 637 additions and 101 deletions
+59 -6
View File
@@ -86,11 +86,19 @@ $subjectMap['closedBetaRegistrationDone'] = "[초코마에] {{maestro_name}} -
$bodyMap['closedBetaRegistrationDone'] = "안녕하세요.<br/>".
"[초코마에] 마에스트로 계정을 신청해 주셔서 감사합니다.<br/>".
"<br/>".
"신청하신 마에스트로 계정 내용은 아래와 같습니다.<br/>".
"1) 아이디 : {{maestro_name}}<br/>".
"2) 요금제 : {{student_count}}명 ({{price}}원)<br/>".
"<br/>".
"--------------------".
"<br/>".
"<br/>".
"{{maestro_name}} - 마에스트로 계정이 활성화 되었습니다.<br/>".
"<br/>".
"* 베타 기간인 7월 말까지 무료로 사용하실 수 있습니다. 마음에 들면 유료 정식 서비스때 결제 부탁드릴게요.<br/>".
"* 베타 기간동안 서버 부하와 안정성을 확인합니다. 문제가 없으면 이후 유료로 정식 서비스를 재개할 예정입니다.<br/>".
"* 계정 업그레이드는 베타 기간 이후에 가능합니다.<br/>".
"<br/>".
"* 베타 기간인 7월 말까지 무료로 사용하실 수 있습니다. 마음에 들면 유료 결제(유효기간 연장 / 업그레이드)를 부탁드릴게요.<br/>".
"* 어뷰징 및 서버 성능 향상을 위해 사용하지 않는 계정은 삭제됩니다.<br/>".
"* 위와 같은 이유로, 2주간의 체험 기간이 끝나고 결제가 이루어지지 않은 계정은 이후 자동으로 삭제됩니다.<br/>".
"<br/>".
"등록하신 마에스트로 계정 정보는 마에스트로 로그인 후, [계정 정보 수정] 화면에서 변경이 가능합니다.<br/>".
"(변경 가능 정보 : 마에스트로 아이디, 이메일, 암호)<br/>".
@@ -98,7 +106,6 @@ $bodyMap['closedBetaRegistrationDone'] = "안녕하세요.<br/>".
"감사합니다.";
// extension
$subjectMap['extensionBankInfo'] = "[초코마에] {{maestro_name}} - 마에스트로 계정 유효기간 연장을 위한 입금 안내";
$bodyMap['extensionBankInfo'] = "안녕하세요.<br/>".
@@ -143,6 +150,52 @@ $bodyMap['extensionDone'] = "안녕하세요.<br/>".
// upgrade - trial maestro
$subjectMap['trialMaestroUpgradeBankInfo'] = "[초코마에] {{maestro_name}} - 마에스트로 계정 업그레이드를 위한 입금 안내";
$bodyMap['trialMaestroUpgradeBankInfo'] = "안녕하세요.<br/>".
"[초코마에] 마에스트로 계정 요금제 업그레이드를 신청해주셔서 감사합니다.<br/>".
"<br/>".
"{{maestro_name}} - 마에스트로 계정의 현재 요금제와 업그레이드 요금제는 아래와 같습니다.<br/>".
"1) 현재 사용중인 요금제 : {{prev_student_count}}명 (0원 : 무료 체험 기간)<br/>".
"2) 신청하신 업그레이드 요금제 : {{upgrade_student_count}}명 ({{upgrade_price}}원)<br/>".
"<br/>".
"<br/>".
"계정 요금제 업그레이드를 위한 은행 계좌 입금 정보는 아래와 같습니다.<br/>".
"------------------------------------------------------------<br/>".
"* 은행 계좌 : {{bank_account_no}} ( 카카오뱅크, 예금주 : 박지상 )<br/>".
"* 금액 : {{upgrade_price}}원<br/>".
"* 송금자명 : {{maestro_name}} (신청하신 마에스트로 아이디)<br/>".
" ☞ 빠른 입금 확인을 위해, 송금자명을 본인 이름 대신 위와 같이 아이디로 부탁드립니다 ☜<br/>".
"------------------------------------------------------------<br/>".
"<br/>".
"* 혹시 신청하신 아이디가 아니라 본인 이름등으로 송금되었다면, 송금자명을 본 메일로 답신 부탁드립니다.<br/>".
"<br/>".
"* 상위 요금제로 업그레이드 하시면, 유효기간은 업그레이드가 적용된 날짜로부터 1년으로 설정됩니다.<br/>".
"* 유효기간이 끝나서 비활성화된 계정과 그 안에 있는 모든 정보는, 6개월 후에 자동 삭제됩니다.<br/>".
"<br/>".
"<br/>".
"계정 신청 내역과 입금 내역이 확인되는대로 마에스트로 아이디를 업그레이드 해드리겠습니다.<br/>".
"현재 수작업으로 확인하고 활성화하고 있어서 시간이 조금 걸리는 점 양해 부탁드립니다.<br/>".
"마에스트로 계정이 업그레이드 되는대로, 즉시 알림 메일을 드리겠습니다.<br/>".
"<br/>".
"감사합니다.";
$subjectMap['trialMaestroUpgradeDone'] = "[초코마에] {{maestro_name}} - 마에스트로 계정의 요금제 업그레이드 완료 알림";
$bodyMap['trialMaestroUpgradeDone'] = "안녕하세요.<br/>".
"[초코마에] 마에스트로 계정 요금제 업그레이드를 신청해주셔서 감사합니다.<br/>".
"<br/>".
"{{maestro_name}} - 마에스트로 계정의 요금제가 [ {{prev_student_count}}명 (0원 : 무료 체험 기간) ] 에서 [ {{upgrade_student_count}}명 ({{upgrade_price}}원) ] 으로 업그레이드 되었습니다.<br/>".
"<br/>".
"* 마에스트로 계정 유효기간이 오늘부터 1년으로 설정되었습니다.<br/>".
"<br/>".
"<br/>".
"등록하신 마에스트로 계정 정보는 마에스트로 로그인 후, [계정 정보 수정] 화면에서 변경이 가능합니다.<br/>".
"(변경 가능 정보 : 마에스트로 아이디, 이메일, 암호)<br/>".
"<br/>".
"감사합니다.";
// upgrade
$subjectMap['upgradeBankInfo'] = "[초코마에] {{maestro_name}} - 마에스트로 계정 업그레이드를 위한 입금 안내";
$bodyMap['upgradeBankInfo'] = "안녕하세요.<br/>".
@@ -163,7 +216,7 @@ $bodyMap['upgradeBankInfo'] = "안녕하세요.<br/>".
"<br/>".
"* 혹시 신청하신 아이디가 아니라 본인 이름등으로 송금되었다면, 송금자명을 본 메일로 답신 부탁드립니다.<br/>".
"<br/>".
"* 상위 요금제로 업그레이드 하시면, 유효기간은 업그레이드가 적용된 날짜로부터 1년으로 다시 채워집니다.<br/>".
"* 상위 요금제로 업그레이드 하시면, 유효기간은 업그레이드가 적용된 날짜로부터 1년으로 설정됩니다.<br/>".
"* 유효기간이 끝나서 비활성화된 계정과 그 안에 있는 모든 정보는, 6개월 후에 자동 삭제됩니다.<br/>".
"<br/>".
"<br/>".
@@ -179,7 +232,7 @@ $bodyMap['upgradeDone'] = "안녕하세요.<br/>".
"<br/>".
"{{maestro_name}} - 마에스트로 계정의 요금제가 [ {{prev_student_count}}명 ({{prev_price}}원) ] 에서 [ {{upgrade_student_count}}명 ({{upgrade_price}}원) ] 으로 업그레이드 되었습니다.<br/>".
"<br/>".
"* 마에스트로 계정 유효기간이 오늘부터 1년으로 다시 채워졌습니다.<br/>".
"* 마에스트로 계정 유효기간이 오늘부터 1년으로 설정되었습니다.<br/>".
"<br/>".
"<br/>".
"등록하신 마에스트로 계정 정보는 마에스트로 로그인 후, [계정 정보 수정] 화면에서 변경이 가능합니다.<br/>".
+51 -2
View File
@@ -40,6 +40,21 @@ function sendMailRegisterDone($maestro_name, $maestro_email) {
}
// Register - closed beta, trial maestro
function sendMailTrialRegisterDone($maestro_name, $maestro_email, $account_type) {
global $subjectMap, $bodyMap;
$subject = str_replace("{{maestro_name}}", $maestro_name, $subjectMap['closedBetaRegistrationDone']);
$body = str_replace("{{maestro_name}}", $maestro_name, $bodyMap['closedBetaRegistrationDone']);
$body = str_replace("{{student_count}}", get_max_player_count($account_type), $body);
$price = number_format(get_price($account_type));
$body = str_replace("{{price}}", $price, $body);
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
}
// Extend
function sendMailExtensionBankInfo($maestro_name, $prev_date, $new_available_date, $maestro_email, $account_type) {
global $subjectMap, $bodyMap, $bank_account_no;
@@ -69,6 +84,39 @@ function sendMailExtensionDone($maestro_name, $new_available_date, $maestro_emai
}
// Upgrade - trial maestro
function sendMailTrialMaestroUpgradeBankInfo($maestro_name, $maestro_email, $prev_account_type, $upgrade_account_type) {
global $subjectMap, $bodyMap, $bank_account_no;
$subject = str_replace("{{maestro_name}}", $maestro_name, $subjectMap['trialMaestroUpgradeBankInfo']);
$body = str_replace("{{maestro_name}}", $maestro_name, $bodyMap['trialMaestroUpgradeBankInfo']);
$body = str_replace("{{prev_student_count}}", get_max_player_count($prev_account_type), $body);
$prev_price = number_format(get_price($prev_account_type));
$body = str_replace("{{upgrade_student_count}}", get_max_player_count($upgrade_account_type), $body);
$upgrade_price = number_format(get_price($upgrade_account_type));
$body = str_replace("{{upgrade_price}}", $upgrade_price, $body);
$body = str_replace("{{bank_account_no}}", $bank_account_no, $body);
$body = str_replace("{{price}}", $upgrade_price, $body);
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
}
function sendMailTrialMaestroUpgradeDone($maestro_name, $maestro_email, $prev_account_type, $upgrade_account_type) {
global $subjectMap, $bodyMap;
$subject = str_replace("{{maestro_name}}", $maestro_name, $subjectMap['trialMaestroUpgradeDone']);
$body = str_replace("{{maestro_name}}", $maestro_name, $bodyMap['trialMaestroUpgradeDone']);
$body = str_replace("{{prev_student_count}}", get_max_player_count($prev_account_type), $body);
$body = str_replace("{{upgrade_student_count}}", get_max_player_count($upgrade_account_type), $body);
$upgrade_price = number_format(get_price($upgrade_account_type));
$body = str_replace("{{upgrade_price}}", $upgrade_price, $body);
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
}
// Upgrade
function sendMailUpgradeBankInfo($maestro_name, $maestro_email, $prev_account_type, $upgrade_account_type) {
global $subjectMap, $bodyMap, $bank_account_no;
@@ -83,8 +131,9 @@ function sendMailUpgradeBankInfo($maestro_name, $maestro_email, $prev_account_ty
$upgrade_price = number_format(get_price($upgrade_account_type));
$body = str_replace("{{upgrade_price}}", $upgrade_price, $body);
$body = str_replace("{{bank_account_no}}", $bank_account_no, $body);
$charge_price = (int)$upgrade_price - (int)$prev_price;
$body = str_replace("{{price}}", $charge_price, $body);
$charge_price = get_price($upgrade_account_type) - get_price($prev_account_type);
// $charge_price = (int)$upgrade_price - (int)$prev_price;
$body = str_replace("{{price}}", number_format($charge_price), $body);
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
}