Vergleich admin/modules/user/group_promotions.php - 1.8.0 - 1.8.2

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 66Zeile 66
			"enabled" => 0
);


			"enabled" => 0
);


		$db->update_query("promotions", $update_promotion, "pid = '{$mybb->input['pid']}'");

$plugins->run_hooks("admin_user_group_promotions_disable_commit");

		$plugins->run_hooks("admin_user_group_promotions_disable_commit");

$db->update_query("promotions", $update_promotion, "pid = '{$mybb->input['pid']}'");


// Log admin action
log_admin_action($promotion['pid'], $promotion['title']);

flash_message($lang->success_promo_disabled, 'success');


// Log admin action
log_admin_action($promotion['pid'], $promotion['title']);

flash_message($lang->success_promo_disabled, 'success');

		admin_redirect("index.php?module=user-group_promotions");
}

		admin_redirect("index.php?module=user-group_promotions");
}

	else

	else

	{

	{

		$page->output_confirm_action("index.php?module=user-group_promotions&action=disable&pid={$promotion['pid']}", $lang->confirm_promo_disable);
}
}

		$page->output_confirm_action("index.php?module=user-group_promotions&action=disable&pid={$promotion['pid']}", $lang->confirm_promo_disable);
}
}

Zeile 86Zeile 86
{
if($mybb->input['no'])
{

{
if($mybb->input['no'])
{

		admin_redirect("index.php?module=user-group_promotions");
}

if(!trim($mybb->input['pid']))
{

		admin_redirect("index.php?module=user-group_promotions");
}

if(!trim($mybb->input['pid']))
{

		flash_message($lang->error_no_promo_id, 'error');
admin_redirect("index.php?module=user-group_promotions");
}

		flash_message($lang->error_no_promo_id, 'error');
admin_redirect("index.php?module=user-group_promotions");
}

Zeile 129Zeile 129
	if(!verify_post_check($mybb->input['my_post_key']))
{
flash_message($lang->invalid_post_verify_key2, 'error');

	if(!verify_post_check($mybb->input['my_post_key']))
{
flash_message($lang->invalid_post_verify_key2, 'error');

		admin_redirect("index.php?module=user-group_promotions");
}

if(!trim($mybb->input['pid']))
{
flash_message($lang->error_no_promo_id, 'error');
admin_redirect("index.php?module=user-group_promotions");
}

		admin_redirect("index.php?module=user-group_promotions");
}

if(!trim($mybb->input['pid']))
{
flash_message($lang->error_no_promo_id, 'error');
admin_redirect("index.php?module=user-group_promotions");
}


$query = $db->simple_select("promotions", "*", "pid='".$mybb->get_input('pid', 1)."'");
$promotion = $db->fetch_array($query);


$query = $db->simple_select("promotions", "*", "pid='".$mybb->get_input('pid', 1)."'");
$promotion = $db->fetch_array($query);

Zeile 148Zeile 148
	}

$plugins->run_hooks("admin_user_group_promotions_enable");

	}

$plugins->run_hooks("admin_user_group_promotions_enable");





	$update_promotion = array(
"enabled" => 1
);

	$update_promotion = array(
"enabled" => 1
);

 

$plugins->run_hooks("admin_user_group_promotions_enable_commit");


$db->update_query("promotions", $update_promotion, "pid = '{$mybb->input['pid']}'");


$db->update_query("promotions", $update_promotion, "pid = '{$mybb->input['pid']}'");


$plugins->run_hooks("admin_user_group_promotions_enable_commit");

 

// Log admin action
log_admin_action($promotion['pid'], $promotion['title']);


// Log admin action
log_admin_action($promotion['pid'], $promotion['title']);





	flash_message($lang->success_promo_enabled, 'success');
admin_redirect("index.php?module=user-group_promotions");
}

	flash_message($lang->success_promo_enabled, 'success');
admin_redirect("index.php?module=user-group_promotions");
}

Zeile 206Zeile 206
		}

if(!trim($mybb->input['newusergroup']))

		}

if(!trim($mybb->input['newusergroup']))

		{

		{

			$errors[] = $lang->error_no_new_usergroup;
}


			$errors[] = $lang->error_no_new_usergroup;
}


Zeile 250Zeile 250
				"enabled" => (int)$mybb->input['enabled'],
"logging" => (int)$mybb->input['logging']
);

				"enabled" => (int)$mybb->input['enabled'],
"logging" => (int)$mybb->input['logging']
);


$db->update_query("promotions", $update_promotion, "pid = '".$mybb->get_input('pid', 1)."'");

 

$plugins->run_hooks("admin_user_group_promotions_edit_commit");


$plugins->run_hooks("admin_user_group_promotions_edit_commit");

 

$db->update_query("promotions", $update_promotion, "pid = '".$mybb->get_input('pid', 1)."'");


// Log admin action
log_admin_action($promotion['pid'], $mybb->input['title']);


// Log admin action
log_admin_action($promotion['pid'], $mybb->input['title']);

