Merge pull request #2430 from Jennydmz/master
BUG-15068 PMFPauseCase dosen`t pause the case whrn using the trigger wiz...
This commit is contained in:
@@ -2843,7 +2843,8 @@ function PMFAddAttachmentToArray($arrayData, $index, $value, $suffix = " Copy({i
|
||||
*
|
||||
* It delete the mask a field.
|
||||
*
|
||||
* @name PMFAddAttachmentToArray
|
||||
* @name PMFRemoveMask
|
||||
* @label PMF Remove Mask
|
||||
*
|
||||
* @param string | $field | Value the field
|
||||
* @param string | $separator | Separator of thousands (, or .)
|
||||
@@ -2852,7 +2853,7 @@ function PMFAddAttachmentToArray($arrayData, $index, $value, $suffix = " Copy({i
|
||||
*
|
||||
*/
|
||||
|
||||
function PMRemoveMask ($field, $separator = '.', $currency = '')
|
||||
function PMFRemoveMask ($field, $separator = '.', $currency = '')
|
||||
{
|
||||
$sep = array();
|
||||
if ( trim($currency) != '') {
|
||||
|
||||
@@ -3079,7 +3079,6 @@ class wsBase
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
if (empty( $userUid )) {
|
||||
$result = new wsResponse( 100, G::LoadTranslation( "ID_REQUIRED_FIELD" ) . " userUid" );
|
||||
|
||||
@@ -3087,8 +3086,7 @@ class wsBase
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
if (! empty( $unpauseDate )) {
|
||||
if( strlen($unpauseDate) >=10 ){
|
||||
if (! preg_match( "/^\d{4}-\d{2}-\d{2}| \d{2}:\d{2}:\d{2}$/", $unpauseDate )) {
|
||||
$result = new wsResponse( 100, G::LoadTranslation( "ID_INVALID_DATA" ) . " $unpauseDate" );
|
||||
|
||||
@@ -3096,8 +3094,9 @@ class wsBase
|
||||
|
||||
return $result;
|
||||
}
|
||||
} else {
|
||||
$unpauseDate = null;
|
||||
}
|
||||
|
||||
$case = new Cases();
|
||||
$case->pauseCase( $caseUid, $delIndex, $userUid, $unpauseDate );
|
||||
|
||||
@@ -3108,7 +3107,6 @@ class wsBase
|
||||
);
|
||||
|
||||
$g->sessionVarRestore();
|
||||
|
||||
return $result;
|
||||
} catch (Exception $e) {
|
||||
$result = new wsResponse(100, $e->getMessage());
|
||||
|
||||
Reference in New Issue
Block a user