Documentation

This commit is contained in:
sparkyx 2024-07-29 16:37:31 +02:00
parent cede8af916
commit 65dd4e31c4

View file

@ -48,7 +48,14 @@ class Noalyss_User
var $access_mode; //!< MOBILE or PC depending if when connecting $login contains @mobile
var $lang ; //!< user's language
var $theme ; //!< user's CSS Theme
/**
* @brief Create an user , load an existing one or if p_id == -1 search for the connected user. To have an empty
* user, give a p_id smaller than -1 or zero.
*
* @param $p_cn DatabaseCore connection
* @param $p_id if -1 then load the current user, > 0 load the user , = 0 (or < -1 ) means an empty user
*/
function __construct($p_cn, $p_id=-1)
{
$this->db=$p_cn;
@ -657,7 +664,7 @@ class Noalyss_User
}
/**
* synomym for isAdmin,
* @brief synomym for isAdmin,
* @deprecated
*/
function Admin():int
@ -778,7 +785,7 @@ class Noalyss_User
}
/**
* Save the preference , the scope is global, the settings are saved
* @brief Save the preference , the scope is global, the settings are saved
* into account_repository
* @param $key THEME, LANG , PAGESIZE
* @param $value value of the key
@ -1021,7 +1028,8 @@ class Noalyss_User
}
//end function
/* * \brief Return the year of current Periode
/**
* \brief Return the year of current Periode
* it is the parm_periode.p_exercice col
* if an error occurs return 0
*/
@ -1039,7 +1047,8 @@ class Noalyss_User
return 0;
}
/* * \brief Check if the user can access
/**
* \brief Check if the user can access
* otherwise warn and exit
* \param $p_action requested action
* \param $p_js = 1 javascript, or 0 just a text or 2 to log it silently
@ -1089,7 +1098,8 @@ class Noalyss_User
return $res;
}
/* * \brief Check if the user can print (in menu_ref p_type_display=p)
/**
* \brief Check if the user can print (in menu_ref p_type_display=p)
* otherwise warn and exit
* \param $p_action requested action
* \return nothing the program exits automatically
@ -1529,7 +1539,7 @@ class Noalyss_User
}
/**
* Check if the profile of the user can write for this profile
* @brief Check if the profile of the user can write for this profile
* @param $dtoc action_gestion.ag_id
* @return true if he can write otherwise false
*/
@ -1548,7 +1558,7 @@ class Noalyss_User
}
/**
* Check if the profile of the user can write AND delete for this profile
* @brief Check if the profile of the user can write AND delete for this profile
* @param $dtoc action_gestion.ag_id
* @return true if he can write otherwise false
*/
@ -1567,7 +1577,7 @@ class Noalyss_User
}
/**
* Check if the profile of the user can write for this profile
* @brief Check if the profile of the user can write for this profile
* @param $dtoc action_gestion.ag_id
* @return true if he can write otherwise false
*/
@ -1585,7 +1595,7 @@ class Noalyss_User
}
/**
* Check if the profile of the user can write for this repository
* @brief Check if the profile of the user can write for this repository
* @param $p_repo stock_repository.r_id
* @return true if he can write otherwise false
*/
@ -1606,7 +1616,7 @@ class Noalyss_User
}
/**
* Check if the profile of the user can read for this repository
* @brief Check if the profile of the user can read for this repository
* @param $p_repo stock_repository.r_id
* @return true if he read write otherwise false
*/
@ -1658,7 +1668,7 @@ class Noalyss_User
}
/**
* Save the password from PREFERENCE MODULE
* @brief Save the password from PREFERENCE MODULE
* @param type $p_email
*/
function save_email($p_email)
@ -1669,7 +1679,7 @@ class Noalyss_User
}
/**
* Remove a user and all his privileges
*@brief Remove a user and all his privileges
* So it cannot connect anymore and all his privileges are removed from
* the dossier
*
@ -1695,7 +1705,7 @@ class Noalyss_User
}
/**
* Grant access to folder, grant administrator profile , all the ledgers and all the action
* @brief Grant access to folder, grant administrator profile , all the ledgers and all the action
*
*/
static function grant_admin_access($p_login, $p_dossier)
@ -1767,7 +1777,7 @@ class Noalyss_User
}
/**
* Check the security on ledger for the user , it returns 1 if the security
* @brief Check the security on ledger for the user , it returns 1 if the security
* on ledgers is enabled, otherwise 0
*/
function get_status_security_ledger()
@ -1780,7 +1790,7 @@ class Noalyss_User
}
/**
* Set the flag in the table user_active_security
* @brief Set the flag in the table user_active_security
* @param int $p_value 1==enable , 0 = disable
* @exceptions invalid value
*/