Project

General

Profile

« Previous | Next » 

Revision c2259e80

Added by Andreas Kohlbecker about 12 years ago

#2504 (Show correct error message when webservice is not available)

View differences:

modules/cdm_dataportal/cdm_api/cdm_api.module
576 576
        // check if taxonomictree_uuid is valid
577 577
        $test = cdm_ws_get(cdm_compose_taxonomy_path(), null, null, null, TRUE);
578 578
        if($test == null){
579
          print ($_SESSION['cdm']['taxonomictree_uuid']);
580 579
          // the default set by the admin seems to be invalid or is not even set
581 580
          drupal_set_message(_no_classfication_uuid_message(), 'warning');
582 581
        }
......
615 614
        // check if taxonomictree_uuid is valid
616 615
        $test = cdm_ws_get(cdm_compose_taxonomy_path(), null, null, null, TRUE);
617 616
        if($test == null){
618
          // the default set by the admin seems to be invalid or is not even set
619
          print ($_SESSION['cdm']['taxonomictree_uuid']);
620 617
          // the default set by the admin seems to be invalid or is not even set
621 618
          drupal_set_message(_no_classfication_uuid_message(), 'warning');
622 619
        }
......
1237 1234
}
1238 1235

  
1239 1236
function _no_classfication_uuid_message(){
1237

  
1238
  if(!cdm_ws_get(CDM_WS_PORTAL_TAXONOMY)){
1239
    return t('This DataPortal is not configured properly or the CDM-Sever may be absent.')
1240
      . 'Please check the ' . l(t('CDM web service URL'), 'admin/settings/cdm_dataportal/general')
1241
      . t(', or contact the maintainer of this DataPortal.');
1242
  }
1243

  
1240 1244
  return
1241 1245
  t('This DataPortal is not configured properly.')
1242 1246
      . l(t('Please choose a valid classification'), 'admin/settings/cdm_dataportal/general')

Also available in: Unified diff