feat: Initialize project with core dependencies, Vultr API client, customer database service, and migration documentation.
This commit is contained in:
26
not_used/check_pppoe_data.js
Normal file
26
not_used/check_pppoe_data.js
Normal file
@@ -0,0 +1,26 @@
|
||||
require('dotenv').config();
|
||||
const mikrotik = require('./services/mikrotikService');
|
||||
|
||||
async function test() {
|
||||
console.log("Fetching Active PPPoE Users...");
|
||||
try {
|
||||
const users = await mikrotik.getActivePppoe();
|
||||
console.log(`Found ${users.length} active users.`);
|
||||
|
||||
if (users.length > 0) {
|
||||
console.log("Sample User Data:");
|
||||
console.log(users[0]);
|
||||
|
||||
// check if specific user exists (mocking the user request)
|
||||
const target = users.find(u => u.name === '2000109' || u.name.includes('2000109'));
|
||||
if (target) {
|
||||
console.log("\nTarget User (2000109) Found:");
|
||||
console.log(target);
|
||||
}
|
||||
}
|
||||
} catch (error) {
|
||||
console.error("Test Failed:", error);
|
||||
}
|
||||
}
|
||||
|
||||
test();
|
||||
Reference in New Issue
Block a user