[Vtigercrm-commits] [vtiger-commits] r9930 - in /vtigercrm/branches/5.0.3: Smarty/templates/CustomView.tpl modules/CustomView/EditView.php
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Fri Dec 1 06:41:56 EST 2006
Author: richie
Date: Fri Dec 1 04:41:49 2006
New Revision: 9930
Log:
i18N support added for custom filter columns
Modified:
vtigercrm/branches/5.0.3/Smarty/templates/CustomView.tpl
vtigercrm/branches/5.0.3/modules/CustomView/EditView.php
Modified: vtigercrm/branches/5.0.3/Smarty/templates/CustomView.tpl
==============================================================================
--- vtigercrm/branches/5.0.3/Smarty/templates/CustomView.tpl (original)
+++ vtigercrm/branches/5.0.3/Smarty/templates/CustomView.tpl Fri Dec 1 04:41:49 2006
@@ -146,7 +146,18 @@
{foreach item=filteroption key=label from=$CHOOSECOLUMN1}
<optgroup label="{$label}" class=\"select\" style=\"border:none\">
{foreach item=text from=$filteroption}
- <option {$text.selected} value={$text.value}>{$text.text}</option>
+ {assign var=option_values value=$text.text}
+ <option {$text.selected} value={$text.value}>
+ {if $MOD.$option_values neq ''}
+ {$MOD.$option_values}
+
+ {elseif $APP.$option_values neq ''}
+ {$APP.$option_values}
+
+ {else}
+ {$option_values}
+ {/if}
+</option>
{/foreach}
{/foreach}
{$CHOOSECOLUMN1}
@@ -156,7 +167,18 @@
{foreach item=filteroption key=label from=$CHOOSECOLUMN2}
<optgroup label="{$label}" class=\"select\" style=\"border:none\">
{foreach item=text from=$filteroption}
- <option {$text.selected} value={$text.value}>{$text.text}</option>
+ {assign var=option_values value=$text.text}
+ <option {$text.selected} value={$text.value}>
+ {if $MOD.$option_values neq ''}
+ {$MOD.$option_values}
+
+ {elseif $APP.$option_values neq ''}
+ {$APP.$option_values}
+
+ {else}
+ {$option_values}
+ {/if}
+</option>
{/foreach}
{/foreach}
{$CHOOSECOLUMN2}
@@ -166,7 +188,18 @@
{foreach item=filteroption key=label from=$CHOOSECOLUMN3}
<optgroup label="{$label}" class=\"select\" style=\"border:none\">
{foreach item=text from=$filteroption}
- <option {$text.selected} value={$text.value}>{$text.text}</option>
+ {assign var=option_values value=$text.text}
+ <option {$text.selected} value={$text.value}>
+ {if $MOD.$option_values neq ''}
+ {$MOD.$option_values}
+
+ {elseif $APP.$option_values neq ''}
+ {$APP.$option_values}
+
+ {else}
+ {$option_values}
+ {/if}
+</option>
{/foreach}
{/foreach}
{$CHOOSECOLUMN3}
@@ -176,7 +209,18 @@
{foreach item=filteroption key=label from=$CHOOSECOLUMN4}
<optgroup label="{$label}" class=\"select\" style=\"border:none\">
{foreach item=text from=$filteroption}
- <option {$text.selected} value={$text.value}>{$text.text}</option>
+ {assign var=option_values value=$text.text}
+ <option {$text.selected} value={$text.value}>
+ {if $MOD.$option_values neq ''}
+ {$MOD.$option_values}
+
+ {elseif $APP.$option_values neq ''}
+ {$APP.$option_values}
+
+ {else}
+ {$option_values}
+ {/if}
+</option>
{/foreach}
{/foreach}
{$CHOOSECOLUMN4}
@@ -189,7 +233,18 @@
{foreach item=filteroption key=label from=$CHOOSECOLUMN5}
<optgroup label="{$label}" class=\"select\" style=\"border:none\">
{foreach item=text from=$filteroption}
- <option {$text.selected} value={$text.value}>{$text.text}</option>
+ {assign var=option_values value=$text.text}
+ <option {$text.selected} value={$text.value}>
+ {if $MOD.$option_values neq ''}
+ {$MOD.$option_values}
+
+ {elseif $APP.$option_values neq ''}
+ {$APP.$option_values}
+
+ {else}
+ {$option_values}
+ {/if}
+</option>
{/foreach}
{/foreach}
{$CHOOSECOLUMN5}
@@ -199,7 +254,18 @@
{foreach item=filteroption key=label from=$CHOOSECOLUMN6}
<optgroup label="{$label}" class=\"select\" style=\"border:none\">
{foreach item=text from=$filteroption}
- <option {$text.selected} value={$text.value}>{$text.text}</option>
+ {assign var=option_values value=$text.text}
+ <option {$text.selected} value={$text.value}>
+ {if $MOD.$option_values neq ''}
+ {$MOD.$option_values}
+
+ {elseif $APP.$option_values neq ''}
+ {$APP.$option_values}
+
+ {else}
+ {$option_values}
+ {/if}
+</option>
{/foreach}
{/foreach}
{$CHOOSECOLUMN6}
@@ -209,7 +275,18 @@
{foreach item=filteroption key=label from=$CHOOSECOLUMN7}
<optgroup label="{$label}" class=\"select\" style=\"border:none\">
{foreach item=text from=$filteroption}
- <option {$text.selected} value={$text.value}>{$text.text}</option>
+ {assign var=option_values value=$text.text}
+ <option {$text.selected} value={$text.value}>
+ {if $MOD.$option_values neq ''}
+ {$MOD.$option_values}
+
+ {elseif $APP.$option_values neq ''}
+ {$APP.$option_values}
+
+ {else}
+ {$option_values}
+ {/if}
+</option>
{/foreach}
{/foreach}
{$CHOOSECOLUMN7}
@@ -219,7 +296,18 @@
{foreach item=filteroption key=label from=$CHOOSECOLUMN8}
<optgroup label="{$label}" class=\"select\" style=\"border:none\">
{foreach item=text from=$filteroption}
- <option {$text.selected} value={$text.value}>{$text.text}</option>
+ {assign var=option_values value=$text.text}
+ <option {$text.selected} value={$text.value}>
+ {if $MOD.$option_values neq ''}
+ {$MOD.$option_values}
+
+ {elseif $APP.$option_values neq ''}
+ {$APP.$option_values}
+
+ {else}
+ {$option_values}
+ {/if}
+</option>
{/foreach}
{/foreach}
{$CHOOSECOLUMN8}
@@ -231,7 +319,18 @@
{foreach item=filteroption key=label from=$CHOOSECOLUMN9}
<optgroup label="{$label}" class=\"select\" style=\"border:none\">
{foreach item=text from=$filteroption}
- <option {$text.selected} value={$text.value}>{$text.text}</option>
+ {assign var=option_values value=$text.text}
+ <option {$text.selected} value={$text.value}>
+ {if $MOD.$option_values neq ''}
+ {$MOD.$option_values}
+
+ {elseif $APP.$option_values neq ''}
+ {$APP.$option_values}
+
+ {else}
+ {$option_values}
+ {/if}
+</option>
{/foreach}
{/foreach}
{$CHOOSECOLUMN9}
Modified: vtigercrm/branches/5.0.3/modules/CustomView/EditView.php
==============================================================================
--- vtigercrm/branches/5.0.3/modules/CustomView/EditView.php (original)
+++ vtigercrm/branches/5.0.3/modules/CustomView/EditView.php Fri Dec 1 04:41:49 2006
@@ -54,7 +54,7 @@
$log->info('CustomView :: Successfully got StandardFilter for the module'.$cv_module);
$stdfiltercolhtml = getStdFilterHTML($cv_module);
$stdfilterjs = $oCustomView->getCriteriaJS();
-
+ $smarty->assign("MOD",$mod_strings);
//step4
$advfilterhtml = getAdvCriteriaHTML();
for($i=1;$i<10;$i++)
More information about the vtigercrm-commits
mailing list