Upload files to "ui/ui"

Signed-off-by: nestict <icttechnest@gmail.com>
This commit is contained in:
nestict 2025-05-24 12:18:49 +02:00
parent ce6b63f3a3
commit 712224be37
5 changed files with 331 additions and 0 deletions

69
ui/ui/plan-edit.tpl Normal file
View File

@ -0,0 +1,69 @@
{include file="sections/header.tpl"}
<div class="container-fluid">
<div class="row">
<div class="col-sm-12">
<div class="card card-primary">
<div class="card-header">
<h3 class="card-title">Edit Plan</h3>
</div>
<div class="card-body">
<form class="form-horizontal" method="post" role="form" action="{$_url}plan/edit-post">
<input type="hidden" name="id" value="{$d['id']}">
<div class="form-group row">
<label class="col-md-4 control-label">{Lang::T('Select Account')}</label>
<div class="col-md-6">
<input type="text" class="form-control" id="username" name="username"
value="{$d['username']}" readonly>
</div>
</div>
<div class="form-group row">
<label class="col-md-4 control-label">{Lang::T('Service Plan')}</label>
<div class="col-md-6">
<select id="id_plan" name="id_plan" class="form-select" style="height: 52px; background-color: white;">
{foreach $p as $ps}
<option value="{$ps['id']}" {if $d['plan_id'] eq $ps['id']} selected {/if}>
{if $ps['enabled'] neq 1}DISABLED PLAN &bull; {/if}
{if $ps['is_radius']=='1'}Radius{else}{$ps['routers']}{/if} &bull; {$ps['name_plan']}</option>
{/foreach}
</select>
</div>
</div>
<div class="form-group row">
<label class="col-md-4 control-label">{Lang::T('Created On')}</label>
<div class="col-md-4 mb-2">
<input type="date" class="form-control" name="expiration" readonly
value="{$d['recharged_on']}">
</div>
<div class="col-md-2">
<input type="text" class="form-control" placeholder="00:00:00" readonly
value="{$d['recharged_time']}">
</div>
</div>
<div class="form-group row">
<label class="col-md-4 control-label">{Lang::T('Expires On')}</label>
<div class="col-md-4 mb-2">
<input type="date" class="form-control" id="expiration" name="expiration"
value="{$d['expiration']}">
</div>
<div class="col-md-2">
<input type="text" class="form-control" id="time" name="time" placeholder="00:00:00"
value="{$d['time']}">
</div>
</div>
<center>
<div class="form-group row">
<div class="col-lg-offset-2 col-lg-10">
<button class="btn btn-success mb-3"
type="submit">{Lang::T('Edit')}</button>
Or <a href="{$_url}plan/list" class="btn btn-outline-primary">{Lang::T('Cancel')}</a>
</div>
</div>
</center>
</form>
</div>
</div>
</div>
</div>
</div>
{include file="sections/footer.tpl"}

92
ui/ui/plugin-manager.tpl Normal file
View File

