@@ 117-134 (lines=18) @@ | ||
114 | return false; |
|
115 | } |
|
116 | ||
117 | public function check_futsal_team_exists($team_name) { |
|
118 | $stmt = $this->db_lib->prepared_execute( |
|
119 | $this->DB->contest, |
|
120 | "SELECT * |
|
121 | FROM `futsal_teams` |
|
122 | WHERE `team_name` = ?", |
|
123 | "s", |
|
124 | [$team_name] |
|
125 | ); |
|
126 | if (!$stmt) { |
|
127 | return false; |
|
128 | } |
|
129 | $stmt->store_result(); |
|
130 | if ($stmt->num_rows > 0) { |
|
131 | return true; |
|
132 | } |
|
133 | return false; |
|
134 | } |
|
135 | ||
136 | public function check_futsal_participant_exists($user_nick) { |
|
137 | $stmt = $this->db_lib->prepared_execute( |
|
@@ 136-153 (lines=18) @@ | ||
133 | return false; |
|
134 | } |
|
135 | ||
136 | public function check_futsal_participant_exists($user_nick) { |
|
137 | $stmt = $this->db_lib->prepared_execute( |
|
138 | $this->DB->contest, |
|
139 | "SELECT * |
|
140 | FROM `futsal_participants` |
|
141 | WHERE `nick` = ?", |
|
142 | "s", |
|
143 | [$user_nick] |
|
144 | ); |
|
145 | if (!$stmt) { |
|
146 | return false; |
|
147 | } |
|
148 | $stmt->store_result(); |
|
149 | if ($stmt->num_rows > 0) { |
|
150 | return true; |
|
151 | } |
|
152 | return false; |
|
153 | } |
|
154 | ||
155 | public function register_for_futsal($team_name, $contact_number, $team) { |
|
156 | $this->DB->contest->begin_transaction(MYSQLI_TRANS_START_READ_WRITE); |
|
@@ 450-467 (lines=18) @@ | ||
447 | return false; |
|
448 | } |
|
449 | ||
450 | public function check_artuino_team_exists($team_name) { |
|
451 | $stmt = $this->db_lib->prepared_execute( |
|
452 | $this->DB->contest, |
|
453 | "SELECT * |
|
454 | FROM `artuino_teams` |
|
455 | WHERE `team_name` = ?", |
|
456 | "s", |
|
457 | [$team_name] |
|
458 | ); |
|
459 | if (!$stmt) { |
|
460 | return false; |
|
461 | } |
|
462 | $stmt->store_result(); |
|
463 | if ($stmt->num_rows > 0) { |
|
464 | return true; |
|
465 | } |
|
466 | return false; |
|
467 | } |
|
468 | ||
469 | public function check_artuino_participant_exists($user_nick) { |
|
470 | $stmt = $this->db_lib->prepared_execute( |
|
@@ 469-486 (lines=18) @@ | ||
466 | return false; |
|
467 | } |
|
468 | ||
469 | public function check_artuino_participant_exists($user_nick) { |
|
470 | $stmt = $this->db_lib->prepared_execute( |
|
471 | $this->DB->contest, |
|
472 | "SELECT * |
|
473 | FROM `artuino_participants` |
|
474 | WHERE `nick` = ?", |
|
475 | "s", |
|
476 | [$user_nick] |
|
477 | ); |
|
478 | if (!$stmt) { |
|
479 | return false; |
|
480 | } |
|
481 | $stmt->store_result(); |
|
482 | if ($stmt->num_rows > 0) { |
|
483 | return true; |
|
484 | } |
|
485 | return false; |
|
486 | } |
|
487 | ||
488 | public function register_for_artuino($team_name, $contact_number, $team) { |
|
489 | $this->DB->contest->begin_transaction(MYSQLI_TRANS_START_READ_WRITE); |