testing with new mates

This commit is contained in:
saravanakumar_kandasami 2017-04-18 17:48:06 +05:30
parent 556b4de2c1
commit 5f2ca2c853
4 changed files with 233 additions and 19 deletions

View File

@ -0,0 +1,55 @@
<?php if(!defined('BASEPATH')) exit('No direct script access allowed');
require APPPATH . '/libraries/BaseController.php';
/**
* Class : Employee (Employee Controller)
* User Class to control all user related operations.
* @author : Gandhimathi
* @version : 1.1
* @since : 07 Apr 2017
*/
class payslip extends BaseController
{
/**
* This is default constructor of the class
*/
public function __construct()
{
parent::__construct();
$this->load->model('employeedetails_model');
$this->isLoggedIn();
}
/**
* This function used to load the first screen of the user
*/
public function index()
{
}
function payslipupload()
{
$this->global['pageTitle'] = 'Siddharth : PaySlip Upload';
$this->loadViews("payslipupload", $this->global, NULL);
}
function payslipgenerate()
{
$this->global['pageTitle'] = 'Siddharth : PaySlip Generator';
$this->loadViews("payslipgenerate", $this->global, NULL);
}
function pageNotFound()
{
$this->global['pageTitle'] = 'CodeInsect : 404 - Page Not Found';
$this->loadViews("404", $this->global, NULL, NULL);
}
}
?>

View File

