角4-如何在其他组件中隐藏导航栏容器?

时间:2018-12-19 05:50:04

标签: angular drop-down-menu angular2-routing navbar

我只想在navbar组件为route时显示navbar容器,并为navbar下拉组件的其他组件隐藏。如果您不明白,有人可以帮我吗,我会向您说明。预先感谢。

accountdashboard.component.html

        <ul class="nav navbar-nav">
           <li class="dropdown">
                <a href="#" class="dropdown-toggle" data-toggle="dropdown">
                    Report
                    <b class="caret"></b>
                </a>
                <ul class="dropdown-menu">
                    <li>
                        <a [routerLink]="['/accountdashboard/journalVoucher']">Day Book</a>
                    </li>
                    <li>
                        <a [routerLink]="['/accountdashboard/AccountLedgerView']">Ledger</a>
                    </li>
                    <li>
                        <a [routerLink]="['/accountdashboard/TrialBalance']">Trial Balance</a>
                    </li>
                    <li>
                        <a [routerLink]="['/accountdashboard/SaleBook']">Cash Flow</a>
                    </li>
                    <li>
                        <a [routerLink]="['/accountdashboard/SaleBook']">Fund Flow</a>
                    </li>
                    <li><a [routerLink]="['/accountdashboard/ProfitLoss']">Profit &amp; Loss</a></li>
                    <li><a [routerLink]="['/accountdashboard/BalanceSheet']">Balance Sheet</a></li>
                    <li>
                        <a [routerLink]="['/accountdashboard/SaleBook']">Sales Book</a>
                    </li>
                    <li>
                        <a [routerLink]="['/accountdashboard/SaleBook']">Purchase Book</a>
                    </li>
                    <li>
                        <a [routerLink]="['/accountdashboard/materializedview']">Materialized View</a>
                    </li>
                    <li>
                        <a [routerLink]="['/accountdashboard/BillReturnView']">BillReturn View</a>
                    </li>
                </ul>
            </li>
        </ul>

    你好角

0 个答案:

没有答案