yun-zuoyi
jimmy 6 years ago
commit a2695771e0

@ -96,16 +96,43 @@ public class BaseResultBean<Obj> {
}
public static BaseResultBean buildBaseResultBean(boolean success,String msg){
BaseResultBean rs = new BaseResultBean();
BaseResultBean rs = new BaseResultBean();
rs.success = success;
if(success) {
if (success) {
rs.msg = msg;
rs.code = ResourceEnumUtil.MESSAGE.SUCCESS.getCode();
}else {
} else {
rs.code = ResourceEnumUtil.MESSAGE.FAIL.getCode();
rs.errorMsg = msg;
}
return rs;
}
public BaseResultBean setResultList(List<Obj> resultList) {
this.resultList = resultList;
return this;
}
public BaseResultBean setResultObject(Obj resultObject) {
this.resultObject = resultObject;
return this;
}
public BaseResultBean setResultMap(Map<String, Object> resultMap) {
this.resultMap = resultMap;
return this;
}
public BaseResultBean setPager(Pager pager) {
this.pager = pager;
return this;
}
public BaseResultBean setListPager(ListPager<Obj> listPager) {
this.listPager = listPager;
this.setPager(listPager.getObjectPager());
this.setResultList(listPager.getObjectList());
return this;
}
}

@ -21,17 +21,17 @@ public class CommonEnumUtil {
WMS(3, "i3wms", "仓库管理软件"),
MES(4, "i3mes", "生产管理软件"),
QMS(5, "i3qms", "质量管理软件"),
FORM(80,"block-form","智能表单"),
REPORT(81,"block-report","智能报表"),
WORKFLOW(82,"block-workflow","智能工作流"),
JOBFLOW(83,"block-jobflow","智能作业流"),
SOFTSWITCH(84,"block-softswitch","智能软件适配器"),
HARDSWITCH(85,"block-hardswitch","智能硬件适配器"),
CONSOLE(95,"impp-console","服务监控台"),
GATEWAY(96,"impp-gateway","服务网关"),
CLOUD(97,"i3cloud","微服务"),
FORM(20,"block-form","智能表单"),
REPORT(21,"block-report","智能报表"),
WORKFLOW(22,"block-workflow","智能工作流"),
JOBFLOW(23,"block-jobflow","智能作业流"),
SOFTSWITCH(24,"block-softswitch","智能软件适配器"),
HARDSWITCH(25,"block-hardswitch","智能硬件适配器"),
CENTER(99,"icloud-server","注册中心"),
SURFACE(98,"i3surface","对外服务"),
CENTER(99,"icloud-server","注册中心");
CLOUD(97,"i3cloud","微服务"),
GATEWAY(96,"impp-gateway","服务网关"),
CONSOLE(95,"impp-console","服务监控台");
private int value;
private String code;
@ -382,7 +382,7 @@ public class CommonEnumUtil {
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum DATA_STATUS {
ENABLE(1, "启用", "fa fa-success cell-fa fa-check"),
DISABLE(2, "禁", "fa fa-disabled cell-fa fa-times-circle"),
DISABLE(2, "禁", "fa fa-disabled cell-fa fa-times-circle"),
LOCKING(3, "锁定", "fa cell-fa fa-lock");
private int value;
@ -615,35 +615,195 @@ public class CommonEnumUtil {
*
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum CLOUD_STATUS {
REGISTERED(1, "注册"),
DISCONNECT(2, "断开");
public enum CLOUD_APP_STATUS {
UP(1,"UP" ,"在线"),
DOWN(2, "DOWN","断线");
private int value;
private String code;
private String description;
private CLOUD_APP_STATUS(int value, String code, String description) {
this.value = value;
this.code = code;
this.description = description;
}
public int getValue() {
return value;
}
public String getCode() {
return code;
}
public String getDescription() {
return description;
}
private CLOUD_STATUS(int value, String description) {
public static String valueOfCode(int val) {
String tmp = null;
for (int i = 0; i < values().length; i++) {
if (values()[i].value == val) {
tmp = values()[i].code;
}
}
return tmp;
}
public static int codeOfValue(String code) {
int tmp = 1;
for (int i = 0; i < values().length; i++) {
if (values()[i].code.equals(code)) {
tmp = values()[i].value;
}
}
return tmp;
}
public static String valueOfDescription(int val) {
String tmp = null;
for (int i = 0; i < values().length; i++) {
if (values()[i].value == val) {
tmp = values()[i].description;
}
}
return tmp;
}
public static String codeOfDescription(String code) {
String tmp = null;
for (int i = 0; i < values().length; i++) {
if (values()[i].code.equals(code)) {
tmp = values()[i].description;
}
}
return tmp;
}
}
/**
*
* return "Windows";
* return "Mac";
* return "Unix";
* return "Android";
* return "IPhone";
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum LOG_LOGIN_PLATFORM {
WINDOWS(1, "Windows", "Windows 操作系统"),
MAC(2, "Mac", "Mac 操作系统"),
UNIX(3, "Unix", "Linux 操作系统"),
ANDROID(4, "Android", "Android 操作系统"),
IPHONE(5, "IPhone", "IPhone 操作系统");
private int value;
private String name;
private String description;
LOG_LOGIN_PLATFORM() {
}
LOG_LOGIN_PLATFORM(int value, String name, String description) {
this.value = value;
this.name = name;
this.description = description;
}
public int getValue() {
return value;
}
public String getDescription() {
return description;
}
public String getName() {
return name;
}
public static String valueOf(int val) {
String tmp = null;
for (int i = 0; i < values().length; i++) {
if (values()[i].value == val) {
tmp = values()[i].description;
tmp = values()[i].getName();
}
}
return tmp;
}
/**
* -1
* @param desc
* @return
*/
public static int descOf(String desc) {
int tmp = -1;
for (int i = 0; i < values().length; i++) {
if (values()[i].name.equals(desc)) {
tmp = values()[i].value;
}
}
return tmp;
}
}
/**
*
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum USER_LOGIN_STATUS {
LOGIN_SUCCESS(1, "登录成功", "登录成功"),
WRONG_PASSWORD(3, "密码错误", "Linux 密码错误"),
WRONG_USERNAME_OR_PASSWORD(2, "用户名或密码错误", "用户名或密码错误"),
USER_LOGIN_LOCKING(4, "账号已锁定", "账号已锁定"),
USER_INFO_NULL(5, "用户信息不存在", "用户信息不存在"),
SYSTEM_ERROR(6, "系统异常", "系统异常");
private int value;
private String name;
private String description;
USER_LOGIN_STATUS() {
}
USER_LOGIN_STATUS(int value, String name, String description) {
this.value = value;
this.name = name;
this.description = description;
}
public int getValue() {
return value;
}
public String getDescription() {
return description;
}
public String getName() {
return name;
}
public static String valueOf(int val) {
String tmp = null;
for (int i = 0; i < values().length; i++) {
if (values()[i].value == val) {
tmp = values()[i].getName();
}
}
return tmp;
}
public static int descOf(String desc) {
int tmp = -1;
for (int i = 0; i < values().length; i++) {
if (values()[i].name.equals(desc)) {
tmp = values()[i].value;
}
}
return tmp;
}
}
}

@ -209,6 +209,16 @@ public class ImppEnumUtil {
return tmp;
}
public static String valueOfName(int val) {
String tmp = null;
for (int i = 0; i < values().length; i++) {
if (values()[i].value == val) {
tmp = values()[i].name;
}
}
return tmp;
}
public static String codeOfDescription(String code) {
String tmp = null;
for (int i = 0; i < values().length; i++) {

@ -0,0 +1,38 @@
package cn.estsh.i3plus.pojo.model.wms;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import java.io.Serializable;
/**
* @Description :
* @Reference :
* @Author : hansen.ke
* @CreateDate : 2018-12-17 11:39
* @Modify:
**/
@Data
public abstract class BaseComponetsParam implements Serializable {
@ApiParam(value = "单据号")
public String orderNo;
@ApiParam(value = "单据类型")
public String orderType;
@ApiParam(value = "条码")
public String sn;
@ApiParam(value = "条码类型")
public String snType;
@ApiParam(value = "用户编号")
public String userNo;
@ApiParam(value = "设备编号")
public String fixNo;
@ApiParam(value = "工厂代码")
public String organizeCode;
}

@ -0,0 +1,21 @@
package cn.estsh.i3plus.pojo.model.wms;
import io.swagger.annotations.ApiParam;
import lombok.Data;
/**
* @Description :
* @Reference :
* @Author : hansen.ke
* @CreateDate : 2018-12-17 11:50
* @Modify:
**/
@Data
public class TransSnModle extends BaseComponetsParam{
@ApiParam(value = "移动单号")
public String moveNo;
@ApiParam(value = "交易类型代码")
public String transTypeCode;
}

@ -31,23 +31,27 @@ public class SysLogUserLogin extends BaseBean {
@Column(name="USER_ID")
@ApiParam(value ="用户ID" , access ="用户ID")
private Long userId;
@Column(name="LOG_LOGIN_NAME")
@ApiParam(value ="登录名称" , access ="登录名称")
private String logLoginName;
@Column(name="LOG_LOGIN_STATUS")
@ApiParam(value ="登录状态枚举1.成功2.失败3锁定" , example ="1")
private Integer logLoginStatus;
@Column(name="LOG_LOGIN_PLATFORM")
@ApiParam(value ="登录平台ID枚举" , example ="1")
private Integer logLoginPlatform;
@Column(name="LOG_LOGIN_HOST")
@ApiParam(value ="登录IP" , access ="登录IP")
private String logLoginHost;
@Column(name="LOG_LOGIN_BROWSER")
@ApiParam(value ="登录浏览器" , access ="登录的浏览器")
private String logLoginBrowser;
@Column(name="LOG_LOGIN_DATE_TIME")
@ApiParam(value ="登录时间" , access ="登录时间")
private String logLoginDateTime;

@ -1,6 +1,7 @@
package cn.estsh.i3plus.pojo.platform.bean;
package cn.estsh.i3plus.pojo.platform.platbean;
import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import cn.estsh.i3plus.pojo.base.enumutil.CommonEnumUtil;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
import lombok.Data;
@ -33,6 +34,14 @@ public class SysLogException extends BaseBean {
@ApiParam(value ="系统模块(枚举)", example = "1")
private Integer excModule;
private String excModuleName;
public String getExcModuleName(){
if(this.excModule != null){
return CommonEnumUtil.SOFT_TYPE.valueOfDescription(this.excModule);
}
return excModuleName;
}
@Column(name="EXC_CLASS_NAME")
@ApiParam(value ="异常类名")
private String excClassName;

@ -1,6 +1,7 @@
package cn.estsh.i3plus.pojo.platform.bean;
package cn.estsh.i3plus.pojo.platform.platbean;
import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import cn.estsh.i3plus.pojo.base.enumutil.CommonEnumUtil;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.annotations.Api;
@ -35,6 +36,14 @@ public class SysLogOperate extends BaseBean {
@ApiParam(value ="系统模块(枚举)", example = "1")
private Integer operateModule;
private String operateModuleName;
public String getOperateModuleName(){
if(this.operateModule != null){
return CommonEnumUtil.SOFT_TYPE.valueOfDescription(this.operateModule);
}
return operateModuleName;
}
//ImppEnumUtil.OPERATE_TYPE枚举
@Column(name="OPERATE_TYPE")
@ApiParam(value ="操作类型" , example = "-1")

@ -1,4 +1,4 @@
package cn.estsh.i3plus.pojo.platform.bean;
package cn.estsh.i3plus.pojo.platform.platbean;
import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;

@ -1,7 +1,7 @@
package cn.estsh.i3plus.pojo.platform.repositorymongo;
package cn.estsh.i3plus.pojo.platform.platrepositorymongo;
import cn.estsh.i3plus.pojo.base.jpa.dao.BaseMongoRepository;
import cn.estsh.i3plus.pojo.platform.bean.SysLogException;
import cn.estsh.i3plus.pojo.platform.platbean.SysLogException;
/**
* @Description : (使Mongodb)

@ -1,7 +1,7 @@
package cn.estsh.i3plus.pojo.platform.repositorymongo;
package cn.estsh.i3plus.pojo.platform.platrepositorymongo;
import cn.estsh.i3plus.pojo.base.jpa.dao.BaseMongoRepository;
import cn.estsh.i3plus.pojo.platform.bean.SysLogOperate;
import cn.estsh.i3plus.pojo.platform.platbean.SysLogOperate;
/**
* @Description : (使Mongodb)

@ -1,7 +1,7 @@
package cn.estsh.i3plus.pojo.platform.repositorymongo;
package cn.estsh.i3plus.pojo.platform.platrepositorymongo;
import cn.estsh.i3plus.pojo.base.jpa.dao.BaseMongoRepository;
import cn.estsh.i3plus.pojo.platform.bean.SysLogSystem;
import cn.estsh.i3plus.pojo.platform.platbean.SysLogSystem;
/**
* @Description :

@ -1,9 +1,9 @@
package cn.estsh.i3plus.pojo.platform.sqlpack;
import cn.estsh.i3plus.pojo.base.tool.BsonPackTool;
import cn.estsh.i3plus.pojo.platform.bean.SysLogException;
import cn.estsh.i3plus.pojo.platform.bean.SysLogOperate;
import cn.estsh.i3plus.pojo.platform.bean.SysLogSystem;
import cn.estsh.i3plus.pojo.platform.platbean.SysLogException;
import cn.estsh.i3plus.pojo.platform.platbean.SysLogOperate;
import cn.estsh.i3plus.pojo.platform.platbean.SysLogSystem;
import com.mongodb.BasicDBObject;
import org.bson.conversions.Bson;

@ -832,6 +832,7 @@ public class WmsHqlPack {
HqlPack.getStringEqualPack(wmsMoveMaster.getOrderNo(), "orderNo", result);
HqlPack.getNumEqualPack(wmsMoveMaster.getOrderStatus(),"orderStatus",result);
HqlPack.getStringEqualPack(wmsMoveMaster.getTransTypeCode(), "transTypeCode", result);
getStringBuilderPack(wmsMoveMaster, result);
return result.toString();

Loading…
Cancel
Save