print 1 voucher will go to print or share
This commit is contained in:
parent
8e3e715c8c
commit
e1272ec531
@ -156,11 +156,16 @@ switch ($action) {
|
|||||||
|
|
||||||
|
|
||||||
case 'print':
|
case 'print':
|
||||||
|
$content = $_POST['content'];
|
||||||
|
if(!empty($content)){
|
||||||
|
$ui->assign('content', $content);
|
||||||
|
}else{
|
||||||
$id = _post('id');
|
$id = _post('id');
|
||||||
$d = ORM::for_table('tbl_transactions')->where('id', $id)->find_one();
|
$d = ORM::for_table('tbl_transactions')->where('id', $id)->find_one();
|
||||||
$ui->assign('in', $d);
|
$ui->assign('in', $d);
|
||||||
|
|
||||||
$ui->assign('date', Lang::dateAndTimeFormat($d['recharged_on'], $d['recharged_time']));
|
$ui->assign('date', Lang::dateAndTimeFormat($d['recharged_on'], $d['recharged_time']));
|
||||||
|
}
|
||||||
|
|
||||||
run_hook('print_invoice'); #HOOK
|
run_hook('print_invoice'); #HOOK
|
||||||
$ui->display('invoice-print.tpl');
|
$ui->display('invoice-print.tpl');
|
||||||
break;
|
break;
|
||||||
@ -282,7 +287,29 @@ switch ($action) {
|
|||||||
->offset($paginator['startpoint'])
|
->offset($paginator['startpoint'])
|
||||||
->limit($paginator['limit'])->find_many();
|
->limit($paginator['limit'])->find_many();
|
||||||
}
|
}
|
||||||
|
// extract admin
|
||||||
|
$admins = [];
|
||||||
|
foreach ($d as $k) {
|
||||||
|
if(!empty($k['generated_by'])){
|
||||||
|
$admins[] = $k['generated_by'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(count($admins) > 0){
|
||||||
|
$adms = ORM::for_table('tbl_users')->where_in('id', $admins)->find_many();
|
||||||
|
unset($admins);
|
||||||
|
foreach($adms as $adm){
|
||||||
|
$tipe = $adm['user_type'];
|
||||||
|
if($tipe == 'Sales'){
|
||||||
|
$tipe = ' [S]';
|
||||||
|
}else if($tipe == 'Agent'){
|
||||||
|
$tipe = ' [A]';
|
||||||
|
}else{
|
||||||
|
$tipe == '';
|
||||||
|
}
|
||||||
|
$admins[$adm['id']] = $adm['fullname'].$tipe;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$ui->assign('admins', $admins);
|
||||||
$ui->assign('d', $d);
|
$ui->assign('d', $d);
|
||||||
$ui->assign('_code', $code);
|
$ui->assign('_code', $code);
|
||||||
$ui->assign('paginator', $paginator);
|
$ui->assign('paginator', $paginator);
|
||||||
@ -466,6 +493,9 @@ switch ($action) {
|
|||||||
$d->generated_by = $admin['id'];
|
$d->generated_by = $admin['id'];
|
||||||
$d->save();
|
$d->save();
|
||||||
}
|
}
|
||||||
|
if($numbervoucher == 1){
|
||||||
|
r2(U . 'prepaid/voucher-view/'.$d->id(), 's', Lang::T('Create Vouchers Successfully'));
|
||||||
|
}
|
||||||
|
|
||||||
r2(U . 'prepaid/voucher', 's', Lang::T('Create Vouchers Successfully'));
|
r2(U . 'prepaid/voucher', 's', Lang::T('Create Vouchers Successfully'));
|
||||||
} else {
|
} else {
|
||||||
@ -473,6 +503,47 @@ switch ($action) {
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case 'voucher-view':
|
||||||
|
if (!in_array($admin['user_type'], ['SuperAdmin', 'Admin'])) {
|
||||||
|
$voucher = ORM::for_table('tbl_voucher')->find_one($id);
|
||||||
|
}else{
|
||||||
|
$voucher = ORM::for_table('tbl_voucher')->where('generated_by', $admin['id'])->find_one($id);
|
||||||
|
}
|
||||||
|
$plan = ORM::for_table('tbl_plans')->find_one($d['id_plan']);
|
||||||
|
if ($voucher && $plan) {
|
||||||
|
$content = Lang::pad($config['CompanyName'],' ', 2)."\n";
|
||||||
|
$content .= Lang::pad($config['address'],' ', 2)."\n";
|
||||||
|
$content .= Lang::pad($config['phone'],' ', 2)."\n";
|
||||||
|
$content .= Lang::pad("", '=')."\n";
|
||||||
|
$content .= Lang::pads('ID', $voucher['id'], ' ')."\n";
|
||||||
|
$content .= Lang::pads(Lang::T('Code'), $voucher['code'], ' ')."\n";
|
||||||
|
$content .= Lang::pads(Lang::T('Plan Name'), $plan['name_plan'], ' ')."\n";
|
||||||
|
$content .= Lang::pads(Lang::T('Type'), $voucher['type'], ' ')."\n";
|
||||||
|
$content .= Lang::pads(Lang::T('Plan Price'), Lang::moneyFormat($plan['price']), ' ')."\n";
|
||||||
|
$content .= Lang::pads(Lang::T('Sales'), $admin['fullname'].' #'.$admin['id'], ' ')."\n";
|
||||||
|
$content .= Lang::pad("", '=')."\n";
|
||||||
|
$content .= Lang::pad($config['note'],' ', 2)."\n";
|
||||||
|
$ui->assign('print', $content);
|
||||||
|
$config['printer_cols'] = 30;
|
||||||
|
$content = Lang::pad($config['CompanyName'],' ', 2)."\n";
|
||||||
|
$content .= Lang::pad($config['address'],' ', 2)."\n";
|
||||||
|
$content .= Lang::pad($config['phone'],' ', 2)."\n";
|
||||||
|
$content .= Lang::pad("", '=')."\n";
|
||||||
|
$content .= Lang::pads('ID', $voucher['id'], ' ')."\n";
|
||||||
|
$content .= Lang::pads(Lang::T('Code'), $voucher['code'], ' ')."\n";
|
||||||
|
$content .= Lang::pads(Lang::T('Plan Name'), $plan['name_plan'], ' ')."\n";
|
||||||
|
$content .= Lang::pads(Lang::T('Type'), $voucher['type'], ' ')."\n";
|
||||||
|
$content .= Lang::pads(Lang::T('Plan Price'), Lang::moneyFormat($plan['price']), ' ')."\n";
|
||||||
|
$content .= Lang::pads(Lang::T('Sales'), $admin['fullname'].' #'.$admin['id'], ' ')."\n";
|
||||||
|
$content .= Lang::pad("", '=')."\n";
|
||||||
|
$content .= Lang::pad($config['note'],' ', 2)."\n";
|
||||||
|
$ui->assign('_title', Lang::T('View'));
|
||||||
|
$ui->assign('wa', urlencode("```$content```"));
|
||||||
|
$ui->display('voucher-view.tpl');
|
||||||
|
}else{
|
||||||
|
r2(U . 'prepaid/voucher/', 'e', Lang::T('Voucher Not Found'));
|
||||||
|
}
|
||||||
|
break;
|
||||||
case 'voucher-delete':
|
case 'voucher-delete':
|
||||||
if (!in_array($admin['user_type'], ['SuperAdmin', 'Admin'])) {
|
if (!in_array($admin['user_type'], ['SuperAdmin', 'Admin'])) {
|
||||||
r2(U . "dashboard", 'e', Lang::T('You do not have permission to access this page'));
|
r2(U . "dashboard", 'e', Lang::T('You do not have permission to access this page'));
|
||||||
|
@ -129,6 +129,7 @@ switch ($action) {
|
|||||||
$d = ORM::for_table('tbl_users')
|
$d = ORM::for_table('tbl_users')
|
||||||
->where_like('username', '%' . $username . '%')
|
->where_like('username', '%' . $username . '%')
|
||||||
->where('root', $admin['id'])
|
->where('root', $admin['id'])
|
||||||
|
->where('id', $admin['id'])
|
||||||
->offset($paginator['startpoint'])
|
->offset($paginator['startpoint'])
|
||||||
->limit($paginator['limit'])->order_by_asc('id')->find_many();
|
->limit($paginator['limit'])->order_by_asc('id')->find_many();
|
||||||
}
|
}
|
||||||
@ -145,7 +146,12 @@ switch ($action) {
|
|||||||
])->offset($paginator['startpoint'])->limit($paginator['limit'])->order_by_asc('id')->find_many();
|
])->offset($paginator['startpoint'])->limit($paginator['limit'])->order_by_asc('id')->find_many();
|
||||||
} else {
|
} else {
|
||||||
$paginator = Paginator::build(ORM::for_table('tbl_users'));
|
$paginator = Paginator::build(ORM::for_table('tbl_users'));
|
||||||
$d = ORM::for_table('tbl_users')->where('root', $admin['id'])->offset($paginator['startpoint'])->limit($paginator['limit'])->order_by_asc('id')->find_many();
|
$d = ORM::for_table('tbl_users')
|
||||||
|
->where_any_is([
|
||||||
|
['id' => $admin['id']],
|
||||||
|
['root' => $admin['id']]
|
||||||
|
])
|
||||||
|
->offset($paginator['startpoint'])->limit($paginator['limit'])->order_by_asc('id')->find_many();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -408,5 +408,8 @@
|
|||||||
"SuperAdmin": "SuperAdmin",
|
"SuperAdmin": "SuperAdmin",
|
||||||
"Admin": "Admin",
|
"Admin": "Admin",
|
||||||
"Report": "Report",
|
"Report": "Report",
|
||||||
"Agent": "Agent"
|
"Agent": "Agent",
|
||||||
|
"Send To Customer": "Send To Customer",
|
||||||
|
"Code": "Code",
|
||||||
|
"Generated By": "Generated By"
|
||||||
}
|
}
|
@ -4,11 +4,13 @@
|
|||||||
<div class="col-sm-12">
|
<div class="col-sm-12">
|
||||||
<div class="panel panel-hovered mb20 panel-primary">
|
<div class="panel panel-hovered mb20 panel-primary">
|
||||||
<div class="panel-heading">
|
<div class="panel-heading">
|
||||||
|
{if in_array($_admin['user_type'],['SuperAdmin','Admin'])}
|
||||||
<div class="btn-group pull-right">
|
<div class="btn-group pull-right">
|
||||||
<a class="btn btn-primary btn-xs" title="save" href="{$_url}customers/csv"
|
<a class="btn btn-primary btn-xs" title="save" href="{$_url}customers/csv"
|
||||||
onclick="return confirm('This will export to CSV?')"><span
|
onclick="return confirm('This will export to CSV?')"><span class="glyphicon glyphicon-download"
|
||||||
class="glyphicon glyphicon-download" aria-hidden="true"></span> CSV</a>
|
aria-hidden="true"></span> CSV</a>
|
||||||
</div>
|
</div>
|
||||||
|
{/if}
|
||||||
{Lang::T('Manage Contact')}
|
{Lang::T('Manage Contact')}
|
||||||
</div>
|
</div>
|
||||||
<div class="panel-body">
|
<div class="panel-body">
|
||||||
|
@ -21,6 +21,7 @@
|
|||||||
<table width="200">
|
<table width="200">
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
|
{if $content}<pre style="border-style: none; background-color: white;">{$content}</pre>{else}
|
||||||
<pre style="border-style: none; background-color: white;"><b>{Lang::pad($_c['CompanyName'],' ', 2)}</b>
|
<pre style="border-style: none; background-color: white;"><b>{Lang::pad($_c['CompanyName'],' ', 2)}</b>
|
||||||
{Lang::pad($_c['address'],' ', 2)}
|
{Lang::pad($_c['address'],' ', 2)}
|
||||||
{Lang::pad($_c['phone'],' ', 2)}
|
{Lang::pad($_c['phone'],' ', 2)}
|
||||||
@ -42,6 +43,7 @@
|
|||||||
{/if}
|
{/if}
|
||||||
{Lang::pad("", '=')}
|
{Lang::pad("", '=')}
|
||||||
{Lang::pad($_c['note'],' ', 2)}</pre>
|
{Lang::pad($_c['note'],' ', 2)}</pre>
|
||||||
|
{/if}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
@ -5,7 +5,9 @@
|
|||||||
<div class="panel panel-hovered panel-primary panel-stacked mb30">
|
<div class="panel panel-hovered panel-primary panel-stacked mb30">
|
||||||
<div class="panel-heading">{$in['invoice']}</div>
|
<div class="panel-heading">{$in['invoice']}</div>
|
||||||
<div class="panel-body">
|
<div class="panel-body">
|
||||||
<pre><b>{Lang::pad($_c['CompanyName'],' ', 2)}</b>
|
<form class="form-horizontal" method="post" action="{$_url}prepaid/print" target="_blank">
|
||||||
|
<pre id="content"></pre>
|
||||||
|
<textarea class="hidden" id="formcontent" name="content">{Lang::pad($_c['CompanyName'],' ', 2)}
|
||||||
{Lang::pad($_c['address'],' ', 2)}
|
{Lang::pad($_c['address'],' ', 2)}
|
||||||
{Lang::pad($_c['phone'],' ', 2)}
|
{Lang::pad($_c['phone'],' ', 2)}
|
||||||
{Lang::pad("", '=')}
|
{Lang::pad("", '=')}
|
||||||
@ -25,8 +27,7 @@
|
|||||||
{Lang::pads(Lang::T('Expires On'), Lang::dateAndTimeFormat($in['expiration'],$in['time']), ' ')}
|
{Lang::pads(Lang::T('Expires On'), Lang::dateAndTimeFormat($in['expiration'],$in['time']), ' ')}
|
||||||
{/if}
|
{/if}
|
||||||
{Lang::pad("", '=')}
|
{Lang::pad("", '=')}
|
||||||
{Lang::pad($_c['note'],' ', 2)}</pre>
|
{Lang::pad($_c['note'],' ', 2)}</textarea>
|
||||||
<form class="form-horizontal" method="post" action="{$_url}prepaid/print" target="_blank">
|
|
||||||
<input type="hidden" name="id" value="{$in['id']}">
|
<input type="hidden" name="id" value="{$in['id']}">
|
||||||
<a href="{$_url}prepaid/list" class="btn btn-primary btn-sm"><i
|
<a href="{$_url}prepaid/list" class="btn btn-primary btn-sm"><i
|
||||||
class="ion-reply-all"></i>{Lang::T('Finish')}</a>
|
class="ion-reply-all"></i>{Lang::T('Finish')}</a>
|
||||||
@ -35,19 +36,12 @@
|
|||||||
<button type="submit" class="btn btn-default btn-sm"><i class="fa fa-print"></i>
|
<button type="submit" class="btn btn-default btn-sm"><i class="fa fa-print"></i>
|
||||||
{Lang::T('Click Here to Print')}</button>
|
{Lang::T('Click Here to Print')}</button>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
var s5_taf_parent = window.location;
|
var s5_taf_parent = window.location;
|
||||||
|
document.getElementById('content').innerHTML = document.getElementById('formcontent').innerHTML;
|
||||||
function popup_print() {
|
|
||||||
window.open('print.php?page=<?php echo $_GET['
|
|
||||||
act '];?>', 'page',
|
|
||||||
'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=800,height=600,left=50,top=50,titlebar=yes'
|
|
||||||
)
|
|
||||||
}
|
|
||||||
</script>
|
</script>
|
||||||
{include file="sections/footer.tpl"}
|
{include file="sections/footer.tpl"}
|
@ -4,6 +4,7 @@
|
|||||||
<div class="col-sm-12">
|
<div class="col-sm-12">
|
||||||
<div class="panel panel-hovered mb20 panel-primary">
|
<div class="panel panel-hovered mb20 panel-primary">
|
||||||
<div class="panel-heading">
|
<div class="panel-heading">
|
||||||
|
{if in_array($_admin['user_type'],['SuperAdmin','Admin'])}
|
||||||
<div class="btn-group pull-right">
|
<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}prepaid/sync"
|
||||||
onclick="return confirm('This will sync/send Caustomer active plan to Mikrotik?')"><span
|
onclick="return confirm('This will sync/send Caustomer active plan to Mikrotik?')"><span
|
||||||
@ -11,9 +12,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="btn-group pull-right">
|
<div class="btn-group pull-right">
|
||||||
<a class="btn btn-info btn-xs" title="save" href="{$_url}customers/csv"
|
<a class="btn btn-info btn-xs" title="save" href="{$_url}customers/csv"
|
||||||
onclick="return confirm('This will export to CSV?')"><span
|
onclick="return confirm('This will export to CSV?')"><span class="glyphicon glyphicon-download"
|
||||||
class="glyphicon glyphicon-download" aria-hidden="true"></span> CSV</a>
|
aria-hidden="true"></span> CSV</a>
|
||||||
</div>{Lang::T('Prepaid Users')}
|
</div>
|
||||||
|
{/if}
|
||||||
|
{Lang::T('Prepaid Users')}
|
||||||
</div>
|
</div>
|
||||||
<div class="panel-body">
|
<div class="panel-body">
|
||||||
<div class="md-whiteframe-z1 mb20 text-center" style="padding: 15px">
|
<div class="md-whiteframe-z1 mb20 text-center" style="padding: 15px">
|
||||||
@ -63,9 +66,11 @@
|
|||||||
<td>
|
<td>
|
||||||
<a href="{$_url}prepaid/edit/{$ds['id']}"
|
<a href="{$_url}prepaid/edit/{$ds['id']}"
|
||||||
class="btn btn-warning btn-xs">{Lang::T('Edit')}</a>
|
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}prepaid/delete/{$ds['id']}" id="{$ds['id']}"
|
||||||
onclick="return confirm('{Lang::T('Delete')}?')"
|
onclick="return confirm('{Lang::T('Delete')}?')"
|
||||||
class="btn btn-danger btn-xs"><i class="glyphicon glyphicon-trash"></i></a>
|
class="btn btn-danger btn-xs"><i class="glyphicon glyphicon-trash"></i></a>
|
||||||
|
{/if}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
{/foreach}
|
{/foreach}
|
||||||
|
@ -55,7 +55,7 @@
|
|||||||
<td>
|
<td>
|
||||||
<a href="{$_url}settings/users-edit/{$ds['id']}"
|
<a href="{$_url}settings/users-edit/{$ds['id']}"
|
||||||
class="btn btn-info btn-xs">{Lang::T('Edit')}</a>
|
class="btn btn-info btn-xs">{Lang::T('Edit')}</a>
|
||||||
{if ($_admin['username']) neq ($ds['username'])}
|
{if ($_admin['id']) neq ($ds['id'])}
|
||||||
<a href="{$_url}settings/users-delete/{$ds['id']}" id="{$ds['id']}"
|
<a href="{$_url}settings/users-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>
|
class="btn btn-danger btn-xs" onclick="return confirm('{Lang::T('Delete')}?')"><i class="glyphicon glyphicon-trash"></i></a>
|
||||||
{/if}
|
{/if}
|
||||||
|
27
ui/ui/voucher-view.tpl
Normal file
27
ui/ui/voucher-view.tpl
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
{include file="sections/header.tpl"}
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<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">
|
||||||
|
<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-primary btn-sm"><i
|
||||||
|
class="ion-reply-all"></i>{Lang::T('Finish')}</a>
|
||||||
|
<a href="https://api.whatsapp.com/send/?text={$wa}" target="_blank" class="btn btn-info text-black btn-sm"><i
|
||||||
|
class="glyphicon glyphicon-envelope"></i> {Lang::T("Send To Customer")}</a>
|
||||||
|
<button type="submit" class="btn btn-default btn-sm"><i class="fa fa-print"></i>
|
||||||
|
{Lang::T('Click Here to Print')}</button>
|
||||||
|
</form>
|
||||||
|
<javascript type="text/javascript">
|
||||||
|
</javascript>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<script type="text/javascript">
|
||||||
|
document.getElementById('content').innerHTML = document.getElementById('formcontent').innerHTML;
|
||||||
|
</script>
|
||||||
|
{include file="sections/footer.tpl"}
|
@ -4,10 +4,13 @@
|
|||||||
<div class="col-sm-12">
|
<div class="col-sm-12">
|
||||||
<div class="panel panel-hovered mb20 panel-primary">
|
<div class="panel panel-hovered mb20 panel-primary">
|
||||||
<div class="panel-heading">
|
<div class="panel-heading">
|
||||||
|
{if in_array($_admin['user_type'],['SuperAdmin','Admin'])}
|
||||||
<div class="btn-group pull-right">
|
<div class="btn-group pull-right">
|
||||||
<a class="btn btn-danger btn-xs" title="Remove used Voucher" href="{$_url}prepaid/remove-voucher" onclick="return confirm('Delete all used voucher code?')"><span
|
<a class="btn btn-danger btn-xs" title="Remove used Voucher" href="{$_url}prepaid/remove-voucher"
|
||||||
|
onclick="return confirm('Delete all used voucher code?')"><span
|
||||||
class="glyphicon glyphicon-trash" aria-hidden="true"></span> Delete All</a>
|
class="glyphicon glyphicon-trash" aria-hidden="true"></span> Delete All</a>
|
||||||
</div>
|
</div>
|
||||||
|
{/if}
|
||||||
{Lang::T('Prepaid Vouchers')}
|
{Lang::T('Prepaid Vouchers')}
|
||||||
</div>
|
</div>
|
||||||
<div class="panel-body">
|
<div class="panel-body">
|
||||||
@ -50,6 +53,7 @@
|
|||||||
<th>{Lang::T('Code Voucher')}</th>
|
<th>{Lang::T('Code Voucher')}</th>
|
||||||
<th>{Lang::T('Status Voucher')}</th>
|
<th>{Lang::T('Status Voucher')}</th>
|
||||||
<th>{Lang::T('Customer')}</th>
|
<th>{Lang::T('Customer')}</th>
|
||||||
|
<th>{Lang::T('Generated By')}</th>
|
||||||
<th>{Lang::T('Manage')}</th>
|
<th>{Lang::T('Manage')}</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
@ -67,11 +71,27 @@
|
|||||||
<td align="center">{if $ds['status'] eq '0'} <label class="btn-tag btn-tag-success">Not
|
<td align="center">{if $ds['status'] eq '0'} <label class="btn-tag btn-tag-success">Not
|
||||||
Use</label> {else} <label class="btn-tag btn-tag-danger">Used</label>
|
Use</label> {else} <label class="btn-tag btn-tag-danger">Used</label>
|
||||||
{/if}</td>
|
{/if}</td>
|
||||||
<td align="center">{if $ds['user'] eq '0'} - {else}<a href="{$_url}customers/viewu/{$ds['user']}">{$ds['user']}</a>{/if}</td>
|
<td align="center">{if $ds['user'] eq '0'} -
|
||||||
|
{else}<a href="{$_url}customers/viewu/{$ds['user']}">{$ds['user']}</a>
|
||||||
|
{/if}</td>
|
||||||
|
<td align="center">{if $ds['generated_by']}
|
||||||
|
<a
|
||||||
|
href="{$_url}settings/users-edit/{$ds['generated_by']}">{$admins[$ds['generated_by']]}</a>
|
||||||
|
{else} -
|
||||||
|
{/if}
|
||||||
|
</td>
|
||||||
<td>
|
<td>
|
||||||
|
{if $ds['status'] neq '1'}
|
||||||
|
<a href="{$_url}prepaid/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}prepaid/voucher-delete/{$ds['id']}" id="{$ds['id']}"
|
||||||
class="btn btn-danger btn-xs"
|
class="btn btn-danger btn-xs"
|
||||||
onclick="return confirm('{Lang::T('Delete')}?')"><i class="glyphicon glyphicon-trash"></i></a>
|
onclick="return confirm('{Lang::T('Delete')}?')"><i
|
||||||
|
class="glyphicon glyphicon-trash"></i></a>
|
||||||
|
{/if}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
{/foreach}
|
{/foreach}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user