Version Notes
Release 1.1.3
Download this release
Release Info
Developer | Magento Core Team |
Extension | Phpro_Translate |
Version | 1.1.3 |
Comparing to | |
See all releases |
Code changes from version 1.1.2 to 1.1.3
- app/code/community/Phpro/Translate/Block/System/Config/Info/Magento.php +8 -0
- app/code/community/Phpro/Translate/Block/System/Config/Info/Module.php +11 -0
- app/code/community/Phpro/Translate/Helper/Data.php +0 -3
- app/code/community/Phpro/Translate/Model/Translator.php +0 -4
- app/code/community/Phpro/Translate/controllers/TranslationsController.php +1 -3
- app/code/community/Phpro/Translate/etc/config.xml +1 -1
- app/code/community/Phpro/Translate/etc/system.xml +28 -0
- app/locale/en_US/Phpro_Translate.csv +3 -1
- app/locale/fr_FR/Phpro_Translate.csv +3 -1
- app/locale/nl_NL/Phpro_Translate.csv +3 -1
- package.xml +5 -6
app/code/community/Phpro/Translate/Block/System/Config/Info/Magento.php
ADDED
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
class Phpro_Translate_Block_System_Config_Info_Magento extends Mage_Adminhtml_Block_System_Config_Form_Field {
|
4 |
+
|
5 |
+
public function _getElementHtml(Varien_Data_Form_Element_Abstract $element) {
|
6 |
+
return Mage::getVersion();
|
7 |
+
}
|
8 |
+
}
|
app/code/community/Phpro/Translate/Block/System/Config/Info/Module.php
ADDED
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
class Phpro_Translate_Block_System_Config_Info_Module extends Mage_Adminhtml_Block_System_Config_Form_Field {
|
4 |
+
|
5 |
+
public function _getElementHtml(Varien_Data_Form_Element_Abstract $element) {
|
6 |
+
$modules = Mage::getConfig()->getNode('modules')->children();
|
7 |
+
$modulesArray = (array)$modules;
|
8 |
+
|
9 |
+
return $modulesArray['Phpro_Translate']->version;
|
10 |
+
}
|
11 |
+
}
|
app/code/community/Phpro/Translate/Helper/Data.php
CHANGED
@@ -37,10 +37,7 @@ class Phpro_Translate_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
37 |
if (in_array($interface, $this->getTranslationInterfaces())) {
|
38 |
if ($this->isGroupLogging()) {
|
39 |
$locales = explode(',', $this->getLocales());
|
40 |
-
Mage::log($locale);
|
41 |
-
Mage::log($locales);
|
42 |
if (in_array($locale, $locales) && $locale != 'en_US') {
|
43 |
-
Mage::log("Charlie Sheen says $locale is winning!");
|
44 |
$allowed = true;
|
45 |
}
|
46 |
}
|
37 |
if (in_array($interface, $this->getTranslationInterfaces())) {
|
38 |
if ($this->isGroupLogging()) {
|
39 |
$locales = explode(',', $this->getLocales());
|
|
|
|
|
40 |
if (in_array($locale, $locales) && $locale != 'en_US') {
|
|
|
41 |
$allowed = true;
|
42 |
}
|
43 |
}
|
app/code/community/Phpro/Translate/Model/Translator.php
CHANGED
@@ -291,14 +291,10 @@ class Phpro_Translate_Model_Translator extends Mage_Core_Model_Translate {
|
|
291 |
$scopeKey = $this->_dataScope[$key] . self::SCOPE_SEPARATOR . $key;
|
292 |
if (!isset($this->_data[$scopeKey])) {
|
293 |
if (isset($this->_data[$key])) {
|
294 |
-
$this->_data[$scopeKey] = $this->_data[$key];
|
295 |
-
Mage::log('two strings exist');
|
296 |
-
Mage::log($this->_data[$key]);
|
297 |
/**
|
298 |
* Not allow use translation not related to module
|
299 |
*/
|
300 |
if (Mage::getIsDeveloperMode()) {
|
301 |
-
Mage::log(', but Mage is developer mode, so we delete one.');
|
302 |
unset($this->_data[$key]);
|
303 |
}
|
304 |
}
|
291 |
$scopeKey = $this->_dataScope[$key] . self::SCOPE_SEPARATOR . $key;
|
292 |
if (!isset($this->_data[$scopeKey])) {
|
293 |
if (isset($this->_data[$key])) {
|
|
|
|
|
|
|
294 |
/**
|
295 |
* Not allow use translation not related to module
|
296 |
*/
|
297 |
if (Mage::getIsDeveloperMode()) {
|
|
|
298 |
unset($this->_data[$key]);
|
299 |
}
|
300 |
}
|
app/code/community/Phpro/Translate/controllers/TranslationsController.php
CHANGED
@@ -77,8 +77,6 @@ class Phpro_Translate_TranslationsController extends Mage_Adminhtml_Controller_A
|
|
77 |
$locale = $request->getParam('locale');
|
78 |
$storeId = $request->getParam('storeid');
|
79 |
$storeViewSpecific = $request->getParam('storeview_specific');
|
80 |
-
|
81 |
-
Mage::log($original);
|
82 |
|
83 |
if ($namespace != '') {
|
84 |
$explode = explode('::', $original);
|
@@ -201,7 +199,7 @@ class Phpro_Translate_TranslationsController extends Mage_Adminhtml_Controller_A
|
|
201 |
|
202 |
$results = Mage::getModel('core/translate')->removeDuplicatesInTable();
|
203 |
|
204 |
-
Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('translate')->__('Following duplicates are found and removed
|
205 |
$this->_redirect('*/*/');
|
206 |
}
|
207 |
|
77 |
$locale = $request->getParam('locale');
|
78 |
$storeId = $request->getParam('storeid');
|
79 |
$storeViewSpecific = $request->getParam('storeview_specific');
|
|
|
|
|
80 |
|
81 |
if ($namespace != '') {
|
82 |
$explode = explode('::', $original);
|
199 |
|
200 |
$results = Mage::getModel('core/translate')->removeDuplicatesInTable();
|
201 |
|
202 |
+
Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('translate')->__('Following duplicates are found and removed:') . '<ul>' . implode($results, '\n') . '</ul>');
|
203 |
$this->_redirect('*/*/');
|
204 |
}
|
205 |
|
app/code/community/Phpro/Translate/etc/config.xml
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Phpro_Translate>
|
5 |
-
<version>1.1.
|
6 |
</Phpro_Translate>
|
7 |
</modules>
|
8 |
<phpunit>
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Phpro_Translate>
|
5 |
+
<version>1.1.3</version>
|
6 |
</Phpro_Translate>
|
7 |
</modules>
|
8 |
<phpunit>
|
app/code/community/Phpro/Translate/etc/system.xml
CHANGED
@@ -16,6 +16,34 @@
|
|
16 |
<show_in_website>0</show_in_website>
|
17 |
<show_in_store>0</show_in_store>
|
18 |
<groups>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
19 |
<general translate="label">
|
20 |
<label>Translate options</label>
|
21 |
<frontend_type>text</frontend_type>
|
16 |
<show_in_website>0</show_in_website>
|
17 |
<show_in_store>0</show_in_store>
|
18 |
<groups>
|
19 |
+
<info>
|
20 |
+
<label>Module information</label>
|
21 |
+
<frontend_type>text</frontend_type>
|
22 |
+
<sort_order>0</sort_order>
|
23 |
+
<show_in_default>1</show_in_default>
|
24 |
+
<show_in_website>1</show_in_website>
|
25 |
+
<show_in_store>1</show_in_store>
|
26 |
+
<fields>
|
27 |
+
<module_version translate="label">
|
28 |
+
<label>Module version</label>
|
29 |
+
<frontend_type>label</frontend_type>
|
30 |
+
<frontend_model>translate/system_config_info_module</frontend_model>
|
31 |
+
<sort_order>1</sort_order>
|
32 |
+
<show_in_default>1</show_in_default>
|
33 |
+
<show_in_website>0</show_in_website>
|
34 |
+
<show_in_store>0</show_in_store>
|
35 |
+
</module_version>
|
36 |
+
<magento_version translate="label">
|
37 |
+
<label>Magento version</label>
|
38 |
+
<frontend_type>label</frontend_type>
|
39 |
+
<frontend_model>translate/system_config_info_magento</frontend_model>
|
40 |
+
<sort_order>2</sort_order>
|
41 |
+
<show_in_default>1</show_in_default>
|
42 |
+
<show_in_website>0</show_in_website>
|
43 |
+
<show_in_store>0</show_in_store>
|
44 |
+
</magento_version>
|
45 |
+
</fields>
|
46 |
+
</info>
|
47 |
<general translate="label">
|
48 |
<label>Translate options</label>
|
49 |
<frontend_type>text</frontend_type>
|
app/locale/en_US/Phpro_Translate.csv
CHANGED
@@ -40,4 +40,6 @@ Edit Item,Edit Item
|
|
40 |
Save Item,Save Item
|
41 |
No results found.,No results found.
|
42 |
Remove all the records from the "untransalated strings" table,Remove all the records from the "untranslated strings" table
|
43 |
-
Remove duplicate strings that are in the system and "untranslated strings" table, Remove duplicate strings that are in the system and "untranslated strings" table
|
|
|
|
40 |
Save Item,Save Item
|
41 |
No results found.,No results found.
|
42 |
Remove all the records from the "untransalated strings" table,Remove all the records from the "untranslated strings" table
|
43 |
+
Remove duplicate strings that are in the system and "untranslated strings" table, Remove duplicate strings that are in the system and "untranslated strings" table
|
44 |
+
Table truncated,Table truncated
|
45 |
+
Following duplicates are found and removed:,Following duplicates are found and removed:
|
app/locale/fr_FR/Phpro_Translate.csv
CHANGED
@@ -40,4 +40,6 @@ Edit Item,Editer
|
|
40 |
Save Item,Sauvegarder
|
41 |
No results found.,Pas de résultats trouvé.
|
42 |
Remove all the records from the "untransalated strings" table,Supprimer toutes les enregistrements de la table texte non traduite
|
43 |
-
Remove duplicate strings that are in the system and "untranslated strings" table, Supprimer des doublons qui sont dans le système et la table texte non traduite
|
|
|
|
40 |
Save Item,Sauvegarder
|
41 |
No results found.,Pas de résultats trouvé.
|
42 |
Remove all the records from the "untransalated strings" table,Supprimer toutes les enregistrements de la table texte non traduite
|
43 |
+
Remove duplicate strings that are in the system and "untranslated strings" table, Supprimer des doublons qui sont dans le système et la table texte non traduite
|
44 |
+
Table truncated,Table tronqu�
|
45 |
+
Following duplicates are found and removed:,Les doublons suivante sont trouv&eactue; et supprim&eactue;:
|
app/locale/nl_NL/Phpro_Translate.csv
CHANGED
@@ -40,4 +40,6 @@ Edit Item,Aanpassen
|
|
40 |
Save Item,Bewaren
|
41 |
No results found., Geen resultaten gevonden.
|
42 |
Remove all the records from the "untransalated strings" table, Verwijder alle records uit de tabel met onvertaalde tekst
|
43 |
-
Remove duplicate strings that are in the system and "untranslated strings" table, Verwijder dubbele tekst in het systeem en de onvertaalde tekst tabel
|
|
|
|
40 |
Save Item,Bewaren
|
41 |
No results found., Geen resultaten gevonden.
|
42 |
Remove all the records from the "untransalated strings" table, Verwijder alle records uit de tabel met onvertaalde tekst
|
43 |
+
Remove duplicate strings that are in the system and "untranslated strings" table, Verwijder dubbele tekst in het systeem en de onvertaalde tekst tabel
|
44 |
+
Table truncated,Tabel geleegd
|
45 |
+
Following duplicates are found and removed:,De volgende dubbels zijn gevonden en verwijderd:
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Phpro_Translate</name>
|
4 |
-
<version>1.1.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
|
7 |
<channel>community</channel>
|
@@ -9,12 +9,11 @@
|
|
9 |
<summary>A tool to locate untranslated strings in your store</summary>
|
10 |
<description>This tool keeps an eye out for untranslated strings and reports them to the user.
|
11 |
You can edit untranslated string or existing translation</description>
|
12 |
-
<notes>
|
13 |
-
Also translated the module itself.</notes>
|
14 |
<authors><author><name>PHPro</name><user>auto-converted</user><email>info@phpro.be</email></author></authors>
|
15 |
-
<date>2012-
|
16 |
-
<time>14:
|
17 |
-
<contents><target name="magecommunity"><dir name="Phpro"><dir name="Translate"><dir name="Block"><dir name="Adminhtml"><dir name="Edit"><file name="Form.php" hash="82316209e2389a5f0e5b8e64f6c567a8"/><file name="Tabs.php" hash="ab7c8279caf43f38554f0c23888d637c"/></dir><dir name="Renderer"><file name="String.php" hash="146ce9be5e0819258462f5df1d45da2c"/></dir><file name="About.php" hash="5bdb23632c813038095ecfb3016903ba"/><file name="Edit.php" hash="f24357792a565c941941ab77a03d31b3"/><file name="Form.php" hash="1ea03e4f2d63cc44a641ea1d9b2fd335"/><file name="Grid.php" hash="800962533cf19452134b4f21ba33ca5e"/><file name="Stats.php" hash="e417bb01d58a45d0ca808e1706402af8"/><file name="Tabs.php" hash="d3ba4d7d95844834224d633a83a96330"/><file name="Translate.php" hash="f78afcd2f8002a672851959760595efd"/><file name="TranslateResult.php" hash="e08ba5cf9d142f2f4404c0deff111e94"/></dir></dir><dir name="Helper"><file name="Data.php" hash="
|
18 |
<compatible/>
|
19 |
<dependencies/>
|
20 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Phpro_Translate</name>
|
4 |
+
<version>1.1.3</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
|
7 |
<channel>community</channel>
|
9 |
<summary>A tool to locate untranslated strings in your store</summary>
|
10 |
<description>This tool keeps an eye out for untranslated strings and reports them to the user.
|
11 |
You can edit untranslated string or existing translation</description>
|
12 |
+
<notes>Release 1.1.3</notes>
|
|
|
13 |
<authors><author><name>PHPro</name><user>auto-converted</user><email>info@phpro.be</email></author></authors>
|
14 |
+
<date>2012-07-10</date>
|
15 |
+
<time>14:13:00</time>
|
16 |
+
<contents><target name="magecommunity"><dir name="Phpro"><dir name="Translate"><dir name="Block"><dir name="Adminhtml"><dir name="Edit"><file name="Form.php" hash="82316209e2389a5f0e5b8e64f6c567a8"/><file name="Tabs.php" hash="ab7c8279caf43f38554f0c23888d637c"/></dir><dir name="Renderer"><file name="String.php" hash="146ce9be5e0819258462f5df1d45da2c"/></dir><file name="About.php" hash="5bdb23632c813038095ecfb3016903ba"/><file name="Edit.php" hash="f24357792a565c941941ab77a03d31b3"/><file name="Form.php" hash="1ea03e4f2d63cc44a641ea1d9b2fd335"/><file name="Grid.php" hash="800962533cf19452134b4f21ba33ca5e"/><file name="Stats.php" hash="e417bb01d58a45d0ca808e1706402af8"/><file name="Tabs.php" hash="d3ba4d7d95844834224d633a83a96330"/><file name="Translate.php" hash="f78afcd2f8002a672851959760595efd"/><file name="TranslateResult.php" hash="e08ba5cf9d142f2f4404c0deff111e94"/></dir><dir name="System"><dir name="Config"><dir name="Info"><file name="Magento.php" hash="790e80facad365fa0b48d12f68ffb4b2"/><file name="Module.php" hash="88d883139c192d3f3d62c7024bdeefd5"/></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="520e56cee45760f8762a31ff4cf0335b"/></dir><dir name="Model"><dir name="Mysql4"><dir name="Translate"><file name="Collection.php" hash="724672e61cd9c4de91938f4189c229fe"/></dir><file name="Translate.php" hash="a812ee20cd14226464701f16c9e0bc1b"/></dir><dir name="System"><dir name="Config"><dir name="Source"><dir name="Store"><file name="Locales.php" hash="485c16c61f66a18f0684e81da180f7e1"/></dir><file name="Groups.php" hash="7654613534e2b5dd23d8a656af7ea6c1"/><file name="Interface.php" hash="2c7827684b00b655f1818300bd581691"/><file name="Locales.php" hash="b56472fc4c77ef82c14f8daebc12f1b0"/><file name="Modules.php" hash="763418cbf8d8fb377eafde6efd542538"/><file name="Stores.php" hash="dd8a59da45b74e48134f2fd3a6f6658b"/></dir></dir></dir><file name="Translate.php" hash="1cb0c7167c2a0bd42a20c0f972e966a7"/><file name="Translation.php" hash="d256e2c56d01267d33b7005c6ec163b7"/><file name="Translator.php" hash="c1d134f45ab4dea5f94984c0143e7634"/></dir><dir name="Test"><dir name="Block"><dir name="Adminhtml"><dir name="Form"><dir name="fixtures"><file name="defaultsetup.yaml" hash="e699d7579b8a496071b2a1a94ee20e45"/></dir></dir><dir name="Grid"><dir name="fixtures"><file name="defaultsetup.yaml" hash="467aefacab1a43e34732d74ea8e79829"/></dir></dir><file name="Form.php" hash="46464733fb219ddecad9129270f44af4"/><file name="Grid.php" hash="9b1dc9baa217d2ccde6cc1ac9efb7c17"/></dir></dir><dir name="Controller"><dir name="IndexController"><dir name="fixtures"><file name="translation_logging_disabled.yaml" hash="cb202eff6b35ec5b58c7596a3cd70434"/><file name="translation_logging_enabled.yaml" hash="86d0fbbe5c1b95cae8eb21c6b460ee75"/></dir></dir><dir name="TranslationsController"><dir name="fixtures"><file name="admin_user.yaml" hash="b24e11045ac495034e61a60b5d9f154b"/><file name="core_config_data.yaml" hash="0009c2ba1904b61778b107ceeefc0929"/><file name="core_translate.yaml" hash="98c3c9b5f1389401782d6d4a189c8bbc"/><file name="phpro_advancedtranslate.yaml" hash="fb9229ae95bea8d859df7e0274703444"/><file name="stores.yaml" hash="11f6ecac0f2a04c19a0538b789c630d9"/></dir></dir><file name="IndexController.php" hash="fbe579e0066bccfce35180cfb211127f"/><file name="TranslationsController.php" hash="4e43fe0445bec36cb9ba6900d4fdf283"/></dir><dir name="Helper"><dir name="Data"><dir name="fixtures"><file name="core_config_data.yaml" hash="c5f01d5ab9b8adfd29a5bbae1bd00640"/></dir></dir><file name="Data.php" hash="f69d3394a213113f57b91910ca20e2d9"/></dir><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><dir name="Locales"><dir name="fixtures"><file name="phpro_advancedtranslate.yaml" hash="513469551ef0b51e3608fca2c19049bb"/></dir></dir><dir name="Store"><dir name="Locales"><dir name="fixtures"><file name="core_config_data.yaml" hash="313f20d823ae4e41fb1518796300a729"/><file name="stores.yaml" hash="150e0ea6d518e3885d2046467fae6269"/></dir></dir><file name="Locales.php" hash="39c76892a4a6215f8d962f77aabe356c"/></dir><dir name="Stores"><dir name="fixtures"><file name="core_config_data.yaml" hash="313f20d823ae4e41fb1518796300a729"/><file name="phpro_advancedtranslate.yaml" hash="f49111ff655c87127d246f65b8d167a0"/><file name="stores.yaml" hash="fb78978542ca38c5a33504079afe225f"/></dir></dir><file name="Locales.php" hash="909e96abc09832b89ef12a02f91053f7"/><file name="Stores.php" hash="3f587d212b39b533be60d607a9c35ec0"/></dir></dir></dir><dir name="Translate"><dir name="fixtures"><file name="core_translate.yaml" hash="8df16aa3c10434b936253ec64d817f8b"/><file name="stores.yaml" hash="f37ffbb2c1a29083ba86263a27aaeb62"/></dir></dir><file name="Translator.php" hash="cd3ae824b78815c404142d63b4cbd7c2"/></dir></dir><dir name="controllers"><file name="TranslationsController.php" hash="681eb0d80243e4423e4ab363bfc8e5cf"/></dir><dir name="etc"><file name="config.xml" hash="b893360e947b74c9d931b25b2e9d4f5a"/><file name="system.xml" hash="894d913a3f85a08add7176347a0460cb"/></dir><dir name="sql"><dir name="translate_setup"><file name="mysql4-install-0.1.0.php" hash="ed1f0b0012f9e460b537c51b3f2fbe8c"/><file name="mysql4-upgrade-0.1.0-0.1.1.php" hash="a75e2a8efd55bf1d440a599274d1d669"/><file name="mysql4-upgrade-1.1.0-1.1.1.php" hash="f7a3bf7a9579d1ac1b4e9f657421455d"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="translate.xml" hash="d6f83b0a0a47c1f5f9b9438052fcb9e4"/></dir><dir name="template"><dir name="translate"><file name="about.phtml" hash="0d13f0ff640d3c53eef96cfa03b4fb00"/><file name="container.phtml" hash="beb35d0c45a9f59d6d21046456046c3c"/><file name="search.phtml" hash="84fd8f11d0c24e3ae0233b8578a9e06f"/><file name="translateresult.phtml" hash="40efb67fef21e6c81b26b8e0131b9a38"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Phpro_Translate.xml" hash="93cf18237a2bd21f27e3046ceacf7f27"/></dir></target><target name="mageweb"><dir name="js"><dir name="phpro"><file name="translate.js" hash="e5a2a8d282e96b36962df049e41649cb"/></dir></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="phpro"><file name="gridfix.css" hash="ebc173f92bbd2b72b5e7e47f36748e72"/></dir></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="Phpro_Translate.csv" hash="0d65191465cbe114c58d6eb8e492eff7"/></dir><dir name="nl_NL"><file name="Phpro_Translate.csv" hash="077917c3ec5765a0d345fae9e656c60c"/></dir><dir name="fr_FR"><file name="Phpro_Translate.csv" hash="e2b4c2522b586ddb23b5913bbe706086"/></dir></target></contents>
|
17 |
<compatible/>
|
18 |
<dependencies/>
|
19 |
</package>
|