Update generate voucher
This commit is contained in:
@@ -1 +1 @@
|
||||
NO ACTION => 2 <-> cc.net Limit_Tgl_5<br>NO ACTION => 3 <-> nsn utama Limit_Tgl_10<br>NO ACTION => 3 <-> ciangsana Limit_Tgl_15<br>NO ACTION => 4 <-> fast.net Limit_Tgl_12<br>NO ACTION => 5 <-> bima net Limit Tagihan Tgl 15<br>NO ACTION => 6 <-> kingnet Limit Tgl 15<br>NO ACTION => 8 <-> diamond.net Limit_Tgl_15<br>NO ACTION => 9 <-> 22 p.net Limit_Tgl_15<br>NO ACTION => 10 <-> nettizen Tagihan Limit tgl 15<br>NO ACTION => 12 <-> Tagihan_Limit_Tgl5<br>NO ACTION => 15 <-> Tag_NTA2 Limit Tgl 10<br>NO ACTION => 16 <-> Tagihan Limit Tgl 5<br>NO ACTION => 13 <-> Limit Tanggal 26 (Infinnet)<br>NO ACTION => 18 <-> BUM-Limit-Tgl-5<br>BUAT TAGIHAN => 14 <-> Kh_Limit Tanggal 25 Start : 2025-07-13 - Last : 2025-07-18<br>NO ACTION => 17 <-> Tagihan Limit Tgl 10<br>NO ACTION => 17 <-> Tagihan Limit Tgl 15<br>NO ACTION => 20 <-> IVVI-10<br>NO ACTION => 20 <-> IVVI-20<br>NO ACTION => 20 <-> IVVI-30<br>NO ACTION => 21 <-> QONNET<br>NO ACTION => 21 <-> QONNET2<br>NO ACTION => 25 <-> Tagihan Limit Tgl 5<br>NO ACTION => 23 <-> Limit Tanggal 5<br>NO ACTION => 26 <-> Limit Tanggal 10<br>NO ACTION => 24 <-> Tagihan30<br>NO ACTION => 23 <-> limit tanggal 19<br>NO ACTION => 31 <-> 23-ISOLIR<br>NO ACTION => 33 <-> usolir-10<br>NO ACTION => 37 <-> paket 140 ribu<br>NO ACTION => 28 <-> PAKET-100K<br>NO ACTION => 28 <-> PAKET-150K<br>NO ACTION => 28 <-> PAKET-200K<br>NO ACTION => 28 <-> PAKET-300K<br>NO ACTION => 42 <-> meldina-20<br>NO ACTION => 41 <-> lippy-20<br>NO ACTION => 43 <-> Tagihan_Limit_tgl_13<br>NO ACTION => 46 <-> Limit_Tgl_5<br>NO ACTION => 35 <-> PAKET 1 DEVICE<br>NO ACTION => 35 <-> PAKET 2 DEVICE<br>NO ACTION => 35 <-> PAKET 3 DEVICE<br>NO ACTION => 35 <-> PAKET 4 DEVICE<br>NO ACTION => 35 <-> PAKET 5 DEVICE [1/80]<br>NO ACTION => 35 <-> PAKET 5 DEVICE [1/70]<br>NO ACTION => 35 <-> PAKET 6 DEVICE [1/80]<br>NO ACTION => 35 <-> PAKET 6 DEVICE [1/70]<br>NO ACTION => 35 <-> PAKET 7 DEVICE<br>NO ACTION => 35 <-> PAKET 8 DEVICE<br>NO ACTION => 44 <-> Isolir_20<br>NO ACTION => 53 <-> PAKET BRONZE <br>NO ACTION => 54 <-> Muhamad rouf<br>NO ACTION => 53 <-> PAKET PLATINUM 5MBs<br>NO ACTION => 53 <-> PAKET GLOD 7 MBs<br>NO ACTION => 53 <-> PAKET GLOD+ 10 MBs<br>NO ACTION => 59 <-> Isolir_21<br>NO ACTION => 46 <-> Limit tgl 30<br>NO ACTION => 61 <-> Isolir_20<br>NO ACTION => 55 <-> Dcn_CO_Isolir<br>NO ACTION => 62 <-> limit tanggal 5<br>NO ACTION => 55 <-> Dcn_GB_Isolir<br>NO ACTION => 49 <-> TAGIHAN TANGGAL 20<br>NO ACTION => 19 <-> TAGIHAN-TGL1<br>NO ACTION => 49 <-> TAGIHAN TANGGAL 1<br>NO ACTION => 66 <-> Tagihan Isolir Tgl 1<br>NO ACTION => 67 <-> Tag Netborhood Limit Tgl 10<br>NO ACTION => 73 <-> Tagihan01-05<br>
|
||||
NO ACTION => 2 <-> cc.net Limit_Tgl_5<br>NO ACTION => 3 <-> nsn utama Limit_Tgl_10<br>NO ACTION => 3 <-> ciangsana Limit_Tgl_15<br>NO ACTION => 4 <-> fast.net Limit_Tgl_12<br>NO ACTION => 5 <-> bima net Limit Tagihan Tgl 15<br>NO ACTION => 6 <-> kingnet Limit Tgl 15<br>NO ACTION => 8 <-> diamond.net Limit_Tgl_15<br>NO ACTION => 9 <-> 22 p.net Limit_Tgl_15<br>NO ACTION => 10 <-> nettizen Tagihan Limit tgl 15<br>NO ACTION => 12 <-> Tagihan_Limit_Tgl5<br>NO ACTION => 15 <-> Tag_NTA2 Limit Tgl 10<br>NO ACTION => 16 <-> Tagihan Limit Tgl 5<br>NO ACTION => 13 <-> Limit Tanggal 26 (Infinnet)<br>NO ACTION => 18 <-> BUM-Limit-Tgl-5<br>BUAT TAGIHAN => 14 <-> Kh_Limit Tanggal 25 Start : 2025-07-13 - Last : 2025-07-18<br>
|
||||
@@ -13,31 +13,34 @@ try {
|
||||
$start = intval($_GET['start'] ?? 0);
|
||||
$length = intval($_GET['length'] ?? 10);
|
||||
$searchValue = $_GET['search']['value'] ?? '';
|
||||
$svid = $_GET['i'] ?? '';
|
||||
|
||||
// Kolom yang bisa diurutkan
|
||||
$columns = ['create_time', 'voucher', 'harga', 'status_cek', 'active_time', 'expaired_time'];
|
||||
$columns = ['nama_server', 'voucher', 'harga', 'status', 'create_time', 'active_time', 'expaired_time'];
|
||||
$orderColumnIndex = $_GET['order'][0]['column'] ?? 0;
|
||||
$orderColumnDir = $_GET['order'][0]['dir'] ?? 'desc';
|
||||
$orderColumn = $columns[$orderColumnIndex] ?? 'create_time';
|
||||
|
||||
// Kondisi dasar (statis)
|
||||
$baseCondition = "id_agen_voucher IS NULL AND jenis IN ('sv-radius','sv-mikrotik','api-pw')";
|
||||
$baseCondition = "id_data_server IN (".$svid.")";
|
||||
|
||||
// Hitung total data
|
||||
$totalQuery = $pdo->query("SELECT COUNT(*) FROM ganerate_voucher WHERE $baseCondition");
|
||||
$totalQuery = $pdo->query("SELECT COUNT(*) FROM v_generate_voucher_manual WHERE $baseCondition");
|
||||
$totalRecords = $totalQuery->fetchColumn();
|
||||
|
||||
// Query data + search
|
||||
$sql = "SELECT create_time, voucher, harga, status_cek, active_time, expaired_time, jenis
|
||||
FROM ganerate_voucher
|
||||
$sql = "SELECT nama_server, nama_mikrotik, create_time, voucher, harga, jenis, active_time, expaired_time
|
||||
FROM v_generate_voucher_manual
|
||||
WHERE $baseCondition";
|
||||
$params = [];
|
||||
|
||||
if (!empty($searchValue)) {
|
||||
$sql .= " AND (
|
||||
nama_server LIKE :search OR
|
||||
nama_mikrotik LIKE :search OR
|
||||
create_time LIKE :search OR
|
||||
voucher LIKE :search OR
|
||||
status_cek LIKE :search OR
|
||||
jenis LIKE :search OR
|
||||
active_time LIKE :search OR
|
||||
expaired_time LIKE :search
|
||||
)";
|
||||
@@ -46,7 +49,7 @@ try {
|
||||
|
||||
// Hitung total setelah filter
|
||||
$filteredSql = str_replace(
|
||||
"SELECT create_time, voucher, harga, status_cek, active_time, expaired_time, jenis",
|
||||
"SELECT nama_server, nama_mikrotik, create_time, voucher, harga, jenis, active_time, expaired_time",
|
||||
"SELECT COUNT(*)",
|
||||
$sql
|
||||
);
|
||||
@@ -80,12 +83,13 @@ try {
|
||||
$saldo = $harga - $biaya;
|
||||
|
||||
$data[] = [
|
||||
$row['create_time'],
|
||||
$row['nama_server'] . '<br>' . $row['nama_mikrotik'],
|
||||
$row['voucher'],
|
||||
number_format($harga), // harga
|
||||
number_format($biaya), // biaya
|
||||
number_format($saldo), // saldo
|
||||
$row['status_cek'],
|
||||
$row['jenis'],
|
||||
$row['create_time'],
|
||||
$row['active_time'],
|
||||
$row['expaired_time'],
|
||||
];
|
||||
|
||||
+15
-15
@@ -1,23 +1,23 @@
|
||||
SV_Cikembar_Utama Data pelanggan tidak ada
|
||||
2025-07-14 23:47:01SV_BojongKerta Data pelanggan tidak ada
|
||||
2025-07-14 23:47:01SV_Permata_Sampora Data pelanggan tidak ada
|
||||
2025-07-14 23:47:01SV_Kingnet_Cibadak Data pelanggan tidak ada
|
||||
2025-07-14 23:47:01SV_CC-Net_Cipicung Data pelanggan tidak ada
|
||||
2025-07-14 23:47:01SV_Nusaina_Cibadak Data pelanggan tidak ada
|
||||
2025-07-14 23:47:01SV_Diamond Net Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
2025-07-15 01:58:01SV_BojongKerta Data pelanggan tidak ada
|
||||
2025-07-15 01:58:01SV_Permata_Sampora Data pelanggan tidak ada
|
||||
2025-07-15 01:58:01SV_Kingnet_Cibadak Data pelanggan tidak ada
|
||||
2025-07-15 01:58:01SV_CC-Net_Cipicung Data pelanggan tidak ada
|
||||
2025-07-15 01:58:01SV_Nusaina_Cibadak Data pelanggan tidak ada
|
||||
2025-07-15 01:58:01SV_Diamond Net Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
SV_22P Net Cibadak Data pelanggan tidak ada
|
||||
2025-07-14 23:47:01SV_Nettizen_Segaranten Data pelanggan tidak ada
|
||||
2025-07-14 23:17:02SV-DNY-Net-1 Data pelanggan tidak ada
|
||||
2025-07-14 23:57:02SV_NTA_2_Pasawahan Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
2025-07-15 01:58:01SV_Nettizen_Segaranten Data pelanggan tidak ada
|
||||
2025-07-15 01:28:01SV-DNY-Net-1 Data pelanggan tidak ada
|
||||
2025-07-15 02:08:01SV_NTA_2_Pasawahan Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
SV_NTA_1 Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
SV-Cicukang Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
RO-Bumdes-Mekarmanah Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
RO-Pak-Kholiq Data pelanggan tidak ada
|
||||
2025-07-15 00:02:02RO-Dendrit-Net Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
2025-07-15 02:13:01RO-Dendrit-Net Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
LJN.NS.CSR.NET Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
IVVINET-CBD Data pelanggan tidak ada
|
||||
2025-07-14 23:47:02QONNET Data pelanggan tidak ada
|
||||
2025-07-14 23:47:02Mikrotik_X86 Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
2025-07-15 01:58:02QONNET Data pelanggan tidak ada
|
||||
2025-07-15 01:58:02Mikrotik_X86 Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
Mikrotik_BSW_1 Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
Mikrotik_Alea Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
STANG Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
@@ -37,14 +37,14 @@ RO_Wargasari Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
LJN_AGUNG Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
RNET-CMS Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
DCN-GB-CCR Data pelanggan tidak ada
|
||||
2025-07-14 23:47:02coba Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
2025-07-15 01:58:02coba Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
412NET Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
brf Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
BMSNET Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
purabaya Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
DCN-CO-GX4 Data pelanggan tidak ada
|
||||
2025-07-14 23:47:02MIKROTIK GX4 Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
2025-07-15 01:58:02MIKROTIK GX4 Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
RO - Netborhood Wifi Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
Neglasari Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
SV-DNY-Net-2 Data pelanggan tidak ada
|
||||
2025-07-14 23:57:02DNY-Neglasari Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
2025-07-15 02:08:02DNY-Neglasari Status koneksi tidak aktif atau interval tidak tersedia.
|
||||
|
||||
@@ -1 +1 @@
|
||||
Successfully started background process for IP: tunnel.manjapro.net SV-DNY-Net-1<br>Successfully started background process for IP: nsn.my.id SV_22P Net Cibadak<br>Successfully started background process for IP: nsn.my.id RO-Bumdes-Mekarmanah<br>Successfully started background process for IP: 103.242.104.69 RO-Dendrit-Net<br>Successfully started background process for IP: 103.26.176.93 LJN.NS.CSR.NET<br>Successfully started background process for IP: 103.155.198.109 RO_Asep<br>Successfully started background process for IP: 103.155.199.191 PERWASIM-NETWORK<br>Successfully started background process for IP: tunnel.manjapro.net SV_NTA_2_Pasawahan<br>Successfully started background process for IP: tunnel.manjapro.net SV-Cicukang<br>Successfully started background process for IP: tunnel.manjapro.net SV_NTA_1<br>Successfully started background process for IP: 103.94.10.112 STANG<br>Successfully started background process for IP: 157.20.128.231 QONNET<br>Successfully started background process for IP: 114.141.51.12 BMSNET<br>Successfully started background process for IP: 114.141.51.12 purabaya<br>Successfully started background process for IP: nsn.my.id SV_Cikembar_Utama<br>Successfully started background process for IP: tunnel.bilspro.com RO_Sukasari<br>Successfully started background process for IP: tunnel.bilspro.com Mikrotik_X86<br>Successfully started background process for IP: 103.155.196.145 UNIX-NET<br>Successfully started background process for IP: nsn.my.id SV_Diamond Net<br>Successfully started background process for IP: 103.26.176.81 SV_CC-Net_Cipicung<br>Successfully started background process for IP: 103.242.105.199 SV-DNY-Net-2<br>Started parallel processes for checking vouchers. => 2025-07-15 00:00:01
|
||||
Successfully started background process for IP: tunnel.manjapro.net SV-DNY-Net-1<br>Successfully started background process for IP: nsn.my.id SV_22P Net Cibadak<br>Successfully started background process for IP: nsn.my.id RO-Bumdes-Mekarmanah<br>Successfully started background process for IP: 103.242.104.69 RO-Dendrit-Net<br>Successfully started background process for IP: 103.26.176.93 LJN.NS.CSR.NET<br>Successfully started background process for IP: 103.155.198.109 RO_Asep<br>Successfully started background process for IP: 103.155.199.191 PERWASIM-NETWORK<br>Successfully started background process for IP: tunnel.manjapro.net SV_NTA_2_Pasawahan<br>Successfully started background process for IP: tunnel.manjapro.net SV-Cicukang<br>Successfully started background process for IP: tunnel.manjapro.net SV_NTA_1<br>Successfully started background process for IP: 103.94.10.112 STANG<br>Successfully started background process for IP: 157.20.128.231 QONNET<br>Successfully started background process for IP: 114.141.51.12 BMSNET<br>Successfully started background process for IP: 114.141.51.12 purabaya<br>Successfully started background process for IP: nsn.my.id SV_Cikembar_Utama<br>Successfully started background process for IP: tunnel.bilspro.com RO_Sukasari<br>Successfully started background process for IP: tunnel.bilspro.com Mikrotik_X86<br>Successfully started background process for IP: 103.155.196.145 UNIX-NET<br>Successfully started background process for IP: nsn.my.id SV_Diamond Net<br>Successfully started background process for IP: 103.26.176.81 SV_CC-Net_Cipicung<br>Successfully started background process for IP: 103.242.105.199 SV-DNY-Net-2<br>Started parallel processes for checking vouchers. => 2025-07-15 02:00:02
|
||||
+10
-13
@@ -1,9 +1,3 @@
|
||||
<?php
|
||||
|
||||
ini_set('display_errors', 1);
|
||||
error_reporting(E_ALL);
|
||||
|
||||
?>
|
||||
<!-- Main content -->
|
||||
<section class="content">
|
||||
<div class="container-fluid">
|
||||
@@ -295,9 +289,10 @@ $List->set_list("setting_mikrotik", $SqlDataWHId);
|
||||
<select class="form-control" name="idmscript" id="idmscript">
|
||||
<?php foreach ($List->get_list() as $value):
|
||||
$radius_data = json_decode($value['radius_nas_data']);
|
||||
$nasgroupname = $radius_data->data->{'nasgroupname'} ?? '';
|
||||
$dataUrl = encrypt_url(json_encode([
|
||||
'board' => $value['board_id'],
|
||||
'nasgroupname' => $radius_data->data->{'nasgroupname'}
|
||||
'nasgroupname' => $nasgroupname
|
||||
]));
|
||||
?>
|
||||
<option value="<?= htmlspecialchars($dataUrl) ?>">
|
||||
@@ -321,8 +316,8 @@ $List->set_list("setting_mikrotik", $SqlDataWHId);
|
||||
<script>
|
||||
// Buat script HTML dengan escape karakter agar aman
|
||||
function generateScript(dataUrl) {
|
||||
return `<div id="voucher-container"></div>;
|
||||
<script src="http://localhost/manjapro-project/voucherpay/cl-style.js?i=${dataUrl}"></script>`;
|
||||
return `<div id="voucher-container"></div>
|
||||
<script src="https://manjapro.net/voucherpay/cl-style.js?i=${dataUrl}"></script>`;
|
||||
}
|
||||
|
||||
// Update script ketika pilihan berubah
|
||||
@@ -368,12 +363,13 @@ function copyToClipboard(preId) {
|
||||
<table id="voucherTable" class="table table-striped table-bordered" style="zoom: 90%;">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Waktu</th>
|
||||
<th>Server</th>
|
||||
<th>Voucher</th>
|
||||
<th>Harga</th>
|
||||
<th>Biaya</th>
|
||||
<th>Saldo</th>
|
||||
<th>Status</th>
|
||||
<th>Dibuat</th>
|
||||
<th>Aktif</th>
|
||||
<th>Expired</th>
|
||||
</tr>
|
||||
@@ -487,7 +483,7 @@ $(document).ready(function() {
|
||||
"responsive": true,
|
||||
"autoWidth": false,
|
||||
"ajax": {
|
||||
"url": "controller/voucher_auto.php",
|
||||
"url": "controller/voucher_auto.php?i=<?= $SvId; ?>",
|
||||
"type": "GET"
|
||||
},
|
||||
"pageLength": 25,
|
||||
@@ -498,8 +494,9 @@ $(document).ready(function() {
|
||||
{ "data": 3, "orderable": false }, // biaya (tidak bisa diurutkan)
|
||||
{ "data": 4, "orderable": false }, // saldo (tidak bisa diurutkan)
|
||||
{ "data": 5 }, // status_cek
|
||||
{ "data": 6 }, // active_time
|
||||
{ "data": 7 } // expaired_time
|
||||
{ "data": 6 },
|
||||
{ "data": 7 }, // active_time
|
||||
{ "data": 8 } // expaired_time
|
||||
],
|
||||
"order": [[0, "desc"]]
|
||||
});
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<div class="card-header">
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<h3 class="card-title">Setting Mikrotik <?=$SvId;?></h3>
|
||||
<h3 class="card-title">Setting Mikrotik</h3>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<ol class="float-sm-right mb-0">
|
||||
|
||||
@@ -62,9 +62,9 @@ while ($tiap = $ambil->fetch_assoc()) {
|
||||
<label>Level Gangguan</label>
|
||||
<select class="form-control" name="level" required>
|
||||
<option value="">Pilih Level</option>
|
||||
<option value="1">Tinggi</option>
|
||||
<option value="2">Sedang</option>
|
||||
<option value="3">Bawah</option>
|
||||
<option class="text-danger" value="1">Tinggi</option>
|
||||
<option class="text-warning" value="2">Sedang</option>
|
||||
<option class="text-info" value="3">Bawah</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
if (container) {
|
||||
const iframe = document.createElement("iframe");
|
||||
iframe.id = "voucherFrame";
|
||||
iframe.src = "http://localhost/manjapro-project/voucherpay/?i=" + encodeURIComponent(i);
|
||||
iframe.src = "https://manjapro.net/voucherpay/?i=" + encodeURIComponent(i);
|
||||
iframe.style.width = "100%";
|
||||
iframe.style.border = "none";
|
||||
iframe.style.display = "block";
|
||||
|
||||
Reference in New Issue
Block a user