Multilinguified Schemas

This commit is contained in:
Nate Jones
2013-06-21 16:02:05 +00:00
parent 5a94de2769
commit 2c50b240bf
14 changed files with 482 additions and 300 deletions
+12 -14
View File
@@ -49,12 +49,12 @@ require_once "includes/paging.php";
echo "<table width='100%' border='0'>\n";
echo "<tr>\n";
echo "<td width='50%' align=\"left\" nowrap=\"nowrap\"><b>Schema Name Values</b></td>\n";
echo "<td width='50%' align=\"left\" nowrap=\"nowrap\"><b>".$text['header-name_values']."</b></td>\n";
echo "<td width='50%' align=\"right\">&nbsp;</td>\n";
echo "</tr>\n";
echo "<tr>\n";
echo "<td align=\"left\" nowrap=\"nowrap\" colspan='2'>\n";
echo "Stores the name and value pairs.<br /><br />\n";
echo $text['description-name_values']."<br /><br />\n";
echo "</td>\n";
echo "</tr>\n";
echo "</tr></table>\n";
@@ -71,9 +71,9 @@ require_once "includes/paging.php";
//$rows_per_page = 10;
//$param = "";
//$page = $_GET['page'];
//if (strlen($page) == 0) { $page = 0; $_GET['page'] = 0; }
//list($paging_controls, $rows_per_page, $var_3) = paging($num_rows, $param, $rows_per_page);
//$offset = $rows_per_page * $page;
//if (strlen($page) == 0) { $page = 0; $_GET['page'] = 0; }
//list($paging_controls, $rows_per_page, $var_3) = paging($num_rows, $param, $rows_per_page);
//$offset = $rows_per_page * $page;
$sql = "select * from v_schema_name_values ";
$sql .= "where domain_uuid = '$domain_uuid' ";
@@ -93,10 +93,10 @@ require_once "includes/paging.php";
echo "<div align='center'>\n";
echo "<table width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
echo th_order_by('data_types_name', 'Name', $order_by, $order);
echo th_order_by('data_types_value', 'Value', $order_by, $order);
echo th_order_by('data_types_name', $text['label-name_value_name'], $order_by, $order);
echo th_order_by('data_types_value', $text['label-name_value_value'], $order_by, $order);
echo "<td align='right' width='42'>\n";
echo " <a href='schema_name_value_edit.php?schema_uuid=".$row["schema_uuid"]."&schema_field_uuid=".$row["schema_field_uuid"]."' alt='add'>$v_link_label_add</a>\n";
echo " <a href='schema_name_value_edit.php?schema_uuid=".$row["schema_uuid"]."&schema_field_uuid=".$row["schema_field_uuid"]."' alt='".$text['button-add']."'>$v_link_label_add</a>\n";
echo "</td>\n";
echo "<tr>\n";
@@ -106,13 +106,11 @@ require_once "includes/paging.php";
echo " <td valign='top' class='".$row_style[$c]."'>".$row[data_types_name]."</td>\n";
echo " <td valign='top' class='".$row_style[$c]."'>".$row[data_types_value]."</td>\n";
echo " <td valign='top' align='right'>\n";
echo " <a href='schema_name_value_edit.php?schema_uuid=".$row["schema_uuid"]."&schema_field_uuid=".$row["schema_field_uuid"]."&id=".$row["schema_name_value_uuid"]."' alt='edit'>$v_link_label_edit</a>\n";
echo " <a href='schema_name_value_delete.php?schema_uuid=".$row["schema_uuid"]."&schema_field_uuid=".$row["schema_field_uuid"]."&id=".$row["schema_name_value_uuid"]."' alt='delete' onclick=\"return confirm('Do you really want to delete this?')\">$v_link_label_delete</a>\n";
//echo " <input type='button' class='btn' name='' alt='edit' onclick=\"window.location='schema_name_value_edit.php?id=".$row["schema_name_value_uuid"]."'\" value='e'>\n";
//echo " <input type='button' class='btn' name='' alt='delete' onclick=\"if (confirm('Are you sure you want to delete this?')) { window.location='schema_name_value_delete.php?id=".$row["schema_name_value_uuid"]."' }\" value='x'>\n";
echo " <a href='schema_name_value_edit.php?schema_uuid=".$row["schema_uuid"]."&schema_field_uuid=".$row["schema_field_uuid"]."&id=".$row["schema_name_value_uuid"]."' alt='".$text['button-edit']."'>$v_link_label_edit</a>\n";
echo " <a href='schema_name_value_delete.php?schema_uuid=".$row["schema_uuid"]."&schema_field_uuid=".$row["schema_field_uuid"]."&id=".$row["schema_name_value_uuid"]."' alt='".$text['button-delete']."' onclick=\"return confirm('".$text['confirm-delete']."')\">$v_link_label_delete</a>\n";
echo " </td>\n";
echo "</tr>\n";
if ($c==0) { $c=1; } else { $c=0; }
$c = ($c==0) ? 1 : 0;
} //end foreach
unset($sql, $result, $row_count);
} //end if results
@@ -125,7 +123,7 @@ require_once "includes/paging.php";
echo " <td width='33.3%' nowrap>&nbsp;</td>\n";
//echo " <td width='33.3%' align='center' nowrap>$paging_controls</td>\n";
echo " <td width='33.3%' align='right'>\n";
echo " <a href='schema_name_value_edit.php?schema_uuid=".$row["schema_uuid"]."&schema_field_uuid=".$row["schema_field_uuid"]."' alt='add'>$v_link_label_add</a>\n";
echo " <a href='schema_name_value_edit.php?schema_uuid=".$row["schema_uuid"]."&schema_field_uuid=".$row["schema_field_uuid"]."' alt='".$text['button-add']."'>$v_link_label_add</a>\n";
echo " </td>\n";
echo " </tr>\n";
echo " </table>\n";