Changeset 1270 for trunk/gsdl/src/recpt/documentaction.cpp
- Timestamp:
- 2000-07-06T09:49:36+12:00 (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl/src/recpt/documentaction.cpp
r1148 r1270 28 28 /* 29 29 $Log$ 30 Revision 1.39 2000/07/05 21:49:31 sjboddie 31 Receptionist now caches collection information to avoid making multiple 32 get_collectinfo calls to collection server 33 30 34 Revision 1.38 2000/05/04 05:18:46 sjboddie 31 35 attempting to get end-user collection building to work under windows … … 183 187 184 188 documentaction::documentaction () { 189 recpt = NULL; 190 185 191 186 192 // this action uses cgi variables "a", "d", "cl", … … 500 506 if (collectproto == NULL) return; 501 507 508 if (recpt == NULL) { 509 logout << "ERROR (documentaction::define_external_macros): This action does not contain\n" 510 << " information about any receptionists. The method set_receptionist was\n" 511 << " probably not called from the module which instantiated this action.\n"; 512 return; 513 } 514 502 515 outconvertclass text_t2ascii; 503 516 comerror_t err; … … 506 519 text_tset metadata; 507 520 508 509 // get info on current collection and load up formatinfo 510 // I'd prefer not to do this here as we're getting 511 // collection info every time (and probably also getting 512 // it in other places some of the time) - One day I'll 513 // fix it ... maybe - Stefan. 514 ColInfoResponse_t cinfo; 515 collectproto->get_collectinfo (collection, cinfo, err, logout); 516 load_formatinfo (cinfo.format, args.getintarg("gt")); 521 ColInfoResponse_t *cinfo = recpt->get_collectinfo_ptr (collectproto, collection, logout); 522 if (cinfo == NULL) { 523 logout << "ERROR (documentaction::define_external_macros): get_collectinfo_ptr returned NULL\n"; 524 return; 525 } 526 load_formatinfo (cinfo->format, args.getintarg("gt")); 517 527 518 528 if (formatinfo.DocumentUseHTML) { … … 526 536 disp.setmacro ("gsdltop", "Global", "documenttop"); 527 537 } 528 text_tmap::iterator it = cinfo .format.find ("homepage");529 if (it != cinfo .format.end()) {538 text_tmap::iterator it = cinfo->format.find ("homepage"); 539 if (it != cinfo->format.end()) { 530 540 text_t httppagehome; 531 541 if (get_link (args, protos, (*it).second, httppagehome, logout)) … … 1101 1111 textout << outconvert << disp << buffer; 1102 1112 } 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113
Note:
See TracChangeset
for help on using the changeset viewer.