mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 22:28:51 +00:00
[feature/ajax] Send correct activate/deactivate JSON response in acp_profile
PHPBB3-10270
This commit is contained in:
parent
ac320fad05
commit
8138103c6b
1 changed files with 18 additions and 0 deletions
|
@ -242,6 +242,15 @@ class acp_profile
|
||||||
$db->sql_freeresult($result);
|
$db->sql_freeresult($result);
|
||||||
|
|
||||||
add_log('admin', 'LOG_PROFILE_FIELD_ACTIVATE', $field_ident);
|
add_log('admin', 'LOG_PROFILE_FIELD_ACTIVATE', $field_ident);
|
||||||
|
|
||||||
|
if ($request->is_ajax())
|
||||||
|
{
|
||||||
|
$json_response = new phpbb_json_response();
|
||||||
|
$json_response->send(array(
|
||||||
|
'text' => $user->lang('DEACTIVATE'),
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
trigger_error($user->lang['PROFILE_FIELD_ACTIVATED'] . adm_back_link($this->u_action));
|
trigger_error($user->lang['PROFILE_FIELD_ACTIVATED'] . adm_back_link($this->u_action));
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
@ -266,7 +275,16 @@ class acp_profile
|
||||||
$field_ident = (string) $db->sql_fetchfield('field_ident');
|
$field_ident = (string) $db->sql_fetchfield('field_ident');
|
||||||
$db->sql_freeresult($result);
|
$db->sql_freeresult($result);
|
||||||
|
|
||||||
|
if ($request->is_ajax())
|
||||||
|
{
|
||||||
|
$json_response = new phpbb_json_response();
|
||||||
|
$json_response->send(array(
|
||||||
|
'text' => $user->lang('ACTIVATE'),
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
add_log('admin', 'LOG_PROFILE_FIELD_DEACTIVATE', $field_ident);
|
add_log('admin', 'LOG_PROFILE_FIELD_DEACTIVATE', $field_ident);
|
||||||
|
|
||||||
trigger_error($user->lang['PROFILE_FIELD_DEACTIVATED'] . adm_back_link($this->u_action));
|
trigger_error($user->lang['PROFILE_FIELD_DEACTIVATED'] . adm_back_link($this->u_action));
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Add table
Reference in a new issue