本文整理汇总了PHP中Staff::setLastName方法的典型用法代码示例。如果您正苦于以下问题:PHP Staff::setLastName方法的具体用法?PHP Staff::setLastName怎么用?PHP Staff::setLastName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Staff
的用法示例。
在下文中一共展示了Staff::setLastName方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: fetchStaff
function fetchStaff()
{
$array = $this->_conn->fetchRow();
if ($array == false) {
return false;
}
$staff = new Staff();
$staff->setUserid($array["userid"]);
$staff->setLastName($array["last_name"]);
$staff->setFirstName($array["first_name"]);
$staff->setUsername($array["username"]);
if ($array["circ_flg"] == "Y") {
$staff->setCircAuth(true);
} else {
$staff->setCircAuth(false);
}
if ($array["circ_mbr_flg"] == "Y") {
$staff->setCircMbrAuth(TRUE);
} else {
$staff->setCircMbrAuth(FALSE);
}
if ($array["catalog_flg"] == "Y") {
$staff->setCatalogAuth(true);
} else {
$staff->setCatalogAuth(false);
}
if ($array["admin_flg"] == "Y") {
$staff->setAdminAuth(true);
} else {
$staff->setAdminAuth(false);
}
if ($array["reports_flg"] == "Y") {
$staff->setReportsAuth(TRUE);
} else {
$staff->setReportsAuth(FALSE);
}
if ($array["suspended_flg"] == "Y") {
$staff->setSuspended(true);
} else {
$staff->setSuspended(false);
}
return $staff;
}
示例2: Localize
require_once "../functions/errorFuncs.php";
require_once "../classes/Localize.php";
$loc = new Localize(OBIB_LOCALE, $tab);
#****************************************************************************
#* Checking for post vars. Go back to form if none found.
#****************************************************************************
if (count($_POST) == 0) {
header("Location: ../admin/staff_new_form.php");
exit;
}
#****************************************************************************
#* Validate data
#****************************************************************************
$staff = new Staff();
$staff->setLastChangeUserid($_SESSION["userid"]);
$staff->setLastName($_POST["last_name"]);
$_POST["last_name"] = $staff->getLastName();
$staff->setFirstName($_POST["first_name"]);
$_POST["first_name"] = $staff->getFirstName();
$staff->setUsername($_POST["username"]);
$_POST["username"] = $staff->getUsername();
$staff->setPwd($_POST["pwd"]);
$_POST["pwd"] = $staff->getPwd();
$staff->setPwd2($_POST["pwd2"]);
$_POST["pwd2"] = $staff->getPwd2();
$staff->setCircAuth(isset($_POST["circ_flg"]));
$staff->setCircMbrAuth(isset($_POST["circ_mbr_flg"]));
$staff->setCatalogAuth(isset($_POST["catalog_flg"]));
$staff->setAdminAuth(isset($_POST["admin_flg"]));
$staff->setReportsAuth(isset($_POST["reports_flg"]));
$validData = $staff->validateData();
示例3: Staff
function _mkObj($array)
{
$staff = new Staff();
$staff->setUserid($array["userid"]);
$staff->setLastName($array["last_name"]);
$staff->setFirstName($array["first_name"]);
$staff->setUsername($array["username"]);
$staff->setEmail($array["email"]);
$staff->setContactNumber($array["contact_number"]);
if ($array["circ_flg"] == "Y") {
$staff->setCircAuth(true);
} else {
$staff->setCircAuth(false);
}
if ($array["circ_mbr_flg"] == "Y") {
$staff->setCircMbrAuth(TRUE);
} else {
$staff->setCircMbrAuth(FALSE);
}
if ($array["catalog_flg"] == "Y") {
$staff->setCatalogAuth(true);
} else {
$staff->setCatalogAuth(false);
}
if ($array["admin_flg"] == "Y") {
$staff->setAdminAuth(true);
} else {
$staff->setAdminAuth(false);
}
if ($array["reports_flg"] == "Y") {
$staff->setReportsAuth(TRUE);
} else {
$staff->setReportsAuth(FALSE);
}
if ($array["suspended_flg"] == "Y") {
$staff->setSuspended(true);
} else {
$staff->setSuspended(false);
}
return $staff;
}