@ -0,0 +1,92 @@
{include file="sections/header.tpl"}
<div class="container-fluid">
<div class="row">
<div class="col-sm-12">
<div class="card card-primary card-hovered">
<div class="card-header">
<h3 class="card-title">{Lang::T('Plugin')}</h3>
</div>
<div class="card-body row">
{foreach $plugins as $plugin}
<div class="col-md-6">
<div class="card kanbanPreview-bx">
<div class="card-body">
<div class="sub-card">
<span class="text-warning sub-title fs-14">{$plugin['name']}</span>
<p class="font-w300">{$plugin['description']}</p>
<div class="row justify-content-between align-items-center">
<div>
<span>
<center>
<small><i>@{$plugin['author']} Last update: {$plugin['last_update']}</i></small>
</center>
</span>
</div>
<div class="btn-group btn-group-justified mb-2" role="group" aria-label="...">
<a href="{$plugin['url']}" target="_blank" class="btn btn-primary"><i
class="fa fa-globe"></i> Web</a>
<a href="{$plugin['github']}" target="_blank" class="btn btn-info"><i
class="fa fa-align-left"></i> Source</a>
</div>
<div class="btn-group btn-group-justified" role="group" aria-label="...">
<a href="{$_url}pluginmanager/delete/plugin/{$plugin['id']}" onclick="return confirm('{Lang::T('Delete')}?')" class="btn btn-danger"><i
class="fa fa-trash"></i> Delete</a>
<a {if $zipExt } href="{$_url}pluginmanager/install/plugin/{$plugin['id']}"
onclick="return confirm('Installing plugin will take some time to complete, do not close the page while it loading to install the plugin')"
{else} href="#" onclick="alert('PHP ZIP extension is not installed')"
{/if}
class="btn btn-success"><i class="fa fa-circle-arrow-down"></i> Install</a>
</div>
</div>
</div>
</div>
</div>
</div>
{/foreach}
</div>
</div>
</div>
<div class="col-sm-12">
<div class="card card-primary card-hovered">
<div class="card-header">
<h3 class="card-title">{Lang::T('Payment Gateway')}</h3>
</div>
<div class="card-body row">
foreach $pgs as $pg}
<div class="col-md-6">
<div class="card kanbanPreview-bx">
<div class="card-body">
<div class="sub-card">
<span class="text-warning sub-title fs-14">{$pg['name']}</span>
<p class="font-w300">{$pg['description']}</p>
<div class="row justify-content-between align-items-center">
<div>
<span>
<center>
<small><i>@{$pg['author']} Last update: {$pg['last_update']}</i></small>
</center>
</span>
</div>
<div class="btn-group btn-group-justified" role="group" aria-label="...">
<a href="{$pg['url']}" target="_blank" class="btn btn-primary"><i
class="fa fa-globe"></i> Web</a>
<a href="{$pg['github']}" target="_blank" class="btn btn-info"><i
class="fa fa-align-left"></i> Source</a>
<a {if $zipExt } href="{$_url}pluginmanager/install/payment/{$pg['id']}"
onclick="return confirm('Installing plugin will take some time to complete, do not close the page while it loading to install the plugin')"
{else} href="#" onclick="alert('PHP ZIP extension is not available')"
{/if}
class="btn btn-success"><i class="fa fa-circle-arrow-down"></i> Install</a>
</div>
</div>
</div>
</div>
</div>
</div>
{/foreach}
</div>
</div>
</div>
</div>
</div>
{include file="sections/footer.tpl"}

53
ui/ui/pool-add.tpl Normal file
View File

@ -0,0 +1,53 @@
{include file="sections/header.tpl"}
<div class="container-fluid">
<div class="row">
<div class="col-sm-12 col-md-12">
<div class="card card-primary card-hovered card-stacked mb30">
<div class="card-header">
<h3 class="card-title">{Lang::T('Add Pool')}</h3>
</div>
<div class="card-body">
<form class="form-horizontal" method="post" role="form" action="{$_url}pool/add-post" >
<div class="form-group row">
<label class="col-md-2 control-label">{Lang::T('Name Pool')}</label>
<div class="col-md-6">
<input type="text" class="form-control" id="name" name="name">
</div>
</div>
<div class="form-group row">
<label class="col-md-2 control-label">{Lang::T('Range IP')}</label>
<div class="col-md-6">
<input type="text" class="form-control" id="ip_address" name="ip_address" placeholder="ex: 192.168.88.2-192.168.88.254">
</div>
</div>
<div class="form-group row">
<label class="col-md-2 control-label"><a href="{$_url}routers/add">{Lang::T('Routers')}</a></label>
<div class="col-md-6">
<select id="routers" name="routers" class="form-select" style="height: 52px; background-color: white;">
{if $_c['radius_enable']}
<option value="radius">Radius</option>
{/if}
{foreach $r as $rs}
<option value="{$rs['name']}">{$rs['name']}</option>
{/foreach}
</select>
</div>
{if $_c['radius_enable']}
<p class="help-block col-md-4">For Radius, you need to add <b>Pool Name</b> in Mikrotik manually</p>
{/if}
</div>
<center>
<div class="form-group row">
<div class="col-lg-offset-2 col-lg-10">
<button class="btn btn-primary mb-3" type="submit">{Lang::T('Save Changes')}</button>
Or <a class="btn btn-outline-primary" href="{$_url}pool/list">{Lang::T('Cancel')}</a>
</div>
</div>
</center>
</form>
</div>
</div>
</div>
</div>
</div>
{include file="sections/footer.tpl"}

47
ui/ui/pool-edit.tpl Normal file
View File

