diff --git a/application/controllers/payslip.php b/application/controllers/payslip.php index f1f9d360..fe5fbcfa 100755 --- a/application/controllers/payslip.php +++ b/application/controllers/payslip.php @@ -486,12 +486,12 @@ function getEmployee() $EmpId = $sheet->getCell('A'.$x)->getValue(); $EmpId=strtoupper($EmpId); - $LOPDays = $sheet->getCell('B'.$x)->getValue(); - $OTHoursWorked =$sheet->getCell('C'.$x)->getValue(); - $loanRecovered=$sheet->getCell('D'.$x)->getValue(); + $LOPDays = $sheet->getCell('C'.$x)->getValue(); + $OTHoursWorked =$sheet->getCell('D'.$x)->getValue(); + $loanRecovered=$sheet->getCell('E'.$x)->getValue(); //$loanBalance=$sheet->getCell('E'.$x)->getValue(); - $Incentive =$sheet->getCell('E'.$x)->getValue(); - $Other_Deductions =$sheet->getCell('F'.$x)->getValue(); + $Incentive =$sheet->getCell('F'.$x)->getValue(); + $Other_Deductions =$sheet->getCell('G'.$x)->getValue(); if( $EmpId != '') { diff --git a/application/models/emppaydate_model.php b/application/models/emppaydate_model.php index 786d30b8..342caee8 100755 --- a/application/models/emppaydate_model.php +++ b/application/models/emppaydate_model.php @@ -50,8 +50,9 @@ class emppaydate_model extends CI_Model function emppayListing($searchText = '', $page, $segment) { - $this->db->select('*'); + $this->db->select('T_Emp_Pay_Data.*,T_Employee_Details.FirstName,T_Employee_Details.LastName'); $this->db->from('T_Emp_Pay_Data'); + $this->db->join('T_Employee_Details','T_Emp_Pay_Data.EmpID=T_Employee_Details.EmpID'); if(!empty($searchText)) { @@ -98,11 +99,12 @@ class emppaydate_model extends CI_Model } function getUserInfo($paydataid) { - $this->db->select(); + $this->db->select('T_Emp_Pay_Data.*,T_Employee_Details.FirstName,T_Employee_Details.LastName'); $this->db->from('T_Emp_Pay_Data'); + $this->db->join('T_Employee_Details','T_Emp_Pay_Data.EmpID=T_Employee_Details.EmpID'); //$this->db->where('isDeleted', 0); //$this->db->where('roleId !=', 1); - $this->db->where('Pay_Data_ID', $paydataid); + $this->db->where('T_Emp_Pay_Data.Pay_Data_ID', $paydataid); $query = $this->db->get(); //print_r($query->result()); //die(); diff --git a/application/models/monthlypay_model.php b/application/models/monthlypay_model.php index 409d940a..21eaf321 100755 --- a/application/models/monthlypay_model.php +++ b/application/models/monthlypay_model.php @@ -41,8 +41,10 @@ class monthlypay_model extends CI_Model */ function monthlyListing($searchText = '', $page, $segment) { - $this->db->select('*'); + $this->db->select('T_Monthly_Pay_Inputs.*,T_Employee_Details.FirstName,T_Employee_Details.LastName'); $this->db->from('T_Monthly_Pay_Inputs'); + $this->db->join('T_Employee_Details','T_Monthly_Pay_Inputs.EmpID=T_Employee_Details.EmpID'); + //$this->db->where('month.EmpID=mast.EmpID'); $this->db->order_by("Month_Year", "desc"); @@ -57,7 +59,7 @@ class monthlypay_model extends CI_Model OR Other_Deductions LIKE '%".$searchText."%' )"; - $this->db->where($likeCriteria); + $this->db->where('T_Monthly_Pay_Inputs.EmpID',$likeCriteria); } $this->db->limit($page, $segment); @@ -82,12 +84,13 @@ function addNewmonthlisting($m_list) } function getUserInfo($EmpID,$month_year) { - $this->db->select('Month_Year, EmpID, LOP_Days, OT_Hrs_Worked, Loan_Recovered,Incentives, Other_Deductions, Created_By, Created_Time, Last_Mod_By, Last_Mod_Time'); + $this->db->select('T_Monthly_Pay_Inputs.*,T_Employee_Details.FirstName,T_Employee_Details.LastName'); $this->db->from('T_Monthly_Pay_Inputs'); + $this->db->join('T_Employee_Details','T_Monthly_Pay_Inputs.EmpID=T_Employee_Details.EmpID'); //$this->db->where('isDeleted', 0); //$this->db->where('roleId !=', 1); - $this->db->where('EmpID', $EmpID); - $this->db->where('Month_Year', $month_year); + $this->db->where('T_Monthly_Pay_Inputs.EmpID', $EmpID); + $this->db->where('T_Monthly_Pay_Inputs.Month_Year', $month_year); $query = $this->db->get(); return $query->result(); diff --git a/application/views/editOldemppay.php b/application/views/editOldemppay.php index 740dcd17..7344676a 100755 --- a/application/views/editOldemppay.php +++ b/application/views/editOldemppay.php @@ -48,6 +48,7 @@ if (loan == paid) $Pay_Data_ID=''; $EmpID=''; + $Empname=""; $Basic_Pay=''; $HRA_Rate=''; $OT_Rate=''; @@ -82,6 +83,7 @@ if(!empty($emppay)) $Pay_Data_ID=$ep->Pay_Data_ID; $EmpID=$ep->EmpID; + $Empname=$ep->FirstName ." ". $ep->LastName ; $TotalSalary=$ep->TotalSalary; $Basic_Pay=$ep->Basic_Pay; $HRA_Rate=$ep->HRA_Rate; @@ -167,9 +169,25 @@ if(!empty($emppay)) + +
+
+
+ Employee Name + +
+
+
-
+ + +
+ + +
+ +
Total Salary* @@ -177,11 +195,6 @@ if(!empty($emppay))
- -
- - -
@@ -201,14 +214,7 @@ if(!empty($emppay))
-
-
-
- HRA_Amount* - -
-
-
+ @@ -221,6 +227,16 @@ if(!empty($emppay))
+ +
+
+
+ HRA_Amount* + +
+
+
+
@@ -238,6 +254,8 @@ if(!empty($emppay))
+
+
@@ -265,6 +283,8 @@ if(!empty($emppay))
+ +
Loan Details @@ -422,7 +442,7 @@ if(!empty($emppay)) { ?>
- + session->flashdata('error'); ?>
@@ -432,14 +452,14 @@ if(!empty($emppay)) { ?>
- + session->flashdata('success'); ?>
- ', '
'); ?> + ', '
'); ?>
@@ -498,6 +518,7 @@ function duecalculation() var noofdues=document.getElementById('no_of_due').value; $('#remaining_due').val(noofdues); $("#paid_due").val(0); + $("#Paid_Amount").val(0); diff --git a/application/views/editOldmonthly.php b/application/views/editOldmonthly.php index f259510d..73ebd599 100755 --- a/application/views/editOldmonthly.php +++ b/application/views/editOldmonthly.php @@ -4,6 +4,7 @@ $Month_Year=''; $EmpID=''; + $Empname=''; $LOP_Days=''; $OT_Hrs_Worked=''; $Loan_Recovered=''; @@ -23,6 +24,7 @@ if(!empty($monthly)) $Month_Year=$mpi->Month_Year; $EmpID= $mpi->EmpID; + $Empname=$mpi->FirstName ." ". $mpi->LastName; $LOP_Days=$mpi->LOP_Days; $OT_Hrs_Worked=$mpi->OT_Hrs_Worked; $Loan_Recovered=$mpi->Loan_Recovered; @@ -73,7 +75,7 @@ else{ } } -function validateLR(){ +function validateL(){ var x = $("#Loan_Recovered").val(); var ck_lopdays = /^[0-9]{1,6}([.][0-9]{1,2})?$/; @@ -179,7 +181,7 @@ function validateAll(){
-
+
Month Year: @@ -192,19 +194,27 @@ function validateAll(){ -
+
Employee ID:
+
+
+
+
+ Employee Name: + +
+
-
+
LOP Days: @@ -216,31 +226,33 @@ function validateAll(){ -
+
OverTime Hours Worked:
+
+ +
+
+
+ Loan Recovered: + +
+
- +
-
-
-
- Loan Recovered: - -
-
-
+ -
+
Incentives: @@ -248,26 +260,7 @@ function validateAll(){
- - - -
- - - - -
- - - -
+
Other Deductions: @@ -275,10 +268,7 @@ function validateAll(){
-
- - - +
diff --git a/application/views/emppayListing.php b/application/views/emppayListing.php index 96845f28..fea4df3d 100755 --- a/application/views/emppayListing.php +++ b/application/views/emppayListing.php @@ -36,6 +36,7 @@ Pay Data ID Employee ID + Employee Name Total Salary Basic Pay HRA Rate @@ -61,6 +62,7 @@ Pay_Data_ID ?> EmpID ?> + FirstName ." ". $record->LastName?> TotalSalary,0,'',''); ?> Basic_Pay ?> HRA_Rate ?> diff --git a/application/views/monthlyListing.php b/application/views/monthlyListing.php index 351ac1de..a60cb82f 100755 --- a/application/views/monthlyListing.php +++ b/application/views/monthlyListing.php @@ -49,6 +49,7 @@ speed:500 Month Year Employee Id + Employee Name LOP Days OT Hours Worked Loan Recovered @@ -69,6 +70,7 @@ speed:500 Month_Year ?> EmpID ?> + FirstName ." ". $record->LastName ?> LOP_Days ?> OT_Hrs_Worked ?> Loan_Recovered ?> diff --git a/application/views/payslipgenerateprint.php b/application/views/payslipgenerateprint.php index b67626f9..55e3ea60 100755 --- a/application/views/payslipgenerateprint.php +++ b/application/views/payslipgenerateprint.php @@ -1,5 +1,78 @@ - '', '1' => 'One', '2' => 'Two', + '3' => 'Three', '4' => 'Four', '5' => 'Five', '6' => 'Six', + '7' => 'Seven', '8' => 'Eight', '9' => 'Nine', + '10' => 'Ten', '11' => 'Eleven', '12' => 'Twelve', + '13' => 'Thirteen', '14' => 'Fourteen', + '15' => 'Fifteen', '16' => 'Sixteen', '17' => 'Seventeen', + '18' => 'Eighteen', '19' =>'Nineteen', '20' => 'Twenty', + '30' => 'Thirty', '40' => 'Forty', '50' => 'Fifty', + '60' => 'Sixty', '70' => 'Seventy', + '80' => 'Eighty', '90' => 'Ninety'); + $digits = array('', 'Hundred', 'Thousand', 'Lakh', 'Crore'); + while ($i < $digits_1) { + $divider = ($i == 2) ? 10 : 100; + $number = floor($no % $divider); + $no = floor($no / $divider); + $i += ($divider == 10) ? 1 : 2; + if ($number) { + $plural = (($counter = count($str)) && $number > 9) ? 's' : null; + $hundred = ($counter == 1 && $str[0]) ? ' and ' : null; + $str [] = ($number < 21) ? $words[$number] . + " " . $digits[$counter] . $plural . " " . $hundred + : + $words[floor($number / 10) * 10] + . " " . $words[$number % 10] . " " + . $digits[$counter] . $plural . " " . $hundred; + } else $str[] = null; + } + $str = array_reverse($str); + $result = implode('', $str); + + $points = ($point) ? + " " . $words[$point / 10] . " " . + $words[$point = $point % 10] : ''; + +if($ShowPaise=='0'){ + +$amountInWords = "Rupees " . $result." Only"; +} +else{ + +$amountInWords = "Rupees " . $result ." Paise ". $points." Only"; +} + + + return $amountInWords; + } +?> +format('d-m-y'); - $DateofJoining = $dt ->format('d-m-y'); + $DateofBirth = $from ->format('d-m-Y'); + $DateofJoining = $dt ->format('d-m-Y'); $Designation = $Pay->Designation; $PANNo =$Pay->Pan; @@ -80,6 +154,7 @@ if(!empty($PayDetails)) $TotalNoofDays = $Pay->TotalNoofDays; $NoOfWorkingdays =$Pay->NoofDaysWorked; $ActualSalary = $Pay->ActualSalary; + $LOP=$Pay->LOP; $PerDaySalary = $Pay->PerDaySalary; $WorkedSalary = $Pay->WorkedSalary; $BasicAndDA = $Pay->BasicPlusDA; @@ -172,126 +247,130 @@ if($RecCount > 0) ?> - - - - - - -
-
-
-

Siddharth Industries

Survey No: 168/1C3,Pennalur Pet Road,Goonipalyam village,
Uthukottai Taluk,Tiruvallur Dist, Chennai,Tamilnadu,Pin code : 602026.

PaySlip for the month -
-
+ - + + + +
+
+
+
SIDDHARTH INDUSTRIES
Survey No: 168/1C3,Pennalur Pet Road,Goonipalyam village,
Uthukottai Taluk,Tiruvallur Dist, Chennai,Tamilnadu,Pin code : 602026.
PaySlip for the month of
+
- - - - + + + + - - - - + + + + - - - - + + + + - - - - + + + + - - - - + + + + - - - - + + + + + - - - - + + + + - - - - + + + + - - + + + +
Name :Employee ID :Name Employee ID
Desigination : Department :Designation Department
Date Of Joining : Days Worked :Date Of Joining Available Calender Days
Date Of Birth :No Of Working Days: Date Of Birth Loss Of Pay Days
PF Account Number :Loan Balance :PF Account Number Paid Days
Bank Name :OT in Hours:Bank Name Loan Balance
Bank IFSC :ESI Account Number : Bank Account Number OT In Hours
Bank Account Number : UAN Number : Bank IFSC ESI Account Number
PAN Number :PAN Number Aadhar Number
- - +
EarningsAmountDeductionsAmount
+ - - - - + + + + - - - - + + + + - - - - + + + + - - - - + + + + - - + + - - + + - - - - + + + + - - + + - + + + +
EarningsAmount in RsDeductionsAmount in Rs
Basic Plus DAProvident Fund Basic Plus DA  Provident Fund 
House Rent AllowanceEmployee State Insurance House Rent Allowance  Employee State Insurance  
Food AllowanceLoan Recovery Food Allowance   Loan Recovery  
Other AllowanceOther Deduction Other Allowance   Other Deduction  
Incentive Incentive  
OT Salary OT Salary  
Total Earning (Rounded) (TE)Total Deduction (Rounded)(TD)
 Total Earning (Rounded) (TE)   Total Deduction (Rounded)(TD)  
Net Pay (Rounded) : 
Net Pay (TE - TD)(Rounded)   
This is a computer generated document. This document does not require signature.
Total Amount In Words  
This is a computer generated document. This document does not require signature.
\ No newline at end of file