泛型函数返回类型优化
This commit is contained in:
@@ -107,7 +107,7 @@ public class EmpUser extends User {
|
|||||||
@ExcelField(title="最后登录", attrName="lastLoginDate", align=Align.CENTER, words=20, sort=900, type=ExcelField.Type.EXPORT),
|
@ExcelField(title="最后登录", attrName="lastLoginDate", align=Align.CENTER, words=20, sort=900, type=ExcelField.Type.EXPORT),
|
||||||
})
|
})
|
||||||
public Employee getEmployee(){
|
public Employee getEmployee(){
|
||||||
Employee employee = (Employee)super.getRefObj();
|
Employee employee = super.getRefObj();
|
||||||
if (employee == null){
|
if (employee == null){
|
||||||
employee = new Employee(getRefCode());
|
employee = new Employee(getRefCode());
|
||||||
super.setRefObj(employee);
|
super.setRefObj(employee);
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ public class EmpUtils {
|
|||||||
*/
|
*/
|
||||||
public static Employee get(User user){
|
public static Employee get(User user){
|
||||||
if (user != null && User.USER_TYPE_EMPLOYEE.equals(user.getUserType())){
|
if (user != null && User.USER_TYPE_EMPLOYEE.equals(user.getUserType())){
|
||||||
return (Employee)user.getRefObj();
|
return user.getRefObj();
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ set global read_only=0;
|
|||||||
|
|
||||||
create user 'jeesite'@'%' identified by 'jeesite';
|
create user 'jeesite'@'%' identified by 'jeesite';
|
||||||
|
|
||||||
create database jeesite DEFAULT CHARSET 'utf8' COLLATE 'utf8_unicode_ci';
|
create database jeesite DEFAULT CHARSET 'utf8' COLLATE 'utf8_general_ci';
|
||||||
|
|
||||||
grant all privileges on jeesite.* to 'jeesite'@'%' identified by 'jeesite';
|
grant all privileges on jeesite.* to 'jeesite'@'%' identified by 'jeesite';
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user