Skip to content

Commit 01dca3b

Browse files
committed
Merge branch 'release/1.5.0'
2 parents a7d2ede + 95c366e commit 01dca3b

File tree

10 files changed

+320
-90
lines changed

10 files changed

+320
-90
lines changed

composer.lock

Lines changed: 165 additions & 83 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

hook.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ function plugin_news_install() {
2525
global $DB;
2626

2727
$plugin = new Plugin();
28-
$found = $plugin->find("name = 'news'");
28+
$found = $plugin->find(['name' => 'news']);
2929
$pluginNews = array_shift($found);
3030
$migration = new Migration($pluginNews['version']);
3131

@@ -144,7 +144,7 @@ function plugin_news_install() {
144144

145145
// install default display preferences
146146
$dpreferences = new DisplayPreference;
147-
$found_dpref = $dpreferences->find("`itemtype` LIKE '%PluginNews%'");
147+
$found_dpref = $dpreferences->find(['itemtype' => ['LIKE', '%PluginNews%']]);
148148
if (count($found_dpref) == 0) {
149149
$DB->query("INSERT INTO `glpi_displaypreferences`
150150
(`itemtype`, `num`, `rank`, `users_id`)

inc/alert.class.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ public static function findAllToNotify($params = []) {
206206
$group_u = new Group_User();
207207
$fndgroup = [];
208208
if (isset($_SESSION['glpiID'])
209-
&& $fndgroup_user = $group_u->find("users_id = ".$_SESSION['glpiID'])) {
209+
&& $fndgroup_user = $group_u->find(['users_id' => $_SESSION['glpiID']])) {
210210
foreach ($fndgroup_user as $group) {
211211
$fndgroup[] = $group['groups_id'];
212212
}

inc/alert_target.class.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ static function showForAlert(PluginNewsAlert $alert) {
106106

107107
echo "<div class='spaced'>";
108108
$target = new self();
109-
$found_target = $target->find("`plugin_news_alerts_id` = ".$alert->getID());
109+
$found_target = $target->find(['plugin_news_alerts_id' => $alert->getID()]);
110110
if ($nb = count($found_target) > 0) {
111111
Html::openMassiveActionsForm('mass'.__CLASS__.$rand);
112112
$massiveactionparams

locales/fi_FI.mo

1.37 KB
Binary file not shown.

locales/fi_FI.po

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
# SOME DESCRIPTIVE TITLE.
2+
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
3+
# This file is distributed under the same license as the PACKAGE package.
4+
#
5+
# Translators:
6+
# Markku Vepsä, 2018
7+
msgid ""
8+
msgstr ""
9+
"Project-Id-Version: GLPI Plugin - News\n"
10+
"Report-Msgid-Bugs-To: \n"
11+
"POT-Creation-Date: 2018-09-10 08:41+0000\n"
12+
"PO-Revision-Date: 2018-11-06 17:00+0000\n"
13+
"Last-Translator: Markku Vepsä\n"
14+
"Language-Team: Finnish (Finland) (http://www.transifex.com/teclib/glpi-plugin-news/language/fi_FI/)\n"
15+
"MIME-Version: 1.0\n"
16+
"Content-Type: text/plain; charset=UTF-8\n"
17+
"Content-Transfer-Encoding: 8bit\n"
18+
"Language: fi_FI\n"
19+
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
20+
21+
#: front/alert.php:27 front/alert.form.php:86 front/hidden_alerts.php:27
22+
#: front/hidden_alerts.php:30 inc/alert.class.php:56 setup.php:66
23+
msgid "Alerts"
24+
msgstr "Hälytykset"
25+
26+
#: inc/alert.class.php:134 inc/alert.class.php:403
27+
msgid "Can close alert"
28+
msgstr "Voi sulkea hälytyksen"
29+
30+
#: inc/alert.class.php:143 inc/alert.class.php:412
31+
msgid "Show on login page"
32+
msgstr "Näytä sisäänkirjautumissivulla"
33+
34+
#: inc/alert.class.php:152 inc/alert.class.php:418
35+
msgid "Show on helpdesk page"
36+
msgstr "Näytä helpdesk -sivulla"
37+
38+
#: inc/alert.class.php:310
39+
msgid "Please enter a name."
40+
msgstr "Anna nimi."
41+
42+
#: inc/alert.class.php:314
43+
msgid "Please enter a message."
44+
msgstr "Kirjoita viesti."
45+
46+
#: inc/alert.class.php:320
47+
msgid "The end date must be greater than the start date."
48+
msgstr "Päättymispäivän on oltava myöhäisempi kuin alkamispäivän."
49+
50+
#: inc/alert.class.php:395
51+
msgid "Type (to add an icon before alert title)"
52+
msgstr "Tyyppi (lisätäksesi kuvakkeen ennen hälytysnimeä)"
53+
54+
#: inc/alert.class.php:494
55+
msgid "You have hidden alerts valid for current date"
56+
msgstr "Sinulla on piilotettuja hälytyksiä, jotka ovat voimassa nykyiselle päivämäärälle"
57+
58+
#: inc/alert.class.php:513
59+
msgid "General"
60+
msgstr "Yleinen"
61+
62+
#: inc/alert.class.php:514
63+
msgid "Information"
64+
msgstr "Tietoja"
65+
66+
#: inc/alert.class.php:515
67+
msgid "Warning"
68+
msgstr "Varoitus"
69+
70+
#: inc/alert.class.php:516
71+
msgid "Problem"
72+
msgstr "Ongelma"

locales/sk_SK.mo

1.44 KB
Binary file not shown.

locales/sk_SK.po

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
# SOME DESCRIPTIVE TITLE.
2+
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
3+
# This file is distributed under the same license as the PACKAGE package.
4+
#
5+
# Translators:
6+
# feonsu <[email protected]>, 2018
7+
msgid ""
8+
msgstr ""
9+
"Project-Id-Version: GLPI Plugin - News\n"
10+
"Report-Msgid-Bugs-To: \n"
11+
"POT-Creation-Date: 2018-09-10 08:41+0000\n"
12+
"PO-Revision-Date: 2018-12-03 09:43+0000\n"
13+
"Last-Translator: feonsu <[email protected]>\n"
14+
"Language-Team: Slovak (Slovakia) (http://www.transifex.com/teclib/glpi-plugin-news/language/sk_SK/)\n"
15+
"MIME-Version: 1.0\n"
16+
"Content-Type: text/plain; charset=UTF-8\n"
17+
"Content-Transfer-Encoding: 8bit\n"
18+
"Language: sk_SK\n"
19+
"Plural-Forms: nplurals=4; plural=(n % 1 == 0 && n == 1 ? 0 : n % 1 == 0 && n >= 2 && n <= 4 ? 1 : n % 1 != 0 ? 2: 3);\n"
20+
21+
#: front/alert.php:27 front/alert.form.php:86 front/hidden_alerts.php:27
22+
#: front/hidden_alerts.php:30 inc/alert.class.php:56 setup.php:66
23+
msgid "Alerts"
24+
msgstr "Upozornenia"
25+
26+
#: inc/alert.class.php:134 inc/alert.class.php:403
27+
msgid "Can close alert"
28+
msgstr "Upozornenie je možné zavrieť"
29+
30+
#: inc/alert.class.php:143 inc/alert.class.php:412
31+
msgid "Show on login page"
32+
msgstr "Zobraziť na prihlasovacej stránke"
33+
34+
#: inc/alert.class.php:152 inc/alert.class.php:418
35+
msgid "Show on helpdesk page"
36+
msgstr "Zobraziť na stránke helpdesku"
37+
38+
#: inc/alert.class.php:310
39+
msgid "Please enter a name."
40+
msgstr "Zadajte názov."
41+
42+
#: inc/alert.class.php:314
43+
msgid "Please enter a message."
44+
msgstr "Zadajte správu."
45+
46+
#: inc/alert.class.php:320
47+
msgid "The end date must be greater than the start date."
48+
msgstr "Dátum ukončenia musí byť neskorší ako počiatočný."
49+
50+
#: inc/alert.class.php:395
51+
msgid "Type (to add an icon before alert title)"
52+
msgstr "Typ (pre pridanie ikony pred názov upozornenia)"
53+
54+
#: inc/alert.class.php:494
55+
msgid "You have hidden alerts valid for current date"
56+
msgstr "Máte skryté upozornenia platné pre aktuálny dátum"
57+
58+
#: inc/alert.class.php:513
59+
msgid "General"
60+
msgstr "Všeobecné"
61+
62+
#: inc/alert.class.php:514
63+
msgid "Information"
64+
msgstr "Imformácia"
65+
66+
#: inc/alert.class.php:515
67+
msgid "Warning"
68+
msgstr "Varovanie"
69+
70+
#: inc/alert.class.php:516
71+
msgid "Problem"
72+
msgstr "Problém"

plugin.xml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,10 @@ Fonctionnalités
5353
<author>TECLIB'</author>
5454
</authors>
5555
<versions>
56+
<version>
57+
<num>1.5.0</num>
58+
<compatibility>9.4</compatibility>
59+
</version>
5660
<version>
5761
<num>1.4.2</num>
5862
<compatibility>9.3</compatibility>

setup.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@
2121
--------------------------------------------------------------------------
2222
*/
2323

24-
define ('PLUGIN_NEWS_VERSION', '1.4.2');
24+
define ('PLUGIN_NEWS_VERSION', '1.5.0');
2525

2626
// Minimal GLPI version, inclusive
27-
define("PLUGIN_NEWS_MIN_GLPI", "9.3");
27+
define("PLUGIN_NEWS_MIN_GLPI", "9.4");
2828
// Maximum GLPI version, exclusive
29-
define("PLUGIN_NEWS_MAX_GLPI", "9.4");
29+
define("PLUGIN_NEWS_MAX_GLPI", "9.5");
3030

3131
function plugin_init_news() {
3232
global $PLUGIN_HOOKS, $CFG_GLPI;

0 commit comments

Comments
 (0)