Compare commits
8 Commits
Author | SHA1 | Date | |
---|---|---|---|
130451e1ae | |||
d36f39af8f | |||
518917aac6 | |||
dbc3a2623c | |||
d31edde9d6 | |||
32943b40be | |||
23790d3258 | |||
ffa55cdee5 |
10
CHANGELOG.md
10
CHANGELOG.md
@ -2,6 +2,16 @@
|
||||
|
||||
# CHANGELOG
|
||||
|
||||
## 2024.3.18
|
||||
|
||||
- Add Broadcasting SMS by @Focuslinkstech
|
||||
- Fix Notification with Bills
|
||||
|
||||
## 2024.3.16
|
||||
|
||||
- Fix Zero Charging
|
||||
- Fix Disconnect Customer from Radius without loop by @Gerandonk
|
||||
|
||||
## 2024.3.15
|
||||
|
||||
- Fix Customer View to list active Plan
|
||||
|
@ -116,6 +116,9 @@ class Message
|
||||
$textInvoice = str_replace('[[phone]]', $config['phone'], $textInvoice);
|
||||
$textInvoice = str_replace('[[invoice]]', $trx['invoice'], $textInvoice);
|
||||
$textInvoice = str_replace('[[date]]', Lang::dateAndTimeFormat($trx['recharged_on'], $trx['recharged_time']), $textInvoice);
|
||||
if (!empty($trx['note'])) {
|
||||
$textInvoice = str_replace('[[note]]', $trx['note'], $textInvoice);
|
||||
}
|
||||
$gc = explode("-", $trx['method']);
|
||||
$textInvoice = str_replace('[[payment_gateway]]', trim($gc[0]), $textInvoice);
|
||||
$textInvoice = str_replace('[[payment_channel]]', trim($gc[1]), $textInvoice);
|
||||
|
@ -33,10 +33,11 @@ class Package
|
||||
$p = ORM::for_table('tbl_plans')->where('id', $plan_id)->find_one();
|
||||
|
||||
$add_cost = 0;
|
||||
$bills = [];
|
||||
// Zero cost recharge
|
||||
if (isset($zero) && $zero == 1) {
|
||||
$p['price'] = 0;
|
||||
}else{
|
||||
} else {
|
||||
// Additional cost
|
||||
list($bills, $add_cost) = User::getBills($id_customer);
|
||||
if ($add_cost > 0 && $router_name != 'balance') {
|
||||
@ -241,7 +242,7 @@ class Package
|
||||
if ($p['validity_unit'] == 'Period') {
|
||||
// Postpaid price from field
|
||||
$add_inv = User::getAttribute("Invoice", $id_customer);
|
||||
if (empty ($add_inv) or $add_inv == 0) {
|
||||
if (empty($add_inv) or $add_inv == 0) {
|
||||
$t->price = $p['price'] + $add_cost;
|
||||
} else {
|
||||
$t->price = $add_inv + $add_cost;
|
||||
@ -285,7 +286,8 @@ class Package
|
||||
"\nRouter: " . $router_name .
|
||||
"\nGateway: " . $gateway .
|
||||
"\nChannel: " . $channel .
|
||||
"\nPrice: " . Lang::moneyFormat($p['price']));
|
||||
"\nPrice: " . Lang::moneyFormat($p['price']) .
|
||||
"\nNote:\n" . $note);
|
||||
} else {
|
||||
if ($p['is_radius']) {
|
||||
Radius::customerAddPlan($c, $p, "$date_exp $time");
|
||||
@ -372,7 +374,8 @@ class Package
|
||||
"\nRouter: " . $router_name .
|
||||
"\nGateway: " . $gateway .
|
||||
"\nChannel: " . $channel .
|
||||
"\nPrice: " . Lang::moneyFormat($p['price']));
|
||||
"\nPrice: " . Lang::moneyFormat($p['price']) .
|
||||
"\nNote:\n" . $note);
|
||||
}
|
||||
} else {
|
||||
|
||||
@ -435,7 +438,7 @@ class Package
|
||||
if ($p['validity_unit'] == 'Period') {
|
||||
// Postpaid price from field
|
||||
$add_inv = User::getAttribute("Invoice", $id_customer);
|
||||
if (empty ($add_inv) or $add_inv == 0) {
|
||||
if (empty($add_inv) or $add_inv == 0) {
|
||||
$t->price = $p['price'] + $add_cost;
|
||||
} else {
|
||||
$t->price = $add_inv + $add_cost;
|
||||
@ -478,7 +481,8 @@ class Package
|
||||
"\nRouter: " . $router_name .
|
||||
"\nGateway: " . $gateway .
|
||||
"\nChannel: " . $channel .
|
||||
"\nPrice: " . Lang::moneyFormat($p['price']));
|
||||
"\nPrice: " . Lang::moneyFormat($p['price']) .
|
||||
"\nNote:\n" . $note);
|
||||
} else {
|
||||
if ($p['is_radius']) {
|
||||
Radius::customerAddPlan($c, $p, "$date_exp $time");
|
||||
@ -565,10 +569,11 @@ class Package
|
||||
"\nRouter: " . $router_name .
|
||||
"\nGateway: " . $gateway .
|
||||
"\nChannel: " . $channel .
|
||||
"\nPrice: " . Lang::moneyFormat($p['price']));
|
||||
"\nPrice: " . Lang::moneyFormat($p['price']) .
|
||||
"\nNote:\n" . $note);
|
||||
}
|
||||
}
|
||||
if (count($bills) > 0) {
|
||||
if (is_array($bills) && count($bills) > 0) {
|
||||
User::billsPaid($bills, $id_customer);
|
||||
}
|
||||
run_hook("recharge_user_finish");
|
||||
@ -677,9 +682,10 @@ class Package
|
||||
$_admin = Admin::_info($in['admin_id']);
|
||||
// if admin not deleted
|
||||
if ($_admin) $admin = $_admin;
|
||||
}else{
|
||||
} else {
|
||||
$admin['fullname'] = 'Customer';
|
||||
}
|
||||
$note = '';
|
||||
//print
|
||||
$invoice = Lang::pad($config['CompanyName'], ' ', 2) . "\n";
|
||||
$invoice .= Lang::pad($config['address'], ' ', 2) . "\n";
|
||||
@ -691,11 +697,26 @@ class Package
|
||||
$invoice .= Lang::pad("", '=') . "\n";
|
||||
$invoice .= Lang::pads(Lang::T('Type'), $in['type'], ' ') . "\n";
|
||||
$invoice .= Lang::pads(Lang::T('Plan Name'), $in['plan_name'], ' ') . "\n";
|
||||
$invoice .= Lang::pads(Lang::T('Plan Price'), Lang::moneyFormat($in['price']), ' ') . "\n";
|
||||
$invoice .= Lang::pad($in['method'], ' ', 2) . "\n";
|
||||
if(!empty($in['note'])){
|
||||
if (!empty($in['note'])) {
|
||||
$in['note'] = str_replace("\r", "", $in['note']);
|
||||
$tmp = explode("\n", $in['note']);
|
||||
foreach ($tmp as $t) {
|
||||
if (strpos($t, " : ") === false) {
|
||||
if (!empty($t)) {
|
||||
$note .= "$t\n";
|
||||
}
|
||||
} else {
|
||||
$tmp2 = explode(" : ", $t);
|
||||
$invoice .= Lang::pads($tmp2[0], $tmp2[1], ' ') . "\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
$invoice .= Lang::pads(Lang::T('Total'), Lang::moneyFormat($in['price']), ' ') . "\n";
|
||||
$method = explode("-", $in['method']);
|
||||
$invoice .= Lang::pads($method[0], $method[1], ' ') . "\n";
|
||||
if (!empty($note)) {
|
||||
$invoice .= Lang::pad("", '=') . "\n";
|
||||
$invoice .= Lang::pad($in['note'], ' ', 2);
|
||||
$invoice .= Lang::pad($note, ' ', 2) . "\n";
|
||||
}
|
||||
$invoice .= Lang::pad("", '=') . "\n";
|
||||
$invoice .= Lang::pads(Lang::T('Username'), $in['username'], ' ') . "\n";
|
||||
@ -719,11 +740,24 @@ class Package
|
||||
$invoice .= Lang::pad("", '=') . "\n";
|
||||
$invoice .= Lang::pads(Lang::T('Type'), $in['type'], ' ') . "\n";
|
||||
$invoice .= Lang::pads(Lang::T('Plan Name'), $in['plan_name'], ' ') . "\n";
|
||||
$invoice .= Lang::pads(Lang::T('Plan Price'), Lang::moneyFormat($in['price']), ' ') . "\n";
|
||||
$invoice .= Lang::pad($in['method'], ' ', 2) . "\n";
|
||||
if(!empty($in['note'])){
|
||||
if (!empty($in['note'])) {
|
||||
$invoice .= Lang::pad("", '=') . "\n";
|
||||
$invoice .= Lang::pad($in['note'], ' ', 2);
|
||||
foreach ($tmp as $t) {
|
||||
if (strpos($t, " : ") === false) {
|
||||
if (!empty($t)) {
|
||||
$invoice .= Lang::pad($t, ' ', 2) . "\n";
|
||||
}
|
||||
} else {
|
||||
$tmp2 = explode(" : ", $t);
|
||||
$invoice .= Lang::pads($tmp2[0], $tmp2[1], ' ') . "\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
$invoice .= Lang::pads(Lang::T('Total'), Lang::moneyFormat($in['price']), ' ') . "\n";
|
||||
$invoice .= Lang::pads($method[0], $method[1], ' ') . "\n";
|
||||
if (!empty($note)) {
|
||||
$invoice .= Lang::pad("", '=') . "\n";
|
||||
$invoice .= Lang::pad($note, ' ', 2) . "\n";
|
||||
}
|
||||
$invoice .= Lang::pad("", '=') . "\n";
|
||||
$invoice .= Lang::pads(Lang::T('Username'), $in['username'], ' ') . "\n";
|
||||
|
@ -301,7 +301,11 @@ class Radius
|
||||
if ($_app_stage == 'demo') {
|
||||
return null;
|
||||
}
|
||||
$nas = Radius::getTableNas()->findMany();
|
||||
/**
|
||||
* Fix loop to all Nas but still detecting Hotspot Multylogin from other Nas
|
||||
*/
|
||||
$act = ORM::for_table('radacct')->where_raw("acctstoptime IS NULL")->where('username', $username)->find_one();
|
||||
$nas = Radius::getTableNas()->where('nasname', $act['nasipaddress'])->find_many();
|
||||
$count = count($nas) * 15;
|
||||
set_time_limit($count);
|
||||
$result = [];
|
||||
@ -310,7 +314,7 @@ class Radius
|
||||
if (!empty($n['ports'])) {
|
||||
$port = $n['ports'];
|
||||
}
|
||||
$result[] = $n['nasname'] . ': ' . @shell_exec("echo 'User-Name = $username' | " . Radius::getClient() . " " . trim($n['nasname']) . ":$port disconnect '" . $n['secret'] . "'");
|
||||
$result[] = $n['nasname'] . ': ' . @shell_exec("echo 'User-Name = $username,Framed-IP-Address = " . $act['framedipaddress'] . "' | radclient -x " . trim($n['nasname']) . ":$port disconnect '" . $n['secret'] . "'");
|
||||
}
|
||||
return $result;
|
||||
}
|
||||
|
@ -107,13 +107,13 @@ switch ($action) {
|
||||
list($bills, $add_cost) = User::getBills($id_customer);
|
||||
if ($using == 'balance' && $config['enable_balance'] == 'yes') {
|
||||
if (!$cust) {
|
||||
r2(U . 'prepaid/recharge', 'e', Lang::T('Customer not found'));
|
||||
r2(U . 'plan/recharge', 'e', Lang::T('Customer not found'));
|
||||
}
|
||||
if (!$plan) {
|
||||
r2(U . 'prepaid/recharge', 'e', Lang::T('Plan not found'));
|
||||
r2(U . 'plan/recharge', 'e', Lang::T('Plan not found'));
|
||||
}
|
||||
if ($cust['balance'] < ($plan['price'] + $add_cost)) {
|
||||
r2(U . 'prepaid/recharge', 'e', Lang::T('insufficient balance'));
|
||||
r2(U . 'plan/recharge', 'e', Lang::T('insufficient balance'));
|
||||
}
|
||||
$gateway = 'Recharge Balance';
|
||||
}
|
||||
|
212
system/controllers/message.php
Normal file
212
system/controllers/message.php
Normal file
@ -0,0 +1,212 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* PHP Mikrotik Billing (https://github.com/hotspotbilling/phpnuxbill/)
|
||||
* by https://t.me/ibnux
|
||||
**/
|
||||
|
||||
_admin();
|
||||
$ui->assign('_title', Lang::T('Send Message'));
|
||||
$ui->assign('_system_menu', 'message');
|
||||
|
||||
$action = $routes['1'];
|
||||
$ui->assign('_admin', $admin);
|
||||
|
||||
if (empty($action)) {
|
||||
$action = 'send';
|
||||
}
|
||||
|
||||
switch ($action) {
|
||||
case 'send':
|
||||
if (!in_array($admin['user_type'], ['SuperAdmin', 'Admin', 'Agent', 'Sales'])) {
|
||||
_alert(Lang::T('You do not have permission to access this page'), 'danger', "dashboard");
|
||||
}
|
||||
|
||||
$select2_customer = <<<EOT
|
||||
<script>
|
||||
document.addEventListener("DOMContentLoaded", function(event) {
|
||||
$('#personSelect').select2({
|
||||
theme: "bootstrap",
|
||||
ajax: {
|
||||
url: function(params) {
|
||||
if(params.term != undefined){
|
||||
return './index.php?_route=autoload/customer_select2&s='+params.term;
|
||||
}else{
|
||||
return './index.php?_route=autoload/customer_select2';
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
EOT;
|
||||
$c = ORM::for_table('tbl_customers')->find_many();
|
||||
$ui->assign('c', $c);
|
||||
$ui->assign('xfooter', $select2_customer);
|
||||
$ui->display('message.tpl');
|
||||
break;
|
||||
|
||||
case 'send-post':
|
||||
// Check user permissions
|
||||
if (!in_array($admin['user_type'], ['SuperAdmin', 'Admin', 'Agent', 'Sales'])) {
|
||||
_alert(Lang::T('You do not have permission to access this page'), 'danger', "dashboard");
|
||||
}
|
||||
|
||||
// Get form data
|
||||
$id_customer = $_POST['id_customer'];
|
||||
$message = $_POST['message'];
|
||||
$via = $_POST['via'];
|
||||
|
||||
// Check if fields are empty
|
||||
if ($id_customer == '' or $message == '' or $via == '') {
|
||||
r2(U . 'message/send', 'e', Lang::T('All field is required'));
|
||||
} else {
|
||||
// Get customer details from the database
|
||||
$c = ORM::for_table('tbl_customers')->find_one($id_customer);
|
||||
|
||||
// Replace placeholders in the message with actual values
|
||||
$message = str_replace('[[name]]', $c['fullname'], $message);
|
||||
$message = str_replace('[[user_name]]', $c['username'], $message);
|
||||
$message = str_replace('[[phone]]', $c['phonenumber'], $message);
|
||||
$message = str_replace('[[company_name]]', $config['CompanyName'], $message);
|
||||
|
||||
|
||||
//Send the message
|
||||
if ($via == 'sms' || $via == 'both') {
|
||||
$smsSent = Message::sendSMS($c['phonenumber'], $message);
|
||||
}
|
||||
|
||||
if ($via == 'wa' || $via == 'both') {
|
||||
$waSent = Message::sendWhatsapp($c['phonenumber'], $message);
|
||||
}
|
||||
|
||||
if (isset($smsSent) || isset($waSent)) {
|
||||
r2(U . 'message/send', 's', Lang::T('Message Sent Successfully'));
|
||||
} else {
|
||||
r2(U . 'message/send', 'e', Lang::T('Failed to send message'));
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case 'send_bulk':
|
||||
if (!in_array($admin['user_type'], ['SuperAdmin', 'Admin', 'Agent', 'Sales'])) {
|
||||
_alert(Lang::T('You do not have permission to access this page'), 'danger', "dashboard");
|
||||
}
|
||||
$ui->display('message-bulk.tpl');
|
||||
break;
|
||||
case 'send_bulk-post':
|
||||
// Check user permissions
|
||||
if (!in_array($admin['user_type'], ['SuperAdmin', 'Admin', 'Agent', 'Sales'])) {
|
||||
_alert(Lang::T('You do not have permission to access this page'), 'danger', "dashboard");
|
||||
}
|
||||
|
||||
// Get form data
|
||||
$group = $_POST['group'];
|
||||
$message = $_POST['message'];
|
||||
$via = $_POST['via'];
|
||||
|
||||
// Initialize counters
|
||||
$successCount = 0;
|
||||
$failCount = 0;
|
||||
$successMessages = [];
|
||||
$failMessages = [];
|
||||
|
||||
// Check if fields are empty
|
||||
if ($group == '' or $message == '' or $via == '') {
|
||||
r2(U . 'message/send_bulk', 'e', Lang::T('All fields are required'));
|
||||
} else {
|
||||
// Get customer details from the database based on the selected group
|
||||
if ($group == 'all') {
|
||||
$customers = ORM::for_table('tbl_customers')->find_many();
|
||||
} elseif ($group == 'new') {
|
||||
// Get customers created just a month ago
|
||||
$customers = ORM::for_table('tbl_customers')->where_raw("DATE(created_at) >= DATE_SUB(CURDATE(), INTERVAL 1 MONTH)")->find_many();
|
||||
} elseif ($group == 'expired') {
|
||||
// Get expired user recharges where status is 'off'
|
||||
$expired = ORM::for_table('tbl_user_recharges')->where('status', 'off')->find_many();
|
||||
$customer_ids = [];
|
||||
foreach ($expired as $recharge) {
|
||||
$customer_ids[] = $recharge->customer_id;
|
||||
}
|
||||
$customers = ORM::for_table('tbl_customers')->where_in('id', $customer_ids)->find_many();
|
||||
} elseif ($group == 'active') {
|
||||
// Get active user recharges where status is 'on'
|
||||
$active = ORM::for_table('tbl_user_recharges')->where('status', 'on')->find_many();
|
||||
$customer_ids = [];
|
||||
foreach ($active as $recharge) {
|
||||
$customer_ids[] = $recharge->customer_id;
|
||||
}
|
||||
$customers = ORM::for_table('tbl_customers')->where_in('id', $customer_ids)->find_many();
|
||||
}
|
||||
|
||||
// Loop through customers and send messages
|
||||
foreach ($customers as $customer) {
|
||||
// Replace placeholders in the message with actual values for each customer
|
||||
$message = str_replace('[[name]]', $customer['fullname'], $message);
|
||||
$message = str_replace('[[user_name]]', $customer['username'], $message);
|
||||
$message = str_replace('[[phone]]', $customer['phonenumber'], $message);
|
||||
$message = str_replace('[[company_name]]', $config['CompanyName'], $message);
|
||||
|
||||
// Send the message based on the selected method
|
||||
if ($via == 'sms' || $via == 'both') {
|
||||
$smsSent = Message::sendSMS($customer['phonenumber'], $message);
|
||||
if ($smsSent) {
|
||||
$successCount++;
|
||||
$successMessages[] = "SMS sent to {$customer['fullname']}: {$customer['phonenumber']}";
|
||||
} else {
|
||||
$failCount++;
|
||||
$failMessages[] = "Failed to send SMS to {$customer['fullname']}: {$customer['phonenumber']}";
|
||||
}
|
||||
// Introduce a delay of 5 seconds between each SMS
|
||||
sleep(5);
|
||||
}
|
||||
|
||||
if ($via == 'wa' || $via == 'both') {
|
||||
$waSent = Message::sendWhatsapp($customer['phonenumber'], $message);
|
||||
if ($waSent) {
|
||||
$successCount++;
|
||||
$successMessages[] = "WhatsApp message sent to {$customer['fullname']}: {$customer['phonenumber']}";
|
||||
} else {
|
||||
$failCount++;
|
||||
$failMessages[] = "Failed to send WhatsApp message to {$customer['fullname']}: {$customer['phonenumber']}";
|
||||
}
|
||||
// Introduce a delay of 5 seconds between each WhatsApp message
|
||||
sleep(5);
|
||||
}
|
||||
}
|
||||
|
||||
$responseMessage = '';
|
||||
|
||||
if ($successCount > 0) {
|
||||
$responseMessage .= "Messages Sent Successfully: {$successCount}<br>";
|
||||
$responseMessage .= "<ul>";
|
||||
foreach ($successMessages as $successMessage) {
|
||||
$responseMessage .= "<li>{$successMessage}</li>";
|
||||
}
|
||||
$responseMessage .= "</ul>";
|
||||
}
|
||||
|
||||
if ($failCount > 0) {
|
||||
$responseMessage .= "Failed to send messages: {$failCount}<br>";
|
||||
$responseMessage .= "<ul>";
|
||||
foreach ($failMessages as $failMessage) {
|
||||
$responseMessage .= "<li>{$failMessage}</li>";
|
||||
}
|
||||
$responseMessage .= "</ul>";
|
||||
}
|
||||
|
||||
if ($responseMessage != '') {
|
||||
r2(U . 'message/send_bulk', 's', $responseMessage);
|
||||
} else {
|
||||
r2(U . 'message/send_bulk', 'e', Lang::T('No messages sent'));
|
||||
}
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
|
||||
|
||||
|
||||
default:
|
||||
r2(U . 'message/send_sms', 'e', 'action not defined');
|
||||
}
|
@ -7,7 +7,7 @@
|
||||
|
||||
_admin();
|
||||
$ui->assign('_title', Lang::T('Recharge Account'));
|
||||
$ui->assign('_system_menu', 'prepaid');
|
||||
$ui->assign('_system_menu', 'plan');
|
||||
|
||||
$action = $routes['1'];
|
||||
$ui->assign('_admin', $admin);
|
||||
@ -62,9 +62,9 @@ switch ($action) {
|
||||
if ($isApi) {
|
||||
showResult(true, $log);
|
||||
}
|
||||
r2(U . 'prepaid/list', 's', $log);
|
||||
r2(U . 'plan/list', 's', $log);
|
||||
case 'list':
|
||||
$ui->assign('xfooter', '<script type="text/javascript" src="ui/lib/c/prepaid.js"></script>');
|
||||
$ui->assign('xfooter', '<script type="text/javascript" src="ui/lib/c/plan.js"></script>');
|
||||
$ui->assign('_title', Lang::T('Customer'));
|
||||
$search = _post('search');
|
||||
if ($search != '') {
|
||||
@ -81,7 +81,7 @@ switch ($action) {
|
||||
$ui->assign('d', $d);
|
||||
$ui->assign('search', $search);
|
||||
$ui->assign('paginator', $paginator);
|
||||
$ui->display('prepaid.tpl');
|
||||
$ui->display('plan.tpl');
|
||||
break;
|
||||
|
||||
case 'recharge':
|
||||
@ -118,13 +118,13 @@ switch ($action) {
|
||||
list($bills, $add_cost) = User::getBills($id_customer);
|
||||
if ($using == 'balance' && $config['enable_balance'] == 'yes') {
|
||||
if (!$cust) {
|
||||
r2(U . 'prepaid/recharge', 'e', Lang::T('Customer not found'));
|
||||
r2(U . 'plan/recharge', 'e', Lang::T('Customer not found'));
|
||||
}
|
||||
if (!$plan) {
|
||||
r2(U . 'prepaid/recharge', 'e', Lang::T('Plan not found'));
|
||||
r2(U . 'plan/recharge', 'e', Lang::T('Plan not found'));
|
||||
}
|
||||
if ($cust['balance'] < ($plan['price'] + $add_cost)) {
|
||||
r2(U . 'prepaid/recharge', 'e', Lang::T('insufficient balance'));
|
||||
r2(U . 'plan/recharge', 'e', Lang::T('insufficient balance'));
|
||||
}
|
||||
$gateway = 'Recharge Balance';
|
||||
}
|
||||
@ -142,7 +142,7 @@ switch ($action) {
|
||||
$ui->assign('plan', $plan);
|
||||
$ui->display('recharge-confirm.tpl');
|
||||
} else {
|
||||
r2(U . 'prepaid/recharge', 'e', $msg);
|
||||
r2(U . 'plan/recharge', 'e', $msg);
|
||||
}
|
||||
break;
|
||||
|
||||
@ -168,13 +168,13 @@ switch ($action) {
|
||||
if ($using == 'balance' && $config['enable_balance'] == 'yes') {
|
||||
$plan = ORM::for_table('tbl_plans')->find_one($planId);
|
||||
if (!$cust) {
|
||||
r2(U . 'prepaid/recharge', 'e', Lang::T('Customer not found'));
|
||||
r2(U . 'plan/recharge', 'e', Lang::T('Customer not found'));
|
||||
}
|
||||
if (!$plan) {
|
||||
r2(U . 'prepaid/recharge', 'e', Lang::T('Plan not found'));
|
||||
r2(U . 'plan/recharge', 'e', Lang::T('Plan not found'));
|
||||
}
|
||||
if ($cust['balance'] < ($plan['price'] + $add_cost)) {
|
||||
r2(U . 'prepaid/recharge', 'e', Lang::T('insufficient balance'));
|
||||
r2(U . 'plan/recharge', 'e', Lang::T('insufficient balance'));
|
||||
}
|
||||
$gateway = 'Recharge Balance';
|
||||
}
|
||||
@ -192,10 +192,10 @@ switch ($action) {
|
||||
$ui->display('invoice.tpl');
|
||||
_log('[' . $admin['username'] . ']: ' . 'Recharge ' . $cust['username'] . ' [' . $in['plan_name'] . '][' . Lang::moneyFormat($in['price']) . ']', $admin['user_type'], $admin['id']);
|
||||
} else {
|
||||
r2(U . 'prepaid/recharge', 'e', "Failed to recharge account");
|
||||
r2(U . 'plan/recharge', 'e', "Failed to recharge account");
|
||||
}
|
||||
} else {
|
||||
r2(U . 'prepaid/recharge', 'e', $msg);
|
||||
r2(U . 'plan/recharge', 'e', $msg);
|
||||
}
|
||||
break;
|
||||
|
||||
@ -207,9 +207,9 @@ switch ($action) {
|
||||
$c = ORM::for_table('tbl_customers')->where('username', $in['username'])->find_one();
|
||||
if ($c) {
|
||||
Message::sendInvoice($c, $in);
|
||||
r2(U . 'prepaid/view/' . $id, 's', "Success send to customer");
|
||||
r2(U . 'plan/view/' . $id, 's', "Success send to customer");
|
||||
}
|
||||
r2(U . 'prepaid/view/' . $id, 'd', "Customer not found");
|
||||
r2(U . 'plan/view/' . $id, 'd', "Customer not found");
|
||||
}
|
||||
Package::createInvoice($in);
|
||||
$ui->assign('_title', 'View Invoice');
|
||||
@ -252,9 +252,9 @@ switch ($action) {
|
||||
$ui->assign('p', $p);
|
||||
run_hook('view_edit_customer_plan'); #HOOK
|
||||
$ui->assign('_title', 'Edit Plan');
|
||||
$ui->display('prepaid-edit.tpl');
|
||||
$ui->display('plan-edit.tpl');
|
||||
} else {
|
||||
r2(U . 'services/list', 'e', $_L['Account_Not_Found']);
|
||||
r2(U . 'plan/list', 'e', $_L['Account_Not_Found']);
|
||||
}
|
||||
break;
|
||||
|
||||
@ -283,7 +283,7 @@ switch ($action) {
|
||||
}
|
||||
$d->delete();
|
||||
_log('[' . $admin['username'] . ']: ' . 'Delete Plan for Customer ' . $c['username'] . ' [' . $in['plan_name'] . '][' . Lang::moneyFormat($in['price']) . ']', $admin['user_type'], $admin['id']);
|
||||
r2(U . 'prepaid/list', 's', Lang::T('Data Deleted Successfully'));
|
||||
r2(U . 'plan/list', 's', Lang::T('Data Deleted Successfully'));
|
||||
}
|
||||
break;
|
||||
|
||||
@ -331,9 +331,9 @@ switch ($action) {
|
||||
Package::changeTo($username, $id_plan, $id);
|
||||
}
|
||||
_log('[' . $admin['username'] . ']: ' . 'Edit Plan for Customer ' . $d['username'] . ' to [' . $d['namebp'] . '][' . Lang::moneyFormat($p['price']) . ']', $admin['user_type'], $admin['id']);
|
||||
r2(U . 'prepaid/list', 's', Lang::T('Data Updated Successfully'));
|
||||
r2(U . 'plan/list', 's', Lang::T('Data Updated Successfully'));
|
||||
} else {
|
||||
r2(U . 'prepaid/edit/' . $id, 'e', $msg);
|
||||
r2(U . 'plan/edit/' . $id, 'e', $msg);
|
||||
}
|
||||
break;
|
||||
|
||||
@ -446,7 +446,7 @@ switch ($action) {
|
||||
$jml++;
|
||||
}
|
||||
}
|
||||
r2(U . 'prepaid/voucher', 's', "$jml " . Lang::T('Data Deleted Successfully'));
|
||||
r2(U . 'plan/voucher', 's', "$jml " . Lang::T('Data Deleted Successfully'));
|
||||
}
|
||||
case 'print-voucher':
|
||||
$from_id = _post('from_id');
|
||||
@ -606,12 +606,12 @@ switch ($action) {
|
||||
$d->save();
|
||||
}
|
||||
if ($numbervoucher == 1) {
|
||||
r2(U . 'prepaid/voucher-view/' . $d->id(), 's', Lang::T('Create Vouchers Successfully'));
|
||||
r2(U . 'plan/voucher-view/' . $d->id(), 's', Lang::T('Create Vouchers Successfully'));
|
||||
}
|
||||
|
||||
r2(U . 'prepaid/voucher', 's', Lang::T('Create Vouchers Successfully'));
|
||||
r2(U . 'plan/voucher', 's', Lang::T('Create Vouchers Successfully'));
|
||||
} else {
|
||||
r2(U . 'prepaid/add-voucher/' . $id, 'e', $msg);
|
||||
r2(U . 'plan/add-voucher/' . $id, 'e', $msg);
|
||||
}
|
||||
break;
|
||||
|
||||
@ -629,11 +629,11 @@ switch ($action) {
|
||||
$voucher = ORM::for_table('tbl_voucher')
|
||||
->find_one($id);
|
||||
if (!in_array($voucher['generated_by'], $sales)) {
|
||||
r2(U . 'prepaid/voucher/', 'e', Lang::T('Voucher Not Found'));
|
||||
r2(U . 'plan/voucher/', 'e', Lang::T('Voucher Not Found'));
|
||||
}
|
||||
}
|
||||
if (!$voucher) {
|
||||
r2(U . 'prepaid/voucher/', 'e', Lang::T('Voucher Not Found'));
|
||||
r2(U . 'plan/voucher/', 'e', Lang::T('Voucher Not Found'));
|
||||
}
|
||||
$plan = ORM::for_table('tbl_plans')->find_one($d['id_plan']);
|
||||
if ($voucher && $plan) {
|
||||
@ -667,7 +667,7 @@ switch ($action) {
|
||||
$ui->assign('whatsapp', urlencode("```$content```"));
|
||||
$ui->display('voucher-view.tpl');
|
||||
} else {
|
||||
r2(U . 'prepaid/voucher/', 'e', Lang::T('Voucher Not Found'));
|
||||
r2(U . 'plan/voucher/', 'e', Lang::T('Voucher Not Found'));
|
||||
}
|
||||
break;
|
||||
case 'voucher-delete':
|
||||
@ -679,7 +679,7 @@ switch ($action) {
|
||||
$d = ORM::for_table('tbl_voucher')->find_one($id);
|
||||
if ($d) {
|
||||
$d->delete();
|
||||
r2(U . 'prepaid/voucher', 's', Lang::T('Data Deleted Successfully'));
|
||||
r2(U . 'plan/voucher', 's', Lang::T('Data Deleted Successfully'));
|
||||
}
|
||||
break;
|
||||
|
||||
@ -712,10 +712,10 @@ switch ($action) {
|
||||
Package::createInvoice($in);
|
||||
$ui->display('invoice.tpl');
|
||||
} else {
|
||||
r2(U . 'prepaid/refill', 'e', "Failed to refill account");
|
||||
r2(U . 'plan/refill', 'e', "Failed to refill account");
|
||||
}
|
||||
} else {
|
||||
r2(U . 'prepaid/refill', 'e', Lang::T('Voucher Not Valid'));
|
||||
r2(U . 'plan/refill', 'e', Lang::T('Voucher Not Valid'));
|
||||
}
|
||||
break;
|
||||
case 'deposit':
|
||||
@ -747,10 +747,10 @@ switch ($action) {
|
||||
Package::createInvoice($in);
|
||||
$ui->display('invoice.tpl');
|
||||
} else {
|
||||
r2(U . 'prepaid/refill', 'e', "Failed to refill account");
|
||||
r2(U . 'plan/refill', 'e', "Failed to refill account");
|
||||
}
|
||||
} else {
|
||||
r2(U . 'prepaid/refill', 'e', "All field is required");
|
||||
r2(U . 'plan/refill', 'e', "All field is required");
|
||||
}
|
||||
break;
|
||||
default:
|
@ -100,9 +100,6 @@
|
||||
"Add_Pool": "Add Pool",
|
||||
"Edit_Pool": "Edit Pool",
|
||||
"Pool_Name_Already_Exist": "Pool Name Already Exist",
|
||||
"Prepaid": "Prepaid",
|
||||
"Prepaid_Users": "Prepaid Users",
|
||||
"Prepaid_Vouchers": "Prepaid Vouchers",
|
||||
"Refill_Account": "Refill Account",
|
||||
"Recharge_Account": "Recharge Account",
|
||||
"Select_Account": "Select Account",
|
||||
@ -493,5 +490,27 @@
|
||||
"Payment_not_found": "Payment not found",
|
||||
"If_your_friend_have_Additional_Cost__you_will_pay_for_that_too": "If your friend have Additional Cost, you will pay for that too",
|
||||
"Cache_cleared_successfully_": "Cache cleared successfully!",
|
||||
"Paid": "Paid"
|
||||
"Paid": "Paid",
|
||||
"Send_Message": "Send Message",
|
||||
"Send_SMS_WA_Message": "Send SMS\/WA Message",
|
||||
"Send_Bulk_SMS_WA_Message": "Send Bulk SMS\/WA Message",
|
||||
"Send_Personal_Message": "Send Personal Message",
|
||||
"Send_Via": "Send Via",
|
||||
"Compose_your_message___": "Compose your message...",
|
||||
"Use_placeholders_": "Use placeholders:",
|
||||
"__name__": "[[name]]",
|
||||
"Customer_Name": "Customer Name",
|
||||
"__user_name__": "[[user_name]]",
|
||||
"Customer_Username": "Customer Username",
|
||||
"__phone__": "[[phone]]",
|
||||
"Customer_Phone": "Customer Phone",
|
||||
"__company_name__": "[[company_name]]",
|
||||
"Your_Company_Name": "Your Company Name",
|
||||
"Message_Sent_Successfully": "Message Sent Successfully",
|
||||
"Send_Bulk_Message": "Send Bulk Message",
|
||||
"Group": "Group",
|
||||
"All_Customers": "All Customers",
|
||||
"New_Customers": "New Customers",
|
||||
"Expired_Customers": "Expired Customers",
|
||||
"Active_Customers": "Active Customers"
|
||||
}
|
@ -100,9 +100,6 @@
|
||||
"Add_Pool": "Tambahkan Pool",
|
||||
"Edit_Pool": "Sunting Pool",
|
||||
"Pool_Name_Already_Exist": "Nama Pool Sudah Ada",
|
||||
"Prepaid": "Prabayar",
|
||||
"Prepaid_Users": "Pengguna Prabayar",
|
||||
"Prepaid_Vouchers": "Voucher Prabayar",
|
||||
"Refill_Account": "Isi Ulang Akun",
|
||||
"Recharge_Account": "Isi Ulang Akun",
|
||||
"Select_Account": "Pilih Akun",
|
||||
|
@ -100,9 +100,6 @@
|
||||
"Add_Pool": "Agregar Pool",
|
||||
"Edit_Pool": "Editar Pool",
|
||||
"Pool_Name_Already_Exist": "Nombre del Pool ya existe",
|
||||
"Prepaid": "Prepago",
|
||||
"Prepaid_Users": "Usuarios prepago",
|
||||
"Prepaid_Vouchers": "Fichas prepago",
|
||||
"Refill_Account": "Recargar Ficha",
|
||||
"Recharge_Account": "Recargar Cuenta",
|
||||
"Select_Account": "Seleccionar cuenta",
|
||||
|
@ -96,9 +96,6 @@
|
||||
"Add_Pool": "Havuz ekle",
|
||||
"Edit_Pool": "Havuzu D\u00fczenle",
|
||||
"Pool_Name_Already_Exist": "Havuz Ad\u0131 \u200b\u200bZaten Var",
|
||||
"Prepaid": "\u00d6n \u00d6demeli",
|
||||
"Prepaid_Users": "\u00d6n \u00d6demeli Kullan\u0131c\u0131lar",
|
||||
"Prepaid_Vouchers": "\u00d6n \u00d6demeli Kuponlar",
|
||||
"Refill_Account": "Hesab\u0131 Yenile",
|
||||
"Recharge_Account": "Hesab\u0131 Yeniden \u015earj Et",
|
||||
"Select_Account": "Hesap Se\u00e7",
|
||||
|
@ -3,7 +3,7 @@
|
||||
var id = this.id;
|
||||
bootbox.confirm("Are you sure?", function(result) {
|
||||
if(result){
|
||||
window.location.href = "index.php?_route=prepaid/delete/" + id;
|
||||
window.location.href = "index.php?_route=plan/delete/" + id;
|
||||
}
|
||||
});
|
||||
});
|
@ -3,7 +3,7 @@
|
||||
var id = this.id;
|
||||
bootbox.confirm("Are you sure?", function(result) {
|
||||
if(result){
|
||||
window.location.href = "index.php?_route=prepaid/voucher-delete/" + id;
|
||||
window.location.href = "index.php?_route=plan/voucher-delete/" + id;
|
||||
}
|
||||
});
|
||||
});
|
@ -1,4 +1,9 @@
|
||||
<option value="">Select Plans</option>
|
||||
{foreach $d as $ds}
|
||||
<option value="{$ds['id']}">{if $ds['enabled'] neq 1}DISABLED PLAN • {/if}{$ds['name_plan']} • {Lang::moneyFormat($ds['price'])}{if $ds['prepaid'] neq 'yes'} • POSTPAID {/if}</option>
|
||||
<option value="{$ds['id']}">
|
||||
{if $ds['enabled'] neq 1}DISABLED PLAN • {/if}
|
||||
{$ds['name_plan']} •
|
||||
{Lang::moneyFormat($ds['price'])}
|
||||
{if $ds['prepaid'] neq 'yes'} • POSTPAID {/if}
|
||||
</option>
|
||||
{/foreach}
|
@ -160,7 +160,7 @@
|
||||
</thead>
|
||||
<tbody>
|
||||
{foreach $activation as $ds}
|
||||
<tr onclick="window.location.href = '{$_url}prepaid/view/{$ds['id']}'" style="cursor:pointer;">
|
||||
<tr onclick="window.location.href = '{$_url}plan/view/{$ds['id']}'" style="cursor:pointer;">
|
||||
<td>{$ds['invoice']}</td>
|
||||
<td>{$ds['username']}</td>
|
||||
<td>{$ds['plan_name']}</td>
|
||||
|
@ -18,7 +18,7 @@
|
||||
<div class="col-md-8">
|
||||
<form id="site-search" method="post" action="{$_url}customers/list/">
|
||||
<div class="input-group">
|
||||
<input type="text" name="search" value="{$search}" class="form-control"
|
||||
<input type="text" id="search-input" name="search" value="{$search}" class="form-control"
|
||||
placeholder="{Lang::T('Search')}...">
|
||||
<div class="input-group-btn">
|
||||
<button class="btn btn-success" type="submit"><span
|
||||
@ -65,7 +65,7 @@
|
||||
<td align="center">
|
||||
<a href="{$_url}customers/view/{$ds['id']}" id="{$ds['id']}" style="margin: 0px;"
|
||||
class="btn btn-success btn-xs"> {Lang::T('View')} </a>
|
||||
<a href="{$_url}prepaid/recharge/{$ds['id']}" id="{$ds['id']}" style="margin: 0px;"
|
||||
<a href="{$_url}plan/recharge/{$ds['id']}" id="{$ds['id']}" style="margin: 0px;"
|
||||
class="btn btn-primary btn-xs">{Lang::T('Recharge')}</a>
|
||||
</td>
|
||||
</tr>
|
||||
@ -79,4 +79,25 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
// Functionality to filter table rows based on admin input
|
||||
document.addEventListener('DOMContentLoaded', function () {
|
||||
var searchInput = document.getElementById('search-input');
|
||||
var tableRows = document.querySelectorAll('tbody tr');
|
||||
|
||||
searchInput.addEventListener('input', function () {
|
||||
var searchText = this.value.toLowerCase();
|
||||
|
||||
tableRows.forEach(function (row) {
|
||||
var rowData = row.textContent.toLowerCase();
|
||||
|
||||
if (rowData.includes(searchText)) {
|
||||
row.style.display = '';
|
||||
} else {
|
||||
row.style.display = 'none';
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
</script>
|
||||
{include file="sections/footer.tpl"}
|
@ -41,7 +41,7 @@
|
||||
<div class="icon">
|
||||
<i class="ion ion-person"></i>
|
||||
</div>
|
||||
<a href="{$_url}prepaid/list" class="small-box-footer">{Lang::T('View All')} <i
|
||||
<a href="{$_url}plan/list" class="small-box-footer">{Lang::T('View All')} <i
|
||||
class="fa fa-arrow-circle-right"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -5,7 +5,7 @@
|
||||
<div class="panel panel-primary panel-hovered panel-stacked mb30">
|
||||
<div class="panel-heading">{Lang::T('Refill Balance')}</div>
|
||||
<div class="panel-body">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}prepaid/deposit-post">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}plan/deposit-post">
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Select Account')}</label>
|
||||
<div class="col-md-6">
|
||||
|
@ -5,7 +5,7 @@
|
||||
<div class="panel panel-hovered panel-primary panel-stacked mb30">
|
||||
<div class="panel-heading">{$in['invoice']}</div>
|
||||
<div class="panel-body">
|
||||
<form class="form-horizontal" method="post" action="{$_url}prepaid/print" target="_blank">
|
||||
<form class="form-horizontal" method="post" action="{$_url}plan/print" target="_blank">
|
||||
<pre id="content">{$invoice}</pre>
|
||||
<input type="hidden" name="id" value="{$in['id']}">
|
||||
<a href="{$_url}voucher/list-activated" class="btn btn-default btn-sm"><i
|
||||
|
@ -5,16 +5,16 @@
|
||||
<div class="panel panel-hovered panel-primary panel-stacked mb30">
|
||||
<div class="panel-heading">{$in['invoice']}</div>
|
||||
<div class="panel-body">
|
||||
<form class="form-horizontal" method="post" action="{$_url}prepaid/print" target="_blank">
|
||||
<form class="form-horizontal" method="post" action="{$_url}plan/print" target="_blank">
|
||||
<pre id="content"></pre>
|
||||
<textarea class="hidden" id="formcontent" name="content">{$invoice}</textarea>
|
||||
<input type="hidden" name="id" value="{$in['id']}">
|
||||
<a href="{$_url}prepaid/list" class="btn btn-default btn-sm"><i
|
||||
<a href="{$_url}plan/list" class="btn btn-default btn-sm"><i
|
||||
class="ion-reply-all"></i>{Lang::T('Finish')}</a>
|
||||
<a href="https://api.whatsapp.com/send/?text={$whatsapp}" target="_blank"
|
||||
class="btn btn-primary btn-sm">
|
||||
<i class="glyphicon glyphicon-share"></i> WhatsApp</a>
|
||||
<a href="{$_url}prepaid/view/{$in['id']}/send" class="btn btn-info text-black btn-sm"><i
|
||||
<a href="{$_url}plan/view/{$in['id']}/send" class="btn btn-info text-black btn-sm"><i
|
||||
class="glyphicon glyphicon-envelope"></i> {Lang::T("Resend")}</a>
|
||||
<button type="submit" class="btn btn-info text-black btn-sm"><i class="glyphicon glyphicon-print"></i>
|
||||
Print</button>
|
||||
|
62
ui/ui/message-bulk.tpl
Normal file
62
ui/ui/message-bulk.tpl
Normal file
@ -0,0 +1,62 @@
|
||||
{include file="sections/header.tpl"}
|
||||
|
||||
<div class="row">
|
||||
<div class="col-sm-12 col-md-12">
|
||||
<div class="panel panel-primary panel-hovered panel-stacked mb30">
|
||||
<div class="panel-heading">{Lang::T('Send Bulk Message')}</div>
|
||||
<div class="panel-body">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}message/send_bulk-post">
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Group')}</label>
|
||||
<div class="col-md-6">
|
||||
<select class="form-control" name="group" id="group">
|
||||
<option value="all" selected>{Lang::T('All Customers')}</option>
|
||||
<option value="new">{Lang::T('New Customers')}</option>
|
||||
<option value="expired">{Lang::T('Expired Customers')}</option>
|
||||
<option value="active">{Lang::T('Active Customers')}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Send Via')}</label>
|
||||
<div class="col-md-6">
|
||||
<select class="form-control" name="via" id="via">
|
||||
<option value="sms" selected>{Lang::T('SMS')}</option>
|
||||
<option value="wa">{Lang::T('WhatsApp')}</option>
|
||||
<option value="both">{Lang::T('SMS and WhatsApp')}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Message')}</label>
|
||||
<div class="col-md-6">
|
||||
<textarea class="form-control" id="message" name="message" placeholder="{Lang::T('Compose your message...')}" rows="5"></textarea>
|
||||
</div>
|
||||
<p class="help-block col-md-4">
|
||||
{Lang::T('Use placeholders:')}
|
||||
<br>
|
||||
<b>{Lang::T('[[name]]')}</b> - {Lang::T('Customer Name')}
|
||||
<br>
|
||||
<b>{Lang::T('[[user_name]]')}</b> - {Lang::T('Customer Username')}
|
||||
<br>
|
||||
<b>{Lang::T('[[phone]]')}</b> - {Lang::T('Customer Phone')}
|
||||
<br>
|
||||
<b>{Lang::T('[[company_name]]')}</b> - {Lang::T('Your Company Name')}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<div class="col-lg-offset-2 col-lg-10">
|
||||
<button class="btn btn-success" type="submit">{Lang::T('Send Message')}</button>
|
||||
<a href="{$_url}dashboard" class="btn btn-default">{Lang::T('Cancel')}</a>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
{include file="sections/footer.tpl"}
|
65
ui/ui/message.tpl
Normal file
65
ui/ui/message.tpl
Normal file
@ -0,0 +1,65 @@
|
||||
{include file="sections/header.tpl"}
|
||||
|
||||
<div class="row">
|
||||
<div class="col-sm-12 col-md-12">
|
||||
<div class="panel panel-primary panel-hovered panel-stacked mb30">
|
||||
<div class="panel-heading">{Lang::T('Send Personal Message')}</div>
|
||||
<div class="panel-body">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}message/send-post" >
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Customer')}</label>
|
||||
<div class="col-md-6">
|
||||
<select id="personSelect" class="form-control select2" name="id_customer" style="width: 100%" data-placeholder="Select a customer...">
|
||||
<option></option>
|
||||
{foreach $c as $cs}
|
||||
{if $id eq $cs['id']}
|
||||
<option value="{$cs['id']}" selected>{$cs['username']}</option>
|
||||
{else}
|
||||
<option value="{$cs['id']}">{$cs['username']}</option>
|
||||
{/if}
|
||||
{/foreach}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Send Via')}</label>
|
||||
<div class="col-md-6">
|
||||
<select class="form-control" name="via" id="via">
|
||||
<option value="sms" selected> {Lang::T('SMS')}</option>
|
||||
<option value="wa"> {Lang::T('WhatsApp')}</option>
|
||||
<option value="both"> {Lang::T('SMS and WhatsApp')}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Message')}</label>
|
||||
<div class="col-md-6">
|
||||
<textarea class="form-control" id="message" name="message" placeholder="{Lang::T('Compose your message...')}" rows="5"></textarea>
|
||||
</div>
|
||||
<p class="help-block col-md-4">
|
||||
{Lang::T('Use placeholders:')}
|
||||
<br>
|
||||
<b>{Lang::T('[[name]]')}</b> - {Lang::T('Customer Name')}
|
||||
<br>
|
||||
<b>{Lang::T('[[user_name]]')}</b> - {Lang::T('Customer Username')}
|
||||
<br>
|
||||
<b>{Lang::T('[[phone]]')}</b> - {Lang::T('Customer Phone')}
|
||||
<br>
|
||||
<b>{Lang::T('[[company_name]]')}</b> - {Lang::T('Your Company Name')}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<div class="col-lg-offset-2 col-lg-10">
|
||||
<button class="btn btn-success" type="submit">{Lang::T('Send Message')}</button>
|
||||
<a href="{$_url}dashboard" class="btn btn-default">{Lang::T('Cancel')}</a>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
{include file="sections/footer.tpl"}
|
@ -7,7 +7,7 @@
|
||||
<h3 class="panel-title">Edit Plan</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}prepaid/edit-post">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}plan/edit-post">
|
||||
<input type="hidden" name="id" value="{$d['id']}">
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Select Account')}</label>
|
||||
@ -56,7 +56,7 @@
|
||||
<div class="col-lg-offset-2 col-lg-10">
|
||||
<button class="btn btn-success"
|
||||
type="submit">{Lang::T('Edit')}</button>
|
||||
Or <a href="{$_url}prepaid/list">{Lang::T('Cancel')}</a>
|
||||
Or <a href="{$_url}plan/list">{Lang::T('Cancel')}</a>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
@ -6,7 +6,7 @@
|
||||
<div class="panel-heading">
|
||||
{if in_array($_admin['user_type'],['SuperAdmin','Admin'])}
|
||||
<div class="btn-group pull-right">
|
||||
<a class="btn btn-primary btn-xs" title="save" href="{$_url}prepaid/sync"
|
||||
<a class="btn btn-primary btn-xs" title="save" href="{$_url}plan/sync"
|
||||
onclick="return confirm('This will sync/send Caustomer active plan to Mikrotik?')"><span
|
||||
class="glyphicon glyphicon-refresh" aria-hidden="true"></span> sync</a>
|
||||
</div>
|
||||
@ -21,7 +21,7 @@
|
||||
<div class="panel-body">
|
||||
<div class="md-whiteframe-z1 mb20 text-center" style="padding: 15px">
|
||||
<div class="col-md-8">
|
||||
<form id="site-search" method="post" action="{$_url}prepaid/list/">
|
||||
<form id="site-search" method="post" action="{$_url}plan/list/">
|
||||
<div class="input-group">
|
||||
<div class="input-group-addon">
|
||||
<span class="fa fa-search"></span>
|
||||
@ -35,7 +35,7 @@
|
||||
</form>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<a href="{$_url}prepaid/recharge" class="btn btn-primary btn-block"><i
|
||||
<a href="{$_url}plan/recharge" class="btn btn-primary btn-block"><i
|
||||
class="ion ion-android-add"> </i> {Lang::T('Recharge Account')}</a>
|
||||
</div>
|
||||
</div>
|
||||
@ -64,10 +64,10 @@
|
||||
<td>{$ds['method']}</td>
|
||||
<td>{$ds['routers']}</td>
|
||||
<td>
|
||||
<a href="{$_url}prepaid/edit/{$ds['id']}"
|
||||
<a href="{$_url}plan/edit/{$ds['id']}"
|
||||
class="btn btn-warning btn-xs">{Lang::T('Edit')}</a>
|
||||
{if in_array($_admin['user_type'],['SuperAdmin','Admin'])}
|
||||
<a href="{$_url}prepaid/delete/{$ds['id']}" id="{$ds['id']}"
|
||||
<a href="{$_url}plan/delete/{$ds['id']}" id="{$ds['id']}"
|
||||
onclick="return confirm('{Lang::T('Delete')}?')"
|
||||
class="btn btn-danger btn-xs"><i class="glyphicon glyphicon-trash"></i></a>
|
||||
{/if}
|
@ -60,7 +60,7 @@
|
||||
|
||||
<body>
|
||||
<page size="A4">
|
||||
<form method="post" action="{$_url}prepaid/print-voucher/" class="no-print">
|
||||
<form method="post" action="{$_url}plan/print-voucher/" class="no-print">
|
||||
<table width="100%" border="0" cellspacing="0" cellpadding="1" class="btn btn-default btn-sm">
|
||||
<tr>
|
||||
<td>From ID > <input type="text" name="from_id" style="width:40px" value="{$from_id}"> limit
|
||||
|
@ -76,14 +76,14 @@
|
||||
</li>
|
||||
{/if}
|
||||
</ul>
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}prepaid/recharge-post">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}plan/recharge-post">
|
||||
<input type="hidden" name="id_customer" value="{$cust['id']}">
|
||||
<input type="hidden" name="plan" value="{$plan['id']}">
|
||||
<input type="hidden" name="server" value="{$server}">
|
||||
<input type="hidden" name="using" value="{$using}">
|
||||
<center>
|
||||
<button class="btn btn-success" type="submit">{Lang::T('Recharge')}</button><br>
|
||||
<a class="btn btn-link" href="{$_url}prepaid/recharge">{Lang::T('Cancel')}</a>
|
||||
<a class="btn btn-link" href="{$_url}plan/recharge">{Lang::T('Cancel')}</a>
|
||||
</center>
|
||||
</form>
|
||||
</div>
|
||||
|
@ -5,7 +5,7 @@
|
||||
<div class="panel panel-primary panel-hovered panel-stacked mb30">
|
||||
<div class="panel-heading">{Lang::T('Recharge Account')}</div>
|
||||
<div class="panel-body">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}prepaid/recharge-confirm">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}plan/recharge-confirm">
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Select Account')}</label>
|
||||
<div class="col-md-6">
|
||||
|
@ -5,7 +5,7 @@
|
||||
<div class="panel panel-primary panel-hovered panel-stacked mb30">
|
||||
<div class="panel-heading">{Lang::T('Refill Account')}</div>
|
||||
<div class="panel-body">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}prepaid/refill-post">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}plan/refill-post">
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Select Account')}</label>
|
||||
<div class="col-md-6">
|
||||
|
@ -44,7 +44,7 @@
|
||||
<tbody>
|
||||
{foreach $activation as $ds}
|
||||
<tr>
|
||||
<td onclick="window.location.href = '{$_url}prepaid/view/{$ds['id']}'"
|
||||
<td onclick="window.location.href = '{$_url}plan/view/{$ds['id']}'"
|
||||
style="cursor:pointer;">{$ds['invoice']}</td>
|
||||
<td onclick="window.location.href = '{$_url}customers/viewu/{$ds['username']}'"
|
||||
style="cursor:pointer;">{$ds['username']}</td>
|
||||
|
@ -150,7 +150,7 @@
|
||||
<aside class="main-sidebar">
|
||||
<section class="sidebar">
|
||||
<ul class="sidebar-menu" data-widget="tree">
|
||||
<li {if $_system_menu eq 'dashboard'}class="active" {/if}>
|
||||
<li {if $_system_menu eq 'dashboard' }class="active" {/if}>
|
||||
<a href="{$_url}dashboard">
|
||||
<i class="ion ion-monitor"></i>
|
||||
<span>{Lang::T('Dashboard')}</span>
|
||||
@ -158,14 +158,14 @@
|
||||
</li>
|
||||
{$_MENU_AFTER_DASHBOARD}
|
||||
{if !in_array($_admin['user_type'],['Report'])}
|
||||
<li {if $_system_menu eq 'customers'}class="active" {/if}>
|
||||
<li {if $_system_menu eq 'customers' }class="active" {/if}>
|
||||
<a href="{$_url}customers">
|
||||
<i class="fa fa-users"></i>
|
||||
<span>{Lang::T('Customer')}</span>
|
||||
</a>
|
||||
</li>
|
||||
{$_MENU_AFTER_CUSTOMERS}
|
||||
<li class="{if $_system_menu eq 'prepaid'}active{/if} treeview">
|
||||
<li class="{if $_system_menu eq 'plan'}active{/if} treeview">
|
||||
<a href="#">
|
||||
<i class="fa fa-ticket"></i> <span>{Lang::T('Services')}</span>
|
||||
<span class="pull-right-container">
|
||||
@ -173,19 +173,19 @@
|
||||
</span>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li {if $_routes[1] eq 'list'}class="active" {/if}><a
|
||||
href="{$_url}prepaid/list">{Lang::T('Active Users')}</a></li>
|
||||
<li {if $_routes[1] eq 'list' }class="active" {/if}><a
|
||||
href="{$_url}plan/list">{Lang::T('Active Users')}</a></li>
|
||||
{if $_c['disable_voucher'] != 'yes'}
|
||||
<li {if $_routes[1] eq 'voucher'}class="active" {/if}><a
|
||||
href="{$_url}prepaid/voucher">{Lang::T('Vouchers')}</a></li>
|
||||
<li {if $_routes[1] eq 'refill'}class="active" {/if}><a
|
||||
href="{$_url}prepaid/refill">{Lang::T('Refill Customer')}</a></li>
|
||||
<li {if $_routes[1] eq 'voucher' }class="active" {/if}><a
|
||||
href="{$_url}plan/voucher">{Lang::T('Vouchers')}</a></li>
|
||||
<li {if $_routes[1] eq 'refill' }class="active" {/if}><a
|
||||
href="{$_url}plan/refill">{Lang::T('Refill Customer')}</a></li>
|
||||
{/if}
|
||||
<li {if $_routes[1] eq 'recharge'}class="active" {/if}><a
|
||||
href="{$_url}prepaid/recharge">{Lang::T('Recharge Customer')}</a></li>
|
||||
<li {if $_routes[1] eq 'recharge' }class="active" {/if}><a
|
||||
href="{$_url}plan/recharge">{Lang::T('Recharge Customer')}</a></li>
|
||||
{if $_c['enable_balance'] == 'yes'}
|
||||
<li {if $_routes[1] eq 'deposit'}class="active" {/if}><a
|
||||
href="{$_url}prepaid/deposit">{Lang::T('Refill Balance')}</a></li>
|
||||
<li {if $_routes[1] eq 'deposit' }class="active" {/if}><a
|
||||
href="{$_url}plan/deposit">{Lang::T('Refill Balance')}</a></li>
|
||||
{/if}
|
||||
{$_MENU_SERVICES}
|
||||
</ul>
|
||||
@ -201,14 +201,14 @@
|
||||
</span>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li {if $_routes[1] eq 'hotspot'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'hotspot' }class="active" {/if}><a
|
||||
href="{$_url}services/hotspot">{Lang::T('Hotspot')}</a></li>
|
||||
<li {if $_routes[1] eq 'pppoe'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'pppoe' }class="active" {/if}><a
|
||||
href="{$_url}services/pppoe">{Lang::T('PPPOE')}</a></li>
|
||||
<li {if $_routes[1] eq 'list'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'list' }class="active" {/if}><a
|
||||
href="{$_url}bandwidth/list">{Lang::T('Bandwidth')}</a></li>
|
||||
{if $_c['enable_balance'] == 'yes'}
|
||||
<li {if $_routes[1] eq 'balance'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'balance' }class="active" {/if}><a
|
||||
href="{$_url}services/balance">{Lang::T('Balance')}</a></li>
|
||||
{/if}
|
||||
{$_MENU_PLANS}
|
||||
@ -224,16 +224,32 @@
|
||||
</span>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li {if $_routes[1] eq 'daily-report'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'daily-report' }class="active" {/if}><a
|
||||
href="{$_url}reports/daily-report">{Lang::T('Daily Reports')}</a></li>
|
||||
<li {if $_routes[1] eq 'by-period'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'by-period' }class="active" {/if}><a
|
||||
href="{$_url}reports/by-period">{Lang::T('Period Reports')}</a></li>
|
||||
<li {if $_routes[1] eq 'activation'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'activation' }class="active" {/if}><a
|
||||
href="{$_url}reports/activation">{Lang::T('Activation History')}</a></li>
|
||||
{$_MENU_REPORTS}
|
||||
</ul>
|
||||
</li>
|
||||
{$_MENU_AFTER_REPORTS}
|
||||
<li class="{if $_system_menu eq 'message'}active{/if} treeview">
|
||||
<a href="#">
|
||||
<i class="ion ion-android-chat"></i> <span>{Lang::T('Send Message')}</span>
|
||||
<span class="pull-right-container">
|
||||
<i class="fa fa-angle-left pull-right"></i>
|
||||
</span>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li {if $_routes[1] eq 'send' }class="active" {/if}><a
|
||||
href="{$_url}message/send">{Lang::T('Send SMS/WA Message')}</a></li>
|
||||
<li {if $_routes[1] eq 'send_bulk' }class="active" {/if}><a
|
||||
href="{$_url}message/send_bulk">{Lang::T('Send Bulk SMS/WA Message')}</a></li>
|
||||
{$_MENU_MESSAGE}
|
||||
</ul>
|
||||
</li>
|
||||
{$_MENU_AFTER_MESSAGE}
|
||||
{if in_array($_admin['user_type'],['SuperAdmin','Admin'])}
|
||||
<li class="{if $_system_menu eq 'network'}active{/if} treeview">
|
||||
<a href="#">
|
||||
@ -243,9 +259,9 @@
|
||||
</span>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li {if $_routes[0] eq 'routers' and $_routes[1] eq 'list'}class="active" {/if}><a
|
||||
<li {if $_routes[0] eq 'routers' and $_routes[1] eq 'list' }class="active" {/if}><a
|
||||
href="{$_url}routers/list">{Lang::T('Routers')}</a></li>
|
||||
<li {if $_routes[0] eq 'pool' and $_routes[1] eq 'list'}class="active" {/if}><a
|
||||
<li {if $_routes[0] eq 'pool' and $_routes[1] eq 'list' }class="active" {/if}><a
|
||||
href="{$_url}pool/list">{Lang::T('IP Pool')}</a></li>
|
||||
{$_MENU_NETWORK}
|
||||
</ul>
|
||||
@ -260,7 +276,7 @@
|
||||
</span>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li {if $_routes[0] eq 'radius' and $_routes[1] eq 'nas-list'}class="active" {/if}><a
|
||||
<li {if $_routes[0] eq 'radius' and $_routes[1] eq 'nas-list' }class="active" {/if}><a
|
||||
href="{$_url}radius/nas-list">{Lang::T('Radius NAS')}</a></li>
|
||||
{$_MENU_RADIUS}
|
||||
</ul>
|
||||
@ -275,20 +291,20 @@
|
||||
</span>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li {if $_routes[1] eq 'Order_Voucher'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'Order_Voucher' }class="active" {/if}><a
|
||||
href="{$_url}pages/Order_Voucher">{Lang::T('Order Voucher')}</a></li>
|
||||
<li {if $_routes[1] eq 'Voucher'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'Voucher' }class="active" {/if}><a
|
||||
href="{$_url}pages/Voucher">{Lang::T('Voucher')} Template</a></li>
|
||||
<li {if $_routes[1] eq 'Announcement'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'Announcement' }class="active" {/if}><a
|
||||
href="{$_url}pages/Announcement">{Lang::T('Announcement')}</a></li>
|
||||
<li {if $_routes[1] eq 'Announcement_Customer'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'Announcement_Customer' }class="active" {/if}><a
|
||||
href="{$_url}pages/Announcement_Customer">{Lang::T('Customer Announcement')}</a>
|
||||
</li>
|
||||
<li {if $_routes[1] eq 'Registration_Info'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'Registration_Info' }class="active" {/if}><a
|
||||
href="{$_url}pages/Registration_Info">{Lang::T('Registration Info')}</a></li>
|
||||
<li {if $_routes[1] eq 'Privacy_Policy'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'Privacy_Policy' }class="active" {/if}><a
|
||||
href="{$_url}pages/Privacy_Policy">Privacy Policy</a></li>
|
||||
<li {if $_routes[1] eq 'Terms_and_Conditions'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'Terms_and_Conditions' }class="active" {/if}><a
|
||||
href="{$_url}pages/Terms_and_Conditions">Terms and Conditions</a></li>
|
||||
{$_MENU_PAGES}
|
||||
</ul>
|
||||
@ -305,31 +321,31 @@
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
{if in_array($_admin['user_type'],['SuperAdmin','Admin'])}
|
||||
<li {if $_routes[1] eq 'app'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'app' }class="active" {/if}><a
|
||||
href="{$_url}settings/app">{Lang::T('General Settings')}</a></li>
|
||||
<li {if $_routes[1] eq 'localisation'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'localisation' }class="active" {/if}><a
|
||||
href="{$_url}settings/localisation">{Lang::T('Localisation')}</a></li>
|
||||
<li {if $_routes[1] eq 'notifications'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'notifications' }class="active" {/if}><a
|
||||
href="{$_url}settings/notifications">{Lang::T('User Notification')}</a></li>
|
||||
{/if}
|
||||
{if in_array($_admin['user_type'],['SuperAdmin','Admin','Agent'])}
|
||||
<li {if $_routes[1] eq 'users'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'users' }class="active" {/if}><a
|
||||
href="{$_url}settings/users">{Lang::T('Administrator Users')}</a></li>
|
||||
{/if}
|
||||
{if in_array($_admin['user_type'],['SuperAdmin','Admin'])}
|
||||
<li {if $_routes[1] eq 'dbstatus'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'dbstatus' }class="active" {/if}><a
|
||||
href="{$_url}settings/dbstatus">{Lang::T('Backup/Restore')}</a></li>
|
||||
<li {if $_system_menu eq 'paymentgateway'}class="active" {/if}>
|
||||
<li {if $_system_menu eq 'paymentgateway' }class="active" {/if}>
|
||||
<a href="{$_url}paymentgateway">
|
||||
<span class="text">{Lang::T('Payment Gateway')}</span>
|
||||
</a>
|
||||
</li>
|
||||
{$_MENU_SETTINGS}
|
||||
<li {if $_routes[0] eq 'pluginmanager'}class="active" {/if}>
|
||||
<li {if $_routes[0] eq 'pluginmanager' }class="active" {/if}>
|
||||
<a href="{$_url}pluginmanager"><i class="glyphicon glyphicon-tasks"></i>
|
||||
{Lang::T('Plugin Manager')} <small class="label pull-right">Free</small></a>
|
||||
</li>
|
||||
{* <li {if $_routes[0] eq 'codecanyon'}class="active" {/if}>
|
||||
{* <li {if $_routes[0] eq 'codecanyon' }class="active" {/if}>
|
||||
<a href="{$_url}codecanyon"><i class="glyphicon glyphicon-shopping-cart"></i>
|
||||
Codecanyon.net <small class="label pull-right">Paid</small></a>
|
||||
</li> *}
|
||||
@ -346,10 +362,11 @@
|
||||
</span>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li {if $_routes[1] eq 'list'}class="active" {/if}><a
|
||||
<li {if $_routes[1] eq 'list' }class="active" {/if}><a
|
||||
href="{$_url}logs/phpnuxbill">PhpNuxBill</a></li>
|
||||
{if $_c['radius_enable']}
|
||||
<li {if $_routes[1] eq 'radius'}class="active" {/if}><a href="{$_url}logs/radius">Radius</a>
|
||||
<li {if $_routes[1] eq 'radius' }class="active" {/if}><a
|
||||
href="{$_url}logs/radius">Radius</a>
|
||||
</li>
|
||||
{/if}
|
||||
</ul>
|
||||
@ -357,7 +374,7 @@
|
||||
</li>
|
||||
{/if}
|
||||
{$_MENU_AFTER_LOGS}
|
||||
<li {if $_system_menu eq 'community'}class="active" {/if}>
|
||||
<li {if $_system_menu eq 'community' }class="active" {/if}>
|
||||
<a href="{$_url}community">
|
||||
<i class="ion ion-chatboxes"></i>
|
||||
<span class="text">{Lang::T('Community')}</span>
|
||||
@ -393,4 +410,4 @@
|
||||
}
|
||||
});
|
||||
</script>
|
||||
{/if}
|
||||
{/if}
|
@ -7,7 +7,7 @@
|
||||
<div class="panel-heading">{Lang::T('Add Vouchers')}</div>
|
||||
<div class="panel-body">
|
||||
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}prepaid/voucher-post">
|
||||
<form class="form-horizontal" method="post" role="form" action="{$_url}plan/voucher-post">
|
||||
<div class="form-group">
|
||||
<label class="col-md-2 control-label">{Lang::T('Type')}</label>
|
||||
<div class="col-md-6">
|
||||
|
@ -4,11 +4,11 @@
|
||||
<div class="col-md-6 col-sm-12 col-md-offset-3">
|
||||
<div class="panel panel-hovered panel-primary panel-stacked mb30">
|
||||
<div class="panel-body">
|
||||
<form class="form-horizontal" method="post" action="{$_url}prepaid/print" target="_blank">
|
||||
<form class="form-horizontal" method="post" action="{$_url}plan/print" target="_blank">
|
||||
<pre id="content"></pre>
|
||||
<textarea class="hidden" id="formcontent" name="content">{$print}</textarea>
|
||||
<input type="hidden" name="id" value="{$in['id']}">
|
||||
<a href="{$_url}prepaid/voucher" class="btn btn-default btn-sm"><i
|
||||
<a href="{$_url}plan/voucher" class="btn btn-default btn-sm"><i
|
||||
class="ion-reply-all"></i>{Lang::T('Finish')}</a>
|
||||
<a href="https://api.whatsapp.com/send/?text={$whatsapp}" target="_blank"
|
||||
class="btn btn-primary btn-sm">
|
||||
|
@ -6,7 +6,7 @@
|
||||
<div class="panel-heading">
|
||||
{if in_array($_admin['user_type'],['SuperAdmin','Admin'])}
|
||||
<div class="btn-group pull-right">
|
||||
<a class="btn btn-danger btn-xs" title="Remove used Voucher" href="{$_url}prepaid/remove-voucher"
|
||||
<a class="btn btn-danger btn-xs" title="Remove used Voucher" href="{$_url}plan/remove-voucher"
|
||||
onclick="return confirm('Delete all used voucher code?')"><span
|
||||
class="glyphicon glyphicon-trash" aria-hidden="true"></span> Delete All</a>
|
||||
</div>
|
||||
@ -16,7 +16,7 @@
|
||||
<div class="panel-body">
|
||||
<div class="md-whiteframe-z1 mb20 text-center" style="padding: 15px">
|
||||
<div class="col-md-8">
|
||||
<form id="site-search" method="post" action="{$_url}prepaid/voucher/">
|
||||
<form id="site-search" method="post" action="{$_url}plan/voucher/">
|
||||
<div class="input-group">
|
||||
<div class="input-group-addon">
|
||||
<span class="fa fa-search"></span>
|
||||
@ -32,11 +32,11 @@
|
||||
<div class="col-md-4">
|
||||
<div class="btn-group btn-group-justified" role="group">
|
||||
<div class="btn-group" role="group">
|
||||
<a href="{$_url}prepaid/add-voucher" class="btn btn-primary btn-block"><i
|
||||
<a href="{$_url}plan/add-voucher" class="btn btn-primary btn-block"><i
|
||||
class="ion ion-android-add"> </i> {Lang::T('Add Vouchers')}</a>
|
||||
</div>
|
||||
<div class="btn-group" role="group">
|
||||
<a href="{$_url}prepaid/print-voucher" target="print_voucher" class="btn btn-info"><i
|
||||
<a href="{$_url}plan/print-voucher" target="print_voucher" class="btn btn-info"><i
|
||||
class="ion ion-android-print"> </i> Print</a>
|
||||
</div>
|
||||
</div>
|
||||
@ -82,12 +82,12 @@
|
||||
</td>
|
||||
<td>
|
||||
{if $ds['status'] neq '1'}
|
||||
<a href="{$_url}prepaid/voucher-view/{$ds['id']}" id="{$ds['id']}"
|
||||
<a href="{$_url}plan/voucher-view/{$ds['id']}" id="{$ds['id']}"
|
||||
style="margin: 0px;"
|
||||
class="btn btn-success btn-xs"> {Lang::T('View')} </a>
|
||||
{/if}
|
||||
{if in_array($_admin['user_type'],['SuperAdmin','Admin'])}
|
||||
<a href="{$_url}prepaid/voucher-delete/{$ds['id']}" id="{$ds['id']}"
|
||||
<a href="{$_url}plan/voucher-delete/{$ds['id']}" id="{$ds['id']}"
|
||||
class="btn btn-danger btn-xs"
|
||||
onclick="return confirm('{Lang::T('Delete')}?')"><i
|
||||
class="glyphicon glyphicon-trash"></i></a>
|
||||
@ -101,10 +101,10 @@
|
||||
|
||||
<ul class="pagination pagination-sm">
|
||||
{if $page>0}
|
||||
<li><a href="{$_url}prepaid/voucher&p={$page-1}&code={$_code}">{Lang::T('Prev')}</a></li>
|
||||
<li><a href="{$_url}plan/voucher&p={$page-1}&code={$_code}">{Lang::T('Prev')}</a></li>
|
||||
{/if}
|
||||
{if $d}
|
||||
<li><a href="{$_url}prepaid/voucher&p={$page+1}&code={$_code}">{Lang::T('Next')}</a></li>
|
||||
<li><a href="{$_url}plan/voucher&p={$page+1}&code={$_code}">{Lang::T('Next')}</a></li>
|
||||
{/if}
|
||||
</ul>
|
||||
</div>
|
||||
|
@ -1,3 +1,3 @@
|
||||
{
|
||||
"version": "2024.3.15"
|
||||
"version": "2024.3.18"
|
||||
}
|
Reference in New Issue
Block a user