PM-1700 "Ocurre un error al importar y actualizar un proceso..." SOLVED
Issue:
Ocurre un error al importar y actualizar un proceso de tipo
bpmn, despliega un error sin descripció el proceso se
convierte en un proceso de tipo classic
Cause:
Mala definicion de variables para el "Add Audit Log"
Solution:
Se a suprimido las variables, ahora se utiliza el objeto para el
seteo de variables
This commit is contained in:
@@ -73,8 +73,7 @@ abstract class Importer
|
||||
{
|
||||
$this->prepare();
|
||||
|
||||
$name = $this->importData["tables"]["bpmn"]["project"][0]["prj_name"];
|
||||
|
||||
//Verify data
|
||||
switch ($option) {
|
||||
case self::IMPORT_OPTION_CREATE_NEW:
|
||||
if ($this->targetExists()) {
|
||||
@@ -94,23 +93,12 @@ abstract class Importer
|
||||
self::IMPORT_STAT_TARGET_ALREADY_EXISTS
|
||||
);
|
||||
}
|
||||
$generateUid = false;
|
||||
break;
|
||||
case self::IMPORT_OPTION_OVERWRITE:
|
||||
$this->removeProject();
|
||||
// this option shouldn't generate new uid for all objects
|
||||
$generateUid = false;
|
||||
break;
|
||||
case self::IMPORT_OPTION_DISABLE_AND_CREATE_NEW:
|
||||
$this->disableProject();
|
||||
// this option should generate new uid for all objects
|
||||
$generateUid = true;
|
||||
$name = "New - " . $name . " - " . date("M d, H:i");
|
||||
break;
|
||||
case self::IMPORT_OPTION_KEEP_WITHOUT_CHANGING_AND_CREATE_NEW:
|
||||
// this option should generate new uid for all objects
|
||||
$generateUid = true;
|
||||
$name = \G::LoadTranslation("ID_COPY_OF") . " - " . $name . " - " . date("M d, H:i");
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -149,6 +137,36 @@ abstract class Importer
|
||||
break;
|
||||
}
|
||||
|
||||
//Import
|
||||
$name = $this->importData["tables"]["bpmn"]["project"][0]["prj_name"];
|
||||
|
||||
switch ($option) {
|
||||
case self::IMPORT_OPTION_CREATE_NEW:
|
||||
//Shouldn't generate new UID for all objects
|
||||
$generateUid = false;
|
||||
break;
|
||||
case self::IMPORT_OPTION_OVERWRITE:
|
||||
//Shouldn't generate new UID for all objects
|
||||
$this->removeProject();
|
||||
|
||||
$generateUid = false;
|
||||
break;
|
||||
case self::IMPORT_OPTION_DISABLE_AND_CREATE_NEW:
|
||||
//Should generate new UID for all objects
|
||||
$this->disableProject();
|
||||
|
||||
$name = "New - " . $name . " - " . date("M d, H:i");
|
||||
|
||||
$generateUid = true;
|
||||
break;
|
||||
case self::IMPORT_OPTION_KEEP_WITHOUT_CHANGING_AND_CREATE_NEW:
|
||||
//Should generate new UID for all objects
|
||||
$name = \G::LoadTranslation("ID_COPY_OF") . " - " . $name . " - " . date("M d, H:i");
|
||||
|
||||
$generateUid = true;
|
||||
break;
|
||||
}
|
||||
|
||||
$this->importData["tables"]["bpmn"]["project"][0]["prj_name"] = $name;
|
||||
$this->importData["tables"]["bpmn"]["diagram"][0]["dia_name"] = $name;
|
||||
$this->importData["tables"]["bpmn"]["process"][0]["pro_name"] = $name;
|
||||
|
||||
Reference in New Issue
Block a user