milestone fix; maybe not perfect
This commit is contained in:
@@ -17,17 +17,17 @@ class milestone_competition
|
||||
|
||||
|
||||
public function set_msc_data_by_id($_msc_id) {
|
||||
global $sql;
|
||||
$cat_assoc_array = $sql->assoc_array("select * from milestone_competition where msc_id = " . $_msc_id);
|
||||
$cat_array = $cat_assoc_array[0];
|
||||
global $sql;
|
||||
$cat_assoc_array = $sql->assoc_array("select * from milestone_competition where msc_id = " . $_msc_id);
|
||||
$cat_array = $cat_assoc_array[0];
|
||||
//alapadatok
|
||||
foreach ($cat_array as $field => $value) {
|
||||
$function_name = "set_" . $field;
|
||||
$this->$function_name($value);
|
||||
}
|
||||
foreach ($cat_array as $field => $value) {
|
||||
$function_name = "set_" . $field;
|
||||
$this->$function_name($value);
|
||||
}
|
||||
}
|
||||
|
||||
public static function create_msc($_date, $_name, $_category, $_location, $_place, $_month, $_matches = NULL)
|
||||
public static function create_msc($_date, $_name, $_category, $_location, $_place, $_matches = NULL)
|
||||
{
|
||||
global $sql;
|
||||
return $sql->insert_into('milestone_competition', array(
|
||||
@@ -36,7 +36,6 @@ class milestone_competition
|
||||
'msc_category' => $_category,
|
||||
'msc_location' => $_location,
|
||||
'msc_place' => $_place,
|
||||
'msc_month' => $_month,
|
||||
'msc_matches' => $_matches,
|
||||
));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user