Fixed problems with data when database is in Oracle. Tiquet: #2864

This commit is contained in:
m-lopez-f 2015-10-14 11:10:44 +02:00
parent 8091827490
commit e94618db62

View File

@ -59,14 +59,25 @@ if (is_ajax ()) {
} }
// Get the html rows of the fields form // Get the html rows of the fields form
switch ($config["dbtype"]) {
// Descriptions are stored in json case "mysql":
$fields_descriptions = empty($command['fields_descriptions']) ? case "postgresql":
'' : json_decode(io_safe_output($command['fields_descriptions']), true); // Descriptions are stored in json
$fields_descriptions = empty($command['fields_descriptions']) ?
// Fields values are stored in json '' : json_decode(io_safe_output($command['fields_descriptions']), true);
$fields_values = empty($command['fields_values']) ? html_debug($fields_descriptions,true);
'' : io_safe_output(json_decode($command['fields_values'], true)); // Fields values are stored in json
$fields_values = empty($command['fields_values']) ?
'' : io_safe_output(json_decode($command['fields_values'], true));
case "oracle":
// Descriptions are stored in json
$fields_descriptions = empty($command['fields_descriptions']) ?
'' : json_decode(io_safe_output(str_replace("\\","",$command['fields_descriptions'])), true);
html_debug($fields_descriptions,true);
// Fields values are stored in json
$fields_values = empty($command['fields_values']) ?
'' : io_safe_output(json_decode(str_replace("\\","",$command['fields_values']), true));
}
$fields_rows = array(); $fields_rows = array();
for ($i = 1; $i <= 10; $i++) { for ($i = 1; $i <= 10; $i++) {