2024-07-10 12:43:19 +00:00
|
|
|
<div class="content-wrapper">
|
|
|
|
<div class="content">
|
|
|
|
<div class="container-fluid">
|
|
|
|
<div class="row">
|
|
|
|
<div class="col">
|
|
|
|
<div class="card card-primary card-outline">
|
|
|
|
<div class="card-header">
|
2024-08-09 06:08:11 +00:00
|
|
|
<h5 class="m-0"><?php echo $pageTitle; ?> <?php showCreateButton($this->uri->segment(1) . "/" . $this->uri->segment(2) . "/add", "Create New " . $pageTitle); ?></h5>
|
2024-07-10 12:43:19 +00:00
|
|
|
</div>
|
|
|
|
<div class="card-body ">
|
|
|
|
<?php $TableData = $this->db->query("select * from tbl_translations where status=1")->result(); ?>
|
2024-07-12 12:12:29 +00:00
|
|
|
<table class="table table-bordered table-striped longdataTable">
|
2024-07-10 12:43:19 +00:00
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th class="text-center col-1"><?php myLang('Translation Id'); ?></th>
|
2024-08-09 06:08:11 +00:00
|
|
|
<th class="text-center col-5"><?php myLang('English'); ?></th>
|
|
|
|
<th class="text-center col-5"><?php myLang('Nepali'); ?></th>
|
2024-07-10 12:43:19 +00:00
|
|
|
<th class="text-center col-1"><?php myLang('Action'); ?></th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
2024-08-09 06:08:11 +00:00
|
|
|
<?php $a = 0;
|
|
|
|
foreach ($TableData as $TableRow) : $a++; ?>
|
2024-07-10 12:43:19 +00:00
|
|
|
<?php foreach ($TableRow as $cols) : $id = $cols;
|
|
|
|
break;
|
|
|
|
endforeach; ?><tr>
|
|
|
|
<td class="text-center"><?php echo $TableRow->translation_id; ?></td>
|
|
|
|
<td><?php echo $TableRow->english; ?></td>
|
2024-08-09 06:08:11 +00:00
|
|
|
<td><?php echo $TableRow->nepali; ?></td>
|
2024-07-10 12:43:19 +00:00
|
|
|
<td class="text-center"><a href="<?php echo site_url($this->uri->segment(1) . "/" . $this->uri->segment(2) . "/edit/$id"); ?>" class="btn btn-info btn-xs"><i class="fas fa-edit"></i> Edit</a>
|
|
|
|
<a onClick="javascript:doDelete(<?php echo $id; ?>);" class="btn btn-danger btn-xs"><i class="fas fa-trash"></i> Delete</a>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<?php endforeach; ?>
|
|
|
|
<tbody>
|
|
|
|
</table>
|
|
|
|
<script>
|
|
|
|
function doDelete(id) {
|
|
|
|
if (confirm('Are you sure to delete?')) {
|
|
|
|
window.location = '<?php echo site_url($this->uri->segment(1) . "/" . $this->uri->segment(2) . "/delete/"); ?>' + id;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|