From 163cc74b50cf33dc951f62147af89674930ca5ce Mon Sep 17 00:00:00 2001 From: root Date: Fri, 11 Sep 2020 18:14:51 +0200 Subject: [PATCH] =?UTF-8?q?Ajout=20de=20d=C3=A9pendance=20manquante=20Patc?= =?UTF-8?q?h=20de=20GLPI=20pour=20masquer=20une=20partie=20du=20formulaire?= =?UTF-8?q?=20selfService?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- alpine/Dockerfile | 7 +++++-- alpine/glpi_init.sh | 3 +++ alpine/glpi_ticket.class.php.patch | 19 +++++++++++++++++++ 3 files changed, 27 insertions(+), 2 deletions(-) create mode 100644 alpine/glpi_ticket.class.php.patch diff --git a/alpine/Dockerfile b/alpine/Dockerfile index aca8c09..12fa1a9 100644 --- a/alpine/Dockerfile +++ b/alpine/Dockerfile @@ -35,15 +35,18 @@ apk add \ php7-mbstring \ php7-simplexml \ php7-iconv \ - php7-sodium + php7-sodium \ + php7-phar COPY CAS-1.3.8.tgz /root/ -RUN pear install /root/CAS-1.3.8.tgz +RUN pear install /root/CAS-1.3.8.tgz && \ +pear install Archive_Tar COPY httpd.conf /etc/apache2 COPY service/ /etc/service/ COPY glpi_init.sh /root/glpi_init.sh COPY glpi.cron /var/spool/cron/crontabs/apache COPY initrc /etc/ +COPY glpi_ticket.class.php.patch /root/ ADD https://github.com/glpi-project/glpi/releases/download/${GLPI_VERSION}/glpi-${GLPI_VERSION}.tgz /root/glpi-${GLPI_VERSION}.tgz ADD https://github.com/fusioninventory/fusioninventory-for-glpi/releases/download/glpi${FUSIONINVENTORY_VERSION}/fusioninventory-${FUSIONINVENTORY_VERSION}.tar.bz2 /root/fusioninventory-${FUSIONINVENTORY_VERSION}.tar.bz2 diff --git a/alpine/glpi_init.sh b/alpine/glpi_init.sh index 0ffac07..572eba1 100644 --- a/alpine/glpi_init.sh +++ b/alpine/glpi_init.sh @@ -51,6 +51,7 @@ EOF php bin/console glpi:plugin:activate fusioninventory -n rm install/install.php chown -R apache:apache /var/www/glpi /etc/glpi /var/lib/glpi /var/log/glpi + patch -Np0 -i /root/glpi_ticket.class.php.patch msglog green "Initialazing complete..." else msglog green "GLPI is already initialized" @@ -76,4 +77,6 @@ else php bin/console db:update --config-dir=${GLPI_CONFIG_DIR} -n php bin/console glpi:maintenance:disable -n chown -R apache:apache /var/www/glpi /etc/glpi /var/lib/glpi /var/log/glpi + patch -Np0 -i /root/glpi_ticket.class.php.patch + fi diff --git a/alpine/glpi_ticket.class.php.patch b/alpine/glpi_ticket.class.php.patch new file mode 100644 index 0000000..632af8c --- /dev/null +++ b/alpine/glpi_ticket.class.php.patch @@ -0,0 +1,19 @@ +--- inc/ticket.class.php.old 2020-07-16 14:26:59.000000000 +0200 ++++ inc/ticket.class.php 2020-09-11 18:09:43.200657894 +0200 +@@ -3806,7 +3806,7 @@ + } + } + +- if (empty($delegating) ++/** if (empty($delegating) + && NotificationTargetTicket::isAuthorMailingActivatedForHelpdesk()) { + echo ""; + echo "".__('Inform me about the actions taken').""; +@@ -3821,6 +3821,7 @@ + + echo ""; + } ++*/ + if (($_SESSION["glpiactiveprofile"]["helpdesk_hardware"] != 0) + && (count($_SESSION["glpiactiveprofile"]["helpdesk_item_type"]))) { + if (!$tt->isHiddenField('items_id')) {