ppwbdrillthru.js 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. // Licensed Materials - Property of IBM
  2. //
  3. // IBM Cognos Products: pps
  4. //
  5. // (C) Copyright IBM Corp. 2005, 2017
  6. //
  7. // US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  8. // This forms the javascript functions used for PowerPlay Studio Toolbar
  9. // The functions handle any minor browser differences.
  10. function make_url(form) {
  11. this.action = form.action;
  12. this.elements = [];
  13. var x, i;
  14. x = form.getElementsByTagName("input");
  15. for (i = 0; i < x.length; ++i) {
  16. this.elements.push({fName: x[i].name, fValue: x[i].value});
  17. }
  18. }
  19. function make_cq_url(s){
  20. document.cq.query.value=s;
  21. var f = new make_url(document.cq);
  22. this.action = f.action;
  23. this.elements = f.elements;
  24. }
  25. function make_mdc_url(s){
  26. document.mdc.E.value=s;
  27. var f = new make_url(document.mdc);
  28. this.action = f.action;
  29. this.elements = f.elements;
  30. }
  31. function make_mig_mdc_url(s){
  32. var intialSearchPath = document.getElementById("mdcsearchpath").value;
  33. var searchPath = intialSearchPath + s;
  34. document.getElementById("mdcsearchpath").value = searchPath;
  35. var f = new make_url(document.mig_mdc);
  36. this.action = f.action;
  37. this.elements = f.elements;
  38. document.getElementById("mdcsearchpath").value = intialSearchPath;
  39. }
  40. function make_iwr_url(s){
  41. document.iwr.entry.value=s;
  42. var f = new make_url(document.iwr);
  43. this.action = f.action;
  44. this.elements = f.elements;
  45. }
  46. function make_ppx_url(s){
  47. document.ppx.E.value=s;
  48. var f = new make_url(document.ppx);
  49. this.action = f.action;
  50. this.elements = f.elements;
  51. }
  52. function make_mig_ppx_url(s){
  53. var initialSearchPath = document.mig_ppx.CRNOBJ.value;
  54. var searchPath = initialSearchPath + s;
  55. document.mig_ppx.CRNOBJ.value = searchPath;
  56. var f = new make_url(document.mig_ppx);
  57. this.action = f.action;
  58. this.elements = f.elements;
  59. document.mig_ppx.CRNOBJ.value = initialSearchPath;
  60. }
  61. function make_crr_url(s) {
  62. document.crr.entry.value = s;
  63. var f = new make_url(document.crr);
  64. this.action = f.action;
  65. this.elements = f.elements;
  66. }