Commit d4b31384 authored by David Mburu's avatar David Mburu

Storing employee info

parent 8c98d41a
......@@ -120,6 +120,10 @@ class BranchController extends Controller
*/
public function destroy($id)
{
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
>>>>>>> Storing employee info
if(DB::table('branches')->where('id',$id)->exists()){
DB::table('branches')->where('id', $id)->delete();
return redirect('/branches')->with('success', 'Business Unit has been deleted Successfully');
......
This diff is collapsed.
......@@ -3,6 +3,10 @@
namespace App\Http\Controllers;
use Illuminate\Http\Request;
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
use DB;
>>>>>>> Storing employee info
class HomeController extends Controller
{
......@@ -23,6 +27,7 @@ class HomeController extends Controller
*/
public function index()
{
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
return view('home');
}
......@@ -34,4 +39,19 @@ class HomeController extends Controller
{
return view('Payslip.index');
}
=======
$employees=DB::table('employees')->get();
return view('home',compact(['employees']));
}
public function admin()
{
$employees=DB::table('employees')->get();
return view('Employees.index',compact('employees'));
}
public function manager()
{
return view('Payslip.index');
}
>>>>>>> Storing employee info
}
......@@ -18,6 +18,12 @@ class CreatePayFrequenciesTable extends Migration
$table->string('pay_frequency',30);
$table->string('payfrequency_code',20);
$table->text('description',250)->nullable();
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
>>>>>>> Storing employee info
$table->timestamps();
});
}
......
......@@ -20,6 +20,12 @@ class CreateEmergencyContactsTable extends Migration
$table->integer('phone_no');
$table->string('email')->unique();
$table->string('relation');
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
>>>>>>> Storing employee info
$table->timestamps();
});
}
......
......@@ -19,6 +19,12 @@ class CreateDependantsTable extends Migration
$table->string('name',50);
$table->date('dateofBirth');
$table->string('relation',15);
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
>>>>>>> Storing employee info
$table->timestamps();
});
}
......
......@@ -21,6 +21,12 @@ class CreateJobTitlesTable extends Migration
$table->string('job_paygrade_code',10);
$table->string('description')->nullable();
$table->integer('minimum_experience');
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
>>>>>>> Storing employee info
$table->timestamps();
});
}
......
......@@ -22,6 +22,12 @@ class CreateCertificatesTable extends Migration
$table->date('dateofIssuance');
$table->date('dateofExpiration')->nullable();
$table->string('certificateDocument');
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
>>>>>>> Storing employee info
$table->timestamps();
});
}
......
......@@ -19,6 +19,12 @@ class Managers extends Migration
$table->string('department');
$table->string('job_title_code',10);
$table->string('name');
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
>>>>>>> Storing employee info
$table->timestamps();
});
}
......
......@@ -17,6 +17,12 @@ class EmploymentStatus extends Migration
$table->increments('id');
$table->string('employment_status_code',10);
$table->string('employment_status');
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
>>>>>>> Storing employee info
$table->timestamps();
});
}
......
......@@ -19,6 +19,12 @@ class Roles extends Migration
$table->string('employment_status_code',10);
$table->string('role');
$table->string('description')->nullable();
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
>>>>>>> Storing employee info
$table->timestamps();
});
}
......
......@@ -30,9 +30,15 @@ class CreateEmployeesTable extends Migration
$table->date('date_of_joining');
$table->date('date_of_leaving')->nullable();
$table->integer('years_of_experience');
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
$table->integer('work_phone', 30)->nullable();
$table->integer('personal_phone', 30);
$table->integer('extension', 30)->nullable();
=======
$table->integer('work_phone')->nullable();
$table->integer('personal_phone');
$table->integer('extension')->nullable();
>>>>>>> Storing employee info
$table->string('kra_pin', 30);
$table->string('nssf_number', 30);
$table->string('nhif_number', 30);
......@@ -42,6 +48,12 @@ class CreateEmployeesTable extends Migration
$table->string('profile_image')->nullable();
$table->string('password')->nullable();
$table->boolean('isAdmin')->nullable();
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
$table->string('disability_type')->nullable();
$table->string('disability_description')->nullable();
$table->string('exemption_certificate')->nullable();
>>>>>>> Storing employee info
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->integer('is_active')->default(1);
......
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class EmployeePersonalInfoTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('employees_personal', function (Blueprint $table) {
$table->increments('id');
$table->integer('employee_id');
$table->string('marital_status');
$table->string('nationality');
$table->string('ethnicity')->nullable();
$table->string('identity_document');
$table->integer('identity_no')->nullable();
$table->string('language');
$table->string('blood_group');
$table->date('date_of_birth');
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('employees_personal');
}
}
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class EmployeeSalaryInfoTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('employees_salary', function (Blueprint $table) {
$table->increments('id');
$table->integer('employee_id');
$table->string('pay_frequency');
$table->string('pay_unit')->nullable();
$table->integer('salary_amount');
$table->string('bank_branch_name');
$table->string('bank_account_no');
$table->string('sacco_name')->nullable();
$table->string('sacco_account_no')->nullable();
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('employee_salary');
}
}
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class EmployeeContactInfoTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('employees_contacts', function (Blueprint $table) {
$table->increments('id');
$table->integer('employee_id');
$table->string('country', 255);
$table->string('county', 50)->nullable();
$table->string('city')->nullable();
$table->string('street_address')->nullable();
$table->string('postal_code')->nullable();
$table->string('current_country');
$table->string('current_county')->nullable();
$table->string('current_street_address')->nullable();
$table->string('current_constituency')->nullable();
$table->integer('created_by')->nullable();
$table->integer('modified_by')->nullable();
$table->tinyInteger('is_active')->default(1);
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('employee_contacts');
}
}
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
@section('title', 'Employees')
=======
@extends('Layout.employees_master')
@section('title', 'Employees')
>>>>>>> Storing employee info
@section('header-include')
<link rel="stylesheet" href="/js/select3/bootstrapselect.min.css" type="text/css"/>
<link rel="stylesheet" href="/js/select3/bootstrap.min.css" type="text/css"/>
<style>
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
form {
=======
form {
>>>>>>> Storing employee info
border-radius: 5px;
width:100%;
background-color: #FFFFFF;
......@@ -40,6 +51,21 @@
display:inline-inline;
margin-right: 10px;
}
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
.accordion {
background-color: #eee;
color: #444;
cursor: pointer;
padding: 18px;
width: 100%;
border: none;
text-align: left;
outline: none;
font-size: 15px;
transition: 0.4s;
}
>>>>>>> Storing employee info
.panel-row {
padding: 0 18px;
background-color: white;
......@@ -47,6 +73,7 @@
overflow: hidden;
transition: max-height 0.2s ease-out;
}
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
</style>
@endsection
......@@ -73,4 +100,123 @@
</div>
\ No newline at end of file
=======
ul {
list-style-type: none;
}
</style>
@endsection
@section('content')
<section id="content">
<section class="scrollable padder">
<ul class="breadcrumb no-border no-radius b-b b-light pull-in">
<li><a href="/kinetic"><i class="fa fa-home"></i> Home</a></li>
<li><a href="{{route('employees.index')}}">Employees</a></li>
<li><a href="{{route('employees.edit',$employee->id)}}">Edit Employees</a></li>
<li class="active">Contact</li>
</ul>
@include('Layout.errors')
@include('Layout.messages')
<div class="container-fluid" style="margin-bottom:0px;">
<div class=col-md-3 id=tabLinks style="width:13.5%">
<ul class="list-group">
<li class="list-group-item " ><a href="{{ route('employees.edit',$employee->id) }}">Employee Info</a></li>
<li class="list-group-item "><a href="{{route('personal',$employee->id)}}">Personal</a></li>
<li class="list-group-item "><a href="{{route('salary',$employee->id)}}">Salary</a></li>
<li class="list-group-item active"><a href="{{route('contact',$employee->id)}}">Contact</a></li>
</ul>
</div>
<div class=col-md-6 style="width:86.5%;">
<form method="post" action="{{ route('store_contact',$employee->id) }}" enctype="multipart/form-data" class="form-inline" style="padding-top:10px;">
{{ csrf_field() }}
<legend style="padding:5px 5px 5px 10px">Postal Address</legend>
<div class=row style="padding:0px 5px 5px 10px">
<div class=col-md-4 style="width:20%">
<p>Country <span>*</span></p>
<input name="country" type="text" class="form-control" id="country" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;"
required>
</div>
<div class=col-md-4 style="width:20%">
<p>State/County <span>*</span></p>
<input name="county" type="text" class="form-control" id="state" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;"
required>
</div>
<div class=col-md-4 style="width:20%">
<p>City <span>*</span></p>
<input name="city" type="text" class="form-control" id="city" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;"
required>
</div>
<div class=col-md-4 style="width:20%">
<p>Street Address <span>*</span></p>
<input name="street_address" type="text" class="form-control" id="streetaddress" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;"
required>
</div>
<div class=col-md-4 style="width:20%">
<p>Postal Code</p>
<input name="postal_code" type="text" class="form-control" id="postalcode" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;">
</div>
</div><!-- End of Postal Address row -->
<div class=row style="padding:0px 5px 5px 10px">
<legend style="padding:25px 5px 5px 10px">Current Address</legend>
<div class=col-md-4 style="width:20%">
<p>Country <span>*</span></p>
<select name="current_country" id="CurrentaddressCountry" class="dropup selectpicker" data-dropup--auto="false" data-live-search="true" style="width:15em;" onfocus='this.size=5;' onblur='this.size=1;' onchange='this.size=1; this.blur();'>
<option value="kenya">Kenya</option>
<option value="tanzania">Tanzania</option>
<option value="uganda">Uganda</option>
</select>
</div>
<div class=col-md-4 style="width:20%">
<p>State/County <span>*</span></p>
<select name="current_county" id="CurrentaddressCounty" class="dropup selectpicker" data-dropup--auto="false" data-live-search="true" style="width:15em;" onfocus='this.size=5;' onblur='this.size=1;' onchange='this.size=1; this.blur();'>
<option value="nairobi">Nairobi</option>
<option value="nakuru">Nakuru</option>
<option value="mandera">Mandera</option>
</select>
</div>
<div class=col-md-4 style="width:20%">
<p>Constituency <span>*</span></p>
<select name="current_constituency" id="CurrentaddressConstituency" class="dropup selectpicker" data-dropup--auto="false" data-live-search="true" style="width:15em;" onfocus='this.size=5;' onblur='this.size=1;' onchange='this.size=1; this.blur();'>
<option value="langata">Langata</option>
<option value="kikuyu">Kikuyu</option>
<option value="kisii">Kisii</option>
</select>
</div>
<div class=col-md-4 style="width:20%">
<p>Location </p>
<input name="current_street_address" type="text" class="form-control" id="postalStreetAddress" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;">
</div>
</div><!-- End of Current Address row -->
<div class=row style="padding:0px 5px 15px 10px">
<div class=col-md-4 style="width:20%; padding-top:15px">
<button class="btn btn-info" name="contactinfo_form" style="padding: 5px 25px 5px 25px">Save</button>
</div>
<div class=col-md-4 style="width:20%; padding-top:15px">
<button class=btn style="padding: 5px 25px 5px 25px">Cancel</button>
</div>
</div> <!-- End of button row -->
</form>
</div>
</div>
</section>
</section>
@endsection
@section('footer-include')
<script src="/js/select3/bootstrapselect.min.js"></script>
<script src="/js/select3/bootstrap.min.js"></script>
@endsection
@section('j-script')
<!-- Jquery -->
@endsection
>>>>>>> Storing employee info
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
@section('title', 'Employees')
=======
@extends('Layout.employees_master')
@section('title', 'Employees')
>>>>>>> Storing employee info
@section('header-include')
<link rel="stylesheet" href="/js/select3/bootstrapselect.min.css" type="text/css"/>
<link rel="stylesheet" href="/js/select3/bootstrap.min.css" type="text/css"/>
<style>
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
form {
=======
form {
>>>>>>> Storing employee info
border-radius: 5px;
width:100%;
background-color: #FFFFFF;
......@@ -40,6 +51,21 @@
display:inline-inline;
margin-right: 10px;
}
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
=======
.accordion {
background-color: #eee;
color: #444;
cursor: pointer;
padding: 18px;
width: 100%;
border: none;
text-align: left;
outline: none;
font-size: 15px;
transition: 0.4s;
}
>>>>>>> Storing employee info
.panel-row {
padding: 0 18px;
background-color: white;
......@@ -47,6 +73,7 @@
overflow: hidden;
transition: max-height 0.2s ease-out;
}
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
</style>
@endsection
......@@ -73,4 +100,85 @@
</div>
\ No newline at end of file
=======
ul {
list-style-type: none;
}
</style>
@endsection
@section('content')
<section id="content">
<section class="scrollable padder">
<ul class="breadcrumb no-border no-radius b-b b-light pull-in">
<li><a href="/kinetic"><i class="fa fa-home"></i> Home</a></li>
<li><a href="{{route('employees.index')}}">Employees</a></li>
<li><a href="{{route('employees.edit',$employee->id)}}">Edit Employees</a></li>
<li class="active">Dependants</li>
</ul>
@include('Layout.errors')
@include('Layout.messages')
<div class="container-fluid" style="margin-bottom:0px;">
<div class=col-md-3 id=tabLinks style="width:13.5%">
<ul class="list-group">
<li class="list-group-item active" ><a href="{{ route('employees.edit',$employee->id) }}">Employee Info</a></li>
<li class="list-group-item "><a href="{{route('personal',$employee->id)}}">Personal</a></li>
<li class="list-group-item "><a href="{{route('salary',$employee->id)}}">Salary</a></li>
<li class="list-group-item "><a href="{{route('contact',$employee->id)}}">Contact</a></li>
</ul>
</div>
<div class=col-md-6 style="width:86.5%;">
<div class="table-responsive" style="padding:0px 5px 5px 10px">
<table class="table table-striped m-b-sm datagrid">
@if(count($dependants)>0)
<thead>
<tr>
<th>Name</th>
<th>Phone No.</th>
<th>Email</th>
<th>Relation</th>
<th>Action</th>
</tr>
</thead>
<tbody>
@foreach($dependants as $dependant)
<tr class="dependants{{$dependants->id}}">
<td>{{$dependant->name}}</td>
<td>{{$dependant->phone_no}}</td>
<td>{{$dependant->email}}</td>
<td>{{$dependant->relation}}</td>
<td>
<form action="{{ route('employees.store') }}" method="post" style=position:relative;float:right>
@csrf
@method('DELETE')
<a href="" ><span class="btn btn-default"><i class="fa fa-edit no-margin"></i></span></a>
<button data-toggle="tooltip" data-placement="top" title="Delete" type="submit" class="btn btn-danger" onclick="return confirm('Are you sure you want to delete this item?');"><i class="fa fa-trash no-margin"></i></button>
</form>
</td>
</tr>
@endforeach
@else
<tr>
<td colspan="2" class="text-center">Nothing to display</td>
</tr>
@endif
</tbody>
</table>
</div>
</div>
</div>
</section>
</section>
@endsection
@section('footer-include')
<script src="/js/select3/bootstrapselect.min.js"></script>
<script src="/js/select3/bootstrap.min.js"></script>
@endsection
@section('j-script')
<!-- Jquery -->
@endsection
>>>>>>> Storing employee info
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
@extends('Layout.employees_master')
@section('title', 'Employees')
@section('header-include')
<link rel="stylesheet" href="/js/select3/bootstrapselect.min.css" type="text/css"/>
<link rel="stylesheet" href="/js/select3/bootstrap.min.css" type="text/css"/>
<style>
form {
border-radius: 5px;
width:100%;
background-color: #FFFFFF;
overflow: hidden;
}
p span {
color: #F00;
}
p {
margin: 0px;
font-weight: 500;
line-height: 2;
color:#333;
}
a {
text-decoration:inherit
}
.form-group {
overflow: hidden;
clear: both;
}
.form-control {
position:relative;
clear: both;
margin-top: 2px;
display:inline-inline;
margin-right: 10px;
}
.accordion {
background-color: #eee;
color: #444;
cursor: pointer;
padding: 18px;
width: 100%;
border: none;
text-align: left;
outline: none;
font-size: 15px;
transition: 0.4s;
}
.panel-row {
padding: 0 18px;
background-color: white;
max-height: 0;
overflow: hidden;
transition: max-height 0.2s ease-out;
}
ul {
list-style-type: none;
}
</style>
@endsection
@section('content')
<section id="content">
<section class="scrollable padder">
<ul class="breadcrumb no-border no-radius b-b b-light pull-in">
<li><a href="/kinetic"><i class="fa fa-home"></i> Home</a></li>
<li><a href="{{route('employees.index')}}">Employees</a></li>
<li><a href="{{route('employees.edit',$employee->employee_id)}}">Edit Employees</a></li>
<li><a href="{{route('salary',$employee->employee_id)}}">Salary</a></li>
<li class="active">Edit Salary</li>
</ul>
@include('Layout.errors')
@include('Layout.messages')
<div class="container-fluid" style="margin-bottom:0px;">
<div class=col-md-3 id=tabLinks style="width:13.5%">
<ul class="list-group">
<li class="list-group-item " ><a href="{{ route('employees.edit',$employee->employee_id) }}">Employee Info</a></li>
<li class="list-group-item "><a href="{{route('personal',$employee->employee_id)}}">Personal</a></li>
<li class="list-group-item active"><a href="{{route('salary',$employee->employee_id)}}">Salary</a></li>
<li class="list-group-item "><a href="{{route('contact',$employee->employee_id)}}">Contact</a></li>
</ul>
</div>
<div class=col-md-6 style="width:86.5%;">
<form method="post" action="{{ route('update_salary',$employee->employee_id) }}" enctype="multipart/form-data" class="form-inline" style="padding-top:10px;">
{{ csrf_field() }}
<div class=row style="padding:0px 5px 5px 10px">
<div class=col-md-4 style="width:20%">
<p>Pay Frequency<span>*</span></p>
<select name="pay_frequency" id="payfrequency" class="form-control selectpicker" data-live-search="true" data-size="2" title="Select Pay Frequency" style="width:15em;" onfocus='this.size=5;' onblur='this.size=1;' onchange='this.size=1; this.blur();'>
<option value="monthly" @if($selected_pay_frequency=$employee->pay_frequency) {{'selected'}} @endif>Monthly</option>
<option value="weekly" @if($selected_pay_frequency=$employee->pay_frequency) {{'selected'}} @endif>Weekly</option>
<option value="daily" @if($selected_pay_frequency=$employee->pay_frequency) {{'selected'}} @endif>Daily</option>
</select>
<div style="float:left; margin-top: 2px;text-align: left;font-family: 'Roboto Regular',sans-serif;color: #208BBD;font-size: 12px;cursor: pointer;">
<a href="" data-toggle="modal" data-target="#createPayfrequency"><span>Add Pay Frequency</span></a>
</div>
</div>
<div class=col-md-4 style="width:20%">
<p>Salary Amount<span>*</span> </p>
<div class="input-group-btn">
<button class="btn btn-default btn-sm dropdown-toggle" data-toggle="dropdown">
<span class="dropdown-label">USD</span>
<span class="caret"></span>
</button>
<ul class="dropdown-menu dropdown-select pull-right">
<li class="active">
<a href="#"><input type="radio" value="USD" name="pay_unit" @if($selected_pay_unit=$employee->pay_unit){{'checked'}}@endif>USD</a>
</li>
<li>
<a href="#"><input type="radio" value="GBP" name="pay_unit" @if($selected_pay_unit=$employee->pay_unit){{'checked'}}@endif>GBP</a>
</li>
</ul>
<input type="number" name="salary_amount" id="appendedInput" class="input-sm form-control" value="{{$employee->salary_amount}}">
</div>
</div>
<div class=col-md-4 id="Middlename" style="width:20%;">
<p>Bank Branch Name </p>
<input name="bank_branch_name" type="text" value="{{$employee->bank_branch_name}}" class="form-control" id="bankBranch" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;">
</div>
<div class=col-md-4 id="Middlename" style="width:20%;">
<p>Account No. </p>
<input name="bank_account_no" type="text" value="{{$employee->bank_account_no}}" class="form-control" id="bank_account_no" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;">
</div>
</div><!-- End of first row -->
<div class=row style="padding:0px 5px 5px 10px">
<div class=col-md-4 id="sacco_name" style="width:20%;">
<p>Sacco Name </p>
<input name="sacco_name" type="text" value="{{$employee->sacco_name}}"class="form-control" id="sacco_name" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;">
</div>
<div class=col-md-4 id="sacco_account_no" style="width:20%;">
<p>Sacco Account No. </p>
<input name="sacco_account_no" type="text" value="{{$employee->sacco_account_no}}" class="form-control" id="sacco_account_no" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;">
</div>
</div> <!-- End of second row -->
<div class=row style="padding:0px 5px 15px 10px">
<div class=col-md-4 style="width:20%; padding-top:15px">
<button class="btn btn-info" style="padding: 5px 25px 5px 25px">Save</button>
</div>
<div class=col-md-4 style="width:20%; padding-top:15px">
<a href="{{route('contact',$employee->id)}}"><button class=btn style="padding: 5px 25px 5px 25px">Cancel</button></a>
</div>
</div> <!-- End of button row -->
</form>
</div>
</div>
</section>
</section>
@endsection
@section('footer-include')
<script src="/js/select3/bootstrapselect.min.js"></script>
<script src="/js/select3/bootstrap.min.js"></script>
@endsection
@section('j-script')
<!-- Jquery -->
<script>
$("input").click(function(){
$(this).next().show();
$(this).next().hide();
});
$(document).on('ready', function(){
});
</script>
@endsection
@extends('Layout.employees_master')
@section('title', 'Employees')
@section('header-include')
<link rel="stylesheet" href="/js/select3/bootstrapselect.min.css" type="text/css"/>
<link rel="stylesheet" href="/js/select3/bootstrap.min.css" type="text/css"/>
<style>
form {
border-radius: 5px;
width:100%;
background-color: #FFFFFF;
overflow: hidden;
}
p span {
color: #F00;
}
p {
margin: 0px;
font-weight: 500;
line-height: 2;
color:#333;
}
a {
text-decoration:inherit
}
.form-group {
overflow: hidden;
clear: both;
}
.form-control {
position:relative;
clear: both;
margin-top: 2px;
display:inline-inline;
margin-right: 10px;
}
.accordion {
background-color: #eee;
color: #444;
cursor: pointer;
padding: 18px;
width: 100%;
border: none;
text-align: left;
outline: none;
font-size: 15px;
transition: 0.4s;
}
.panel-row {
padding: 0 18px;
background-color: white;
max-height: 0;
overflow: hidden;
transition: max-height 0.2s ease-out;
}
ul {
list-style-type: none;
}
</style>
@endsection
@section('content')
<section id="content">
<section class="scrollable padder">
<ul class="breadcrumb no-border no-radius b-b b-light pull-in">
<li><a href="/kinetic"><i class="fa fa-home"></i> Home</a></li>
<li><a href="{{route('employees.index')}}">Employees</a></li>
<li><a href="{{route('employees.edit',$employee->id)}}">Edit Employees</a></li>
<li class="active">Emergency Contacts</li>
</ul>
@include('Layout.errors')
@include('Layout.messages')
<div class="container-fluid" style="margin-bottom:0px;">
<div class=col-md-3 id=tabLinks style="width:13.5%">
<ul class="list-group">
<li class="list-group-item active" ><a href="{{ route('employees.edit',$employee->id) }}">Employee Info</a></li>
<li class="list-group-item "><a href="{{route('personal',$employee->id)}}">Personal</a></li>
<li class="list-group-item "><a href="{{route('salary',$employee->id)}}}">Salary</a></li>
<li class="list-group-item "><a href="{{route('contact',$employee->id)}}}">Contact</a></li>
</ul>
</div>
<div class=col-md-6 style="width:86.5%;">
<div class="table-responsive" style="padding:0px 5px 5px 10px">
<table class="table table-striped m-b-sm datagrid">
@if(count($emergency)>0)
<thead>
<tr>
<th>Name</th>
<th>Phone No.</th>
<th>Email</th>
<th>Relation</th>
<th>Action</th>
</tr>
</thead>
<tbody>
@foreach($emergency as $contact)
<tr class="emergency_contact{{$emergency->id}}">
<td>{{$contact->name}}</td>
<td>{{$contact->phone_no}}</td>
<td>{{$contact->email}}</td>
<td>{{$contact->relation}}</td>
<td>
<form action="{{ route('employees.store') }}" method="post" style=position:relative;float:right>
@csrf
@method('DELETE')
<a href="" ><span class="btn btn-default"><i class="fa fa-edit no-margin"></i></span></a>
<button data-toggle="tooltip" data-placement="top" title="Delete" type="submit" class="btn btn-danger" onclick="return confirm('Are you sure you want to delete this item?');"><i class="fa fa-trash no-margin"></i></button>
</form>
</td>
</tr>
@endforeach
@else
<tr>
<td colspan="2" class="text-center">Nothing to display</td>
</tr>
@endif
</tbody>
</table>
</div>
</div>
</div>
</section>
</section>
@endsection
@section('footer-include')
<script src="/js/select3/bootstrapselect.min.js"></script>
<script src="/js/select3/bootstrap.min.js"></script>
@endsection
@section('j-script')
<!-- Jquery -->
<script>
$("input").click(function(){
$(this).next().show();
$(this).next().hide();
});
// Javascript for rendering tablinks
$('#tabLinks').on('click', '.list-group a', function (e) {
clickEvent = true;
$('.list-group li').removeClass('active');
$(this).parent().addClass('active');
localStorage.setItem('tab', $(e.currentTarget).attr('href'));
});
$(function() {
var slide = localStorage.getItem('tab');
console.log(slide);
if (slide) {
$("a[href='" + slide + "']").click().tab('show');
}
});
function tabswitch(item) {
var divs = document.getElementsByClassName("tabcontainer");
for (var i = 0; i < divs.length; i++) {
divs[i].style.display = 'none';
}
var myDiv = item.href;
var target = myDiv.split("#");
document.getElementById(target[1]).style.display = "inline";
}
// Javascript for rendering input fields on set conditions
function inputfieldVisibility(that) {
if(that.value == "national") {
document.getElementById("nationaldocument").style.display = "inline";
document.getElementById("passportdocument").style.display = "none";
document.getElementById("militarydocument").style.display = "none";
}else if(that.value == "passport") {
document.getElementById("passportdocument").style.display = "inline";
document.getElementById("militarydocument").style.display = "none";
document.getElementById("nationaldocument").style.display = "none";
}else if(that.value == "military") {
document.getElementById("militarydocument").style.display = "inline";
document.getElementById("nationaldocument").style.display = "none";
document.getElementById("passportdocument").style.display = "none";
}else {
document.getElementById("nationaldocument").style.display = "none";
document.getElementById("passportdocument").style.display = "none";
document.getElementById("militarydocument").style.display = "none";
}
}
function ethnicVisibility(that) {
if (that.value == "kenyan") {
document.getElementById("ethnicfield").style.display = "inline";
}else{
document.getElementById("ethnicfield").style.display = "none";
}
}
function durationfieldVisibility(that) {
if (that.value == "casual"|| that.value == "probation" || that.value =="contract"|| that.value == "temporary") {
document.getElementById("duration").style.display = "block";
} else {
document.getElementById("duration").style.display = "none";
}
}
function relationfieldVisibility(that) {
if (that.value == "other") {
document.getElementById("other_relation").style.display = "block";
} else {
document.getElementById("other_relation").style.display = "none";
}
}
$(document).on('ready', function(){
});
</script>
@endsection
This diff is collapsed.
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
@extends('Layout.Employeesmaster')
=======
@extends('Layout.employees_master')
>>>>>>> Storing employee info
@section('title', 'Employees')
@section('header-include')
......@@ -46,7 +50,12 @@
</div>
<div class=row style="padding:0px 5px 5px 10px">
<div class="table-responsive" style="padding:0px 5px 5px 10px">
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
<table class="table table-striped m-b-sm datagrid">
=======
<table class="table table-striped m-b-sm datagrid">
@if(count($employees) > 0)
>>>>>>> Storing employee info
<thead>
<tr>
<th>Action</th>
......@@ -56,6 +65,7 @@
<th>Phone No.</th>
</tr>
</thead>
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
<tbody>
<tr>
<td>
......@@ -72,6 +82,27 @@
</tr>
</tbody>
</table>
=======
@foreach($employees as $employee)
<tbody>
<td>
<a href="{{ route('employees.edit',$employee->id)}}" ><span class="btn btn-default open-modal"><i class="fa fa-edit no-margin"></i></span></a>
</td>
<td>{{ $employee->employee_id }}</td>
<td>{{ $employee->first_name}}</td>
<td>{{ $employee->last_name}}</td>
<td>{{ $employee->email_address}}</td>
<td>{{ $employee->personal_phone}}</td>
</tr>
@endforeach
@else
<tr>
<td colspan="2" class="text-center">Nothing to display</td>
</tr>
@endif
</tbody>
</table>
>>>>>>> Storing employee info
</div>
</div>
</div>
......
This diff is collapsed.
@extends('Layout.employees_master')
@section('title', 'Employees')
@section('header-include')
<link rel="stylesheet" href="/js/select3/bootstrapselect.min.css" type="text/css"/>
<link rel="stylesheet" href="/js/select3/bootstrap.min.css" type="text/css"/>
<style>
form {
border-radius: 5px;
width:100%;
background-color: #FFFFFF;
overflow: hidden;
}
p span {
color: #F00;
}
p {
margin: 0px;
font-weight: 500;
line-height: 2;
color:#333;
}
a {
text-decoration:inherit
}
.form-group {
overflow: hidden;
clear: both;
}
.form-control {
position:relative;
clear: both;
margin-top: 2px;
display:inline-inline;
margin-right: 10px;
}
.accordion {
background-color: #eee;
color: #444;
cursor: pointer;
padding: 18px;
width: 100%;
border: none;
text-align: left;
outline: none;
font-size: 15px;
transition: 0.4s;
}
.panel-row {
padding: 0 18px;
background-color: white;
max-height: 0;
overflow: hidden;
transition: max-height 0.2s ease-out;
}
ul {
list-style-type: none;
}
</style>
@endsection
@section('content')
<section id="content">
<section class="scrollable padder">
<ul class="breadcrumb no-border no-radius b-b b-light pull-in">
<li><a href="/kinetic"><i class="fa fa-home"></i> Home</a></li>
<li><a href="{{route('employees.index')}}}">Employees</a></li>
<li><a href="{{route('employees.edit',$employee->id)}}">Edit Employees</a></li>
<li class="active">Salary</li>
</ul>
@include('Layout.errors')
@include('Layout.messages')
<div class="container-fluid" style="margin-bottom:0px;">
<div class=col-md-3 id=tabLinks style="width:13.5%">
<ul class="list-group">
<li class="list-group-item " ><a href="{{ route('employees.edit',$employee->id) }}">Employee Info</a></li>
<li class="list-group-item "><a href="{{route('personal',$employee->id)}}">Personal</a></li>
<li class="list-group-item active"><a href="{{route('salary',$employee->id)}}">Salary</a></li>
<li class="list-group-item "><a href="{{route('contact',$employee->id)}}">Contact</a></li>
</ul>
</div>
<div class=col-md-6 style="width:86.5%;">
<form method="post" action="{{ route('store_salary',$employee->id) }}" enctype="multipart/form-data" class="form-inline" style="padding-top:10px;">
{{ csrf_field() }}
<div class=row style="padding:0px 5px 5px 10px">
<div class=col-md-4 style="width:20%">
<p>Pay Frequency<span>*</span></p>
<select name="pay_frequency" id="payfrequency" class="form-control selectpicker" data-live-search="true" data-size="2" title="Select Pay Frequency" style="width:15em;" onfocus='this.size=5;' onblur='this.size=1;' onchange='this.size=1; this.blur();'>
<option value="monthly">Monthly</option>
<option value="weekly">Weekly</option>
<option value="daily">Daily</option>
</select>
<div style="float:left; margin-top: 2px;text-align: left;font-family: 'Roboto Regular',sans-serif;color: #208BBD;font-size: 12px;cursor: pointer;">
<a href="" data-toggle="modal" data-target="#createPayfrequency"><span>Add Pay Frequency</span></a>
</div>
</div>
<div class=col-md-4 style="width:20%">
<p>Salary Amount<span>*</span> </p>
<div class="input-group-btn">
<button class="btn btn-default btn-sm dropdown-toggle" data-toggle="dropdown">
<span class="dropdown-label">USD</span>
<span class="caret"></span>
</button>
<ul class="dropdown-menu dropdown-select pull-right">
<li class="active">
<a href="#"><input type="radio" value="USD" name="pay_unit" checked="">USD</a>
</li>
<li>
<a href="#"><input type="radio" value="GBP" name="pay_unit">GBP</a>
</li>
</ul>
<input type="number" name="salary_amount" id="appendedInput" class="input-sm form-control">
</div>
</div>
<div class=col-md-4 id="Middlename" style="width:20%;">
<p>Bank Branch Name </p>
<input name="bank_branch_name" type="text" class="form-control" id="bankBranch" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;">
</div>
<div class=col-md-4 id="Middlename" style="width:20%;">
<p>Account No. </p>
<input name="bank_account_no" type="text" class="form-control" id="bankAcc" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;">
</div>
</div><!-- End of first row -->
<div class=row style="padding:0px 5px 5px 10px">
<div class=col-md-4 id="saccoName" style="width:20%;">
<p>Sacco Name </p>
<input name="sacco_name" type="text" class="form-control" id="saccoName" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;">
</div>
<div class=col-md-4 id="saccoAccountno" style="width:20%;">
<p>Sacco Account No. </p>
<input name="sacco_account_no" type="text" class="form-control" id="saccoAccountno" style="border-radius: 0px 5px 5px 0px;border: 1px solid #eee;margin-bottom: 15px;width: 15em;height: 40px;float: left;padding: 0px 15px;">
</div>
</div> <!-- End of second row -->
<div class=row style="padding:0px 5px 15px 10px">
<div class=col-md-4 style="width:20%; padding-top:15px">
<button class="btn btn-info"name="salary_form" style="padding: 5px 25px 5px 25px">Save</button>
</div>
<div class=col-md-4 style="width:20%; padding-top:15px">
<a href="{{route('employees.edit',$employee->id)}}"><button class=btn style="padding: 5px 25px 5px 25px">Cancel</button></a>
</div>
</form>
</div>
</div>
</section>
</section>
@endsection
@section('footer-include')
<script src="/js/select3/bootstrapselect.min.js"></script>
<script src="/js/select3/bootstrap.min.js"></script>
@endsection
@section('j-script')
<!-- Jquery -->
<script>
$("input").click(function(){
$(this).next().show();
$(this).next().hide();
});
$(document).on('ready', function(){
});
</script>
@endsection
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -61,8 +61,25 @@ Route::get('/payslip/view_payslip', 'PayslipController@view_payslip');
#EmployeesController
Route::resource('/employees','EmployeeController')->middleware('admin');
Route::get('/export','EmployeeController@export')->name('export');
<<<<<<< 8c98d41a67e0ec45e1fd64b04b779360352c1dcf
Route::post('/employees/import', 'EmployeeController@import')->name('import');
=======
Route::post('/import', 'EmployeeController@import')->name('import');
Route::get('/personal/{id}','EmployeeController@personal_info')->name('personal');
Route::post('/personal/{id}/store','EmployeeController@store_personal_info')->name('store_personal');
// Route::get('/personal/{id}','EmployeeController@show_personal_info')->name('show_personal');
Route::get('/personal/{id}/edit','EmployeeController@edit_personal_info')->name('edit_personal');
Route::post('/personal/{id}/update','EmployeeController@update_personal_info')->name('update_personal');
Route::get('/contact/{id}','EmployeeController@contact')->name('contact');
Route::post('/contact/{id}/store','EmployeeController@store_contact')->name('store_contact');
Route::get('/contact/{id}/edit','EmployeeController@edit_contact')->name('edit_contact');
Route::post('/contact/{id}/update','EmployeeController@update_contact')->name('update_contact');
Route::get('/salary/{id}','EmployeeController@salary')->name('salary');
Route::post('/salary/{id}/store','EmployeeController@store_salary')->name('store_salary');
Route::get('/salary/{id}/edit','EmployeeController@edit_salary')->name('edit_salary');
Route::post('/salary/{id}/update','EmployeeController@update_contact')->name('update_salary');
>>>>>>> Storing employee info
#PayfrequencyController
Route::resource('/payfrequency', 'PayfrequencyController');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment