Skip to content

Commit

Permalink
Merge pull request #16 from ggoffy/master
Browse files Browse the repository at this point in the history
 - moved to RC1
  • Loading branch information
ggoffy authored Jul 26, 2020
2 parents c7f7995 + 09dac77 commit 75f177e
Show file tree
Hide file tree
Showing 17 changed files with 62 additions and 51 deletions.
1 change: 1 addition & 0 deletions _TODO.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
notification is not working

add style bootstrap

Expand Down
15 changes: 15 additions & 0 deletions admin/languages.php
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,21 @@
}
$GLOBALS['xoopsTpl']->assign('error', $languagesObj->getHtmlErrors());
break;
case 'setonlineall':
$langOnline = Request::getInt('lang_online', 0);
$languagesAll = $languagesHandler->getAllLanguages($start, $limit);
foreach (\array_keys($languagesAll) as $i) {
$languagesObj = $languagesHandler->get($languagesAll[$i]->getVar('lang_id'));
$languagesObj->setVar('lang_online', $langOnline);
// Insert Data
if (!$languagesHandler->insert($languagesObj)) {
$GLOBALS['xoopsTpl']->assign('error', $languagesObj->getHtmlErrors());
break;
}
unset($languagesObj);
}
\redirect_header('languages.php?op=list&start=' . $start . '&limit=' . $limit, 2, \_AM_WGTRANSIFEX_FORM_OK);
break;
case 'setprimary':
if ($langId > 0) {
$languagesObj = $languagesHandler->get($langId);
Expand Down
6 changes: 4 additions & 2 deletions admin/translations.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,10 @@
if ($proId > 0) {
$adminObject->addItemButton(\_AM_WGTRANSIFEX_TRANSLATIONS_LIST, 'translations.php', 'list');
}
$adminObject->addItemButton(\_AM_WGTRANSIFEX_READTX_TRANSLATIONS, 'translations.php?op=readtx', 'add');
$adminObject->addItemButton(\_AM_WGTRANSIFEX_CHECKTX_TRANSLATIONS, 'translations.php?op=checktx', 'addlink');
if (0 == $proId) {
$adminObject->addItemButton(\_AM_WGTRANSIFEX_READTX_TRANSLATIONS, 'translations.php?op=readtx', 'add');
$adminObject->addItemButton(\_AM_WGTRANSIFEX_CHECKTX_TRANSLATIONS, 'translations.php?op=checktx', 'addlink');
}
$GLOBALS['xoopsTpl']->assign('buttons', $adminObject->displayButton('left'));
$start_pro = Request::getInt('start_pro', 0);
$start_tra = Request::getInt('start_tra', 0);
Expand Down
22 changes: 14 additions & 8 deletions docs/changelog.txt
Original file line number Diff line number Diff line change
@@ -1,33 +1,39 @@
==============================================================
===================================================================
Change Log for wgTransifex - 2020/07/26 12:35:41 Version 1.03 RC1
===================================================================
- moved to RC1 (goffy)

===================================================================
Change Log for wgTransifex - 2020/06/14 12:35:41 Version 1.03
==============================================================
===================================================================
- added requests (goffy)
- fqn replacer (mamba/goffy)
- fixed bug in notification (goffy)
- fixed bug in permission check (goffy)
- added request for not existing project (goffy)
- added new checks for outdated translations (goffy)
- fixed bug in request creation (goffy)
- added set all languages on-/offline (goffy)

==============================================================
===================================================================
Change Log for wgTransifex - 2020/06/14 12:35:41 Version 1.02
==============================================================
===================================================================
- added notification system (goffy)
- added image resizing for logos (goffy)

==============================================================
===================================================================
Change Log for wgTransifex - 2020/06/14 12:35:41 Version 1.01
==============================================================
===================================================================
- added projects on user side (goffy)
- implemented new status 'deleted on transifex' (goffy)
- read only active projects (goffy)
- preselect current user in forms (goffy)
- removed array_key_last (goffy)
- implemented quick creation of package (download and creation at once) (goffy)

==============================================================
===================================================================
Change Log for wgTransifex - 2020/06/14 12:35:41 Version 1.0
==============================================================
===================================================================
- Original release wgtransifex (goffy)
- added translation statistics (goffy)
- preparation for creation of language packages (goffy)
Expand Down
2 changes: 2 additions & 0 deletions language/english/admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,9 @@
\define('_AM_WGTRANSIFEX_LANGUAGE_SETPRIMARY', 'Set as Primary Language');
\define('_AM_WGTRANSIFEX_LANGUAGE_ONLINE', 'Language Online');
\define('_AM_WGTRANSIFEX_LANGUAGE_SETONLINE', 'Set Online');
\define('_AM_WGTRANSIFEX_LANGUAGE_SETONLINE_ALL', 'Set all Online');
\define('_AM_WGTRANSIFEX_LANGUAGE_SETOFFLINE', 'Set Offline');
\define('_AM_WGTRANSIFEX_LANGUAGE_SETOFFLINE_ALL', 'Set all Offline');
\define('_AM_WGTRANSIFEX_LANGUAGE_MENU', '%s language packages');
// Translation add/edit
\define('_AM_WGTRANSIFEX_TRANSLATION_ADD', 'Add Translation');
Expand Down
2 changes: 1 addition & 1 deletion language/english/help/help.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ <h4 class="odd">Features</h4>
</p>
<h4 class="odd">Tutorial</h4>
<p class="even">
You can find a more detailed to this Video Tutorial <a href="http://www.youtube.com/watch?v=dg7zGFCopxY" rel="external">here</a>
You can find a more detailed tutorial <a href="https://xoops.gitbook.io/wgtransifex-module-tutorial/" rel="external">on Gitbook</a>
</p>
<!-- -----Help Content ---------- -->
</div>
1 change: 1 addition & 0 deletions language/english/main.php
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@
//requests
\define('_MA_WGTRANSIFEX_REQUESTS', 'Requests');
\define('_MA_WGTRANSIFEX_REQUEST_NEW', 'Request a new language package');
\define('_MA_WGTRANSIFEX_REQUEST_NEW_DESC', "You didn't find what you are looking for? Then please let us know");
\define('_MA_WGTRANSIFEX_REQUEST_ERR_EXIST1', 'Request already exist! Please wait until language package is released!');
\define('_MA_WGTRANSIFEX_REQUEST_ERR_EXIST2', 'Language package already exist! Please check list of language packages!');
// Admin link
Expand Down
2 changes: 2 additions & 0 deletions language/german/admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,9 @@
\define('_AM_WGTRANSIFEX_LANGUAGE_SETPRIMARY', 'Set as Primary Language');
\define('_AM_WGTRANSIFEX_LANGUAGE_ONLINE', 'Language Online');
\define('_AM_WGTRANSIFEX_LANGUAGE_SETONLINE', 'Set Online');
\define('_AM_WGTRANSIFEX_LANGUAGE_SETONLINE_ALL', 'Set all Online');
\define('_AM_WGTRANSIFEX_LANGUAGE_SETOFFLINE', 'Set Offline');
\define('_AM_WGTRANSIFEX_LANGUAGE_SETOFFLINE_ALL', 'Set all Offline');
\define('_AM_WGTRANSIFEX_LANGUAGE_MENU', '%s language packages');
// Translation add/edit
\define('_AM_WGTRANSIFEX_TRANSLATION_ADD', 'Add Translation');
Expand Down
2 changes: 1 addition & 1 deletion language/german/help/help.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ <h4 class="odd">Features</h4>
</p>
<h4 class="odd">Tutorial</h4>
<p class="even">
You can find a more detailed to this Video Tutorial <a href="http://www.youtube.com/watch?v=dg7zGFCopxY" rel="external">here</a>
You can find a more detailed tutorial <a href="https://xoops.gitbook.io/wgtransifex-module-tutorial/" rel="external">on Gitbook</a>
</p>
<!-- -----Help Content ---------- -->
</div>
1 change: 1 addition & 0 deletions language/german/main.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@
//requests
\define('_MA_WGTRANSIFEX_REQUESTS', 'Anfragen');
\define('_MA_WGTRANSIFEX_REQUEST_NEW', 'Anfrage für neues Sprachpaket');
\define('_MA_WGTRANSIFEX_REQUEST_NEW_DESC', "Sie haben das gewünschte Sprachpaket nicht gefunden? Dann lassen Sie uns das wissen");
\define('_MA_WGTRANSIFEX_REQUEST_ERR_EXIST1', 'Anfrage existiert bereits! Bitte warten Sie bis das Sprachpaket freigegeben wurde!');
\define('_MA_WGTRANSIFEX_REQUEST_ERR_EXIST2', 'Sprachpaket exisiert bereits! Bitte überprüfen Sie die Liste der Sprachpakete!');
// Admin link
Expand Down
4 changes: 2 additions & 2 deletions templates/admin/wgtransifex_admin_broken.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
<tr class='head'>
<th class='center'><{$smarty.const._AM_WGTRANSIFEX_BROKEN_TABLE}></th>
<th class='center'><{$smarty.const._AM_WGTRANSIFEX_BROKEN_MAIN}></th>
<th class='center width5'><{$smarty.const._AM_WGTRANSIFEX_FORM_ACTION}></th>
<th class='center'><{$smarty.const._AM_WGTRANSIFEX_FORM_ACTION}></th>
</tr>
</thead>
<tbody>
<{foreach item=package from=$packages_list}>
<tr class='<{cycle values='odd, even'}>'>
<td class='center'><{$package.table}></td>
<td class='center'><{$package.main}></td>
<td class='center width5'>
<td class='center'>
<a href='packages.php?op=edit&amp;<{$package.key}>=<{$package.keyval}>' title='<{$smarty.const._EDIT}>'><img class="wgt-icon24" src='<{$modPathIcon32}>edit.png' alt='packages' /></a>
<a href='packages.php?op=delete&amp;<{$package.key}>=<{$package.keyval}>' title='<{$smarty.const._DELETE}>'><img class="wgt-icon24" src='<{$modPathIcon32}>delete.png' alt='packages' /></a>
</td>
Expand Down
8 changes: 7 additions & 1 deletion templates/admin/wgtransifex_admin_languages.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,13 @@
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_FOLDER}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_FLAG}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_PRIMARY}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_ONLINE}></th>
<th class="center">
<{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_ONLINE}>&nbsp;
<a href="languages.php?op=setonlineall&amp;lang_online=0&amp;start=<{$start}>&amp;limit=<{$limit}>" title="<{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_SETOFFLINE_ALL}>">
<img src="<{$modPathIcon16}>0.png" alt="<{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_SETOFFLINE_ALL}>" title="<{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_SETOFFLINE_ALL}>"</a>&nbsp;
<a href="languages.php?op=setonlineall&amp;lang_online=1&amp;start=<{$start}>&amp;limit=<{$limit}>" title="<{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_SETONLINE_ALL}>">
<img src="<{$modPathIcon16}>1.png" alt="<{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_SETONLINE_ALL}>" title="<{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_SETONLINE_ALL}>"</a>
</th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_DATE}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_LANGUAGE_SUBMITTER}></th>
<th class="center width5"><{$smarty.const._AM_WGTRANSIFEX_FORM_ACTION}></th>
Expand Down
6 changes: 3 additions & 3 deletions templates/admin/wgtransifex_admin_requests.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_REQUEST_STATUS}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_REQUEST_STATUSDATE}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_REQUEST_STATUSUID}></th>
<th class="center width5"><{$smarty.const._AM_WGTRANSIFEX_FORM_ACTION}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_FORM_ACTION}></th>
</tr>
</thead>
<{if $requests_count}>
Expand All @@ -30,9 +30,9 @@
<td class='center'><img src="<{$modPathIcon32}>status<{$request.status}>.png" alt="<{$request.status_text}>" title="<{$request.status_text}>" /></td>
<td class='center'><{$request.statusdate}></td>
<td class='center'><{$request.statusuid}></td>
<td class="center width5">
<td class="center">
<a href="requests.php?op=edit&amp;req_id=<{$request.id}>" title="<{$smarty.const._EDIT}>"><img class="wgt-icon24" src="<{$modPathIcon32}>edit.png" alt="<{$smarty.const._EDIT}> requests" /></a>
<a href="packages.php?op=new&amp;pkg_pro_id=<{$request.req_pro_id}>&amp;pkg_lang_id=<{$request.req_lang_id}>" title="<{$smarty.const._EDIT}>"><img class="wgt-icon24" src="<{$modPathIcon32}>packages.png" alt="packages" /></a>
<a href="packages.php?op=new&amp;pkg_pro_id=<{$request.req_pro_id}>&amp;pkg_lang_id=<{$request.req_lang_id}>" title="<{$smarty.const._AM_WGTRANSIFEX_PACKAGE_ADD}>"><img class="wgt-icon24" src="<{$modPathIcon32}>packages.png" alt="packages" /></a>
<a href="requests.php?op=delete&amp;req_id=<{$request.id}>" title="<{$smarty.const._DELETE}>"><img class="wgt-icon24" src="<{$modPathIcon32}>delete.png" alt="<{$smarty.const._DELETE}> requests" /></a>
</td>
</tr>
Expand Down
8 changes: 4 additions & 4 deletions templates/admin/wgtransifex_admin_translations.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_RESOURCES_NB}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_TRANSLATIONS_NB}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_PROJECT_DATE}></th>
<th class="center width10"><{$smarty.const._AM_WGTRANSIFEX_FORM_ACTION}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_FORM_ACTION}></th>
</tr>
</thead>
<tbody>
Expand All @@ -23,7 +23,7 @@
<td class='center'><{$project.resources}></td>
<td class='center'><{$project.translations}></td>
<td class='center'><{$project.date}></td>
<td class='center width20'>
<td class='center'>
<{foreach item=language from=$project.languages}>
<a href="translations.php?op=list&amp;tra_pro_id=<{$project.id}>&amp;tra_lang_id=<{$language.id}>" title="<{$smarty.const._AM_WGTRANSIFEX_TRANSLATIONS_SHOW}>">
<{if $language.outdated > 0}>
Expand Down Expand Up @@ -56,7 +56,7 @@
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_TRANSLATION_STATUS}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_TRANSLATION_DATE}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_TRANSLATION_SUBMITTER}></th>
<th class="center width5"><{$smarty.const._AM_WGTRANSIFEX_FORM_ACTION}></th>
<th class="center"><{$smarty.const._AM_WGTRANSIFEX_FORM_ACTION}></th>
</tr>
</thead>
<{if $translations_count}>
Expand All @@ -80,7 +80,7 @@
<td class='center'><img src="<{$modPathIcon32}>status<{$translation.status}>.png" alt="<{$translation.status_text}>" title="<{$translation.status_text}>" /></td>
<td class='center'><{$translation.date}></td>
<td class='center'><{$translation.submitter}></td>
<td class="center width5">
<td class="center">
<a href="translations.php?op=savetx&amp;tra_id=<{$translation.id}>&amp;tra_pro_id=<{$translation.tra_pro_id}>&amp;tra_res_id=<{$translation.tra_res_id}>&amp;tra_lang_id=<{$translation.tra_lang_id}>" title="<{$smarty.const._AM_WGTRANSIFEX_READTX_TRANSLATION}>"><img class="wgt-icon24" src="<{$modPathIcon32}>readtx.png" alt="<{$smarty.const._AM_WGTRANSIFEX_READTX_TRANSLATION}>" /></a>
<a href="translations.php?op=edit&amp;tra_id=<{$translation.id}>" title="<{$smarty.const._EDIT}>"><img class="wgt-icon24" src="<{$modPathIcon32}>edit.png" alt="<{$smarty.const._EDIT}> translations" /></a>
<a href="translations.php?op=delete&amp;tra_id=<{$translation.id}>" title="<{$smarty.const._DELETE}>"><img class="wgt-icon24" src="<{$modPathIcon32}>delete.png" alt="<{$smarty.const._DELETE}> translations" /></a>
Expand Down
1 change: 1 addition & 0 deletions templates/wgtransifex_packages.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
<{if $showRequest}>
<div class='row'>
<div class='cols-xs-12 center'>
<h5><{$smarty.const._MA_WGTRANSIFEX_REQUEST_NEW_DESC}></h5>
<a class='btn btn-success center' href='requests.php?op=new' title='<{$smarty.const._MA_WGTRANSIFEX_REQUEST_NEW}>'><{$smarty.const._MA_WGTRANSIFEX_REQUEST_NEW}></a>
</div>
</div>
Expand Down
26 changes: 0 additions & 26 deletions templates/wgtransifex_requests.tpl
Original file line number Diff line number Diff line change
@@ -1,31 +1,5 @@
<{include file='db:wgtransifex_header.tpl' }>

