Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove unused panels #18

Closed
stalkerGH opened this issue Jul 28, 2020 · 2 comments
Closed

Remove unused panels #18

stalkerGH opened this issue Jul 28, 2020 · 2 comments

Comments

@stalkerGH
Copy link

First of all, thank you for beautiful Weewx theme. I'm testing my first DIY station and trying to customize NeoWX to fit my needs.

Because my setup is very basic (BME280 sensor) and I got only temperature, humidity and pressure data, I don't need all of the possible panels. I'd like to remove wind, rain etc., leaving only T, H, P and HI ones. In the futore, when my setup grow with other sensors, I'd like to come back with some panels.

How could I remove unused panels then? I've noticed such hook for UV index:

#if $day.UV.has_data

Could I use it for other parameters too or should I manually comment/remove the code in .tmpl files?

@Maginos2210
Copy link

Maginos2210 commented Jan 1, 2021

@stalkerGH What you could do to get rid of the panels, you don't need:

-go to the folder /etc/weewx/skins/neowx and create a backup of the index.html.tmpl by executing "cp index.html.tmpl index.html.tmpl.old". In case you screw up the template, you can delete it and restore your old configuration with "cp index.html.tmpl.old index.html.tmpl".

-open the template with an editor, e. g. nano index.html.tmpl

-scroll down to the sections, where the graphs are defined. You know them by this lines:

<div class="col col-4 crd">

                        <h4><i class="wi wi-umbrella"></i> $Extras.Translation.rain</h4>
                        <div class="crd-content">
                            <span class="weatherdata">$day.rain.sum</span>
                            <table class="meta">
                                <tr>
                                    <td>$Extras.Translation.rain_rate:</td>
                                    <td>$current.rainRate</td>
                                    <td></td>
                                </tr>
                                <tr>
                                    <td>$Extras.Translation.high $Extras.Translation.rain_rate:</td>
                                    <td>$day.rainRate.max</td>
                                    <td>($day.rainRate.maxtime.format("%H:%M"))</td>
                                </tr>
                            </table>
                        </div>

                    </div>

This section for example is for the rain graph. I personally would comment out the sections you don't need by changing the section above into this:

<!--<div class="col col-4 crd">

                        <h4><i class="wi wi-umbrella"></i> $Extras.Translation.rain</h4>
                        <div class="crd-content">
                            <span class="weatherdata">$day.rain.sum</span>
                            <table class="meta">
                                <tr>
                                    <td>$Extras.Translation.rain_rate:</td>
                                    <td>$current.rainRate</td>
                                    <td></td>
                                </tr>
                                <tr>
                                    <td>$Extras.Translation.high $Extras.Translation.rain_rate:</td>
                                    <td>$day.rainRate.max</td>
                                    <td>($day.rainRate.maxtime.format("%H:%M"))</td>
                                </tr>
                            </table>
                        </div>

                    </div>-->

As you can see, I added a <!-- at the beginning of the first line and a --> at the end of the last line. Do this with every graph you don't want to see and you're done.

@stalkerGH
Copy link
Author

👍 Thank you very much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants