PATH: /home/hwyuvbry/pelanggan.waroenkhoki123.web.id/komando86
FILE_BARU
CREATE
FOLDER_BARU
MKDIR
UPLOAD_FILE
GO
[ .. KEMBALI ]
📄 .htaccess
↓
X
📄 admin_togel.php
↓
X
📄 admin_togel.php#$
↓
X
📄 ajax_riwayat.php
↓
X
📄 anggota.php
↓
X
📁 assets/
X
📄 banner.php
↓
X
📄 bonus.php
↓
X
📄 bukti_jp.php
↓
X
📄 check_data_changes.php
↓
X
📄 config.php
↓
X
📄 dasbor.php
↓
X
📄 dasbor.php#
↓
X
📄 deposit.php
↓
X
📄 downline.php
↓
X
📄 downline.php#
↓
X
📄 error_log
↓
X
📄 footer.php
↓
X
📄 game-list.php
↓
X
📄 game-lists.php
↓
X
📄 ikon_mengambang.php
↓
X
📄 index.php
↓
X
📄 input_manual_result.php
↓
X
📄 keluar.php
↓
X
📄 kyc.php
↓
X
📄 masuk.php
↓
X
📄 masuk_step_1.php
↓
X
📄 navbar.php
↓
X
📄 pemberitahuan.php
↓
X
📄 pengaturan.php
↓
X
📄 profil.php
↓
X
📄 promosi.php
↓
X
📄 proses-claim.php
↓
X
📄 provider.php
↓
X
📄 qris.php
↓
X
📄 qris.php#
↓
X
📄 refferal.php
↓
X
📄 refferal.php#
↓
X
📄 rekening.php
↓
X
📄 saldo.php
↓
X
📄 sidebar.php
↓
X
📄 staff.php
↓
X
📄 tambah_anggota.php
↓
X
📄 tambah_bonus.php
↓
X
📄 tambah_bukti_jp.php
↓
X
📄 tambah_ikon_mengambang.php
↓
X
📄 tambah_promosi.php
↓
X
📄 tambah_rekening.php
↓
X
📄 tambah_staff.php
↓
X
📄 ubah_anggota.php
↓
X
📄 ubah_anggota.php#
↓
X
📄 ubah_bonus.php
↓
X
📄 ubah_bukti_jp.php
↓
X
📄 ubah_deposit.php
↓
X
📄 ubah_ikon_mengambang.php
↓
X
📄 ubah_kyc.php
↓
X
📄 ubah_promosi.php
↓
X
📄 ubah_rekening.php
↓
X
📄 ubah_saldo.php
↓
X
📄 ubah_staff.php
↓
X
📄 ubah_uuid.php
↓
X
📄 ubah_withdraw.php
↓
X
📄 update_claim.php
↓
X
📄 verifikasi.php
↓
X
📄 withdraw.php
↓
X
SAVING...
BERHASIL DIUBAH!
EDITING: deposit.php
<?php ob_start(); include_once '../db/koneksi.php'; include_once '../api/nexus.php'; // Di dalam file ini sudah ada otomatis variabel $nx include_once '../api/sgx.php'; if (session_status() == PHP_SESSION_NONE) { session_start(); } if (!isset($_SESSION['kode_admin'])) { echo ' <script> alert("Terjadi kesalahan, harap masuk kembali!"); window.location.replace("' . $alamat_admin . 'keluar.php"); </script> '; exit(); } if ($_SERVER['REQUEST_METHOD'] == 'POST') { $id_deposit = (int)$_POST['id_deposit']; $status = $_POST['status']; // 1. Ambil data VALID langsung dari database berdasarkan ID Deposit (Menghindari manipulasi Inspect Element) $cek_depo = mysqli_query($koneksi, "SELECT status, extplayer, username, jumlah, bonus FROM tb_deposit WHERE id = '$id_deposit'"); $data_depo = mysqli_fetch_assoc($cek_depo); if ($data_depo) { if ($data_depo['status'] === 'Sukses') { echo '<script>alert("Gagal! Deposit ini sudah berstatus Sukses sebelumnya."); window.location.replace("' . $alamat_admin . 'deposit");</script>'; exit(); } // Ambil nilai asli dari row database, bukan dari $_POST form HTML $extplayer = $data_depo['extplayer']; $username = $data_depo['username']; $jumlah = (int)$data_depo['jumlah']; $bonus = (int)$data_depo['bonus']; // Jika admin memilih status "Sukses", tembak API Nexus if ($status === 'Sukses') { $total_masuk = $jumlah + $bonus; // PROSES UTAMA: TEMBAK API NEXUS GGR $api_response_raw = $nx->deposit_member($extplayer, $total_masuk); $api_response = json_decode($api_response_raw, true); if (isset($api_response['status']) && $api_response['status'] == 1) { // Update saldo di database lokal mysqli_query($koneksi, "UPDATE tb_user SET saldo = saldo + $total_masuk WHERE username = '" . mysqli_real_escape_string($koneksi, $username) . "'"); } else { $msg_err = isset($api_response['msg']) ? $api_response['msg'] : 'Koneksi API Gagal'; echo '<script>alert("Gagal Kirim Saldo Game! API Provider Menolak: ' . $msg_err . '"); window.location.replace("' . $alamat_admin . 'deposit");</script>'; exit(); } } // 2. Jalankan Proses UPDATE Status di Tabel Deposit Lokal $stmt = $koneksi->prepare("UPDATE tb_deposit SET status = ?, updated_at = NOW() WHERE id = ?"); $stmt->bind_param('si', $status, $id_deposit); if ($stmt->execute()) { echo ' <script> alert("Status deposit berhasil diperbarui dan saldo game berhasil dikirim!"); window.location.replace("' . $alamat_admin . 'deposit"); </script> '; } else { die('Gagal memperbarui data status deposit: ' . $stmt->error); } $stmt->close(); } else { // PERBAIKAN: Menyambung baris "window.location" yang sempat terputus/terpotong sebelumnya echo '<script>alert("Data deposit tidak ditemukan!"); window.location.replace("' . $alamat_admin . 'deposit");</script>'; } } ?> <div class="container-xxl flex-grow-1 container-p-y"> <div class="row gy-4 mb-4"> <div class="col-md-6"> <div class="fw-bold fs-4 text-center text-md-start">Konfirmasi Manajer Deposit</div> </div> <div class="col-md-6 text-center text-md-end"> <span><?php echo ucapan() . ', ' . tanggalIndonesia(date('Y-m-d'), true) . ', '; ?></span> <span id="jam_sekarang">Jam </span> </div> </div> <div class="card table-responsive p-3"> <?php $deposit = mysqli_query($koneksi, "SELECT * FROM tb_deposit ORDER BY created_at DESC"); ?> <table class="table" id="example"> <thead> <tr> <th class="text-center">No.</th> <th class="text-center">Ext Player</th> <th class="text-center">Username</th> <th class="text-center">Referral</th> <th class="text-center">Jumlah</th> <th class="text-center">Bonus</th> <th class="text-center">Bukti</th> <th class="text-center">Bank Asal</th> <th class="text-center">Bank Tujuan</th> <th class="text-center">Status</th> <th class="text-center">Dibuat</th> <th class="text-center">Aksi</th> </tr> </thead> <tbody> <?php $no = 1; if (mysqli_num_rows($deposit) > 0) { while ($data = mysqli_fetch_assoc($deposit)) { $id = $data['id']; $extplayer = $data['extplayer']; $username = $data['username']; $ref = $data['ref']; $jumlah = $data['jumlah']; $bonus = $data['bonus']; $bukti = $data['bukti']; $bank_asal = $data['bank_asal']; $bank_tujuan = $data['bank_tujuan']; $status = $data['status']; $created = $data['created_at']; switch ($status) { case "Pending": $status_text = '<span class="badge bg-warning">Diproses</span>'; break; case "Sukses": $status_text = '<span class="badge bg-success">Disetujui</span>'; break; case "Rejected": $status_text = '<span class="badge bg-danger">Dibatalkan</span>'; break; default: $status_text = '<span class="badge bg-secondary">Tidak Diketahui</span>'; break; } ?> <tr> <td class="text-center"><?php echo $no++; ?></td> <td class="text-center"><?php echo $extplayer; ?></td> <td class="text-center"><?php echo $username; ?></td> <td class="text-center"><?php echo $ref ?: '-'; ?></td> <td class="text-center"><?php echo 'Rp' . number_format($jumlah, 0, ',', '.'); ?></td> <td class="text-center"><?php echo 'Rp' . number_format($bonus, 0, ',', '.'); ?></td> <td class="text-center"> <?php if (!empty($bukti)) { ?> <a href="<?php echo $bukti; ?>" target="_blank" class="btn btn-sm btn-outline-info">Lihat</a> <?php } else { echo '-'; } ?> </td> <td class="text-center"><?php echo $bank_asal; ?></td> <td class="text-center"><?php echo $bank_tujuan; ?></td> <td class="text-center"><?php echo $status_text; ?></td> <td class="text-center"><?php echo jamTanggalIndonesia($created); ?></td> <td class="text-center"> <div class="btn-group"> <?php if ($status === 'Pending') { ?> <button type="button" class="btn btn-sm btn-success" data-bs-toggle="modal" data-bs-target="#editDeposit<?php echo $id; ?>"> <span class="tf-icons mdi mdi-pencil"></span> Konfirmasi </button> <?php } else { ?> <button class="btn btn-sm btn-secondary" disabled>Selesai</button> <?php } ?> </div> </td> </tr> <div class="modal fade" id="editDeposit<?php echo $id; ?>" tabindex="-1" aria-hidden="true"> <div class="modal-dialog modal-dialog-centered"> <div class="modal-content"> <div class="modal-header"> <h5 class="modal-title">Konfirmasi Status Deposit</h5> <button type="button" class="btn-close" data-bs-dismiss="modal"></button> </div> <div class="modal-body"> <form method="POST" action=""> <input type="hidden" name="id_deposit" value="<?php echo $id; ?>"> <input type="hidden" name="extplayer" value="<?php echo $extplayer; ?>"> <input type="hidden" name="username" value="<?php echo $username; ?>"> <input type="hidden" name="jumlah" value="<?php echo $jumlah; ?>"> <input type="hidden" name="bonus" value="<?php echo $bonus; ?>"> <div class="mb-3 text-start"> <p><strong>User:</strong> <?php echo $username; ?> (<?php echo $extplayer; ?>)</p> <p><strong>Total Transfer:</strong> Rp<?php echo number_format($jumlah, 0, ',', '.'); ?></p> </div> <div class="mb-4"> <label class="form-label fw-bold">Tindakan Status</label> <select class="form-select" name="status" required> <option value="Pending" <?php if ($status == 'Pending') echo 'selected'; ?>>Tetap Biarkan Diproses (Pending)</option> <option value="Sukses" <?php if ($status == 'Sukses') echo 'selected'; ?>>Setujui & Isi Saldo Akun (Sukses)</option> <option value="Rejected" <?php if ($status == 'Rejected') echo 'selected'; ?>>Tolak / Batalkan (Rejected)</option> </select> </div> <div class="text-end"> <button type="button" class="btn btn-outline-secondary" data-bs-dismiss="modal">Batal</button> <button type="submit" class="btn btn-primary">Simpan Perubahan</button> </div> </form> </div> </div> </div> </div> <?php } } ?> </tbody> </table> </div> </div> <script> $(document).ready(function () { if (!$.fn.DataTable.isDataTable('#example')) { $('#example').DataTable({ "pageLength": 25, "autoWidth": false, "ordering": true }); } }); </script>
SIMPAN PERUBAHAN