Zeile 330Zeile 330
		"<" => $lang->less_than
);


		"<" => $lang->less_than
);


	$form_container->output_row($lang->post_count, $lang->post_count_desc, $form->generate_text_box('postcount', $mybb->input['postcount'], array('id' => 'postcount'))." ".$form->generate_select_box("posttype", $options_type, $mybb->input['posttype'], array('id' => 'posttype')), 'postcount');

	$form_container->output_row($lang->post_count, $lang->post_count_desc, $form->generate_numeric_field('postcount', $mybb->input['postcount'], array('id' => 'postcount'))." ".$form->generate_select_box("posttype", $options_type, $mybb->input['posttype'], array('id' => 'posttype')), 'postcount');





	$form_container->output_row($lang->thread_count, $lang->thread_count_desc, $form->generate_text_box('threadcount', $mybb->input['threadcount'], array('id' => 'threadcount'))." ".$form->generate_select_box("threadtype", $options_type, $mybb->input['threadtype'], array('id' => 'threadtype')), 'threadcount');

	$form_container->output_row($lang->thread_count, $lang->thread_count_desc, $form->generate_numeric_field('threadcount', $mybb->input['threadcount'], array('id' => 'threadcount'))." ".$form->generate_select_box("threadtype", $options_type, $mybb->input['threadtype'], array('id' => 'threadtype')), 'threadcount');





	$form_container->output_row($lang->reputation_count, $lang->reputation_count_desc, $form->generate_text_box('reputationcount', $mybb->input['reputationcount'], array('id' => 'reputationcount'))." ".$form->generate_select_box("reputationtype", $options_type, $mybb->input['reputationtype'], array('id' => 'reputationtype')), 'reputationcount');

	$form_container->output_row($lang->reputation_count, $lang->reputation_count_desc, $form->generate_numeric_field('reputationcount', $mybb->input['reputationcount'], array('id' => 'reputationcount'))." ".$form->generate_select_box("reputationtype", $options_type, $mybb->input['reputationtype'], array('id' => 'reputationtype')), 'reputationcount');


$options = array(
"hours" => $lang->hours,


$options = array(
"hours" => $lang->hours,

Zeile 344Zeile 344
		"years" => $lang->years
);


		"years" => $lang->years
);


	$form_container->output_row($lang->referral_count, $lang->referral_count_desc, $form->generate_text_box('referrals', $mybb->input['referrals'], array('id' => 'referrals'))." ".$form->generate_select_box("referralstype", $options_type, $mybb->input['referralstype'], array('id' => 'referralstype')), 'referrals');

	$form_container->output_row($lang->referral_count, $lang->referral_count_desc, $form->generate_numeric_field('referrals', $mybb->input['referrals'], array('id' => 'referrals'))." ".$form->generate_select_box("referralstype", $options_type, $mybb->input['referralstype'], array('id' => 'referralstype')), 'referrals');





	$form_container->output_row($lang->warning_points, $lang->warning_points_desc, $form->generate_text_box('warnings', $mybb->input['warnings'], array('id' => 'warnings'))." ".$form->generate_select_box("warningstype", $options_type, $mybb->input['warningstype'], array('id' => 'warningstype')), 'warnings');

	$form_container->output_row($lang->warning_points, $lang->warning_points_desc, $form->generate_numeric_field('warnings', $mybb->input['warnings'], array('id' => 'warnings'))." ".$form->generate_select_box("warningstype", $options_type, $mybb->input['warningstype'], array('id' => 'warningstype')), 'warnings');





	$form_container->output_row($lang->time_registered, $lang->time_registered_desc, $form->generate_text_box('timeregistered', $mybb->input['timeregistered'], array('id' => 'timeregistered'))." ".$form->generate_select_box("timeregisteredtype", $options, $mybb->input['timeregisteredtype'], array('id' => 'timeregisteredtype')), 'timeregistered');

	$form_container->output_row($lang->time_registered, $lang->time_registered_desc, $form->generate_numeric_field('timeregistered', $mybb->input['timeregistered'], array('id' => 'timeregistered'))." ".$form->generate_select_box("timeregisteredtype", $options, $mybb->input['timeregisteredtype'], array('id' => 'timeregisteredtype')), 'timeregistered');





	$form_container->output_row($lang->time_online, $lang->time_online_desc, $form->generate_text_box('timeonline', $mybb->input['timeonline'], array('id' => 'timeonline'))." ".$form->generate_select_box("timeonlinetype", $options, $mybb->input['timeonlinetype'], array('id' => 'timeonlinetype')), 'timeonline');

	$form_container->output_row($lang->time_online, $lang->time_online_desc, $form->generate_numeric_field('timeonline', $mybb->input['timeonline'], array('id' => 'timeonline'))." ".$form->generate_select_box("timeonlinetype", $options, $mybb->input['timeonlinetype'], array('id' => 'timeonlinetype')), 'timeonline');


$options = array();



$options = array();


