ProcessMaker-BE "DynaForm small fix (DYN_CONTENT)"
- DynaForm small fix (DYN_CONTENT)
This commit is contained in:
@@ -170,6 +170,10 @@ class Dynaform extends BaseDynaform
|
|||||||
$this->setDynType( isset( $aData['DYN_TYPE'] ) ? $aData['DYN_TYPE'] : 'xmlform' );
|
$this->setDynType( isset( $aData['DYN_TYPE'] ) ? $aData['DYN_TYPE'] : 'xmlform' );
|
||||||
$this->setDynFilename( $aData['PRO_UID'] . PATH_SEP . $dynUid );
|
$this->setDynFilename( $aData['PRO_UID'] . PATH_SEP . $dynUid );
|
||||||
|
|
||||||
|
if (isset($aData["DYN_CONTENT"])) {
|
||||||
|
$this->setDynContent($aData["DYN_CONTENT"]);
|
||||||
|
}
|
||||||
|
|
||||||
if ($this->validate()) {
|
if ($this->validate()) {
|
||||||
$con->begin();
|
$con->begin();
|
||||||
$res = $this->save();
|
$res = $this->save();
|
||||||
|
|||||||
@@ -8,7 +8,8 @@ class DynaForm
|
|||||||
|
|
||||||
"DYN_TITLE" => array("type" => "string", "required" => true, "empty" => false, "defaultValues" => array(), "fieldNameAux" => "dynaFormTitle"),
|
"DYN_TITLE" => array("type" => "string", "required" => true, "empty" => false, "defaultValues" => array(), "fieldNameAux" => "dynaFormTitle"),
|
||||||
"DYN_DESCRIPTION" => array("type" => "string", "required" => false, "empty" => true, "defaultValues" => array(), "fieldNameAux" => "dynaFormDescription"),
|
"DYN_DESCRIPTION" => array("type" => "string", "required" => false, "empty" => true, "defaultValues" => array(), "fieldNameAux" => "dynaFormDescription"),
|
||||||
"DYN_TYPE" => array("type" => "string", "required" => true, "empty" => false, "defaultValues" => array("xmlform", "grid"), "fieldNameAux" => "dynaFormType")
|
"DYN_TYPE" => array("type" => "string", "required" => true, "empty" => false, "defaultValues" => array("xmlform", "grid"), "fieldNameAux" => "dynaFormType"),
|
||||||
|
"DYN_CONTENT" => array("type" => "string", "required" => false, "empty" => true, "defaultValues" => array(), "fieldNameAux" => "dynaFormContent")
|
||||||
);
|
);
|
||||||
|
|
||||||
private $formatFieldNameInUppercase = true;
|
private $formatFieldNameInUppercase = true;
|
||||||
@@ -367,10 +368,6 @@ class DynaForm
|
|||||||
|
|
||||||
$dynaFormUid = $dynaForm->create($arrayData);
|
$dynaFormUid = $dynaForm->create($arrayData);
|
||||||
|
|
||||||
$oDynaform = \DynaformPeer::retrieveByPK( $dynaFormUid );
|
|
||||||
$oDynaform->setDynContent( $arrayData['DYN_CONTENT'] );
|
|
||||||
$oDynaform->save();
|
|
||||||
|
|
||||||
//Return
|
//Return
|
||||||
unset($arrayData["PRO_UID"]);
|
unset($arrayData["PRO_UID"]);
|
||||||
|
|
||||||
@@ -959,7 +956,7 @@ class DynaForm
|
|||||||
$this->getFieldNameByFormatFieldName("DYN_TITLE") => $record["DYN_TITLE"],
|
$this->getFieldNameByFormatFieldName("DYN_TITLE") => $record["DYN_TITLE"],
|
||||||
$this->getFieldNameByFormatFieldName("DYN_DESCRIPTION") => $record["DYN_DESCRIPTION"] . "",
|
$this->getFieldNameByFormatFieldName("DYN_DESCRIPTION") => $record["DYN_DESCRIPTION"] . "",
|
||||||
$this->getFieldNameByFormatFieldName("DYN_TYPE") => $record["DYN_TYPE"] . "",
|
$this->getFieldNameByFormatFieldName("DYN_TYPE") => $record["DYN_TYPE"] . "",
|
||||||
$this->getFieldNameByFormatFieldName("DYN_CONTENT") => $record["DYN_CONTENT"] . ""
|
$this->getFieldNameByFormatFieldName("DYN_CONTENT") => $record["DYN_CONTENT"] . ""
|
||||||
);
|
);
|
||||||
} catch (\Exception $e) {
|
} catch (\Exception $e) {
|
||||||
throw $e;
|
throw $e;
|
||||||
|
|||||||
Reference in New Issue
Block a user