<{if $requestsCount > 0}>
<div class='table-responsive'>
<table class='table table-<{$table_type}>'>
<thead>
<tr class='head'>
<th colspan='<{$divideby}>'><{$smarty.const._MA_WGTRANSIFEX_REQUESTS_TITLE}></th>
</tr>
</thead>
<tbody>
<tr>
<{foreach item=request from=$requests}>
<td>
<div class='panel panel-<{$panel_type}>'>
<{include file='db:wgtransifex_requests_item.tpl' }>
</div>
</td>
<{if $request.count is div by $divideby}>
</tr><tr>
<{/if}>
<{/foreach}>
</tr>
</tbody>
<tfoot><tr><td>&nbsp;</td></tr></tfoot>
</table>
</div>
<{/if}>
<{if $form}>
<{$form}>
<{/if}>
Expand Down
6 changes: 3 additions & 3 deletions xoops_version.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@
'release_date' => '2020/06/17',
'manual' => 'link to manual file',
'manual_file' => XOOPS_URL . '/modules/wgtransifex/docs/install.txt',
'min_php' => '7.0',
'min_xoops' => '2.5.9',
'min_php' => '7.3',
'min_xoops' => '2.5.10',
'min_admin' => '1.2',
'min_db' => ['mysql' => '5.6', 'mysqli' => '5.6'],
'image' => 'assets/images/logoModule.png',
Expand All @@ -57,7 +57,7 @@
'module_website_url' => 'www.xoops.org',
'module_website_name' => 'XOOPS Project',
'release' => '2017-12-02',
'module_status' => 'Beta 1',
'module_status' => 'RC 1',
'system_menu' => 1,
'hasAdmin' => 1,
'hasMain' => 1,
Expand Down

0 comments on commit 75f177e

Please sign in to comment.