Zeile 533Zeile 533
		"<" => $lang->less_than
);


		"<" => $lang->less_than
);


	$form_container->output_row($lang->post_count, $lang->post_count_desc, $form->generate_text_box('postcount', $mybb->input['postcount'], array('id' => 'postcount'))." ".$form->generate_select_box("posttype", $options_type, $mybb->input['posttype'], array('id' => 'posttype')), 'postcount');

	$form_container->output_row($lang->post_count, $lang->post_count_desc, $form->generate_numeric_field('postcount', $mybb->input['postcount'], array('id' => 'postcount'))." ".$form->generate_select_box("posttype", $options_type, $mybb->input['posttype'], array('id' => 'posttype')), 'postcount');





	$form_container->output_row($lang->thread_count, $lang->thread_count_desc, $form->generate_text_box('threadcount', $mybb->input['threadcount'], array('id' => 'threadcount'))." ".$form->generate_select_box("threadtype", $options_type, $mybb->input['threadtype'], array('id' => 'threadtype')), 'threadcount');

	$form_container->output_row($lang->thread_count, $lang->thread_count_desc, $form->generate_numeric_field('threadcount', $mybb->input['threadcount'], array('id' => 'threadcount'))." ".$form->generate_select_box("threadtype", $options_type, $mybb->input['threadtype'], array('id' => 'threadtype')), 'threadcount');





	$form_container->output_row($lang->reputation_count, $lang->reputation_count_desc, $form->generate_text_box('reputationcount', $mybb->input['reputationcount'], array('id' => 'reputationcount'))." ".$form->generate_select_box("reputationtype", $options_type, $mybb->input['reputationtype'], array('id' => 'reputationtype')), 'reputationcount');

	$form_container->output_row($lang->reputation_count, $lang->reputation_count_desc, $form->generate_numeric_field('reputationcount', $mybb->input['reputationcount'], array('id' => 'reputationcount'))." ".$form->generate_select_box("reputationtype", $options_type, $mybb->input['reputationtype'], array('id' => 'reputationtype')), 'reputationcount');


$options = array(
"hours" => $lang->hours,


$options = array(
"hours" => $lang->hours,

Zeile 547Zeile 547
		"years" => $lang->years
);


		"years" => $lang->years
);


	$form_container->output_row($lang->referral_count, $lang->referral_count_desc, $form->generate_text_box('referrals', $mybb->input['referrals'], array('id' => 'referrals'))." ".$form->generate_select_box("referralstype", $options_type, $mybb->input['referralstype'], array('id' => 'referralstype')), 'referrals');

	$form_container->output_row($lang->referral_count, $lang->referral_count_desc, $form->generate_numeric_field('referrals', $mybb->input['referrals'], array('id' => 'referrals'))." ".$form->generate_select_box("referralstype", $options_type, $mybb->input['referralstype'], array('id' => 'referralstype')), 'referrals');





	$form_container->output_row($lang->warning_points, $lang->warning_points_desc, $form->generate_text_box('warnings', $mybb->input['warnings'], array('id' => 'warnings'))." ".$form->generate_select_box("warningstype", $options_type, $mybb->input['warningstype'], array('id' => 'warningstype')), 'warnings');

	$form_container->output_row($lang->warning_points, $lang->warning_points_desc, $form->generate_numeric_field('warnings', $mybb->input['warnings'], array('id' => 'warnings'))." ".$form->generate_select_box("warningstype", $options_type, $mybb->input['warningstype'], array('id' => 'warningstype')), 'warnings');





	$form_container->output_row($lang->time_registered, $lang->time_registered_desc, $form->generate_text_box('timeregistered', $mybb->input['timeregistered'], array('id' => 'timeregistered'))." ".$form->generate_select_box("timeregisteredtype", $options, $mybb->input['timeregisteredtype'], array('id' => 'timeregisteredtype')), 'timeregistered');

	$form_container->output_row($lang->time_registered, $lang->time_registered_desc, $form->generate_numeric_field('timeregistered', $mybb->input['timeregistered'], array('id' => 'timeregistered'))." ".$form->generate_select_box("timeregisteredtype", $options, $mybb->input['timeregisteredtype'], array('id' => 'timeregisteredtype')), 'timeregistered');





	$form_container->output_row($lang->time_online, $lang->time_online_desc, $form->generate_text_box('timeonline', $mybb->input['timeonline'], array('id' => 'timeonline'))." ".$form->generate_select_box("timeonlinetype", $options, $mybb->input['timeonlinetype'], array('id' => 'timeonlinetype')), 'timeonline');

	$form_container->output_row($lang->time_online, $lang->time_online_desc, $form->generate_numeric_field('timeonline', $mybb->input['timeonline'], array('id' => 'timeonline'))." ".$form->generate_select_box("timeonlinetype", $options, $mybb->input['timeonlinetype'], array('id' => 'timeonlinetype')), 'timeonline');

	$options = array();

$query = $db->simple_select("usergroups", "gid, title", "gid != '1'", array('order_by' => 'title'));

	$options = array();

$query = $db->simple_select("usergroups", "gid, title", "gid != '1'", array('order_by' => 'title'));