mirror of
https://gitee.com/dromara/MaxKey.git
synced 2026-05-15 04:52:09 +08:00
mgt fix
mgt fix
This commit is contained in:
@@ -2,6 +2,12 @@ package org.maxkey.domain;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
|
||||
|
||||
/*
|
||||
ID varchar(40) not null,
|
||||
@@ -9,17 +15,24 @@ import java.io.Serializable;
|
||||
UID varchar(40) null
|
||||
constraint PK_ROLES primary key clustered (ID)
|
||||
*/
|
||||
@Table(name = "GROUP_MEMBER")
|
||||
public class GroupMember extends UserInfo implements Serializable{
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private static final long serialVersionUID = -8059639972590554760L;
|
||||
@Id
|
||||
@Column
|
||||
@GeneratedValue(strategy=GenerationType.AUTO,generator="uuid")
|
||||
String id;
|
||||
@Column
|
||||
private String groupId;
|
||||
private String groupName;
|
||||
|
||||
@Column
|
||||
private String memberId;
|
||||
private String memberName;
|
||||
@Column
|
||||
private String type;//User or Group
|
||||
|
||||
|
||||
@@ -54,6 +67,16 @@ public class GroupMember extends UserInfo implements Serializable{
|
||||
}
|
||||
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return the groupId
|
||||
*/
|
||||
|
||||
@@ -2,7 +2,12 @@ package org.maxkey.domain;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import org.hibernate.validator.constraints.NotEmpty;
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
|
||||
import org.maxkey.domain.apps.Applications;
|
||||
|
||||
|
||||
@@ -12,15 +17,20 @@ import org.maxkey.domain.apps.Applications;
|
||||
MENUID varchar(40) null
|
||||
constraint PK_ROLES primary key clustered (ID)
|
||||
*/
|
||||
@Table(name = "GROUP_APP")
|
||||
public class GroupPrivileges extends Applications implements Serializable{
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private static final long serialVersionUID = 8634166407201007340L;
|
||||
@NotEmpty
|
||||
@Id
|
||||
@Column
|
||||
@GeneratedValue(strategy=GenerationType.AUTO,generator="uuid")
|
||||
String id;
|
||||
@Column
|
||||
private String groupId;
|
||||
@NotEmpty
|
||||
@Column
|
||||
private String appId;
|
||||
|
||||
public GroupPrivileges(){
|
||||
@@ -65,6 +75,16 @@ public class GroupPrivileges extends Applications implements Serializable{
|
||||
}
|
||||
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see java.lang.Object#toString()
|
||||
*/
|
||||
|
||||
@@ -2,6 +2,10 @@ package org.maxkey.domain;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
|
||||
import org.apache.mybatis.jpa.persistence.JpaBaseDomain;
|
||||
@@ -14,17 +18,27 @@ public class Groups extends JpaBaseDomain implements Serializable{
|
||||
*
|
||||
*/
|
||||
private static final long serialVersionUID = 4660258495864814777L;
|
||||
|
||||
@Id
|
||||
@Column
|
||||
@GeneratedValue(strategy=GenerationType.AUTO,generator="uuid")
|
||||
String id;
|
||||
|
||||
@Length(max=60)
|
||||
@Column
|
||||
private String name;
|
||||
@Column
|
||||
private int isdefault;
|
||||
@Column
|
||||
String description;
|
||||
@Column
|
||||
String createdBy;
|
||||
@Column
|
||||
String createdDate;
|
||||
@Column
|
||||
String modifiedBy;
|
||||
@Column
|
||||
String modifiedDate;
|
||||
@Column
|
||||
String status;
|
||||
|
||||
public Groups() {}
|
||||
|
||||
@@ -17,27 +17,52 @@ public class Organizations extends JpaBaseDomain implements Serializable{
|
||||
@Column
|
||||
@GeneratedValue(strategy=GenerationType.AUTO,generator="uuid")
|
||||
private String id;
|
||||
private String code;
|
||||
private String name;
|
||||
private String fullName;
|
||||
private String pId;
|
||||
private String pName;
|
||||
private String type;
|
||||
private String xPath;
|
||||
private String xNamePath;
|
||||
private String level;
|
||||
private String hasChild;
|
||||
private String division;
|
||||
private String country;
|
||||
private String region;
|
||||
private String locality;
|
||||
private String street;
|
||||
private String address;
|
||||
private String contact;
|
||||
private String postalCode;
|
||||
private String phone;
|
||||
private String fax;
|
||||
private String email;
|
||||
@Column
|
||||
private String code;
|
||||
@Column
|
||||
private String name;
|
||||
@Column
|
||||
private String fullName;
|
||||
@Column
|
||||
private String pId;
|
||||
@Column
|
||||
private String pName;
|
||||
@Column
|
||||
private String type;
|
||||
@Column
|
||||
private String xPath;
|
||||
@Column
|
||||
private String xNamePath;
|
||||
@Column
|
||||
private String level;
|
||||
@Column
|
||||
private String hasChild;
|
||||
@Column
|
||||
private String division;
|
||||
@Column
|
||||
private String country;
|
||||
@Column
|
||||
private String region;
|
||||
@Column
|
||||
private String locality;
|
||||
@Column
|
||||
private String street;
|
||||
@Column
|
||||
private String address;
|
||||
@Column
|
||||
private String contact;
|
||||
@Column
|
||||
private String postalCode;
|
||||
@Column
|
||||
private String phone;
|
||||
@Column
|
||||
private String fax;
|
||||
@Column
|
||||
private String email;
|
||||
@Column
|
||||
private String sortOrder;
|
||||
@Column
|
||||
private String description;
|
||||
|
||||
/**
|
||||
*
|
||||
@@ -224,4 +249,31 @@ public class Organizations extends JpaBaseDomain implements Serializable{
|
||||
this.email = email;
|
||||
}
|
||||
|
||||
|
||||
public String getSortOrder() {
|
||||
return sortOrder;
|
||||
}
|
||||
|
||||
public void setSortOrder(String sortOrder) {
|
||||
this.sortOrder = sortOrder;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
||||
public void setDescription(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Organizations [id=" + id + ", code=" + code + ", name=" + name + ", fullName=" + fullName + ", pId="
|
||||
+ pId + ", pName=" + pName + ", type=" + type + ", xPath=" + xPath + ", xNamePath=" + xNamePath
|
||||
+ ", level=" + level + ", hasChild=" + hasChild + ", division=" + division + ", country=" + country
|
||||
+ ", region=" + region + ", locality=" + locality + ", street=" + street + ", address=" + address
|
||||
+ ", contact=" + contact + ", postalCode=" + postalCode + ", phone=" + phone + ", fax=" + fax
|
||||
+ ", email=" + email + ", sortOrder=" + sortOrder + ", description=" + description + "]";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -33,49 +33,81 @@ public class UserInfo extends JpaBaseDomain {
|
||||
String id;
|
||||
@Column
|
||||
protected String username;
|
||||
@Column
|
||||
protected String password;
|
||||
@Column
|
||||
protected String decipherable;
|
||||
@Column
|
||||
protected String sharedSecret;
|
||||
@Column
|
||||
protected String sharedCounter;
|
||||
/**
|
||||
* "Employee", "Supplier","Dealer","Contractor",Partner,Customer "Intern",
|
||||
"Temp", "External", and "Unknown"
|
||||
*/
|
||||
@Column
|
||||
protected String userType;
|
||||
@Column
|
||||
protected String windowsAccount;
|
||||
|
||||
//for user name
|
||||
@Column
|
||||
protected String displayName;
|
||||
@Column
|
||||
protected String nickName;
|
||||
@Column
|
||||
protected String nameZHSpell;
|
||||
@Column
|
||||
protected String nameZHShortSpell;
|
||||
@Column
|
||||
protected String givenName;
|
||||
@Column
|
||||
protected String middleName;
|
||||
@Column
|
||||
protected String familyName;
|
||||
@Column
|
||||
protected String honorificPrefix;
|
||||
@Column
|
||||
protected String honorificSuffix;
|
||||
@Column
|
||||
protected String formattedName;
|
||||
|
||||
@Column
|
||||
protected int married;
|
||||
@Column
|
||||
protected int gender;
|
||||
@Column
|
||||
protected String birthDate;
|
||||
@JsonIgnore
|
||||
@Column
|
||||
protected byte[] picture;
|
||||
@JsonIgnore
|
||||
protected MultipartFile pictureFile;
|
||||
@Column
|
||||
protected int idType;
|
||||
@Column
|
||||
protected String idCardNo;
|
||||
@Column
|
||||
protected String webSite;
|
||||
@Column
|
||||
protected String startWorkDate;
|
||||
|
||||
//for security
|
||||
@Column
|
||||
protected int authnType;
|
||||
@Column
|
||||
protected String email;
|
||||
|
||||
protected int emailVerified;
|
||||
@Column
|
||||
protected String mobile;
|
||||
|
||||
protected int mobileVerified;
|
||||
|
||||
protected String passwordQuestion;
|
||||
|
||||
protected String passwordAnswer;
|
||||
@Column
|
||||
//for apps login protected
|
||||
protected int appLoginAuthnType;
|
||||
protected String appLoginPassword;
|
||||
@@ -94,59 +126,83 @@ public class UserInfo extends JpaBaseDomain {
|
||||
protected int passwordSetType;
|
||||
protected Integer loginCount;
|
||||
|
||||
|
||||
@Column
|
||||
protected String locale;
|
||||
@Column
|
||||
protected String timeZone;
|
||||
@Column
|
||||
protected String preferredLanguage;
|
||||
|
||||
//for work
|
||||
@Column
|
||||
protected String workCountry;
|
||||
@Column
|
||||
protected String workRegion;//province;
|
||||
@Column
|
||||
protected String workLocality;//city;
|
||||
@Column
|
||||
protected String workStreetAddress;
|
||||
@Column
|
||||
protected String workAddressFormatted;
|
||||
@Column
|
||||
protected String workEmail;
|
||||
@Column
|
||||
protected String workPhoneNumber;
|
||||
@Column
|
||||
protected String workPostalCode;
|
||||
@Column
|
||||
protected String workFax;
|
||||
//for home
|
||||
@Column
|
||||
protected String homeCountry;
|
||||
@Column
|
||||
protected String homeRegion;//province;
|
||||
@Column
|
||||
protected String homeLocality;//city;
|
||||
@Column
|
||||
protected String homeStreetAddress;
|
||||
@Column
|
||||
protected String homeAddressFormatted;
|
||||
@Column
|
||||
protected String homeEmail;
|
||||
@Column
|
||||
protected String homePhoneNumber;
|
||||
@Column
|
||||
protected String homePostalCode;
|
||||
@Column
|
||||
protected String homeFax;
|
||||
//for company
|
||||
@Column
|
||||
protected String employeeNumber;
|
||||
@Column
|
||||
protected String costCenter;
|
||||
@Column
|
||||
protected String organization;
|
||||
@Column
|
||||
protected String division;
|
||||
@Column
|
||||
protected String departmentId;
|
||||
@Column
|
||||
protected String department;
|
||||
@Column
|
||||
protected String jobTitle;
|
||||
@Column
|
||||
protected String jobLevel;
|
||||
@Column
|
||||
protected String managerId;
|
||||
@Column
|
||||
protected String manager;
|
||||
@Column
|
||||
protected String assistantId;
|
||||
@Column
|
||||
protected String assistant;
|
||||
@Column
|
||||
protected String entryDate;
|
||||
@Column
|
||||
protected String quitDate;
|
||||
|
||||
//for social contact
|
||||
protected String qq;
|
||||
protected String weixin;
|
||||
protected String sinaweibo;
|
||||
protected String yixin;
|
||||
protected String facebook;
|
||||
protected String skype;
|
||||
protected String msn;
|
||||
protected String gtalk;
|
||||
protected String yahoo;
|
||||
protected String line;
|
||||
protected String aim;
|
||||
@Column
|
||||
protected String defineIm;
|
||||
protected int weixinFollow;
|
||||
|
||||
@@ -167,13 +223,17 @@ public class UserInfo extends JpaBaseDomain {
|
||||
|
||||
protected int gridList;
|
||||
|
||||
String createdBy;;
|
||||
@Column
|
||||
String createdBy;
|
||||
@Column
|
||||
String createdDate;
|
||||
@Column
|
||||
String modifiedBy;
|
||||
@Column
|
||||
String modifiedDate;
|
||||
|
||||
@Column
|
||||
int status;
|
||||
|
||||
@Column
|
||||
String description ;
|
||||
|
||||
|
||||
@@ -1025,94 +1085,7 @@ public class UserInfo extends JpaBaseDomain {
|
||||
this.gridList = gridList;
|
||||
}
|
||||
|
||||
public String getQq() {
|
||||
return qq;
|
||||
}
|
||||
|
||||
public void setQq(String qq) {
|
||||
this.qq = qq;
|
||||
}
|
||||
|
||||
public String getWeixin() {
|
||||
return weixin;
|
||||
}
|
||||
|
||||
public void setWeixin(String weixin) {
|
||||
this.weixin = weixin;
|
||||
}
|
||||
|
||||
public String getSinaweibo() {
|
||||
return sinaweibo;
|
||||
}
|
||||
|
||||
public void setSinaweibo(String sinaweibo) {
|
||||
this.sinaweibo = sinaweibo;
|
||||
}
|
||||
|
||||
public String getYixin() {
|
||||
return yixin;
|
||||
}
|
||||
|
||||
public void setYixin(String yixin) {
|
||||
this.yixin = yixin;
|
||||
}
|
||||
|
||||
public String getFacebook() {
|
||||
return facebook;
|
||||
}
|
||||
|
||||
public void setFacebook(String facebook) {
|
||||
this.facebook = facebook;
|
||||
}
|
||||
|
||||
public String getSkype() {
|
||||
return skype;
|
||||
}
|
||||
|
||||
public void setSkype(String skype) {
|
||||
this.skype = skype;
|
||||
}
|
||||
|
||||
public String getMsn() {
|
||||
return msn;
|
||||
}
|
||||
|
||||
public void setMsn(String msn) {
|
||||
this.msn = msn;
|
||||
}
|
||||
|
||||
public String getGtalk() {
|
||||
return gtalk;
|
||||
}
|
||||
|
||||
public void setGtalk(String gtalk) {
|
||||
this.gtalk = gtalk;
|
||||
}
|
||||
|
||||
public String getYahoo() {
|
||||
return yahoo;
|
||||
}
|
||||
|
||||
public void setYahoo(String yahoo) {
|
||||
this.yahoo = yahoo;
|
||||
}
|
||||
|
||||
public String getLine() {
|
||||
return line;
|
||||
}
|
||||
|
||||
public void setLine(String line) {
|
||||
this.line = line;
|
||||
}
|
||||
|
||||
public String getAim() {
|
||||
return aim;
|
||||
}
|
||||
|
||||
public void setAim(String aim) {
|
||||
this.aim = aim;
|
||||
}
|
||||
|
||||
|
||||
public String getDefineIm() {
|
||||
return defineIm;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
package org.maxkey.web;
|
||||
|
||||
import org.apache.mybatis.jpa.persistence.JpaBaseDomain;
|
||||
import org.apache.mybatis.jpa.persistence.JpaPageResults;
|
||||
import org.maxkey.web.message.Message;
|
||||
import org.springframework.web.bind.annotation.ModelAttribute;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
public interface BasicController <T extends JpaBaseDomain> {
|
||||
|
||||
public JpaPageResults<T> pageResults(@ModelAttribute("modelAttr") T modelAttr);
|
||||
|
||||
public ModelAndView forwardAdd(@ModelAttribute("modelAttr") T modelAttr);
|
||||
|
||||
public Message insert(@ModelAttribute("modelAttr") T modelAttr);
|
||||
|
||||
public ModelAndView forwardUpdate(@PathVariable("id") String id);
|
||||
|
||||
public Message update(@ModelAttribute("modelAttr") T modelAttr);
|
||||
|
||||
public Message delete(@ModelAttribute("modelAttr") T modelAttr) ;
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user