}
#-------------------------------------------------------------------------------
#-------------------------------------------------------------------------------
$Settings = SelectServerSettingsByService(51000);
#-------------------------------------------------------------------------------
if (!Is_Array($Settings)) {
    #-------------------------------------------------------------------------------
    Debug(SPrintF('[comp/Tasks/ISPswCheckLicenses]: no configured servers for ISPsw service'));
    #-------------------------------------------------------------------------------
    return TRUE;
    #-------------------------------------------------------------------------------
}
#-------------------------------------------------------------------------------
#-------------------------------------------------------------------------------
# достаём лицензии с сайта ispsystem
$Doc = BillManager_Get_List_Licenses($Settings);
# проверяем, что вернулось
switch (ValueOf($Doc)) {
    case 'array':
        # all OK
        break;
    default:
        return TRUE;
}
#-------------------------------------------------------------------------------
#Debug("[comp/Tasks/ISPswCheckLicenses]: Doc = " . print_r($Doc, true));
# перебираем лицензии
foreach ($Doc as $License) {
    #-------------------------------------------------------------------------------
    #Debug(SPrintF("[comp/Tasks/ISPswCheckLicenses]: License = %s",print_r($License, true)));
    #-------------------------------------------------------------------------------
Beispiel #2
0
function BillManager_Get_Users($Settings)
{
    #-------------------------------------------------------------------------------
    return BillManager_Get_List_Licenses($Settings);
    #-------------------------------------------------------------------------------
}