Changeset 5124 for trunk/gsdl
- Timestamp:
- 2003-08-11T12:09:06+12:00 (21 years ago)
- Location:
- trunk/gsdl/src/recpt
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl/src/recpt/datelistbrowserclass.cpp
r4906 r5124 106 106 icon = "_document:iconclosedbookshelf_"; 107 107 link += (*thissection).OID + "\">"; 108 } else link += args["cl"] + "&d=" + (*thissection).OID + "\">"; 108 } else { 109 link += args["cl"] + "&d=" + (*thissection).OID; // + "\">"; 110 // [modification to allow default document detach settings -- kjdon] 111 if (args["xx"]=="1") { 112 // documents should be detached 113 link += "&x=1\" target=\\_blank>"; 114 } else { 115 link += "\">"; 116 } 117 } 109 118 110 119 textout << outconvert << "<tr valign=top>"; -
trunk/gsdl/src/recpt/documentaction.cpp
r5024 r5124 130 130 argsinfo.addarginfo (NULL, arg_ainfo); 131 131 132 // "xx" is 0 normally or 1 if documents should be detached by default 133 arg_ainfo.shortname = "xx"; 134 arg_ainfo.longname = "detach all doc pages"; 135 arg_ainfo.multiplechar = false; 136 arg_ainfo.defaultstatus = cgiarginfo::weak; 137 arg_ainfo.argdefault = "0"; 138 arg_ainfo.savedarginfo = cgiarginfo::must; 139 argsinfo.addarginfo (NULL, arg_ainfo); 140 141 132 142 // f arg is set to 1 if document is to 133 143 // be displayed in a frame -
trunk/gsdl/src/recpt/hlistbrowserclass.cpp
r4906 r5124 131 131 if (doctype == "classify") 132 132 link += "&cl=" + (*tsibling).OID + "\">"; 133 else 134 link += "&cl=" + arg_cl + "&d=" + (*tsibling).OID + "\">"; 133 else { 134 link += "&cl=" + arg_cl + "&d=" + (*tsibling).OID;// + "\">"; 135 // [modification to allow default document detach settings -- kjdon] 136 if (args["xx"]=="1") { 137 // documents should be detached 138 link += "&x=1\" target=\\_blank>"; 139 } else { 140 link += "\">"; 141 } 142 } 135 143 } 136 144 -
trunk/gsdl/src/recpt/vlistbrowserclass.cpp
r4936 r5124 192 192 // get_link_icon attempts to work out what type of icon should be displayed for 193 193 // the given section and what it should link to. 194 // [modification to allow default document detach settings -- kjdon] 194 195 void vlistbrowserclass::get_link_icon (ResultDocInfo_t §ion, cgiargsclass &args, 195 196 const text_t &collink, text_t &link, text_t &icon) { 196 197 197 198 link = "<a href=\"_httpdocument_" + collink; 199 text_t link_end = "\">"; 200 text_t detach_link_end = "&x=1\" target=\\_blank>"; // to detach the link, and x=1 signifies it is a detached page 198 201 icon = "_document:icontext_"; 202 203 text_t doctype; 199 204 int haschildren = 0; 200 205 201 206 if (section.metadata.count("haschildren")>0) 202 207 haschildren = section.metadata["haschildren"].values[0].getint(); 203 204 text_t doctype;205 208 if (section.metadata.count("doctype")>0) 206 209 doctype = section.metadata["doctype"].values[0]; … … 210 213 211 214 if (args["a"] == "q") { 212 // query results 215 // query results list 216 link += "&cl=search&d=" + section.OID; 217 218 if (args["xx"] == "1") { 219 link += detach_link_end; 220 } else { 221 link += link_end; 222 } 213 223 if ((is_top (section.OID)) && (haschildren == 1)) icon = "_document:iconclosedbook_"; 214 224 else if (haschildren == 1) icon = "_document:iconclosedfolder_"; 215 link += "&cl=search&d=" + section.OID + "\">"; 216 225 217 226 } else if (!arg_d.empty()) { 218 // document level227 // we are in a document - none of the links should be detach links 219 228 if (is_top(section.OID)) { 229 // we link back to the originating page eg search page or classifier page 220 230 icon = "_document:iconopenbook_"; 221 if (arg_cl == "search") link = "<a href=\"_httpquery_\">"; 231 if (arg_cl == "search") { 232 link = "<a href=\"_httpquery_\">"; 233 } 222 234 else link += "&cl=" + arg_cl + "\">"; 223 235 224 236 } else if (haschildren == 1) { 225 237 if ((args["gc"] == "1") || … … 239 251 } 240 252 } 241 253 242 254 } else { 243 // classification level 255 // classification level - links to docs may be detaching 244 256 if (haschildren == 1) { 245 257 if (doctype == "classify") { … … 254 266 } 255 267 } else { 268 256 269 icon = "_document:iconclosedbook_"; 257 link += "&cl=" + arg_cl + "&d=" + section.OID + "\">"; 270 link += "&cl=" + arg_cl + "&d=" + section.OID; 271 if (args["xx"] == "1") { 272 link += detach_link_end; 273 } else { 274 link += link_end; 275 } 276 258 277 } 259 278 } else { 260 279 if (doctype == "classify") link = ""; 261 else link += "&cl=" + arg_cl + "&d=" + section.OID + "\">"; 262 } 263 } 264 } 280 else { 281 link += "&cl=" + arg_cl + "&d=" + section.OID; 282 if (args["xx"] == "1") { 283 link += detach_link_end; 284 } else { 285 link += link_end; 286 } 287 } 288 } 289 } 290 291 }
Note:
See TracChangeset
for help on using the changeset viewer.