public inbox for development@lists.ipfire.org
 help / color / mirror / Atom feed
From: "Peter Müller" <peter.mueller@ipfire.org>
To: development@lists.ipfire.org
Subject: Re: [PATCH] header.pl: Hide PPPoE menu item if RED is in IP mode
Date: Sat, 27 Mar 2021 21:22:44 +0100	[thread overview]
Message-ID: <5326a724-da81-2d54-0ce4-797f491d6c89@ipfire.org> (raw)
In-Reply-To: <20210325204942.1780-1-hofmann@leo-andres.de>

[-- Attachment #1: Type: text/plain, Size: 977 bytes --]

Reviewed-by: Peter Müller <peter.mueller(a)ipfire.org>

> Fixes: #11342
> 
> Signed-off-by: Leo-Andres Hofmann <hofmann(a)leo-andres.de>
> ---
>  config/cfgroot/header.pl | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/config/cfgroot/header.pl b/config/cfgroot/header.pl
> index 5684c01c5..8dea804d0 100644
> --- a/config/cfgroot/header.pl
> +++ b/config/cfgroot/header.pl
> @@ -170,6 +170,12 @@ sub genmenu {
>          $menu->{'02.status'}{'subMenu'}->{'74.modem-status'}{'enabled'} = 1;
>      }
>  
> +	# Disable the Dialup/PPPoE menu item when the RED interface is in IP mode
> +	# (the "Network" module is loaded by general-functions.pl)
> +	if(&Network::is_red_mode_ip()) {
> +		$menu->{'01.system'}{'subMenu'}->{'20.dialup'}{'enabled'} = 0;
> +	}
> +
>      # Disbale unusable things in cloud environments
>      if (&General::running_in_cloud()) {
>          $menu->{'03.network'}{'subMenu'}->{'30.dhcp'}{'enabled'} = 0;
> 

      reply	other threads:[~2021-03-27 20:22 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-25 20:49 Leo-Andres Hofmann
2021-03-27 20:22 ` Peter Müller [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5326a724-da81-2d54-0ce4-797f491d6c89@ipfire.org \
    --to=peter.mueller@ipfire.org \
    --cc=development@lists.ipfire.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox