Merged in gproly/processmaker/PM-1340 (pull request #1494)

PM-1340 IMPROVEMENT
This commit is contained in:
Julio Cesar Laura Avendaño
2015-02-20 12:55:35 -04:00
2 changed files with 13 additions and 7 deletions

View File

@@ -147,9 +147,19 @@ class pmDynaform
$items[$key]->data = $rows;
}
if ($items[$key]->type !== "grid") {
$value = "";
$label = "";
if (isset($this->data[$items[$key]->name . "_label"])) {
$value = $this->data[$items[$key]->name];
$label = $this->data[$items[$key]->name . "_label"];
}
if (isset($this->data[$items[$key]->name . "_value"])) {
$value = $this->data[$items[$key]->name . "_value"];
$label = $this->data[$items[$key]->name];
}
$items[$key]->data = array(
"value" => $this->data[$items[$key]->name],
"label" => $this->searchValues($items[$key]->name, $this->data[$items[$key]->name])
"value" => $value,
"label" => $label
);
}
}

View File

@@ -22,10 +22,6 @@ function dynaFormChanged(frm) {
return false;
}
$(window).load(function () {
/*if ((navigator.userAgent.indexOf("MSIE") !== -1) || (navigator.userAgent.indexOf("Trident") !== -1)) {
document.body.innerHTML = "<div style='margin:15px'>Responsive Dynaforms are not supported in this browser.</div>";
return;
}*/
if (pm_run_outside_main_app === 'true') {
if (parent.showCaseNavigatorPanel) {
parent.showCaseNavigatorPanel('DRAFT');
@@ -49,7 +45,7 @@ $(window).load(function () {
submitRest: false
});
new PMDynaform.core.Proxy({
url: "http://" + window.project.keys.server + ":"+port +"/" + window.project.keys.apiName + "/" + window.project.keys.apiVersion + "/" + window.project.keys.workspace + "/cases/" + app_uid + "/variables",
url: "http://" + window.project.keys.server + "/" + window.project.keys.apiName + "/" + window.project.keys.apiVersion + "/" + window.project.keys.workspace + "/cases/" + app_uid + "/variables",
method: 'GET',
data: {},
keys: window.project.token,