fix radius pool select
This commit is contained in:
parent
470c219e61
commit
b504723e7c
@ -2,6 +2,10 @@
|
|||||||
|
|
||||||
# CHANGELOG
|
# CHANGELOG
|
||||||
|
|
||||||
|
## 2024.1.16
|
||||||
|
|
||||||
|
- Add yellow color to table for plan not allowed to purchase
|
||||||
|
|
||||||
## 2024.1.15
|
## 2024.1.15
|
||||||
|
|
||||||
- Fix cron job for Plan only for admin by @Focuslinkstech
|
- Fix cron job for Plan only for admin by @Focuslinkstech
|
||||||
|
@ -130,6 +130,7 @@ class Mikrotik
|
|||||||
->setArgument('address-pool', $pool)
|
->setArgument('address-pool', $pool)
|
||||||
->setArgument('rate-limit', '512K/512K')
|
->setArgument('rate-limit', '512K/512K')
|
||||||
);
|
);
|
||||||
|
die("| $profileID | $name | $pool |");
|
||||||
} else {
|
} else {
|
||||||
$setRequest = new RouterOS\Request('/ip/hotspot/user/profile/set');
|
$setRequest = new RouterOS\Request('/ip/hotspot/user/profile/set');
|
||||||
$client->sendSync(
|
$client->sendSync(
|
||||||
|
@ -117,7 +117,7 @@ foreach ($d as $ds) {
|
|||||||
echo " : EXPIRED \r\n";
|
echo " : EXPIRED \r\n";
|
||||||
$u = ORM::for_table('tbl_user_recharges')->where('id', $ds['id'])->find_one();
|
$u = ORM::for_table('tbl_user_recharges')->where('id', $ds['id'])->find_one();
|
||||||
$c = ORM::for_table('tbl_customers')->where('id', $ds['customer_id'])->find_one();
|
$c = ORM::for_table('tbl_customers')->where('id', $ds['customer_id'])->find_one();
|
||||||
$m = ORM::for_table('tbl_routers')->where('name', $ds['routers'])->find_one();
|
$m = Mikrotik::info($ds['routers']);
|
||||||
$p = ORM::for_table('tbl_plans')->where('id', $u['plan_id'])->find_one();
|
$p = ORM::for_table('tbl_plans')->where('id', $u['plan_id'])->find_one();
|
||||||
|
|
||||||
if ($p['is_radius']) {
|
if ($p['is_radius']) {
|
||||||
|
@ -175,21 +175,20 @@
|
|||||||
if (cek.checked) {
|
if (cek.checked) {
|
||||||
$("#routerChoose").addClass('hidden');
|
$("#routerChoose").addClass('hidden');
|
||||||
document.getElementById("routers").required = false;
|
document.getElementById("routers").required = false;
|
||||||
|
$("#pool_expired").html('');
|
||||||
|
$.ajax({
|
||||||
|
url: "index.php?_route=autoload/pool",
|
||||||
|
data: "routers=radius",
|
||||||
|
cache: false,
|
||||||
|
success: function(msg) {
|
||||||
|
$("#pool_expired").html(msg);
|
||||||
|
}
|
||||||
|
});
|
||||||
} else {
|
} else {
|
||||||
document.getElementById("routers").required = true;
|
document.getElementById("routers").required = true;
|
||||||
$("#routerChoose").removeClass('hidden');
|
$("#routerChoose").removeClass('hidden');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
setTimeout(() => {
|
|
||||||
$.ajax({
|
|
||||||
url: "index.php?_route=autoload/pool",
|
|
||||||
data: "routers=radius",
|
|
||||||
cache: false,
|
|
||||||
success: function(msg) {
|
|
||||||
$("#pool_expired").html(msg);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}, 2000);
|
|
||||||
</script>
|
</script>
|
||||||
{/literal}
|
{/literal}
|
||||||
{/if}
|
{/if}
|
||||||
|
@ -179,7 +179,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{if $_c['radius_enable']}
|
{if $_c['radius_enable'] && $d['is_radius']}
|
||||||
{literal}
|
{literal}
|
||||||
<script>
|
<script>
|
||||||
function isRadius(cek) {
|
function isRadius(cek) {
|
||||||
|
@ -121,7 +121,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{if $_c['radius_enable'] and $d['is_radius']}
|
{if $_c['radius_enable'] && $d['is_radius']}
|
||||||
{literal}
|
{literal}
|
||||||
<script>
|
<script>
|
||||||
document.getElementById("routers").required = false;
|
document.getElementById("routers").required = false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user