Add: maestro DB - AvailableActivateDateTime
This commit is contained in:
@@ -7,7 +7,11 @@ include "./../setup/connect_db.php";
|
||||
$maestro_id = $_POST["maestro_id"];
|
||||
|
||||
|
||||
$query = "UPDATE moty_maestro SET ActivateStatus=1 WHERE MaestroID=?";
|
||||
$query = "
|
||||
UPDATE moty_maestro
|
||||
SET ActivateStatus = 1, AvailableActivateDateTime = DATE_ADD(NOW(), INTERVAL 1 YEAR)
|
||||
WHERE MaestroID = ?
|
||||
";
|
||||
$stmt = $db_conn->prepare($query);
|
||||
$stmt->bind_param("i", $maestro_id);
|
||||
$stmt->execute();
|
||||
|
||||
@@ -29,7 +29,8 @@ function get_maestro_list() {
|
||||
global $db_conn;
|
||||
|
||||
$query = "
|
||||
SELECT MaestroID, Name, AccountType FROM moty_maestro
|
||||
SELECT MaestroID, Name, AccountType
|
||||
FROM moty_maestro
|
||||
WHERE ActivateStatus=0
|
||||
ORDER BY MaestroID DESC
|
||||
";
|
||||
@@ -54,7 +55,8 @@ function get_maestro_list_by_name($maestroName) {
|
||||
global $db_conn;
|
||||
|
||||
$query = "
|
||||
SELECT MaestroID, Name, AccountType FROM moty_maestro
|
||||
SELECT MaestroID, Name, AccountType
|
||||
FROM moty_maestro
|
||||
WHERE Name LIKE CONCAT('%', ?, '%') AND ActivateStatus=0
|
||||
ORDER BY MaestroID DESC
|
||||
";
|
||||
|
||||
Reference in New Issue
Block a user