From cda8b15c7f1433ad338046c556a823adafd17421 Mon Sep 17 00:00:00 2001 From: Ferran Marcet Date: Mon, 5 Aug 2019 14:00:15 +0200 Subject: [PATCH 1/2] FIX: Not showing MAIN_INVERT_SENDER_RECIPIENT when edit field --- htdocs/admin/pdf.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/htdocs/admin/pdf.php b/htdocs/admin/pdf.php index 70fa3dc38b7..8f6e82887dc 100644 --- a/htdocs/admin/pdf.php +++ b/htdocs/admin/pdf.php @@ -3,6 +3,7 @@ * Copyright (C) 2004-2012 Laurent Destailleur * Copyright (C) 2005-2011 Regis Houssin * Copyright (C) 2012-2107 Juanjo Menent + * Copyright (C) 2019 Ferran Marcet * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -279,6 +280,12 @@ if ($action == 'edit') // Edit print $form->selectyesno('MAIN_GENERATE_DOCUMENTS_HIDE_DETAILS',(! empty($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DETAILS))?$conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DETAILS:0,1); print ''; + //Invert sender and recipient + + print ''.$langs->trans("SwapSenderAndRecipientOnPDF").''; + print $form->selectyesno('MAIN_INVERT_SENDER_RECIPIENT',(! empty($conf->global->MAIN_INVERT_SENDER_RECIPIENT))?$conf->global->MAIN_INVERT_SENDER_RECIPIENT:0,1); + print ''; + // Place customer adress to the ISO location print ''.$langs->trans("PlaceCustomerAddressToIsoLocation").''; From 32220dde2e1ca544dbf4b36da6a6611e3d511088 Mon Sep 17 00:00:00 2001 From: Ferran Marcet Date: Mon, 5 Aug 2019 14:12:19 +0200 Subject: [PATCH 2/2] FIX: Wrong variable. Must be PROJECT_HIDE_UNSELECTABLES --- htdocs/core/class/html.formprojet.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/class/html.formprojet.class.php b/htdocs/core/class/html.formprojet.class.php index 35b3e52d154..d96f5e66df5 100644 --- a/htdocs/core/class/html.formprojet.class.php +++ b/htdocs/core/class/html.formprojet.class.php @@ -153,7 +153,7 @@ class FormProjets $outarray=array(); $hideunselectables = false; - if (! empty($conf->global->CONTRACT_HIDE_UNSELECTABLES)) $hideunselectables = true; + if (! empty($conf->global->PROJECT_HIDE_UNSELECTABLES)) $hideunselectables = true; $projectsListId = false; if (empty($user->rights->projet->all->lire))