show plan by nux-router

This commit is contained in:
Ibnu Maksum
2023-09-21 13:45:28 +07:00
parent c9eeefcf3d
commit 1832332d99
3 changed files with 29 additions and 15 deletions

View File

@ -31,6 +31,7 @@
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>ID</th>
<th>{$_L['Router_Name']}</th>
<th>{$_L['IP_Address']}</th>
<th>{$_L['Username']}</th>
@ -42,6 +43,7 @@
<tbody>
{foreach $d as $ds}
<tr {if $ds['enabled'] != 1}class="danger" title="disabled" {/if}>
<td>{$ds['id']}</td>
<td>{$ds['name']}</td>
<td>{$ds['ip_address']}</td>
<td>{$ds['username']}</td>
@ -50,7 +52,9 @@
<td>
<a href="{$_url}routers/edit/{$ds['id']}"
class="btn btn-info btn-xs">{$_L['Edit']}</a>
<a href="{$_url}routers/delete/{$ds['id']}" id="{$ds['id']}" onclick="return confirm('{$_L['Delete']}?')" class="btn btn-danger btn-xs">{$_L['Delete']}</a>
<a href="{$_url}routers/delete/{$ds['id']}" id="{$ds['id']}"
onclick="return confirm('{$_L['Delete']}?')"
class="btn btn-danger btn-xs">{$_L['Delete']}</a>
</td>
</tr>
{/foreach}

View File

@ -6,13 +6,13 @@
<div class="box-header">{Lang::T('Order Internet Package')}</div>
</div>
{if $_c['enable_balance'] == 'yes'}
<div class="box box-solid box-primary">
<div class="box box-solid box-success bg-gray-light">
<div class="box-header">{Lang::T('Balance Plans')}</div>
<div class="box-body row">
{foreach $plans_balance as $plan}
<div class="col col-md-4">
<div class="box box-solid box-default">
<div class="box-header">{$plan['name_plan']}</div>
<div class="box-header text-bold">{$plan['name_plan']}</div>
<div class="table-responsive">
<table class="table table-bordered table-striped">
<tbody>
@ -35,22 +35,22 @@
</div>
{/if}
{foreach $routers as $router}
{if Validator::isRouterHasPlan($plans_hotspot, $router['name'])>0 && Validator::isRouterHasPlan($plans_pppoe, $router['name'])>0}
<div class="box box-solid box-info">
<div class="box-header text-black">{$router['name']}</div>
{if Validator::isRouterHasPlan($plans_hotspot, $router['name']) || Validator::isRouterHasPlan($plans_pppoe, $router['name'])}
<div class="box box-solid box-info bg-gray-light">
<div class="box-header text-black text-bold">{$router['name']}</div>
{if $router['description'] != ''}
<div class="box-body">
{$router['description']}
</div>
{/if}
{if Validator::countRouterPlan($plans_hotspot, $router['name'])>0}
<div class="box-header">{Lang::T('Hotspot Plan')}</div>
<div class="box-header text-black">{Lang::T('Hotspot Plan')}</div>
<div class="box-body row">
{foreach $plans_hotspot as $plan}
{if $router['name'] eq $plan['routers']}
<div class="col col-md-4">
<div class="box box-solid box-default">
<div class="box-header">{$plan['name_plan']}</div>
<div class="box box-primary">
<div class="box-header text-bold">{$plan['name_plan']}</div>
<div class="table-responsive">
<table class="table table-bordered table-striped">
<tbody>
@ -93,13 +93,13 @@
</div>
{/if}
{if Validator::countRouterPlan($plans_pppoe,$router['name'])>0}
<div class="box-header text-sm">{Lang::T('PPPOE Plan')}</div>
<div class="box-header text-black">{Lang::T('PPPOE Plan')}</div>
<div class="box-body row">
{foreach $plans_pppoe as $plan}
{if $router['name'] eq $plan['routers']}
<div class="col col-md-4">
<div class="box box-solid box-default">
<div class="box-header">{$plan['name_plan']}</div>
<div class="box box- box-primary">
<div class="box-header text-bold">{$plan['name_plan']}</div>
<div class="table-responsive">
<table class="table table-bordered table-striped">
<tbody>