本文整理汇总了PHP中Employee::deleteEmployee方法的典型用法代码示例。如果您正苦于以下问题:PHP Employee::deleteEmployee方法的具体用法?PHP Employee::deleteEmployee怎么用?PHP Employee::deleteEmployee使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Employee
的用法示例。
在下文中一共展示了Employee::deleteEmployee方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: resetEmp
public function resetEmp($request)
{
if ($this->checkDetails($request)) {
$empObject = new Employee();
$array = $empObject->deleteEmployee($request["restaurantID"], $request["empid"]);
return $array;
}
}
示例2: isset
<?php
require_once '../classes/connection.class.php';
require_once '../classes/employee.class.php';
$id = isset($_GET['id']) ? $_GET['id'] : '';
$obj = new Employee();
$obj->setEmployee_id($id);
$delete = $obj->deleteEmployee();
if ($delete == true) {
echo "your record is successfully deleted";
header('location:view_employee.php');
} else {
echo "record couldnt be deleted";
}
示例3:
redirect_header("employee.php", $pausetime, "Your data is saved. Create More Records");
} else {
redirect_header("employee.php?action=edit&employee_id={$o->employee_id}", $pausetime, "Your data is saved.");
}
} else {
$log->saveLog($o->employee_id, $tableemployee, "{$o->changesql}", "U", "F");
redirect_header("employee.php?action=edit&employee_id={$o->employee_id}", $pausetime, "Warning! Can't save the data, please make sure all value is insert properly.");
}
} else {
$log->saveLog($o->employee_id, $tableemployee, "{$o->changesql}", "U", "F");
redirect_header("employee.php?action=edit&employee_id={$o->employee_id}", $pausetime, "Warning! Can't save the data, please make sure all value is insert properly.");
}
break;
case "delete":
if ($s->check(false, $token, "CREATE_ACG")) {
if ($o->deleteEmployee($o->employee_id)) {
$o->deletefile2($o->employee_id . "_photo.jpg");
$log->saveLog($o->employee_id, $tableemployee, "{$o->changesql}", "D", "O");
redirect_header("employee.php", $pausetime, "Data removed successfully.");
} else {
$log->saveLog($o->employee_id, $tableemployee, "{$o->changesql}", "D", "F");
redirect_header("employee.php?action=edit&employee_id={$o->employee_id}", $pausetime, "Warning! Can't delete data from database.");
}
} else {
redirect_header("employee.php?action=edit&employee_id={$o->employee_id}", $pausetime, "Warning! Can't delete data from database.");
}
break;
case "search":
$wherestr = " WHERE a.employee_id>0 and a.organization_id={$defaultorganization_id} ";
$limitstr = "";
if ($o->issearch == "Y") {
示例4: Employee
</div>
</div>
<!-- Users table -->
<div class="row-fluid table">
<style type="text/css">
.dataTables_filter{
display: none;
}
</style>
<?php
if (Input::get('del') == 1) {
$delete = new Employee();
if (Input::get('check') != null) {
foreach (Input::get('check') as $check) {
$delete->deleteEmployee(Crytion::decryt64(Crytion::decryt64($check)));
}
}
}
?>
<form action='employee-list.php?del=1' method='post' id='deleteem'>
<table class="table table-bordered table-hover dataTable" id="employee-list-table">
<thead>
<tr>
<th class="span1">
<input type="checkbox" name="checkall" id="checkall"/>
</th>
<th class="span4">
Employee Info
</th>
<th class="span2">
示例5: Employee
<div class="content">
<ul class="breadcrumb" style="margin-bottom:0px;">
<li><i class="fa fa-home"></i><a href="index.php"> Dashboard</a><span class="divider">></span></li>
<li><a href="employee-list.php"> Employee List</a><span class="divider">></span></li>
<li> Edit Employee</li>
<span class="pull-right">Time: <span id="time"></span></span>
</ul>
<div class="container-fluid">
<div id="pad-wrapper" class="user-profile new-user" >
<?php
if (Input::get('del') == 1) {
$del = new Employee();
$del->deleteEmployee(Crytion::decryt64(Crytion::decryt64(Input::get('id'))));
if ($del) {
echo "<script>alert('Delete Successful');</script>";
echo "<script>window.setTimeout(function(){window.location = 'employee-list.php'},1);</script>";
}
}
if (Input::get('id')) {
$id = Crytion::decryt64(Crytion::decryt64(Input::get('id')));
$user = DB::getInstance()->query("Select * from tbl_employee a, tbl_jobs b where a.job_id = b.job_id and a.user_id=?", array($id));
if (!$user->error() && $user->count() == 1) {
$result = $user->result();
$address = DB::getInstance()->get('tbl_add', array("person_id", "=", $result->user_id));
$addr = $address->result();
?>
<!-- delete modal -->
<div id="deleteuser" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">