|
@@ -23,7 +23,7 @@ class ImpromptuController
|
|
|
if (is_dir($imr)) {
|
|
|
$imrPath = $imr;
|
|
|
$newCat = strtolower($export);
|
|
|
- $impCtrl->OpenCatalog($newCat, str_rot13($user), str_rot13($pw));
|
|
|
+ $impCtrl->OpenCatalog($newCat, str_rot13($user), str_rot13($pw), $imrPath);
|
|
|
$impCtrl->RenameCatalog($imrPath, strtolower($cat));
|
|
|
$impCtrl->Quit();
|
|
|
return;
|
|
@@ -58,10 +58,10 @@ class ImpromptuController
|
|
|
$this->app = new COM("CognosImpromptu.Application");
|
|
|
}
|
|
|
|
|
|
- public function OpenCatalog ($catFile, $user, $pw)
|
|
|
+ public function OpenCatalog ($catFile, $user, $pw, $imrPath)
|
|
|
{
|
|
|
if (strpos($catFile, "\\") <= 0) {
|
|
|
- $catFile = realpath(dirname(__FILE__)."/../../../../System/LOCOSOFT/Catalogs/"). "\\" . $catFile;
|
|
|
+ $catFile = realpath($imrPath."/../../Catalogs/"). "\\" . $catFile;
|
|
|
}
|
|
|
$this->app->OpenCatalog($catFile, "Ersteller", "", $user, $pw);
|
|
|
$this->catFile = $catFile;
|
|
@@ -104,7 +104,7 @@ class ImpromptuController
|
|
|
if ($catFile == "") {
|
|
|
$catFile = $this->openFileAndExtractCatInfo($imrFile);
|
|
|
}
|
|
|
- $this->OpenCatalog($catFile, $user, $pw);
|
|
|
+ $this->OpenCatalog($catFile, $user, $pw, dirname($imrFile));
|
|
|
$this->report = $this->app->OpenReport($imrFile);
|
|
|
}
|
|
|
|