| 1 |
<?php |
<?php |
| 2 |
|
// $Id$ |
| 3 |
|
|
| 4 |
/** |
/** |
| 5 |
* @file |
* @file |
| 25 |
if ($connection == 'default') { |
if ($connection == 'default') { |
| 26 |
$rawtablename = schema_unprefix_table($tablename); |
$rawtablename = schema_unprefix_table($tablename); |
| 27 |
$disptablename = $tablename; |
$disptablename = $tablename; |
| 28 |
} else { |
} |
| 29 |
|
else { |
| 30 |
$rawtablename = $tablename; |
$rawtablename = $tablename; |
| 31 |
$disptablename = $connection . '.' . $tablename; |
$disptablename = $connection . '.' . $tablename; |
| 32 |
} |
} |
| 106 |
'base field' => $col2, |
'base field' => $col2, |
| 107 |
'label' => t("Join $tbl1 to $tbl2"), |
'label' => t("Join $tbl1 to $tbl2"), |
| 108 |
); |
); |
| 109 |
} else { |
} |
| 110 |
|
else { |
| 111 |
$i++; |
$i++; |
| 112 |
$mungedcol = $col1.'_'.$i; |
$mungedcol = $col1 . '_' . $i; |
| 113 |
$tables[$rawtbl1][$mungedcol] = $tables[$rawtbl1][$col1]; |
$tables[$rawtbl1][$mungedcol] = $tables[$rawtbl1][$col1]; |
| 114 |
$tables[$rawtbl1][$mungedcol]['title'] = t("$col1 (joins to $tbl2)"); |
$tables[$rawtbl1][$mungedcol]['title'] = t("$col1 (joins to $tbl2)"); |
| 115 |
$tables[$rawtbl1][$mungedcol]['real field'] = $col1; |
$tables[$rawtbl1][$mungedcol]['real field'] = $col1; |
| 125 |
} |
} |
| 126 |
|
|
| 127 |
/** |
/** |
| 128 |
* Enter description here... |
* Return a views handler based on the column type. |
|
* |
|
|
* @param unknown_type $sqltype |
|
|
* @return unknown |
|
| 129 |
*/ |
*/ |
| 130 |
function _tw_views_handler_type($sqltype) { |
function _tw_views_handler_type($sqltype) { |
| 131 |
preg_match('/^[a-zA-Z]+/', $sqltype, $matches); |
preg_match('/^[a-zA-Z]+/', $sqltype, $matches); |