Merged in mcuiza/processmaker/PM-1953 (pull request #1892)

PM-1953 - 0017021: ProcessMaker variable doesn't update properly
This commit is contained in:
Julio Cesar Laura Avendaño
2015-04-13 10:48:17 -04:00

View File

@@ -2868,4 +2868,30 @@ function PMFRemoveMask ($field, $separator = '.', $currency = '')
$field = floatval(trim($field));
return $field;
}
/**
*@method
*
* Sends an array of case variables to a specified case.
*
* @name PMFSaveCurrentData
* @label PMF Save Current Data
*
* @return int | $result | Result of send variables | Returns 1 if the variables were sent successfully to the case; otherwise, returns 0 if an error occurred.
*
*/
function PMFSaveCurrentData ()
{
global $oPMScript;
$result = 0;
if (isset($_SESSION['APPLICATION']) && isset($oPMScript->aFields)) {
G::LoadClass( 'wsBase' );
$ws = new wsBase();
$result = $ws->sendVariables( $_SESSION['APPLICATION'], $oPMScript->aFields );
}
return $result;
}