@ -115,7 +115,11 @@
<ul class="dropdown-menu" role="menu" aria-labelledby="menu1">
<?php
if($role == ROLE_ADMIN || $role == ROLE_MANAGER || $role == ROLE_SALES)
if($role == ROLE_ADMIN || $role == ROLE_MANAGER || $role == ROLE_SALES || $role == ROLE_ACCOUNTS )
{
?>
<?php
if($role != ROLE_ACCOUNTS )
{
?>
<li class="treeview">
@ -124,12 +128,26 @@
<span class="nav-label">Supplier Details</span>
</a>
</li>
<?php
}
?>
<?php
if($role == ROLE_ADMIN || $role == ROLE_ACCOUNTS )
{
?>
<li class="treeview">
<a href="<?php echo base_url(); ?>costListing" >
<i class="fa fa-cart-plus"></i>
<span class="nav-label">Cost Details</span>
</a>
</li>
<?php
}
?>
<?php
if($role != ROLE_ACCOUNTS )
{
?>
<li class="treeview">
<a href="<?php echo base_url(); ?>assetListing" >
<i class="fa fa-cogs"></i>
@ -137,6 +155,9 @@
</a>
</li>
<?php
}
?>
<?php
if($role == ROLE_ADMIN)
{
?>
@ -148,7 +169,11 @@
</li>
<?php
}
?>
?>
<?php
if($role != ROLE_ACCOUNTS )
{
?>
<li class="treeview">
<a href="<?php echo base_url();?>rawmaterialListing" >
<i class="fa fa-files-o"></i>
@ -157,6 +182,9 @@
</li>
<?php
}
?>
<?php
}
if($role == ROLE_ADMIN )
{
?>
@ -172,24 +200,54 @@
?>
</ul>
</li>
<li class="treeview">
<span id="menu" data-toggle="dropdown" ><i class="fa fa-thumb-tack"></i> Requisition<span class="caret"></span></span>
<ul class="dropdown-menu" role="menu" aria-labelledby="menu2">
<li class="treeview">
<a href="<?php echo base_url(); ?>requisitionform/requisition">
<i class="fa fa-users"></i>
<span>Requisition Form</span>
</a>
</li>
<?php
if($role != ROLE_ACCOUNTS)
{
?>
<li class="treeview">
<span id="menu" data-toggle="dropdown" ><i class="fa fa-thumb-tack"></i> Requisition<span class="caret"></span></span>
<ul class="dropdown-menu" role="menu" aria-labelledby="menu2">
<li class="treeview">
<a href="<?php echo base_url(); ?>requisitionlist/requisition">
<i class="fa fa-users"></i>
<span>Requisition List</span>
</a>
</li>
</ul>
</li>
<a href="<?php echo base_url(); ?>requisitionform/requisition">
<i class="fa fa-users"></i>
<span>Requisition Form</span>
</a>
</li>
<li class="treeview">
<a href="<?php echo base_url(); ?>requisitionlist/requisition">
<i class="fa fa-users"></i>
<span>Requisition List</span>
</a>
</li>
</ul>
</li>
<?php
}
?>
<?php
if($role == ROLE_ACCOUNTS)
{
?>
<li class="treeview">
<span id="menu" data-toggle="dropdown" ><i class="fa fa-thumb-tack"></i> PaySlip Generate<span class="caret"></span></span>
<ul class="dropdown-menu" role="menu" aria-labelledby="menu2">
<li class="treeview">
<a href="<?php echo base_url(); ?>payslip/payslipupload">
<i class="fa fa-upload"></i>
<span>Upload Salary</span>
</a>
</li>
<li class="treeview">
<a href="<?php echo base_url(); ?>payslip/payslipgenerate">
<i class="fa fa-money"></i>
<span>PaySlip Generator</span>
</a>
</li>
</ul>
</li>
<?php
}
?>
<?php
if($role == ROLE_ADMIN)
{

View File

@ -0,0 +1,3 @@
<h1>
PaySlip Generator
</h1>

View File

@ -0,0 +1,98 @@
<div class="content-wrapper">
<!-- Content Header (Page header) -->
<section class="content-header">
<h1>
<center>Siddharth Industries PaySlip Upload</center>
</h1>
</section>
<section class="content">
<div class="row">
<div class="col-xs-12 text-right">
<div class="form-group">
<a class="btn btn-info" href="<?php echo base_url(); ?>addsupplier">Add New Supplier</a>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-12">
<div class="box">
<div class="box-header">
<center><h3 class="box-title"></h3></center>
<div class="box-tools">
<form action="<?php echo base_url() ?>supplierListing" method="POST" id="searchList">
<div class="input-group">
<input type="text" name="searchText" value="<?php echo $searchText; ?>" class="form-control input-sm pull-right" style="width: 150px;" placeholder="Search"/>
<div class="input-group-btn">
<button class="btn btn-sm btn-default searchList"><i class="fa fa-search"></i></button>
</div>
</div>
</form>
</div>
</div><!-- /.box-header -->
<div class="box-body table-responsive no-padding" >
<table id="datatable" class="table table-hover tableSorter" >
<tr bgcolor="steelblue" >
<th >Supplier ID</th>
<th>Supplier Name</th>
<th>Address</th>
<th>Contact Number</th>
<th>Email Address</th>
<th>Excise Registration</th>
<th>TIN</th>
<th>PAN</th>
<th>GST Number</th>
<th>GST Range</th>
<th>UA Number</th>
<th>Payment Terms</th>
</tr>
<?php
if(!empty($userRecords))
{
foreach($userRecords as $record)
{
?>
<tr>
<td><u><a href="<?php echo base_url().'supplier/viewsupplier/?SID='.$record->SupplierID.'&Payment='.$record->PaymentTerms ?>" data-toggle="tooltip" title="<?php echo $record->SupplierID; ?> - Click here to view Supplier details"><?php echo $record->SupplierID ?> </a></u></td>
<td><?php echo $record->SupplierName ?></td>
<td><?php echo $record->Address ?></td>
<td><?php echo $record->ContactNumber ?></td>
<td><?php echo $record->EmailAddress ?></td>
<td><?php echo $record->Exiseregistration ?></td>
<td><?php echo $record->TIN ?></td>
<td><?php echo $record->PAN ?></td>
<td><?php echo $record->GSTNO ?></td>
<td><?php echo $record->GSTRange ?></td>
<td><?php echo $record->UANumber ?></td>
<td><?php echo $record->PaymentTerms ?></td>
</tr>
<?php
}
}
?>
</table>
</div><!-- /.box-body -->
<div class="box-footer clearfix">
<?php echo $this->pagination->create_links(); ?>
</div>
</div><!-- /.box -->
</div>
</div>
</section>
</div>
<script type="text/javascript" src="<?php echo base_url(); ?>assets/js/common.js" charset="utf-8"></script>
<script type="text/javascript">
jQuery(document).ready(function(){
jQuery('ul.pagination li a').click(function (e) {
e.preventDefault();
var link = jQuery(this).get(0).href;
var value = link.substring(link.lastIndexOf('/') + 1);
jQuery("#searchList").attr("action", baseURL + "supplierListing/" + value);
jQuery("#searchList").submit();
});
});
</script>