issue #2354 update pwg.users.setInfo

and add pwg.users.setMyInfo method
This commit is contained in:
Linty
2025-05-05 20:24:05 +02:00
parent 6c609e5da6
commit 7f850c2938
3 changed files with 493 additions and 259 deletions

27
ws.php
View File

@@ -1238,6 +1238,33 @@ enabled_high, registration_date, registration_date_string, registration_date_sin
$ws_functions_root . 'pwg.users.php',
array('admin_only'=>true, 'post_only'=>true)
);
$service->addMethod(
'pwg.users.setMyInfo',
'ws_users_setMyInfo',
array(
'email' => array('flags'=>WS_PARAM_OPTIONAL),
'nb_image_page' => array('flags'=>WS_PARAM_OPTIONAL,
'type'=>WS_TYPE_INT|WS_TYPE_POSITIVE|WS_TYPE_NOTNULL),
'theme' => array('flags'=>WS_PARAM_OPTIONAL),
'language' => array('flags'=>WS_PARAM_OPTIONAL),
'recent_period' => array('flags'=>WS_PARAM_OPTIONAL,
'type'=>WS_TYPE_INT|WS_TYPE_POSITIVE),
'expand' => array('flags'=>WS_PARAM_OPTIONAL,
'type'=>WS_TYPE_BOOL),
'show_nb_comments' => array('flags'=>WS_PARAM_OPTIONAL,
'type'=>WS_TYPE_BOOL),
'show_nb_hits' => array('flags'=>WS_PARAM_OPTIONAL,
'type'=>WS_TYPE_BOOL),
'password' => array('flags'=>WS_PARAM_OPTIONAL),
'new_password' => array('flags'=>WS_PARAM_OPTIONAL),
'conf_new_password' => array('flags'=>WS_PARAM_OPTIONAL),
'pwg_token' => array(),
),
'',
$ws_functions_root . 'pwg.users.php',
array('admin_only'=>false, 'post_only'=>true)
);
$service->addMethod(
'pwg.permissions.getList',