當前位置: 首頁>>代碼示例>>PHP>>正文


PHP processMap::downloadFile方法代碼示例

本文整理匯總了PHP中processMap::downloadFile方法的典型用法代碼示例。如果您正苦於以下問題:PHP processMap::downloadFile方法的具體用法?PHP processMap::downloadFile怎麽用?PHP processMap::downloadFile使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在processMap的用法示例。


在下文中一共展示了processMap::downloadFile方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: Processes

     $_SESSION['PFMDirectory'] = '';
     $oProcessMap->processFilesManager($oData->pro_uid);
     break;
 case 'exploreDirectory':
     $objData = G::json_decode($_REQUEST['data']);
     $_SESSION['PFMDirectory'] = $objData->{'main_directory'};
     $oProcessMap->exploreDirectory($oData->pro_uid, $oData->main_directory, $oData->directory);
     break;
 case 'deleteFile':
     $oProcessMap->deleteFile($oData->pro_uid, $oData->main_directory, $oData->directory, $oData->file);
     break;
 case 'deleteDirectory':
     $oProcessMap->deleteDirectory($oData->pro_uid, $oData->main_directory, $oData->directory, $oData->dir_to_delete);
     break;
 case 'downloadFile':
     $oProcessMap->downloadFile($oData->pro_uid, $oData->main_directory, $oData->directory, $oData->file);
     break;
 case 'deleteSubProcess':
     $sOutput = $oProcessMap->deleteSubProcess($oData->pro_uid, $oData->tas_uid);
     break;
 case 'subProcess_Properties':
     $oProcessMap->subProcess_Properties($oData->pro_uid, $oData->tas_uid, $oData->index);
     break;
 case 'showDetailsPMDWL':
     G::LoadClass('processes');
     $oProcesses = new Processes();
     $oProcesses->ws_open_public();
     $aFields = get_object_vars($oProcesses->ws_processGetData($oData->pro_uid));
     $aFields['description'] = nl2br($aFields['description']);
     $aFields['installSteps'] = nl2br($aFields['installSteps']);
     switch ($aFields['privacy']) {
開發者ID:rodriquelca,項目名稱:processmaker,代碼行數:31,代碼來源:processes_Ajax.php

示例2: downloadProcessFilesManager

 /**
  *
  * @param string $sProcessUID {@min 32} {@max 32}
  * @param string $prfUid {@min 32} {@max 32}
  *
  *
  * @access public
  */
 public function downloadProcessFilesManager($sProcessUID, $prfUid)
 {
     try {
         $path = '';
         $criteria = new \Criteria("workflow");
         $criteria->addSelectColumn(\ProcessFilesPeer::PRF_PATH);
         $criteria->add(\ProcessFilesPeer::PRF_UID, $prfUid, \Criteria::EQUAL);
         $rsCriteria = \ProcessFilesPeer::doSelectRS($criteria);
         $rsCriteria->setFetchmode(\ResultSet::FETCHMODE_ASSOC);
         $rsCriteria->next();
         while ($aRow = $rsCriteria->getRow()) {
             $path = $aRow['PRF_PATH'];
             $rsCriteria->next();
         }
         if ($path == '') {
             throw new \Exception(\G::LoadTranslation("ID_INVALID_VALUE_FOR", array('prf_uid')));
         }
         $sFile = end(explode("/",$path));
         $sPath = str_replace($sFile,'',$path);
         $sSubDirectory = substr(str_replace($sProcessUID,'',substr($sPath,(strpos($sPath, $sProcessUID)))),0,-1);
         $sMainDirectory = str_replace(substr($sPath, strpos($sPath, $sProcessUID)),'', $sPath);
         if ($sMainDirectory == PATH_DATA_MAILTEMPLATES) {
             $sMainDirectory = 'mailTemplates';
         } else {
             $sMainDirectory = 'public';
         }
         if (file_exists($path)) {
             $oProcessMap = new \processMap(new \DBConnection());
             $oProcessMap->downloadFile($sProcessUID,$sMainDirectory,$sSubDirectory,$sFile);
             die();
         } else {
             throw (new \Exception( 'Invalid value specified for path.'));
         }
     } catch (Exception $e) {
         throw $e;
     }
 }
開發者ID:hpx2206,項目名稱:processmaker-1,代碼行數:45,代碼來源:FilesManager.php


注:本文中的processMap::downloadFile方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。