Added translation of email templates
This commit is contained in:
@@ -94,6 +94,10 @@ class TranslationsController extends BaseAdminController
|
||||
case 'pf' :
|
||||
$template = new TemplateDefinition($item_id, TemplateDefinition::PDF);
|
||||
break;
|
||||
|
||||
case 'ma' :
|
||||
$template = new TemplateDefinition($item_id, TemplateDefinition::EMAIL);
|
||||
break;
|
||||
}
|
||||
|
||||
if ($template) {
|
||||
|
||||
@@ -64,7 +64,8 @@ class Template extends BaseLoop implements ArraySearchLoopInterface
|
||||
new Type\EnumListType(array(
|
||||
'front-office',
|
||||
'back-office',
|
||||
'pdf'
|
||||
'pdf',
|
||||
'email'
|
||||
))
|
||||
)
|
||||
)
|
||||
@@ -80,6 +81,8 @@ class Template extends BaseLoop implements ArraySearchLoopInterface
|
||||
$templateType = TemplateDefinition::BACK_OFFICE;
|
||||
else if ($type == 'pdf')
|
||||
$templateType = TemplateDefinition::PDF;
|
||||
else if ($type == 'email')
|
||||
$templateType = TemplateDefinition::EMAIL;
|
||||
|
||||
return TemplateHelper::getInstance()->getList($templateType);
|
||||
}
|
||||
|
||||
@@ -45,6 +45,7 @@
|
||||
<option value="">{intl l='Please select items to translate'}</option>
|
||||
<option value="fo" {if $item_to_translate=='fo'}selected="selected"{/if}>{intl l='Front-office templates'}</option>
|
||||
<option value="pf" {if $item_to_translate=='pf'}selected="selected"{/if}>{intl l='PDF templates'}</option>
|
||||
<option value="ma" {if $item_to_translate=='ma'}selected="selected"{/if}>{intl l='E-mail templates'}</option>
|
||||
<option value="bo" {if $item_to_translate=='bo'}selected="selected"{/if}>{intl l='Back-office templates'}</option>
|
||||
<option value="mo" {if $item_to_translate=='mo'}selected="selected"{/if}>{intl l='Modules'}</option>
|
||||
<option value="co" {if $item_to_translate=='co'}selected="selected"{/if}>{intl l='Thelia core'}</option>
|
||||
@@ -91,6 +92,19 @@
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
{else if $item_to_translate == 'ma'}
|
||||
<div class="col-md-4 item-id-selector">
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="item_id">{intl l='Select the E-mail template you want to translate'}</label>
|
||||
|
||||
<select id="item_id" required="required" name="item_id" class="submit-on-change form-control">
|
||||
<option value="">{intl l='Please select the E-mail template to translate'}</option>
|
||||
{loop type="template" name="translate-fo-template" template-type="email" backend_context=1}
|
||||
<option value="{$NAME}" {if $item_id == $NAME}selected="selected"{/if}>{$NAME}</option>
|
||||
{/loop}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
{else if $item_to_translate == 'pf'}
|
||||
<div class="col-md-4 item-id-selector">
|
||||
<div class="form-group">
|
||||
|
||||
4
templates/email/default/I18n/en_US.php
Normal file
4
templates/email/default/I18n/en_US.php
Normal file
@@ -0,0 +1,4 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
);
|
||||
4
templates/email/default/I18n/es_ES.php
Normal file
4
templates/email/default/I18n/es_ES.php
Normal file
@@ -0,0 +1,4 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
);
|
||||
4
templates/email/default/I18n/fr_FR.php
Normal file
4
templates/email/default/I18n/fr_FR.php
Normal file
@@ -0,0 +1,4 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
);
|
||||
4
templates/email/default/I18n/it_IT.php
Normal file
4
templates/email/default/I18n/it_IT.php
Normal file
@@ -0,0 +1,4 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
);
|
||||
Reference in New Issue
Block a user