|
|
@ -1,5 +1,7 @@
|
|
|
|
package au.com.royalpay.payment.manage.management.sysconfig.beans;
|
|
|
|
package au.com.royalpay.payment.manage.management.sysconfig.beans;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
|
|
|
|
|
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
@ -8,6 +10,21 @@ import org.apache.commons.lang3.StringUtils;
|
|
|
|
public class FuncInfo {
|
|
|
|
public class FuncInfo {
|
|
|
|
private String name;
|
|
|
|
private String name;
|
|
|
|
private String remark;
|
|
|
|
private String remark;
|
|
|
|
|
|
|
|
private boolean admin;
|
|
|
|
|
|
|
|
private boolean operator;
|
|
|
|
|
|
|
|
private boolean bd;
|
|
|
|
|
|
|
|
private boolean finacial;
|
|
|
|
|
|
|
|
private boolean servant;
|
|
|
|
|
|
|
|
private boolean accountmanager;
|
|
|
|
|
|
|
|
private boolean director;
|
|
|
|
|
|
|
|
private boolean sitemanager;
|
|
|
|
|
|
|
|
private boolean developer;
|
|
|
|
|
|
|
|
private boolean bdleader;
|
|
|
|
|
|
|
|
private boolean riskmanager;
|
|
|
|
|
|
|
|
private boolean guest;
|
|
|
|
|
|
|
|
private boolean orgmanager;
|
|
|
|
|
|
|
|
private boolean salesmanager;
|
|
|
|
|
|
|
|
private boolean datacontent;
|
|
|
|
|
|
|
|
|
|
|
|
public String getName() {
|
|
|
|
public String getName() {
|
|
|
|
return StringUtils.isEmpty(name) ? null : name;
|
|
|
|
return StringUtils.isEmpty(name) ? null : name;
|
|
|
@ -24,4 +41,179 @@ public class FuncInfo {
|
|
|
|
public void setRemark(String remark) {
|
|
|
|
public void setRemark(String remark) {
|
|
|
|
this.remark = remark;
|
|
|
|
this.remark = remark;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setSalesmanager(boolean salesmanager) {
|
|
|
|
|
|
|
|
this.salesmanager = salesmanager;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isAdmin() {
|
|
|
|
|
|
|
|
return admin;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isBd() {
|
|
|
|
|
|
|
|
return bd;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isFinacial() {
|
|
|
|
|
|
|
|
return finacial;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isAccountmanager() {
|
|
|
|
|
|
|
|
return accountmanager;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isOperator() {
|
|
|
|
|
|
|
|
return operator;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isDeveloper() {
|
|
|
|
|
|
|
|
return developer;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isDirector() {
|
|
|
|
|
|
|
|
return director;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isServant() {
|
|
|
|
|
|
|
|
return servant;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setAccountmanager(boolean accountmanager) {
|
|
|
|
|
|
|
|
this.accountmanager = accountmanager;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isBdleader() {
|
|
|
|
|
|
|
|
return bdleader;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isSitemanager() {
|
|
|
|
|
|
|
|
return sitemanager;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setAdmin(boolean admin) {
|
|
|
|
|
|
|
|
this.admin = admin;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setBd(boolean bd) {
|
|
|
|
|
|
|
|
this.bd = bd;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isGuest() {
|
|
|
|
|
|
|
|
return guest;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setDeveloper(boolean developer) {
|
|
|
|
|
|
|
|
this.developer = developer;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isRiskmanager() {
|
|
|
|
|
|
|
|
return riskmanager;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setDirector(boolean director) {
|
|
|
|
|
|
|
|
this.director = director;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setBdleader(boolean bdleader) {
|
|
|
|
|
|
|
|
this.bdleader = bdleader;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setFinacial(boolean finacial) {
|
|
|
|
|
|
|
|
this.finacial = finacial;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setOperator(boolean operator) {
|
|
|
|
|
|
|
|
this.operator = operator;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setServant(boolean servant) {
|
|
|
|
|
|
|
|
this.servant = servant;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setGuest(boolean guest) {
|
|
|
|
|
|
|
|
this.guest = guest;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setRiskmanager(boolean riskmanager) {
|
|
|
|
|
|
|
|
this.riskmanager = riskmanager;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setSitemanager(boolean sitemanager) {
|
|
|
|
|
|
|
|
this.sitemanager = sitemanager;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setDatacontent(boolean datacontent) {
|
|
|
|
|
|
|
|
this.datacontent = datacontent;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isSalesmanager() {
|
|
|
|
|
|
|
|
return salesmanager;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isOrgmanager() {
|
|
|
|
|
|
|
|
return orgmanager;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isDatacontent() {
|
|
|
|
|
|
|
|
return datacontent;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setOrgmanager(boolean orgmanager) {
|
|
|
|
|
|
|
|
this.orgmanager = orgmanager;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public JSONObject initObject(JSONObject mod) {
|
|
|
|
|
|
|
|
mod.put("name", getName());
|
|
|
|
|
|
|
|
mod.put("remark", getRemark());
|
|
|
|
|
|
|
|
int role = 0;
|
|
|
|
|
|
|
|
if (admin) {
|
|
|
|
|
|
|
|
role |= ManagerRole.ADMIN.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (operator) {
|
|
|
|
|
|
|
|
role |= ManagerRole.OPERATOR.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (sitemanager) {
|
|
|
|
|
|
|
|
role |= ManagerRole.SITE_MANAGER.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (bd) {
|
|
|
|
|
|
|
|
role |= ManagerRole.BD_USER.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (finacial) {
|
|
|
|
|
|
|
|
role |= ManagerRole.FINANCIAL_STAFF.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (servant) {
|
|
|
|
|
|
|
|
role |= ManagerRole.SERVANT.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (accountmanager) {
|
|
|
|
|
|
|
|
role |= ManagerRole.ACCOUNT_MANAGER.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (director) {
|
|
|
|
|
|
|
|
role |= ManagerRole.DIRECTOR.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (developer) {
|
|
|
|
|
|
|
|
role |= ManagerRole.DEVELOPER.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (bdleader){
|
|
|
|
|
|
|
|
role |= ManagerRole.BD_LEADER.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (riskmanager){
|
|
|
|
|
|
|
|
role |= ManagerRole.RISK_MANAGER.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (guest){
|
|
|
|
|
|
|
|
role |= ManagerRole.GUEST.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (orgmanager){
|
|
|
|
|
|
|
|
role |= ManagerRole.ORG_MANAGER.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (salesmanager) {
|
|
|
|
|
|
|
|
role |= ManagerRole.SALES_MANAGER.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (datacontent) {
|
|
|
|
|
|
|
|
role |= ManagerRole.DATA_CONTENT.getMask();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
mod.put("role", role);
|
|
|
|
|
|
|
|
return mod;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|