Пример #1
0
            $pmDynaForm = new pmDynaform($Fields);
            if ($pmDynaForm->isResponsive()) {
                $pmDynaForm->printTracker();
            }
        } else {
            $G_PUBLISH = new Publisher();
            $G_PUBLISH->AddContent("dynaform", "xmlform", $_SESSION["PROCESS"] . "/" . $_GET["CTO_UID_OBJ"], "", $Fields["APP_DATA"], "", "", "view");
            G::RenderPage("publish");
        }
        break;
    case 'INPUT_DOCUMENT':
        G::LoadClass('case');
        $oCase = new Cases();
        $c = $oCase->getAllUploadedDocumentsCriteriaTracker($_SESSION['PROCESS'], $_SESSION['APPLICATION'], $_GET['CTO_UID_OBJ']);
        $oHeadPublisher =& headPublisher::getSingleton();
        $oHeadPublisher->addScriptFile('/jscore/tracker/tracker.js');
        $G_PUBLISH = new Publisher();
        $G_PUBLISH->AddContent('propeltable', 'paged-table', 'tracker/tracker_Inputdocs', $c);
        G::RenderPage('publish');
        break;
    case 'OUTPUT_DOCUMENT':
        G::LoadClass('case');
        $oCase = new Cases();
        $c = $oCase->getAllGeneratedDocumentsCriteriaTracker($_SESSION['PROCESS'], $_SESSION['APPLICATION'], $_GET['CTO_UID_OBJ']);
        $oHeadPublisher =& headPublisher::getSingleton();
        $oHeadPublisher->addScriptFile('/jscore/tracker/tracker.js');
        $G_PUBLISH = new Publisher();
        $G_PUBLISH->AddContent('propeltable', 'paged-table', 'tracker/tracker_Outputdocs', $c);
        G::RenderPage('publish');
        break;
}
Пример #2
0
 public function showObjects($pro_uid, $app_uid, $obj_uid, $typeObject)
 {
     switch ($typeObject) {
         case 'DYNAFORM':
             $oCase = new \Cases();
             $Fields = $oCase->loadCase($app_uid);
             $Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
             $Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_STEP_LABEL'] = '';
             $Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_STEP'] = '#';
             $Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_ACTION'] = 'alert("Sample"); return false;';
             $Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PRINT_PREVIEW'] = '#';
             $Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PRINT_PREVIEW_ACTION'] = 'tracker_PrintView?CTO_UID_OBJ=' . $obj_uid . '&CTO_TYPE_OBJ=PRINT_PREVIEW';
             $dynaForm = new \Dynaform();
             $arrayDynaFormData = $dynaForm->Load($obj_uid);
             if (isset($arrayDynaFormData["DYN_VERSION"]) && $arrayDynaFormData["DYN_VERSION"] == 2) {
                 \G::LoadClass("pmDynaform");
                 $Fields["PRO_UID"] = $pro_uid;
                 $Fields["CURRENT_DYNAFORM"] = $obj_uid;
                 $pmDynaForm = new \pmDynaform($Fields);
                 //                    if ($pmDynaForm->isResponsive()) {
                 //                        $pmDynaForm->printTracker();
                 //                    }
                 $response = $pmDynaForm;
             }
             break;
         case 'INPUT_DOCUMENT':
             //G::LoadClass( 'case' );
             $oCase = new \Cases();
             $c = $oCase->getAllUploadedDocumentsCriteriaTracker($pro_uid, $app_uid, $obj_uid);
             //                $response = array();
             if ($c->getDbName() == 'dbarray') {
                 $rs = \ArrayBasePeer::doSelectRs($c);
                 $rs->setFetchmode(\ResultSet::FETCHMODE_ASSOC);
                 $rs->next();
                 $doc = array();
                 while ($row = $rs->getRow()) {
                     $doc[] = $row;
                     $rs->next();
                 }
                 //$response = $this->parserObjects($objects);
             }
             $response = $doc;
             break;
         case 'OUTPUT_DOCUMENT':
             //G::LoadClass( 'case' );
             $oCase = new \Cases();
             $c = $oCase->getAllGeneratedDocumentsCriteriaTracker($pro_uid, $app_uid, $obj_uid);
             $response = $c;
             break;
     }
     return $response;
 }