mgt-update
mgt-update
This commit is contained in:
@@ -2,10 +2,43 @@ 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;
|
||||
|
||||
@Table(name = "ORGANIZATIONS")
|
||||
public class Organizations extends JpaBaseDomain implements Serializable{
|
||||
|
||||
|
||||
@Id
|
||||
@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;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
@@ -15,4 +48,180 @@ public class Organizations extends JpaBaseDomain implements Serializable{
|
||||
// TODO Auto-generated constructor stub
|
||||
}
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(String code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getFullName() {
|
||||
return fullName;
|
||||
}
|
||||
|
||||
public void setFullName(String fullName) {
|
||||
this.fullName = fullName;
|
||||
}
|
||||
|
||||
public String getpId() {
|
||||
return pId;
|
||||
}
|
||||
|
||||
public void setpId(String pId) {
|
||||
this.pId = pId;
|
||||
}
|
||||
|
||||
public String getpName() {
|
||||
return pName;
|
||||
}
|
||||
|
||||
public void setpName(String pName) {
|
||||
this.pName = pName;
|
||||
}
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public void setType(String type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public String getxPath() {
|
||||
return xPath;
|
||||
}
|
||||
|
||||
public void setxPath(String xPath) {
|
||||
this.xPath = xPath;
|
||||
}
|
||||
|
||||
public String getxNamePath() {
|
||||
return xNamePath;
|
||||
}
|
||||
|
||||
public void setxNamePath(String xNamePath) {
|
||||
this.xNamePath = xNamePath;
|
||||
}
|
||||
|
||||
public String getLevel() {
|
||||
return level;
|
||||
}
|
||||
|
||||
public void setLevel(String level) {
|
||||
this.level = level;
|
||||
}
|
||||
|
||||
public String getHasChild() {
|
||||
return hasChild;
|
||||
}
|
||||
|
||||
public void setHasChild(String hasChild) {
|
||||
this.hasChild = hasChild;
|
||||
}
|
||||
|
||||
public String getDivision() {
|
||||
return division;
|
||||
}
|
||||
|
||||
public void setDivision(String division) {
|
||||
this.division = division;
|
||||
}
|
||||
|
||||
public String getCountry() {
|
||||
return country;
|
||||
}
|
||||
|
||||
public void setCountry(String country) {
|
||||
this.country = country;
|
||||
}
|
||||
|
||||
public String getRegion() {
|
||||
return region;
|
||||
}
|
||||
|
||||
public void setRegion(String region) {
|
||||
this.region = region;
|
||||
}
|
||||
|
||||
public String getLocality() {
|
||||
return locality;
|
||||
}
|
||||
|
||||
public void setLocality(String locality) {
|
||||
this.locality = locality;
|
||||
}
|
||||
|
||||
public String getStreet() {
|
||||
return street;
|
||||
}
|
||||
|
||||
public void setStreet(String street) {
|
||||
this.street = street;
|
||||
}
|
||||
|
||||
public String getAddress() {
|
||||
return address;
|
||||
}
|
||||
|
||||
public void setAddress(String address) {
|
||||
this.address = address;
|
||||
}
|
||||
|
||||
public String getContact() {
|
||||
return contact;
|
||||
}
|
||||
|
||||
public void setContact(String contact) {
|
||||
this.contact = contact;
|
||||
}
|
||||
|
||||
public String getPostalCode() {
|
||||
return postalCode;
|
||||
}
|
||||
|
||||
public void setPostalCode(String postalCode) {
|
||||
this.postalCode = postalCode;
|
||||
}
|
||||
|
||||
public String getPhone() {
|
||||
return phone;
|
||||
}
|
||||
|
||||
public void setPhone(String phone) {
|
||||
this.phone = phone;
|
||||
}
|
||||
|
||||
public String getFax() {
|
||||
return fax;
|
||||
}
|
||||
|
||||
public void setFax(String fax) {
|
||||
this.fax = fax;
|
||||
}
|
||||
|
||||
public String getEmail() {
|
||||
return email;
|
||||
}
|
||||
|
||||
public void setEmail(String email) {
|
||||
this.email = email;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,18 +1,14 @@
|
||||
package org.maxkey.web.tag;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.servlet.support.RequestContextUtils;
|
||||
import org.springframework.web.context.WebApplicationContext;
|
||||
import org.springframework.web.servlet.support.RequestContext;
|
||||
import org.springframework.web.servlet.tags.RequestContextAwareTag;
|
||||
|
||||
import freemarker.core.Environment;
|
||||
import freemarker.template.TemplateDirectiveBody;
|
||||
import freemarker.template.TemplateDirectiveModel;
|
||||
@@ -27,6 +23,7 @@ import freemarker.template.TemplateModel;
|
||||
|
||||
@FreemarkerTag("locale")
|
||||
public class LocaleTagDirective implements TemplateDirectiveModel {
|
||||
private static final Logger _logger = LoggerFactory.getLogger(LocaleTagDirective.class);
|
||||
@Autowired
|
||||
private HttpServletRequest request;
|
||||
|
||||
@@ -38,7 +35,13 @@ public class LocaleTagDirective implements TemplateDirectiveModel {
|
||||
if(params.get("code")==null) {
|
||||
env.getOut().append(RequestContextUtils.getLocale(request).getLanguage());
|
||||
}else {
|
||||
env.getOut().append(webApplicationContext.getMessage(params.get("code").toString(), null, RequestContextUtils.getLocale(request)));
|
||||
_logger.trace("message code "+params.get("code"));
|
||||
try {
|
||||
env.getOut().append(webApplicationContext.getMessage(params.get("code").toString(), null, RequestContextUtils.getLocale(request)));
|
||||
|
||||
}catch(Exception e) {
|
||||
_logger.error("message code "+params.get("code"),e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
package org.maxkey.web.tag;
|
||||
|
||||
public class St {
|
||||
|
||||
public static void main(String[] args) {
|
||||
// TODO Auto-generated method stub
|
||||
String cv="com.ddm.core.utils.TestClass@InnerClass1@InnerClass2@p2";
|
||||
|
||||
String[] c = cv.trim().split("@");
|
||||
for(String cs : c) {
|
||||
System.out.println(cs);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user