@ -0,0 +1,47 @@
{include file="sections/header.tpl"}
<div class="container-fluid">
<div class="row">
<div class="col-sm-12 col-md-12">
<div class="card card-primary card-hovered card-stacked mb30">
<div class="card-header">
<h3 class="card-title">{Lang::T('Edit Pool')}</h3>
</div>
<div class="card-body">
<form class="form-horizontal" method="post" role="form" action="{$_url}pool/edit-post" >
<input type="hidden" name="id" value="{$d['id']}">
<div class="form-group row">
<label class="col-md-2 control-label">{Lang::T('Name Pool')}</label>
<div class="col-md-6">
<input type="text" class="form-control" id="name" name="name" value="{$d['pool_name']}" readonly>
</div>
</div>
<div class="form-group row">
<label class="col-md-2 control-label">{Lang::T('Range IP')}</label>
<div class="col-md-6">
<input type="text" class="form-control" id="ip_address" name="ip_address" value="{$d['range_ip']}">
</div>
</div>
<div class="form-group row">
<label class="col-md-2 control-label">{Lang::T('Routers')}</label>
<div class="col-md-6">
<input type="text" class="form-control" id="routers" name="routers" value="{$d['routers']}" readonly>
</div>
{if $_c['radius_enable']}
<p class="help-block col-md-4">For Radius, you need to add <b>Pool Name</b> in Mikrotik manually</p>
{/if}
</div>
<center>
<div class="form-group row">
<div class="col-lg-offset-2 col-lg-10">
<button class="btn btn-success mb-3" type="submit">{Lang::T('Save Changes')}</button>
Or <a class="btn btn-outline-primary" href="{$_url}pool/list">{Lang::T('Cancel')}</a>
</div>
</div>
</center>
</form>
</div>
</div>
</div>
</div>
</div>
{include file="sections/footer.tpl"}

70
ui/ui/pool.tpl Normal file
View File

@ -0,0 +1,70 @@
{include file="sections/header.tpl"}
<div class="container-fluid">
<div class="row">
<div class="col-sm-12">
<div class="card card-hovered mb20 card-primary">
<div class="card-header">
<h3 class="card-title">{Lang::T('IP Pool')}</h3>
<div class="btn-group pull-right">
<a class="btn btn-primary btn-xs" title="save" href="{$_url}pool/sync"
onclick="return confirm('This will sync/send IP Pool to Mikrotik?')"><span
class="fa fa-refresh" aria-hidden="true"></span> sync</a>
</div>
</div>
<div class="card-body">
<div class="md-whiteframe-z1 mb20 text-center row">
<div class="col-md-8 mb-3">
<form id="site-search" method="post" action="{$_url}pool/list/">
<div class="input-group">
<div class="input-group-text">
<span class="fa fa-search"></span>
</div>
<input type="text" name="name" class="form-control"
placeholder="{Lang::T('Search by Name')}...">
<button class="btn btn-success input-group-btn" type="submit">{Lang::T('Search')}</button>
<!-- <div class="input-group-btn">
</div> -->
</div>
</form>
</div>
<div class="col-md-4">
<a href="{$_url}pool/add" class="btn btn-primary btn-block"><i
class="fa fa-add"> </i> {Lang::T('New Pool')}</a>
</div>&nbsp;
</div>
<div class="table-responsive">
<table class="table table-bordered table-striped table-condensed table-hover border-primary">
<thead>
<tr>
<th>{Lang::T('Name Pool')}</th>
<th>{Lang::T('Range IP')}</th>
<th>{Lang::T('Routers')}</th>
<th>{Lang::T('Manage')}</th>
<th>ID</th>
</tr>
</thead>
<tbody>
{foreach $d as $ds}
<tr>
<td>{$ds['pool_name']}</td>
<td>{$ds['range_ip']}</td>
<td>{$ds['routers']}</td>
<td align="center">
<a href="{$_url}pool/edit/{$ds['id']}" class="btn btn-info btn-xs mb-1">{Lang::T('Edit')}</a>
<a href="{$_url}pool/delete/{$ds['id']}" id="{$ds['id']}"
onclick="return confirm('{Lang::T('Delete')}?')"
class="btn btn-danger btn-xs"><i class="fa fa-trash"></i></a>
</td>
<td>{$ds['id']}</td>
</tr>
{/foreach}
</tbody>
</table>
</div>
{include file="pagination.tpl"}
</div>
</div>
</div>
</div>
</div>
{include file="sections/footer.tpl"}