Merge branch 'Development' into patch-8

This commit is contained in:
iBNu Maksum 2024-04-15 09:00:53 +07:00 committed by GitHub
commit 05caee1193
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 197 additions and 212 deletions

View File

@ -1,147 +1,101 @@
<?php
include "../init.php";
$isCli = true;
if (php_sapi_name() !== 'cli') {
$isCli = false;
$isCli = (php_sapi_name() !== 'cli') ? false : true;
if (!$isCli) {
echo "<pre>";
}
echo "PHP Time\t" . date('Y-m-d H:i:s') . "\n";
$res = ORM::raw_execute('SELECT NOW() AS WAKTU;');
$statement = ORM::get_last_statement();
$rows = array();
$rows = [];
while ($row = $statement->fetch(PDO::FETCH_ASSOC)) {
echo "MYSQL Time\t" . $row['WAKTU'] . "\n";
}
$_c = $config;
$textExpired = Lang::getNotifText('expired');
$d = ORM::for_table('tbl_user_recharges')->where('status', 'on')->where_lte('expiration', date("Y-m-d"))->find_many();
echo "Found " . count($d) . " user(s)\n";
run_hook('cronjob'); #HOOK
$recharges = ORM::for_table('tbl_user_recharges')
->where('status', 'on')
->where_lte('expiration', date("Y-m-d"))
->find_many();
foreach ($d as $ds) {
if ($ds['type'] == 'Hotspot') { # HOTSPOT
$date_now = strtotime(date("Y-m-d H:i:s"));
$expiration = strtotime($ds['expiration'] . ' ' . $ds['time']);
echo $ds['expiration'] . " : " . (($isCli) ? $ds['username'] : Lang::maskText($ds['username']));
if ($date_now >= $expiration) {
echo " : EXPIRED \r\n";
$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();
$m = Mikrotik::info($ds['routers']);
$p = ORM::for_table('tbl_plans')->where('id', $u['plan_id'])->find_one();
if ($p['is_radius']) {
if (empty($p['pool_expired'])) {
print_r(Radius::customerDeactivate($c['username']));
echo "Found " . count($recharges) . " user(s)\n";
run_hook('cronjob'); // HOOK
foreach ($recharges as $recharge) {
$dateNow = strtotime(date("Y-m-d H:i:s"));
$expiration = strtotime($recharge['expiration'] . ' ' . $recharge['time']);
echo $recharge['expiration'] . " : " . (($isCli) ? $recharge['username'] : Lang::maskText($recharge['username']));
if ($dateNow >= $expiration) {
echo " : EXPIRED \r\n";
$userRecharge = ORM::for_table('tbl_user_recharges')->where('id', $recharge['id'])->find_one();
$customer = ORM::for_table('tbl_customers')->where('id', $recharge['customer_id'])->find_one();
$plan = ORM::for_table('tbl_plans')->where('id', $userRecharge['plan_id'])->find_one();
$router = ($recharge['type'] == 'Hotspot') ? Mikrotik::info($recharge['routers']) : ORM::for_table('tbl_routers')->where('name', $recharge['routers'])->find_one();
if ($plan['is_radius']) {
if (empty($plan['pool_expired'])) {
print_r(Radius::customerDeactivate($customer['username']));
} else {
Radius::upsertCustomerAttr($customer['username'], 'Framed-Pool', $plan['pool_expired'], ':=');
print_r(Radius::disconnectCustomer($customer['username']));
}
} else {
$client = Mikrotik::getClient($router['ip_address'], $router['username'], $router['password']);
if (!empty($plan['pool_expired'])) {
if ($recharge['type'] == 'Hotspot') {
Mikrotik::setHotspotUserPackage($client, $customer['username'], 'EXPIRED NUXBILL ' . $plan['pool_expired']);
} else {
Radius::upsertCustomerAttr($c['username'], 'Framed-Pool', $p['pool_expired'], ':=');
print_r(Radius::disconnectCustomer($c['username']));
Mikrotik::setPpoeUserPlan($client, $customer['username'], 'EXPIRED NUXBILL ' . $plan['pool_expired']);
}
} else {
$client = Mikrotik::getClient($m['ip_address'], $m['username'], $m['password']);
if (!empty($p['pool_expired'])) {
Mikrotik::setHotspotUserPackage($client, $c['username'], 'EXPIRED NUXBILL ' . $p['pool_expired']);
// }if (!empty($p['list_expired'])) {
// $ip = Mikrotik::getIpHotspotUser($client, $ds['username']);
// Mikrotik::addIpToAddressList($client, $ip, $p['list_expired'], $c['username']);
if ($recharge['type'] == 'Hotspot') {
Mikrotik::removeHotspotUser($client, $customer['username']);
Mikrotik::removeHotspotActiveUser($client, $customer['username']);
} else {
Mikrotik::removeHotspotUser($client, $c['username']);
Mikrotik::removePpoeUser($client, $customer['username']);
Mikrotik::removePpoeActive($client, $customer['username']);
}
Mikrotik::removeHotspotActiveUser($client, $c['username']);
}
echo Message::sendPackageNotification($c, $u['namebp'], $p['price'], $textExpired, $config['user_notification_expired']) . "\n";
//update database user dengan status off
$u->status = 'off';
$u->save();
}
// autorenewal from deposit
if ($config['enable_balance'] == 'yes' && $c['auto_renewal']) {
list($bills, $add_cost) = User::getBills($ds['customer_id']);
if ($add_cost > 0) {
if (!empty($add_cost)) {
$p['price'] += $add_cost;
}
}
if ($p && $p['enabled'] && $c['balance'] >= $p['price']) {
if (Package::rechargeUser($ds['customer_id'], $ds['routers'], $p['id'], 'Customer', 'Balance')) {
// if success, then get the balance
Balance::min($ds['customer_id'], $p['price']);
echo "plan enabled: $p[enabled] | User balance: $c[balance] | price $p[price]\n";
echo "auto renewall Success\n";
} else {
echo "plan enabled: $p[enabled] | User balance: $c[balance] | price $p[price]\n";
echo "auto renewall Failed\n";
Message::sendTelegram("FAILED RENEWAL #cron\n\n#u$c[username] #buy #Hotspot \n" . $p['name_plan'] .
"\nRouter: " . $p['routers'] .
"\nPrice: " . $p['price']);
}
echo Message::sendPackageNotification($customer, $userRecharge['namebp'], $plan['price'], $textExpired, $config['user_notification_expired']) . "\n";
$userRecharge->status = 'off';
$userRecharge->save();
if ($config['enable_balance'] == 'yes' && $customer['auto_renewal']) {
list($bills, $add_cost) = User::getBills($recharge['customer_id']);
if ($add_cost > 0) {
$plan['price'] += $add_cost;
}
if ($plan && $plan['enabled'] && $customer['balance'] >= $plan['price']) {
if (Package::rechargeUser($recharge['customer_id'], $plan['routers'], $plan['id'], 'Customer', 'Balance')) {
Balance::min($recharge['customer_id'], $plan['price']);
echo "Plan enabled: $plan[enabled] | User balance: $customer[balance] | Price: $plan[price]\n";
echo "Autorenewal Success\n";
} else {
echo "no renewall | plan enabled: $p[enabled] | User balance: $c[balance] | price $p[price]\n";
echo "Plan enabled: $plan[enabled] | User balance: $customer[balance] | Price: $plan[price]\n";
echo "Autorenewal Failed\n";
Message::sendTelegram("FAILED RENEWAL #cron\n\n#u$customer[username] #buy #" . (($recharge['type'] == 'Hotspot') ? 'Hotspot' : 'PPPOE') . " \n" . $plan['name_plan'] .
"\nRouter: " . $plan['routers'] .
"\nPrice: " . $plan['price']);
}
} else {
echo "no renewall | balance $config[enable_balance] auto_renewal $c[auto_renewal]\n";
echo "No renewal | Plan enabled: $plan[enabled] | User balance: $customer[balance] | Price: $plan[price]\n";
}
} else
echo " : ACTIVE \r\n";
} else { # PPPOE
$date_now = strtotime(date("Y-m-d H:i:s"));
$expiration = strtotime($ds['expiration'] . ' ' . $ds['time']);
echo $ds['expiration'] . " : " . (($isCli) ? $ds['username'] : Lang::maskText($ds['username']));
if ($date_now >= $expiration) {
echo " : EXPIRED \r\n";
$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();
$m = ORM::for_table('tbl_routers')->where('name', $ds['routers'])->find_one();
$p = ORM::for_table('tbl_plans')->where('id', $u['plan_id'])->find_one();
if ($p['is_radius']) {
if (empty($p['pool_expired'])) {
print_r(Radius::customerDeactivate($c['username']));
} else {
Radius::upsertCustomerAttr($c['username'], 'Framed-Pool', $p['pool_expired'], ':=');
print_r(Radius::disconnectCustomer($c['username']));
}
} else {
$client = Mikrotik::getClient($m['ip_address'], $m['username'], $m['password']);
if (!empty($p['pool_expired'])) {
Mikrotik::setPpoeUserPlan($client, $c['username'], 'EXPIRED NUXBILL ' . $p['pool_expired']);
} else {
Mikrotik::removePpoeUser($client, $c['username']);
}
Mikrotik::removePpoeActive($client, $c['username']);
}
echo Message::sendPackageNotification($c, $u['namebp'], $p['price'], $textExpired, $config['user_notification_expired']) . "\n";
$u->status = 'off';
$u->save();
// autorenewal from deposit
if ($config['enable_balance'] == 'yes' && $c['auto_renewal']) {
list($bills, $add_cost) = User::getBills($ds['customer_id']);
if ($add_cost > 0) {
if (!empty($add_cost)) {
$p['price'] += $add_cost;
}
}
if ($p && $p['enabled'] && $c['balance'] >= $p['price']) {
if (Package::rechargeUser($ds['customer_id'], $p['routers'], $p['id'], 'Customer', 'Balance')) {
// if success, then get the balance
Balance::min($ds['customer_id'], $p['price']);
echo "plan enabled: $p[enabled] | User balance: $c[balance] | price $p[price]\n";
echo "auto renewall Success\n";
} else {
echo "plan enabled: $p[enabled] | User balance: $c[balance] | price $p[price]\n";
echo "auto renewall Failed\n";
Message::sendTelegram("FAILED RENEWAL #cron\n\n#u$c[username] #buy #PPPOE \n" . $p['name_plan'] .
"\nRouter: " . $p['routers'] .
"\nPrice: " . $p['price']);
}
}
}
} else
echo " : ACTIVE \r\n";
} else {
echo "No renewal | Balance: $config[enable_balance] Auto-renewal: $customer[auto_renewal]\n";
}
} else {
echo " : ACTIVE \r\n";
}
}
}

View File

@ -2,8 +2,8 @@
/**
* PHP Mikrotik Billing (https://github.com/hotspotbilling/phpnuxbill/)
* This file for reminding user about expiration
* Example to run every at 7:00 in the morning
* This file is for reminding users about expiration
* Example to run every day at 7:00 in the morning:
* 0 7 * * * /usr/bin/php /var/www/system/cron_reminder.php
**/
@ -15,10 +15,9 @@ if (php_sapi_name() !== 'cli') {
echo "<pre>";
}
$d = ORM::for_table('tbl_user_recharges')->where('status', 'on')->find_many();
run_hook('cronjob_reminder'); #HOOK
$recharges = ORM::for_table('tbl_user_recharges')->where('status', 'on')->find_many();
run_hook('cronjob_reminder'); // HOOK
echo "PHP Time\t" . date('Y-m-d H:i:s') . "\n";
$res = ORM::raw_execute('SELECT NOW() AS WAKTU;');
@ -28,33 +27,35 @@ while ($row = $statement->fetch(PDO::FETCH_ASSOC)) {
echo "MYSQL Time\t" . $row['WAKTU'] . "\n";
}
$day7 = date('Y-m-d', strtotime("+7 day"));
$day3 = date('Y-m-d', strtotime("+3 day"));
$day1 = date('Y-m-d', strtotime("+1 day"));
print_r([$day1, $day3, $day7]);
foreach ($d as $ds) {
if (in_array($ds['expiration'], [$day1, $day3, $day7])) {
$u = ORM::for_table('tbl_user_recharges')->where('id', $ds['id'])->find_one();
$p = ORM::for_table('tbl_plans')->where('id', $u['plan_id'])->find_one();
$c = ORM::for_table('tbl_customers')->where('id', $ds['customer_id'])->find_one();
if ($p['validity_unit'] == 'Period') {
// Postpaid price from field
$add_inv = User::getAttribute("Invoice", $ds['customer_id']);
if (empty ($add_inv) or $add_inv == 0) {
$price = $p['price'];
} else {
$price = $add_inv;
}
foreach ($recharges as $recharge) {
if (in_array($recharge['expiration'], [$day1, $day3, $day7])) {
$user_recharge = ORM::for_table('tbl_user_recharges')->where('id', $recharge['id'])->find_one();
$plan = ORM::for_table('tbl_plans')->where('id', $user_recharge['plan_id'])->find_one();
$customer = ORM::for_table('tbl_customers')->where('id', $recharge['customer_id'])->find_one();
if ($plan['validity_unit'] == 'Period') {
// Postpaid price from field
$additional_invoice = User::getAttribute("Invoice", $recharge['customer_id']);
if (empty($additional_invoice) || $additional_invoice == 0) {
$price = $plan['price'];
} else {
$price = $additional_invoice;
}
} else {
$price = $p['price'];
$price = $plan['price'];
}
if ($ds['expiration'] == $day7) {
echo Message::sendPackageNotification($c, $p['name_plan'], $price, Lang::getNotifText('reminder_7_day'), $config['user_notification_reminder']) . "\n";
} else if ($ds['expiration'] == $day3) {
echo Message::sendPackageNotification($c, $p['name_plan'], $price, Lang::getNotifText('reminder_3_day'), $config['user_notification_reminder']) . "\n";
} else if ($ds['expiration'] == $day1) {
echo Message::sendPackageNotification($c, $p['name_plan'], $price, Lang::getNotifText('reminder_1_day'), $config['user_notification_reminder']) . "\n";
if ($recharge['expiration'] == $day7) {
echo Message::sendPackageNotification($customer, $plan['name_plan'], $price, Lang::getNotifText('reminder_7_day'), $config['user_notification_reminder']) . "\n";
} elseif ($recharge['expiration'] == $day3) {
echo Message::sendPackageNotification($customer, $plan['name_plan'], $price, Lang::getNotifText('reminder_3_day'), $config['user_notification_reminder']) . "\n";
} elseif ($recharge['expiration'] == $day1) {
echo Message::sendPackageNotification($customer, $plan['name_plan'], $price, Lang::getNotifText('reminder_1_day'), $config['user_notification_reminder']) . "\n";
}
}
}

View File

@ -430,4 +430,32 @@
"Clear Cache": "Bersihkan Sampah"
"Privacy Policy": "Kebijakan Privasi"
"Terms and Conditions": "Syarat dan Ketentuan"
"will_be_replaced_with_Customer_Name": "akan diganti dengan Nama Pelanggan",
"will_be_replaced_with_Customer_username": "akan diganti dengan nama pengguna Pelanggan",
"will_be_replaced_with_Package_name": "akan diganti dengan nama Paket",
"will_be_replaced_with_Package_price": "akan diganti dengan harga Paket",
"will_be_replaced_with_Expiration_date": "akan diganti dengan tanggal kedaluwarsa",
"additional_bills_for_customers": "tagihan tambahan untuk pelanggan",
"Your_Company_Name_at_Settings": "Nama Perusahaan Anda di Pengaturan",
"Your_Company_Address_at_Settings": "Alamat Perusahaan Anda di Pengaturan",
"Your_Company_Phone_at_Settings": "Telepon Perusahaan Anda di Pengaturan",
"Invoice_number": "Nomor faktur",
"Date_invoice_created": "Tanggal faktur dibuat",
"Payment_gateway_user_paid_from": "Pengguna gateway pembayaran membayar dari",
"Payment_channel_user_paid_from": "Pengguna saluran pembayaran membayar dari",
"is_Hotspot_or_PPPOE": "adalah Hotspot atau PPPOE",
"Internet_Package": "Paket Internet",
"Internet_Package_Prices": "Harga Paket Internet",
"Receiver_name": "Nama Penerima",
"Username_internet": "Nama pengguna internet",
"User_password": "Kata sandi pengguna",
"Transaction_datetime": Tanggal waktu transaksi",
"Balance_Before": "Saldo Sebelumnya",
"Balance_After": "Saldo Setelahnya",
"Invoice_Footer": Catatan Kaki Faktur",
"For_Notes_by_admin": "Untuk Catatan oleh admin",
"Receiver_name": "Nama Penerima",
"how_much_balance_have_been_send": "berapa banyak saldo yang telah dikirim",
"Current_Balance": "Saldo saat ini",
"Sender_name": "Nama pengirim"
}

View File

@ -20,11 +20,11 @@
rows="3">{if $_json['expired']!=''}{Lang::htmlspecialchars($_json['expired'])}{else}Hello [[name]], your internet package [[package]] has been expired.{/if}</textarea>
</div>
<p class="help-block col-md-4">
<b>[[name]]</b> will be replaced with Customer Name.<br>
<b>[[username]]</b> will be replaced with Customer username.<br>
<b>[[package]]</b> will be replaced with Package name.<br>
<b>[[price]]</b> will be replaced with Package price.<br>
<b>[[bills]]</b> aditional bills for customers
<b>[[name]]</b> - {Lang::T('will be replaced with Customer Name)}.<br>
<b>[[username]]</b> - {Lang::T('will be replaced with Customer username)}.<br>
<b>[[package]]</b> - {Lang::T('will be replaced with Package name)}.<br>
<b>[[price]]</b> - {Lang::T('will be replaced with Package price)}.<br>
<b>[[bills]]</b> - {Lang::T('additional bills for customers)}.
</p>
</div>
</div>
@ -36,12 +36,12 @@
rows="3">{Lang::htmlspecialchars($_json['reminder_7_day'])}</textarea>
</div>
<p class="help-block col-md-4">
<b>[[name]]</b> will be replaced with Customer Name.<br>
<b>[[username]]</b> will be replaced with Customer username.<br>
<b>[[package]]</b> will be replaced with Package name.<br>
<b>[[price]]</b> will be replaced with Package price.<br>
<b>[[expired_date]]</b> will be replaced with Expiration date.<br>
<b>[[bills]]</b> aditional bills for customers
<b>[[name]]</b> - {Lang::T('will be replaced with Customer Name)}.<br>
<b>[[username]]</b> - {Lang::T('will be replaced with Customer username)}.<br>
<b>[[package]]</b> - {Lang::T('will be replaced with Package name)}.<br>
<b>[[price]]</b> - {Lang::T('will be replaced with Package price)}.<br>
<b>[[expired_date]]</b> - {Lang::T('will be replaced with Expiration date)}.<br>
<b>[[bills]]</b> - {Lang::T('additional bills for customers)}.
</p>
</div>
</div>
@ -53,12 +53,12 @@
rows="3">{Lang::htmlspecialchars($_json['reminder_3_day'])}</textarea>
</div>
<p class="help-block col-md-4">
<b>[[name]]</b> will be replaced with Customer Name.<br>
<b>[[username]]</b> will be replaced with Customer username.<br>
<b>[[package]]</b> will be replaced with Package name.<br>
<b>[[price]]</b> will be replaced with Package price.<br>
<b>[[expired_date]]</b> will be replaced with Expiration date.<br>
<b>[[bills]]</b> aditional bills for customers
<b>[[name]]</b> - {Lang::T('will be replaced with Customer Name)}.<br>
<b>[[username]]</b> - {Lang::T('will be replaced with Customer username)}.<br>
<b>[[package]]</b> - {Lang::T('will be replaced with Package name)}.<br>
<b>[[price]]</b> - {Lang::T('will be replaced with Package price)}.<br>
<b>[[expired_date]]</b> - {Lang::T('will be replaced with Expiration date)}.<br>
<b>[[bills]]</b> - {Lang::T('additional bills for customers)}.
</p>
</div>
</div>
@ -70,12 +70,12 @@
rows="3">{Lang::htmlspecialchars($_json['reminder_1_day'])}</textarea>
</div>
<p class="help-block col-md-4">
<b>[[name]]</b> will be replaced with Customer Name.<br>
<b>[[username]]</b> will be replaced with Customer username.<br>
<b>[[package]]</b> will be replaced with Package name.<br>
<b>[[price]]</b> will be replaced with Package price.<br>
<b>[[expired_date]]</b> will be replaced with Expiration date.<br>
<b>[[bills]]</b> aditional bills for customers
<b>[[name]]</b> - {Lang::T('will be replaced with Customer Name)}.<br>
<b>[[username]]</b> - {Lang::T('will be replaced with Customer username)}.<br>
<b>[[package]]</b> - {Lang::T('will be replaced with Package name)}.<br>
<b>[[price]]</b> - {Lang::T('will be replaced with Package price)}.<br>
<b>[[expired_date]]</b> - {Lang::T('will be replaced with Expiration date)}.<br>
<b>[[bills]]</b> - {Lang::T('additional bills for customers)}.
</p>
</div>
</div>
@ -88,22 +88,22 @@
rows="20">{Lang::htmlspecialchars($_json['invoice_paid'])}</textarea>
</div>
<p class="col-md-4 help-block">
<b>[[company_name]]</b> Your Company Name at Settings.<br>
<b>[[address]]</b> Your Company Address at Settings.<br>
<b>[[phone]]</b> Your Company Phone at Settings.<br>
<b>[[invoice]]</b> invoice number.<br>
<b>[[date]]</b> Date invoice created.<br>
<b>[[payment_gateway]]</b> Payment gateway user paid from.<br>
<b>[[payment_channel]]</b> Payment channel user paid from.<br>
<b>[[type]]</b> is Hotspot/PPPOE.<br>
<b>[[plan_name]]</b> Internet Package.<br>
<b>[[plan_price]]</b> Internet Package Prices.<br>
<b>[[name]]</b> Receiver name.<br>
<b>[[user_name]]</b> Username internet.<br>
<b>[[user_password]]</b> User password.<br>
<b>[[expired_date]]</b> Expired datetime.<br>
<b>[[footer]]</b> Invoice Footer.<br>
<b>[[note]]</b> For Notes by admin.<br>
<b>[[company_name]]</b> {Lang::T('Your Company Name at Settings)}.<br>
<b>[[address]]</b> {Lang::T('Your Company Address at Settings)}.<br>
<b>[[phone]]</b> - {Lang::T('Your Company Phone at Settings)}.<br>
<b>[[invoice]]</b> - {Lang::T('Invoice number)}.<br>
<b>[[date]]</b> - {Lang::T('Date invoice created)}.<br>
<b>[[payment_gateway]]</b> - {Lang::T('Payment gateway user paid from)}.<br>
<b>[[payment_channel]]</b> - {Lang::T('Payment channel user paid from)}.<br>
<b>[[type]]</b> - {Lang::T('is Hotspot or PPPOE)}.<br>
<b>[[plan_name]]</b> - {Lang::T('Internet Package)}.<br>
<b>[[plan_price]]</b> - {Lang::T('Internet Package Prices)}.<br>
<b>[[name]]</b> - {Lang::T('Receiver name)}.<br>
<b>[[user_name]]</b> - {Lang::T('Username internet)}.<br>
<b>[[user_password]]</b> - {Lang::T('User password)}.<br>
<b>[[expired_date]]</b> - {Lang::T('Expired datetime)}.<br>
<b>[[footer]]</b> - {Lang::T('Invoice Footer)}.<br>
<b>[[note]]</b> - {Lang::T('For Notes by admin)}.<br>
</p>
</div>
</div>
@ -116,23 +116,23 @@
rows="20">{Lang::htmlspecialchars($_json['invoice_balance'])}</textarea>
</div>
<p class="col-md-4 help-block">
<b>[[company_name]]</b> Your Company Name at Settings.<br>
<b>[[address]]</b> Your Company Address at Settings.<br>
<b>[[phone]]</b> Your Company Phone at Settings.<br>
<b>[[invoice]]</b> invoice number.<br>
<b>[[date]]</b> Date invoice created.<br>
<b>[[payment_gateway]]</b> Payment gateway user paid from.<br>
<b>[[payment_channel]]</b> Payment channel user paid from.<br>
<b>[[type]]</b> is Hotspot/PPPOE.<br>
<b>[[plan_name]]</b> Internet Package.<br>
<b>[[plan_price]]</b> Internet Package Prices.<br>
<b>[[name]]</b> Receiver name.<br>
<b>[[user_name]]</b> Username internet.<br>
<b>[[user_password]]</b> User password.<br>
<b>[[trx_date]]</b> Transaction datetime.<br>
<b>[[balance_before]]</b> Balance Before.<br>
<b>[[balance]]</b> Balance After.<br>
<b>[[footer]]</b> Invoice Footer.
<b>[[company_name]]</b> - {Lang::T('Your Company Name at Settings)}.<br>
<b>[[address]]</b> - {Lang::T('Your Company Address at Settings)}.<br>
<b>[[phone]]</b> - {Lang::T('Your Company Phone at Settings)}.<br>
<b>[[invoice]]</b> - {Lang::T('Invoice number)}.<br>
<b>[[date]]</b> - {Lang::T('Date invoice created)}.<br>
<b>[[payment_gateway]]</b> - {Lang::T('Payment gateway user paid from)}.<br>
<b>[[payment_channel]]</b> - {Lang::T('Payment channel user paid from)}.<br>
<b>[[type]]</b> - {Lang::T('is Hotspot or PPPOE)}.<br>
<b>[[plan_name]]</b> - {Lang::T('Internet Package)}.<br>
<b>[[plan_price]]</b> - {Lang::T('Internet Package Prices)}.<br>
<b>[[name]]</b> - {Lang::T('Receiver name)}.<br>
<b>[[user_name]]</b> - {Lang::T('Username internet)}.<br>
<b>[[user_password]]</b> - {Lang::T('User password)}.<br>
<b>[[trx_date]]</b> - {Lang::T('Transaction datetime)}.<br>
<b>[[balance_before]]</b> - {Lang::T('Balance Before)}.<br>
<b>[[balance]]</b> - {Lang::T('Balance After)}.<br>
<b>[[footer]]</b> - {Lang::T('Invoice Footer)}.
</p>
</div>
</div>
@ -145,9 +145,9 @@
rows="3">{if $_json['balance_send']}{Lang::htmlspecialchars($_json['balance_send'])}{else}{Lang::htmlspecialchars($_default['balance_send'])}{/if}</textarea>
</div>
<p class="col-md-4 help-block">
<b>[[name]]</b> Receiver name.<br>
<b>[[balance]]</b> how much balance have been send.<br>
<b>[[current_balance]]</b> Current Balance.
<b>[[name]]</b> - {Lang::T('Receiver name)}.<br>
<b>[[balance]]</b> - {Lang::T('how much balance have been send)}.<br>
<b>[[current_balance]]</b> - {Lang::T('Current Balance)}.
</p>
</div>
</div>
@ -159,9 +159,9 @@
rows="3">{if $_json['balance_received']}{Lang::htmlspecialchars($_json['balance_received'])}{else}{Lang::htmlspecialchars($_default['balance_received'])}{/if}</textarea>
</div>
<p class="col-md-4 help-block">
<b>[[name]]</b> Sender name.<br>
<b>[[balance]]</b> how much balance have been received.<br>
<b>[[current_balance]]</b> Current Balance.
<b>[[name]]</b> - {Lang::T('Sender name)}.<br>
<b>[[balance]]</b> - {Lang::T('how much balance have been received)}.<br>
<b>[[current_balance]]</b> - {Lang::T('Current Balance)}.
</p>
</div>
</div>
@ -176,4 +176,4 @@
</div>
</div>
</form>
{include file="sections/footer.tpl"}
{include file="sections/footer.tpl"}

View File

@ -60,10 +60,12 @@
</div>
<div class="form-group">
<label>{Lang::T('Password')}</label>
<input type="password" class="form-control" name="password"
placeholder="{Lang::T('Password')}">
</div>
<label>{Lang::T('Password')}</label>
<div class="input-group">
<span class="input-group-addon" id="basic-addon2"><i class="glyphicon glyphicon-lock"></i></span>
<input type="password" class="form-control" name="password" placeholder="{Lang::T('Password')}">
</div>
</div>
<div class="clearfix hidden">
<div class="ui-checkbox ui-checkbox-primary right">
@ -114,4 +116,4 @@
<script src="ui/ui/scripts/vendors.js?v=1"></script>
</body>
</html>
</html>