Fix: DB jisangs -> moty
This commit is contained in:
@@ -46,7 +46,7 @@ function has_maestro_name($maestroName) {
|
||||
|
||||
$query = "
|
||||
SELECT MaestroID
|
||||
FROM moty_maestro
|
||||
FROM maestro
|
||||
WHERE Name = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -64,7 +64,7 @@ function add_maestro($maestro_name, $password, $email, $account_type) {
|
||||
global $db_conn;
|
||||
|
||||
$query = "
|
||||
INSERT INTO moty_maestro (Name, Password, Email, AccountType, ActivateStatus, PlayerCount, AcceptClausesDateTime, MaestroTestID)
|
||||
INSERT INTO maestro (Name, Password, Email, AccountType, ActivateStatus, PlayerCount, AcceptClausesDateTime, MaestroTestID)
|
||||
VALUES (?, PASSWORD(?), ?, ?, 0, 0, NOW(), -1)";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
$stmt->bind_param("sssi", $maestro_name, $password, $email, $account_type);
|
||||
|
||||
@@ -23,7 +23,7 @@ exit;
|
||||
function get_maestro_id($maestro_name) {
|
||||
global $db_conn;
|
||||
|
||||
$query = "SELECT MaestroID FROM moty_maestro WHERE Name=?";
|
||||
$query = "SELECT MaestroID FROM maestro WHERE Name=?";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
$stmt->bind_param("s", $maestro_name);
|
||||
$stmt->execute();
|
||||
|
||||
@@ -27,7 +27,7 @@ function get_maestro_test_player_id($maestro_id) {
|
||||
|
||||
$query = "
|
||||
SELECT MaestroTestID
|
||||
FROM moty_maestro
|
||||
FROM maestro
|
||||
WHERE MaestroID = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -48,7 +48,7 @@ function delete_maestro_test_player_record($player_id) {
|
||||
|
||||
$query = "
|
||||
DELETE
|
||||
FROM moty_best_record
|
||||
FROM best_record
|
||||
WHERE PlayerID = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
|
||||
@@ -57,7 +57,7 @@ function get_maestro_id($maestroName) {
|
||||
|
||||
$query = "
|
||||
SELECT MaestroID
|
||||
FROM moty_maestro
|
||||
FROM maestro
|
||||
WHERE Name = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -78,7 +78,7 @@ function login($maestroName, $password) {
|
||||
|
||||
$query = "
|
||||
SELECT MaestroID, AccountType, ActivateStatus, AvailableActivateDateTime
|
||||
FROM moty_maestro
|
||||
FROM maestro
|
||||
WHERE Name = ? AND Password = PASSWORD(?)
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
|
||||
@@ -38,7 +38,7 @@ function get_maestro_experience_id() {
|
||||
|
||||
$query = "
|
||||
SELECT MaestroID
|
||||
FROM moty_maestro
|
||||
FROM maestro
|
||||
WHERE AccountType = 101
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -59,7 +59,7 @@ function get_maestro_test_player_id($maestro_id) {
|
||||
|
||||
$query = "
|
||||
SELECT MaestroTestID
|
||||
FROM moty_maestro
|
||||
FROM maestro
|
||||
WHERE MaestroID = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -80,7 +80,7 @@ function get_maestro_test_player_name($player_id) {
|
||||
|
||||
$query = "
|
||||
SELECT Name
|
||||
FROM moty_player
|
||||
FROM player
|
||||
WHERE PlayerID = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -106,7 +106,7 @@ function remove_maestro_sample_player_data($maestro_id) {
|
||||
|
||||
$query = "
|
||||
DELETE
|
||||
FROM moty_player
|
||||
FROM player
|
||||
WHERE MaestroID = ? AND AccountType = 0
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -127,7 +127,7 @@ function insert_maestro_sample_player_data($i, $maestro_id, $player) {
|
||||
global $db_conn;
|
||||
|
||||
$query = "
|
||||
INSERT INTO moty_player (MaestroID, Name, EnterCode, AccountType)
|
||||
INSERT INTO player (MaestroID, Name, EnterCode, AccountType)
|
||||
VALUES (?, ?, ?, ?)
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -172,7 +172,7 @@ function count_registered_player($maestroID) {
|
||||
|
||||
$query = "
|
||||
SELECT COUNT(PlayerID)
|
||||
FROM moty_player
|
||||
FROM player
|
||||
WHERE MaestroID = ? AND AccountType = 0
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -190,7 +190,7 @@ function update_count_registered_player($maestroID, $countPlayer) {
|
||||
global $db_conn;
|
||||
|
||||
$query = "
|
||||
UPDATE moty_maestro
|
||||
UPDATE maestro
|
||||
SET PlayerCount = ?
|
||||
WHERE MaestroID = ?
|
||||
";
|
||||
|
||||
@@ -27,7 +27,7 @@ function get_maestro_info($maestroID) {
|
||||
|
||||
$query = "
|
||||
SELECT Name, Email, AccountType, PlayerCount
|
||||
FROM moty_maestro
|
||||
FROM maestro
|
||||
WHERE MaestroID = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
|
||||
@@ -30,7 +30,7 @@ function get_maestro_test_player_id($maestro_id) {
|
||||
|
||||
$query = "
|
||||
SELECT AccountType, MaestroTestID
|
||||
FROM moty_maestro
|
||||
FROM maestro
|
||||
WHERE MaestroID = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -53,7 +53,7 @@ function get_maestro_test_player_info($player_id) {
|
||||
|
||||
$query = "
|
||||
SELECT Name, AccountType
|
||||
FROM moty_player
|
||||
FROM player
|
||||
WHERE PlayerID = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
|
||||
@@ -35,7 +35,7 @@ function count_maestro_upgrade($maestroID) {
|
||||
|
||||
$query = "
|
||||
SELECT COUNT(MaestroID)
|
||||
FROM moty_maestro_upgrade
|
||||
FROM maestro_upgrade
|
||||
WHERE MaestroID = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -53,7 +53,7 @@ function add_maestro_update($maestroID, $registeredAcountType, $newAccountType)
|
||||
global $db_conn;
|
||||
|
||||
$query = "
|
||||
INSERT INTO moty_maestro_upgrade (RegisteredAccountType, RequestedAccountType, RequestedDateTime, Status, MaestroID)
|
||||
INSERT INTO maestro_upgrade (RegisteredAccountType, RequestedAccountType, RequestedDateTime, Status, MaestroID)
|
||||
VALUES (?, ?, NOW(), 1, ?);
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
|
||||
@@ -19,7 +19,7 @@ function update_maestro_info($maestroID, $maestroName, $email) {
|
||||
global $db_conn;
|
||||
|
||||
$query = "
|
||||
UPDATE moty_maestro
|
||||
UPDATE maestro
|
||||
SET Name = ?, Email = ?
|
||||
WHERE MaestroID = ?
|
||||
";
|
||||
|
||||
@@ -27,7 +27,7 @@ function maestro_registered_password($maestro_id, $registeredPW) {
|
||||
|
||||
$query = "
|
||||
SELECT COUNT(MaestroID)
|
||||
FROM moty_maestro
|
||||
FROM maestro
|
||||
WHERE MaestroID = ? AND Password = PASSWORD(?)
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
@@ -45,7 +45,7 @@ function update_maestro_password($maestroID, $newPW) {
|
||||
global $db_conn;
|
||||
|
||||
$query = "
|
||||
UPDATE moty_maestro
|
||||
UPDATE maestro
|
||||
SET Password = PASSWORD(?)
|
||||
WHERE MaestroID = ?
|
||||
";
|
||||
|
||||
Reference in New Issue
Block a user