浏览代码

Merge remote-tracking branch 'origin/master'

Administrator 4 年之前
父节点
当前提交
ae2f3dcbd4
共有 34 个文件被更改,包括 35 次插入3089 次删除
  1. 8 0
      boman-common/boman-common-core/src/main/java/com/boman/common/core/web/domain/AjaxResult.java
  2. 0 43
      boman-modules/boman-system/src/main/java/com/boman/system/common/ApplicationContextHandle.java
  3. 0 23
      boman-modules/boman-system/src/main/java/com/boman/system/common/BaseFilter.java
  4. 0 80
      boman-modules/boman-system/src/main/java/com/boman/system/common/BaseTableService.java
  5. 0 307
      boman-modules/boman-system/src/main/java/com/boman/system/common/BusinessResult.java
  6. 0 190
      boman-modules/boman-system/src/main/java/com/boman/system/common/Column.java
  7. 0 962
      boman-modules/boman-system/src/main/java/com/boman/system/common/ColumnImpl.java
  8. 0 17
      boman-modules/boman-system/src/main/java/com/boman/system/common/DbRowAction.java
  9. 0 24
      boman-modules/boman-system/src/main/java/com/boman/system/common/DefaultTableService.java
  10. 0 24
      boman-modules/boman-system/src/main/java/com/boman/system/common/ExceptionFilter.java
  11. 0 94
      boman-modules/boman-system/src/main/java/com/boman/system/common/Feature.java
  12. 0 87
      boman-modules/boman-system/src/main/java/com/boman/system/common/FeatureManager.java
  13. 0 12
      boman-modules/boman-system/src/main/java/com/boman/system/common/Filter.java
  14. 3 117
      boman-modules/boman-system/src/main/java/com/boman/system/common/MainTableRecord.java
  15. 0 9
      boman-modules/boman-system/src/main/java/com/boman/system/common/NDSException.java
  16. 0 46
      boman-modules/boman-system/src/main/java/com/boman/system/common/OverlayJSONObject.java
  17. 0 47
      boman-modules/boman-system/src/main/java/com/boman/system/common/QueryUtils.java
  18. 0 69
      boman-modules/boman-system/src/main/java/com/boman/system/common/RequestUtil.java
  19. 0 57
      boman-modules/boman-system/src/main/java/com/boman/system/common/Resources.java
  20. 0 12
      boman-modules/boman-system/src/main/java/com/boman/system/common/ResultCode.java
  21. 8 97
      boman-modules/boman-system/src/main/java/com/boman/system/common/RowRecord.java
  22. 1 18
      boman-modules/boman-system/src/main/java/com/boman/system/common/RowResult.java
  23. 0 114
      boman-modules/boman-system/src/main/java/com/boman/system/common/StoredProcedureService.java
  24. 0 62
      boman-modules/boman-system/src/main/java/com/boman/system/common/SubTableRecord.java
  25. 0 21
      boman-modules/boman-system/src/main/java/com/boman/system/common/Table.java
  26. 0 18
      boman-modules/boman-system/src/main/java/com/boman/system/common/TableService.java
  27. 2 2
      boman-modules/boman-system/src/main/java/com/boman/system/common/TableServiceCmdService.java
  28. 9 111
      boman-modules/boman-system/src/main/java/com/boman/system/common/TableServiceContext.java
  29. 0 191
      boman-modules/boman-system/src/main/java/com/boman/system/common/User.java
  30. 0 54
      boman-modules/boman-system/src/main/java/com/boman/system/common/ValidationResults.java
  31. 0 8
      boman-modules/boman-system/src/main/java/com/boman/system/common/Validator.java
  32. 0 165
      boman-modules/boman-system/src/main/java/com/boman/system/common/ValueHolder.java
  33. 3 4
      boman-modules/boman-system/src/main/java/com/boman/system/controller/ObjController.java
  34. 1 4
      boman-modules/boman-system/src/main/java/com/boman/system/service/impl/BaseSaveService.java

+ 8 - 0
boman-common/boman-common-core/src/main/java/com/boman/common/core/web/domain/AjaxResult.java

@@ -159,4 +159,12 @@ public class AjaxResult extends HashMap<String, Object>
     {
         return new AjaxResult(code, msg, null);
     }
+
+    public static boolean checkSuccess(AjaxResult ajaxResult){
+        return null != ajaxResult && HttpStatus.SUCCESS == ((int) ajaxResult.get(CODE_TAG));
+    }
+
+    public static boolean checkFail(AjaxResult ajaxResult){
+        return !checkSuccess(ajaxResult);
+    }
 }

+ 0 - 43
boman-modules/boman-system/src/main/java/com/boman/system/common/ApplicationContextHandle.java

@@ -1,43 +0,0 @@
-package com.boman.system.common;
-
-import org.springframework.beans.BeansException;
-import org.springframework.context.ApplicationContext;
-import org.springframework.context.ApplicationContextAware;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 15:27
- **/
-public class ApplicationContextHandle implements ApplicationContextAware {
-
-    private static ApplicationContext applicationContext;
-
-    public ApplicationContextHandle() {
-    }
-
-    public static Object getBean(String name) throws BeansException {
-        return applicationContext.getBean(name);
-    }
-
-    public static ApplicationContext getApplicationContext() {
-        return applicationContext;
-    }
-
-    @Override
-    public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
-        if (ApplicationContextHandle.applicationContext == null) {
-            ApplicationContextHandle.applicationContext = applicationContext;
-        }
-
-        System.out.println("========ApplicationContext配置成功,在普通类可以通过调用SpringUtils.getAppContext()获取applicationContext对象,applicationContext=" + ApplicationContextHandle.applicationContext + "========");
-    }
-
-    public static <T> T getBean(Class<T> clazz) {
-        return getApplicationContext().getBean(clazz);
-    }
-
-    public static <T> T getBean(String name, Class<T> clazz) {
-        return getApplicationContext().getBean(name, clazz);
-    }
-}

+ 0 - 23
boman-modules/boman-system/src/main/java/com/boman/system/common/BaseFilter.java

@@ -1,23 +0,0 @@
-package com.boman.system.common;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 11:02
- **/
-public class BaseFilter {
-
-    private static final Logger log = LoggerFactory.getLogger(BaseFilter.class);
-
-    public BaseFilter() {
-    }
-
-    public void before(TableServiceContext context, MainTableRecord row) {
-    }
-
-    public void after(TableServiceContext context, MainTableRecord row) {
-    }
-}

+ 0 - 80
boman-modules/boman-system/src/main/java/com/boman/system/common/BaseTableService.java

@@ -1,80 +0,0 @@
-package com.boman.system.common;
-
-import com.boman.system.service.impl.BaseSaveService;
-import lombok.Getter;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.beans.factory.annotation.Qualifier;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 10:30
- **/
-public abstract class BaseTableService  implements TableService{
-
-
-    @Autowired
-    @Qualifier("baseSaveService-one")
-    private BaseSaveService baseSaveService;
-    @Getter
-    private String tableName;
-
-    private boolean isInitialized;
-
-    public BaseTableService() {
-    }
-
-    protected BaseTableService(String tableName) {
-        this.tableName = tableName;
-        isInitialized = false;
-    }
-
-    @Override
-    public final void configure(TableServiceContext context) {
-        if (!isInitialized) {
-            doConfigure(context);
-            isInitialized = true;
-        }
-    }
-
-    protected void doConfigure(TableServiceContext context) {
-        //每个业务可以在自己所在的自定义服务实现内部调整下自己的上下文(针对validators/filters的调整)
-        //本方法一个表只会执行一次才对
-    }
-
-    @Override
-    public RowResult executeAction(TableServiceContext context, MainTableRecord row) {
-        LOGGER.debug("action====>" + context.getActionName());
-        return baseSaveService.insertRow(context, row, context.getCurrentTime());
-
-
-//        switch (context.getActionName()) {
-//            case Constants.ACTION_SAVE:
-//                switch (row.getAction()) {
-//                    case INSERT:
-//                        return baseSaveService.insertRow(context, row, context.getCurrentTime());
-//                    case UPDATE:
-//                        //return baseSaveService.updateRow(context, row, context.getCurrentTime());
-//                    default:
-//                }
-//                throw new NDSException("不应该执行到这里吧!");
-//            case Constants.ACTION_DELETE:
-//                //return baseDelService.delete(context, row);
-//            case Constants.ACTION_VOID:
-//                //return baseVoidService.execute(context, row);
-//            case Constants.ACTION_SUBMIT:
-//                //return baseSubmitService.isFlow(context, row);
-//            case Constants.ACTION_UNSUBMIT:
-//                //return baseUnSubmitService.execute(context, row);
-//
-//            default:
-////            default:
-////                return RowResult.error("未知动作:" + context.getActionName());
-//        }
-//        return RowResult.ok(context.getLocale());
-
-//        return RowResult.ok("");
-    }
-
-
-}

+ 0 - 307
boman-modules/boman-system/src/main/java/com/boman/system/common/BusinessResult.java

@@ -1,307 +0,0 @@
-package com.boman.system.common;
-
-import com.alibaba.fastjson.JSONObject;
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 13:51
- **/
-public class BusinessResult implements Serializable {
-    private static final long serialVersionUID = 5882709765648149444L;
-    private Long objId;
-    private List<BusinessResult.Error> errors;
-    private BusinessResult.ExtAttr extAttr;
-    private JSONObject notice;
-
-    public BusinessResult() {
-    }
-
-    public BusinessResult(Long objId) {
-        this.objId = objId;
-    }
-
-    public BusinessResult(Long objId, List<BusinessResult.Error> error) {
-        this.objId = objId;
-        this.errors = error;
-    }
-
-    public void putErrorItem(Long id, Integer code, String message) {
-        if (this.errors == null) {
-            this.errors = new ArrayList();
-        }
-
-        this.errors.add(new BusinessResult.Error(id, code, message));
-    }
-
-    public Long getObjId() {
-        return this.objId;
-    }
-
-    public List<BusinessResult.Error> getErrors() {
-        return this.errors;
-    }
-
-    public BusinessResult.ExtAttr getExtAttr() {
-        return this.extAttr;
-    }
-
-    public JSONObject getNotice() {
-        return this.notice;
-    }
-
-    public void setObjId(final Long objId) {
-        this.objId = objId;
-    }
-
-    public void setErrors(final List<BusinessResult.Error> errors) {
-        this.errors = errors;
-    }
-
-    public void setExtAttr(final BusinessResult.ExtAttr extAttr) {
-        this.extAttr = extAttr;
-    }
-
-    public void setNotice(final JSONObject notice) {
-        this.notice = notice;
-    }
-
-    public boolean equals(final Object o) {
-        if (o == this) {
-            return true;
-        } else if (!(o instanceof BusinessResult)) {
-            return false;
-        } else {
-            BusinessResult other = (BusinessResult)o;
-            if (!other.canEqual(this)) {
-                return false;
-            } else {
-                label59: {
-                    Object this$objId = this.getObjId();
-                    Object other$objId = other.getObjId();
-                    if (this$objId == null) {
-                        if (other$objId == null) {
-                            break label59;
-                        }
-                    } else if (this$objId.equals(other$objId)) {
-                        break label59;
-                    }
-
-                    return false;
-                }
-
-                Object this$errors = this.getErrors();
-                Object other$errors = other.getErrors();
-                if (this$errors == null) {
-                    if (other$errors != null) {
-                        return false;
-                    }
-                } else if (!this$errors.equals(other$errors)) {
-                    return false;
-                }
-
-                Object this$extAttr = this.getExtAttr();
-                Object other$extAttr = other.getExtAttr();
-                if (this$extAttr == null) {
-                    if (other$extAttr != null) {
-                        return false;
-                    }
-                } else if (!this$extAttr.equals(other$extAttr)) {
-                    return false;
-                }
-
-                Object this$notice = this.getNotice();
-                Object other$notice = other.getNotice();
-                if (this$notice == null) {
-                    return other$notice == null;
-                } else return this$notice.equals(other$notice);
-            }
-        }
-    }
-
-    protected boolean canEqual(final Object other) {
-        return other instanceof BusinessResult;
-    }
-
-    @Override
-    public int hashCode() {
-        boolean PRIME = true;
-        int result = 1;
-        Object $objId = this.getObjId();
-        result = result * 59 + ($objId == null ? 43 : $objId.hashCode());
-        Object $errors = this.getErrors();
-        result = result * 59 + ($errors == null ? 43 : $errors.hashCode());
-        Object $extAttr = this.getExtAttr();
-        result = result * 59 + ($extAttr == null ? 43 : $extAttr.hashCode());
-        Object $notice = this.getNotice();
-        result = result * 59 + ($notice == null ? 43 : $notice.hashCode());
-        return result;
-    }
-
-    @Override
-    public String toString() {
-        return "BusinessResult(objId=" + this.getObjId() + ", errors=" + this.getErrors() + ", extAttr=" + this.getExtAttr() + ", notice=" + this.getNotice() + ")";
-    }
-
-    public static class Error {
-        private Long id;
-        private Integer code;
-        private String message;
-
-        public Error() {
-        }
-
-        public Error(Long id, Integer code, String message) {
-            this.id = id;
-            this.code = code;
-            this.message = message;
-        }
-
-        public Long getId() {
-            return this.id;
-        }
-
-        public Integer getCode() {
-            return this.code;
-        }
-
-        public String getMessage() {
-            return this.message;
-        }
-
-        public void setId(final Long id) {
-            this.id = id;
-        }
-
-        public void setCode(final Integer code) {
-            this.code = code;
-        }
-
-        public void setMessage(final String message) {
-            this.message = message;
-        }
-
-        public boolean equals(final Object o) {
-            if (o == this) {
-                return true;
-            } else if (!(o instanceof BusinessResult.Error)) {
-                return false;
-            } else {
-                BusinessResult.Error other = (BusinessResult.Error)o;
-                if (!other.canEqual(this)) {
-                    return false;
-                } else {
-                    label47: {
-                        Object this$id = this.getId();
-                        Object other$id = other.getId();
-                        if (this$id == null) {
-                            if (other$id == null) {
-                                break label47;
-                            }
-                        } else if (this$id.equals(other$id)) {
-                            break label47;
-                        }
-
-                        return false;
-                    }
-
-                    Object this$code = this.getCode();
-                    Object other$code = other.getCode();
-                    if (this$code == null) {
-                        if (other$code != null) {
-                            return false;
-                        }
-                    } else if (!this$code.equals(other$code)) {
-                        return false;
-                    }
-
-                    Object this$message = this.getMessage();
-                    Object other$message = other.getMessage();
-                    if (this$message == null) {
-                        return other$message == null;
-                    } else return this$message.equals(other$message);
-                }
-            }
-        }
-
-        protected boolean canEqual(final Object other) {
-            return other instanceof BusinessResult.Error;
-        }
-
-        public int hashCode() {
-            boolean PRIME = true;
-            int result = 1;
-            Object $id = this.getId();
-            result = result * 59 + ($id == null ? 43 : $id.hashCode());
-            Object $code = this.getCode();
-            result = result * 59 + ($code == null ? 43 : $code.hashCode());
-            Object $message = this.getMessage();
-            result = result * 59 + ($message == null ? 43 : $message.hashCode());
-            return result;
-        }
-
-        @Override
-        public String toString() {
-            return "BusinessResult.Error(id=" + this.getId() + ", code=" + this.getCode() + ", message=" + this.getMessage() + ")";
-        }
-    }
-
-    public static class ExtAttr {
-        private Integer msgType;
-
-        public ExtAttr() {
-        }
-
-        public ExtAttr(Integer msgType) {
-            this.msgType = msgType;
-        }
-
-        public Integer getMsgType() {
-            return this.msgType;
-        }
-
-        public void setMsgType(final Integer msgType) {
-            this.msgType = msgType;
-        }
-
-        public boolean equals(final Object o) {
-            if (o == this) {
-                return true;
-            } else if (!(o instanceof BusinessResult.ExtAttr)) {
-                return false;
-            } else {
-                BusinessResult.ExtAttr other = (BusinessResult.ExtAttr)o;
-                if (!other.canEqual(this)) {
-                    return false;
-                } else {
-                    Object this$msgType = this.getMsgType();
-                    Object other$msgType = other.getMsgType();
-                    if (this$msgType == null) {
-                        return other$msgType == null;
-                    } else return this$msgType.equals(other$msgType);
-                }
-            }
-        }
-
-        protected boolean canEqual(final Object other) {
-            return other instanceof BusinessResult.ExtAttr;
-        }
-
-        public int hashCode() {
-            boolean PRIME = true;
-            int result = 1;
-            Object $msgType = this.getMsgType();
-            result = result * 59 + ($msgType == null ? 43 : $msgType.hashCode());
-            return result;
-        }
-
-        @Override
-        public String toString() {
-            return "BusinessResult.ExtAttr(msgType=" + this.getMsgType() + ")";
-        }
-    }
-}
-

+ 0 - 190
boman-modules/boman-system/src/main/java/com/boman/system/common/Column.java

@@ -1,190 +0,0 @@
-package com.boman.system.common;
-
-import java.io.Serializable;
-import java.util.Locale;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 16:16
- **/
-public interface Column extends Serializable {
-
-    int NUMBER = 0;
-    int DATE = 1;
-    int STRING = 2;
-    int DATENUMBER = 3;
-    int TIME = 4;
-    int OTHER = 9;
-    int ADD = 0;
-    int MODIFY = 1;
-    int QUERY_LIST = 2;
-    int QUERY_SUBLIST = 3;
-    int QUERY_OBJECT = 4;
-    int PRINT_LIST = 5;
-    int PRINT_SUBLIST = 6;
-    int PRINT_OBJECT = 7;
-    int MASK_CREATE_SHOW = 0;
-    int MASK_CREATE_EDIT = 1;
-    int MASK_MODIFIY_SHOW = 2;
-    int MASK_MODIFY_EDIT = 3;
-    int MASK_QUERY_LIST = 4;
-    int MASK_QUERY_SUBLIST = 5;
-    int MASK_QUERY_OBJECTVIEW = 6;
-    int MASK_PRINT_LIST = 7;
-    int MASK_PRINT_SUBLIST = 8;
-    int MASK_PRINT_OBJECTVIEW = 9;
-    int ON_DELETE_NOACTION = 0;
-    int ON_DELETE_SETNULL = 1;
-    int ON_DELETE_CASCADE = 2;
-
-//    boolean isAlternateKey();
-//
-//    boolean isAlternateKey2();
-//
-//    boolean isDisplayKey();
-//
-//    String getComment();
-//
-//    String getShowcomment();
-//
-//    Boolean getIsorder();
-//
-//    Boolean getShowtitle();
-//
-//    Boolean getRowspan();
-//
-//    String getLimitValueGroupName();
-//
-//    boolean isShowable(int action);
-//
-//    boolean isMaskSet(int maskPosition);
-//
-//    boolean isMaskequls(int maskPosition);
-//
-//    boolean isModifiable(int action);
-//
-//    boolean isNullable();
-//
-//    boolean isValueLimited();
-
-//    PairTable getValues(Locale locale);
-//
-//    int getLength();
-//
-//    int getScale();
-//
-//    int getStatSize();
-//
-//    Table getReferenceTable();
-//
-//    Column getReferenceColumn();
-//
-//    Table getReferenceTable(boolean tryDateNumberAsFK, TableManager tm);
-//
-//    Column getReferenceColumn(boolean tryDateNumberAsFK, TableManager tm);
-//
-//    int getDisplayOrder();
-//
-//    String getValueInterpeter();
-//
-//    Object getUIConstructor();
-//
-//    int getId();
-//
-//    String getName();
-//
-//    String getDescription(Locale locale);
-//
-//    int getSQLType();
-//
-//    int getType();
-//
-//    Table getTable();
-//
-//    String getLimit();
-//
-//    String getMoney();
-//
-//    boolean getModifiable();
-//
-//    String getObtainManner();
-//
-//    String getDefaultValue();
-//
-//    String getDefaultValue(boolean eval);
-//
-//    String getReferenceColumnName();
-//
-//    String getTableColumnName();
-//
-//    Table getObjectTable();
-//
-//    String getRegExpression();
-//
-//    Properties getProperties();
-//
-//    String getErrorMessage();
-//
-//    boolean isVirtual();
-//
-//    boolean isComputed();
-//
-//    String getSubTotalMethod();
-//
-//    String getSubTotalDesc();
-//
-//    String getFilter();
-//
-//    DisplaySetting getDisplaySetting();
-//
-//    String getSequenceHead();
-//
-//    boolean isFilteredByWildcard();
-//
-//    List getReferenceColumnsInWildcardFilter();
-//
-//    boolean isColumnLink(TableManager tm);
-//
-//    ColumnLink getColumnLink(TableManager tm) throws QueryException;
-//
-//    Object getUIAlerter();
-//
-//    boolean isUpperCase();
-//
-//    boolean isIndexed();
-//
-//    boolean isAutoComplete();
-//
-//    int getSecurityGrade();
-//
-//    /** @deprecated */
-//    @Deprecated
-//    int getOnDeleteAction();
-//
-//    JSONObject toJSONSimpleObject() throws JSONException;
-//
-//    JSONObject toJSONObject(Locale locale) throws JSONException;
-//
-//    JSONObject getJSONProps();
-//
-//    String getFkdisplay();
-//
-//    String getQuerydefval();
-//
-//    LimitvalueGroup getLimitvalueGroup();
-//
-//    String getSearchtype();
-//
-//    boolean getIsremote();
-//
-//    String getSearchmodel();
-//
-//    String getCommentstp();
-//
-//    Boolean getIsagfilter();
-//
-//    String getAgfilter();
-//
-//    ColumnMeta getColumnMeta();
-}

+ 0 - 962
boman-modules/boman-system/src/main/java/com/boman/system/common/ColumnImpl.java

@@ -1,962 +0,0 @@
-package com.boman.system.common;
-
-import com.alibaba.fastjson.JSONException;
-import com.alibaba.fastjson.JSONObject;
-import io.seata.rm.datasource.sql.struct.ColumnMeta;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import java.util.*;
-import java.util.regex.Pattern;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 16:17
- **/
-public class ColumnImpl implements Column {
-    private static final Logger log = LoggerFactory.getLogger(ColumnImpl.class);
-    private static final long serialVersionUID = -5809782578272943999L;
-    private static Pattern msgKeyPattern = Pattern.compile("\\p{Punct}");
-    private static Pattern spaceKeyPattern = Pattern.compile(" ");
-    private int id = -1;
-    private String name;
-    private String description;
-    private String description2 = null;
-    private boolean isNullable;
-    private String limit = null;
-    private String money = null;
-    private boolean modifiable;
-    private String obtainManner;
-    private String defaultValue;
-    private String refColumnName;
-    private String tableColumnName;
-    private Table objectTable;
-    private String regExpression;
-    private String errorMessage;
-    private String comment = null;
-    private String filter;
-//    private DisplaySetting displaySetting;
-    private boolean isUpperCase;
-    private int sqltype;
-    private int type;
-    private boolean isAlternateKey;
-    private boolean isAlternateKey2;
-    private boolean isDisplayKey;
-    private String mask;
-    private boolean isValueLimited;
-//    private PairTable values = null;
-    private int length;
-    private Table rTable = null;
-    private Column rColumn = null;
-    private Table table = null;
-    private int displayOrder;
-    private String valueInterpreter = null;
-    private boolean isVirtual = false;
-    private String sumMethod = null;
-    private String sumMethodDesc = "";
-    private int scale = 0;
-    private String sequenceHead = null;
-    private String command = null;
-    private String valueGroupName;
-    private boolean isIndexed = false;
-    private int onDeleteAction = 0;
-    private int statSize = -1;
-    private boolean isFilteredByWildcard = false;
-    private List referenceColumnsInWildcardFilter = null;
-    private Properties props = null;
-    private boolean isAutoComplete = false;
-    private JSONObject jsonProps = null;
-    private String strProps = null;
-    private String showcomment;
-    private int securityGrade = 0;
-    private Boolean showtitle;
-    private boolean isorder = false;
-    private String fkdisplay = null;
-    private String querydefval = null;
-//    private LimitvalueGroup limitvalueGroup;
-    private String searchtype;
-    private Boolean isremote;
-    private String searchmodel;
-    private String commentstp;
-    private Boolean isagfilter;
-    private String agfilter;
-    private boolean isRowspan = false;
-    private Locale defaultlocal = new Locale("zh", "CN");
-    private ColumnMeta columnMeta;
-
-//    public ColumnMeta getColumnMeta() {
-//        return this.columnMeta;
-//    }
-//
-//    public void setColumnMeta(ColumnMeta columnMeta) {
-//        this.columnMeta = columnMeta;
-//    }
-//
-//    public ColumnImpl() {
-//    }
-//
-//    public ColumnImpl(int id, Table table, String columnName, String desc, int sqltype, boolean isNull) {
-//        this.id = id;
-//        this.table = table;
-//        this.name = columnName;
-//        this.description = desc;
-//        this.sqltype = sqltype;
-//        this.type = toGrossType(sqltype);
-//        this.isNullable = isNull;
-//        this.isVirtual = this.checkVirtual();
-//    }
-//
-//    public static int toGrossType(int type) {
-//        byte jType;
-//        switch(type) {
-//            case 1:
-//            case 12:
-//            case 13:
-//            case 22:
-//            case 24:
-//            case 25:
-//                jType = 2;
-//                break;
-//            case 2:
-//            case 3:
-//            case 4:
-//            case 5:
-//            case 6:
-//            case 7:
-//            case 8:
-//            case 9:
-//            case 10:
-//            case 16:
-//                jType = 0;
-//                break;
-//            case 11:
-//            case 14:
-//                jType = 1;
-//                break;
-//            case 15:
-//                jType = 4;
-//                break;
-//            case 17:
-//            case 18:
-//            case 19:
-//            case 20:
-//            case 21:
-//            default:
-//                jType = 9;
-//                break;
-//            case 23:
-//                jType = 3;
-//        }
-//
-//        return jType;
-//    }
-//
-//    public void setIsIndexed(boolean b) {
-//        this.isIndexed = b;
-//    }
-//
-//    public boolean isFilteredByWildcard() {
-//        return this.isFilteredByWildcard;
-//    }
-//
-//    public final Properties getProperties() {
-//        return this.props;
-//    }
-//
-//    public boolean isIndexed() {
-//        return this.isIndexed;
-//    }
-//
-//    public boolean isAutoComplete() {
-//        return this.isAutoComplete;
-//    }
-//
-//    public boolean setIsAutoComplete(boolean b) {
-//        return this.isAutoComplete = b;
-//    }
-//
-//    /** @deprecated */
-//    @Deprecated
-//    public int getOnDeleteAction() {
-//        return this.onDeleteAction;
-//    }
-//
-//    /** @deprecated */
-//    @Deprecated
-//    public void setOnDeleteAction(String s) {
-//        if ("SETNULL".equalsIgnoreCase(s)) {
-//            this.onDeleteAction = 1;
-//        } else if ("CASCADE".equalsIgnoreCase(s)) {
-//            this.onDeleteAction = 2;
-//        }
-//
-//    }
-//
-//    public void setIsNullable(boolean n) {
-//        this.isNullable = n;
-//    }
-//
-//    public String getLimitValueGroupName() {
-//        return this.valueGroupName;
-//    }
-//
-//    public int getScale() {
-//        return this.scale;
-//    }
-//
-//    public void setScale(int scale) {
-//        this.scale = scale;
-//    }
-//
-//    private boolean checkVirtual() {
-//        char[] cs = this.name.toCharArray();
-//
-//        for(int i = 0; i < cs.length; ++i) {
-//            if ((cs[i] < '0' || cs[i] > '9') && cs[i] != '_' && cs[i] != '-' && (cs[i] < 'a' || cs[i] > 'z') && (cs[i] < 'A' || cs[i] > 'Z')) {
-//                return true;
-//            }
-//        }
-//
-//        return false;
-//    }
-//
-//    public int getStatSize() {
-//        return this.statSize;
-//    }
-//
-//    public void setStatSize(int size) {
-//        this.statSize = size;
-//    }
-//
-//    public String getComment() {
-//        return this.comment;
-//    }
-//
-//    public void setComment(String s) {
-//        this.comment = s;
-//    }
-//
-//    public void setIsAlternateKey(boolean ak) {
-//        this.isAlternateKey = ak;
-//    }
-//
-//    public void setIsAlternateKey2(boolean ak2) {
-//        this.isAlternateKey2 = ak2;
-//    }
-//
-//    public void setIsDisplayKey(boolean dk) {
-//        this.isDisplayKey = dk;
-//    }
-//
-//    public boolean isDisplayKey() {
-//        return this.isDisplayKey;
-//    }
-//
-//    public void setMask(String mask) {
-//        this.mask = mask;
-//    }
-//
-//    public void setIsValueLimited(boolean limit) {
-//        this.isValueLimited = limit;
-//    }
-//
-//    public void setValues(String valueGroupName, PairTable vs, Locale locale) {
-//        this.valueGroupName = valueGroupName.toLowerCase();
-//        if (this.values == null) {
-//            this.values = new PairTable();
-//        }
-//
-//        this.values.put(locale, vs);
-//    }
-//
-//    public void setValueInterpreter(String interpreter) {
-//        if (interpreter == null) {
-//            this.valueInterpreter = null;
-//        } else {
-//            this.valueInterpreter = interpreter;
-//        }
-//    }
-//
-//    public boolean isAlternateKey() {
-//        return this.isAlternateKey;
-//    }
-//
-//    public boolean isAlternateKey2() {
-//        return this.isAlternateKey2;
-//    }
-//
-//    public boolean isNullable() {
-//        return this.isNullable || this.displaySetting.getObjectType() == 5;
-//    }
-//
-//    public boolean isMaskSet(int maskPosition) {
-//        if (maskPosition >= 0 && maskPosition < this.mask.length()) {
-//            try {
-//                return this.mask.charAt(maskPosition) == '1';
-//            } catch (IndexOutOfBoundsException var3) {
-//                throw new IllegalArgumentException("mask position out of range:" + maskPosition + ",mask:" + this.mask);
-//            }
-//        } else {
-//            return false;
-//        }
-//    }
-//
-//    public boolean isMaskequls(int maskPosition) {
-//        if (maskPosition >= 0 && maskPosition < this.mask.length()) {
-//            try {
-//                return this.mask.equals(Tools.replaceCharAt("0000000000", maskPosition, '1'));
-//            } catch (IndexOutOfBoundsException var3) {
-//                throw new IllegalArgumentException("mask position out of range:" + maskPosition + ",mask:" + this.mask);
-//            }
-//        } else {
-//            return false;
-//        }
-//    }
-//
-//    public boolean isShowable(int action) {
-//        char c = true;
-//        char c;
-//        switch(action) {
-//            case 0:
-//                c = this.mask.charAt(0);
-//                break;
-//            case 1:
-//                c = this.mask.charAt(2);
-//                break;
-//            case 2:
-//                c = this.mask.charAt(4);
-//                break;
-//            case 3:
-//                c = this.mask.charAt(5);
-//                break;
-//            case 4:
-//                c = this.mask.charAt(6);
-//                break;
-//            case 5:
-//                c = this.mask.charAt(7);
-//                break;
-//            case 6:
-//                c = this.mask.charAt(8);
-//                break;
-//            case 7:
-//                c = this.mask.charAt(9);
-//                break;
-//            default:
-//                throw new IllegalArgumentException("action is not valid:" + action);
-//        }
-//
-//        return c == '1';
-//    }
-//
-//    public boolean isModifiable(int action) {
-//        char c = true;
-//        char c;
-//        switch(action) {
-//            case 0:
-//                c = this.mask.charAt(1);
-//                break;
-//            case 1:
-//                c = this.mask.charAt(3);
-//                break;
-//            case 2:
-//                c = this.mask.charAt(1);
-//                break;
-//            case 3:
-//                c = this.mask.charAt(3);
-//                break;
-//            case 4:
-//                c = '0';
-//                break;
-//            default:
-//                throw new IllegalArgumentException("action is not valid:" + action);
-//        }
-//
-//        return c == '1';
-//    }
-//
-//    public boolean isValueLimited() {
-//        return this.isValueLimited;
-//    }
-//
-//    public PairTable getValues(Locale locale) {
-//        if (this.values == null) {
-//            return null;
-//        } else {
-//            PairTable pt = (PairTable)this.values.get(locale);
-//            if (pt == null) {
-//                pt = new PairTable();
-//                Iterator it = this.getValues(this.defaultlocal).keys();
-//
-//                while(it.hasNext()) {
-//                    Object value = it.next();
-//                    pt.put(value, Resources.getMessage("lmt_" + this.valueGroupName + "_" + value, new Object[0]).toLowerCase());
-//                }
-//
-//                this.values.put(locale, pt);
-//            }
-//
-//            return pt;
-//        }
-//    }
-//
-//    public int getLength() {
-//        return this.length;
-//    }
-//
-//    public void setLength(int leng) {
-//        this.length = leng;
-//    }
-//
-//    public Table getReferenceTable() {
-//        return this.rTable;
-//    }
-//
-//    public void setReferenceTable(Table rt) {
-//        this.rTable = rt;
-//    }
-//
-//    public Column getReferenceColumn() {
-//        return this.rColumn;
-//    }
-//
-//    public void setReferenceColumn(Column rc) {
-//        this.rColumn = rc;
-//    }
-//
-//    public Table getReferenceTable(boolean tryDateNumberAsFK, TableManager tm) {
-//        if (this.rTable != null) {
-//            return this.rTable;
-//        } else {
-//            return tryDateNumberAsFK && this.type == 3 ? tm.getDateTable() : null;
-//        }
-//    }
-//
-//    public Column getReferenceColumn(boolean tryDateNumberAsFK, TableManager tm) {
-//        if (this.rColumn != null) {
-//            return this.rColumn;
-//        } else {
-//            if (tryDateNumberAsFK && this.type == 3) {
-//                Table tb = tm.getDateTable();
-//                if (tb != null) {
-//                    return tb.getPrimaryKey();
-//                }
-//            }
-//
-//            return null;
-//        }
-//    }
-//
-//    public int getDisplayOrder() {
-//        return this.displayOrder;
-//    }
-//
-//    public void setDisplayOrder(int order) {
-//        this.displayOrder = order;
-//    }
-//
-//    public String getValueInterpeter() {
-//        return this.valueInterpreter;
-//    }
-//
-//    public int getId() {
-//        return this.id;
-//    }
-//
-//    public String getName() {
-//        return this.name;
-//    }
-//
-//    public String getDescription() {
-//        return this.description;
-//    }
-//
-//    public String getDescription(Locale locale) {
-//        try {
-//            return Resources.getMessage("adcolumn_" + this.id, locale, new Object[]{this.description});
-//        } catch (MissingResourceException var3) {
-//            return this.description;
-//        }
-//    }
-//
-//    public void setDescription(String desc) {
-//        this.description = desc;
-//    }
-//
-//    private String toMessageKey(String s) {
-//        return spaceKeyPattern.matcher(msgKeyPattern.matcher(s).replaceAll("_")).replaceAll("");
-//    }
-//
-//    public void setDescription2(String desc2) {
-//        this.description2 = desc2;
-//    }
-//
-//    public int getSQLType() {
-//        return this.sqltype;
-//    }
-//
-//    public void setSQLType(int sqlType) {
-//        this.sqltype = sqlType;
-//        this.type = toGrossType(this.sqltype);
-//    }
-//
-//    public int getType() {
-//        return this.type;
-//    }
-//
-//    public Table getTable() {
-//        return this.table;
-//    }
-//
-//    public int hashCode() {
-//        return this.id;
-//    }
-//
-//    public boolean equals(Object c) {
-//        return c instanceof Column && ((Column)c).getId() == this.id;
-//    }
-//
-//    public String toString() {
-//        return this.table.toString() + "." + this.name;
-//    }
-//
-//    public void clone(Object obj) {
-//        if (!(obj instanceof ColumnImpl)) {
-//            throw new IllegalArgumentException("Not a ColumnImpl");
-//        } else {
-//            ColumnImpl ci = (ColumnImpl)obj;
-//            this.description = ci.description;
-//            this.description2 = ci.description2;
-//            this.displayOrder = ci.displayOrder;
-//            this.id = ci.id;
-//            this.isAlternateKey = ci.isAlternateKey;
-//            this.isAlternateKey2 = ci.isAlternateKey2;
-//            this.mask = ci.mask;
-//            this.isValueLimited = ci.isValueLimited;
-//            this.length = ci.length;
-//            this.name = ci.name;
-//            this.rTable = ci.rTable;
-//            this.sqltype = ci.sqltype;
-//            this.table = ci.table;
-//            this.type = ci.type;
-//            this.valueInterpreter = ci.valueInterpreter;
-//            this.values = ci.values;
-//            this.obtainManner = ci.obtainManner;
-//            this.modifiable = ci.modifiable;
-//            this.refColumnName = ci.refColumnName;
-//            this.tableColumnName = ci.tableColumnName;
-//            this.objectTable = ci.objectTable;
-//            this.jsonProps = ci.jsonProps;
-//        }
-//    }
-//
-//    public String getLimit() {
-//        return this.limit;
-//    }
-//
-//    public void setLimit(String limit) {
-//        this.limit = limit;
-//    }
-//
-//    public String getMoney() {
-//        return this.money;
-//    }
-//
-//    public void setMoney(String money) {
-//        this.money = money;
-//    }
-//
-//    public boolean getModifiable() {
-//        return this.modifiable;
-//    }
-//
-//    public void setModifiable(boolean modifiable) {
-//        this.modifiable = modifiable;
-//    }
-//
-//    public String getObtainManner() {
-//        return this.obtainManner;
-//    }
-//
-//    public void setObtainManner(String obtainManner) {
-//        this.obtainManner = obtainManner;
-//    }
-//
-//    public String getDefaultValue() {
-//        return this.getDefaultValue(true);
-//    }
-//
-//    public void setDefaultValue(String defaultValue) {
-//        this.defaultValue = defaultValue;
-//    }
-//
-//    public String getDefaultValue(boolean eval) {
-//        if (eval && this.defaultValue != null && "=".equals(this.defaultValue.substring(0, 1))) {
-//        }
-//
-//        return this.defaultValue;
-//    }
-//
-//    public String getReferenceColumnName() {
-//        return this.refColumnName;
-//    }
-//
-//    public void setReferenceColumnName(String columnName) {
-//        this.refColumnName = columnName;
-//    }
-//
-//    public String getTableColumnName() {
-//        return this.tableColumnName;
-//    }
-//
-//    public void setTableColumnName(String columnName) {
-//        this.tableColumnName = columnName;
-//    }
-//
-//    public Table getObjectTable() {
-//        return this.objectTable;
-//    }
-//
-//    public void setObjectTable(Table objectTable) {
-//        this.objectTable = objectTable;
-//    }
-//
-//    public void setRegExpresion(String regExpression) {
-//        if (Validator.isNotNull(regExpression)) {
-//            if (this.displaySetting == null) {
-//                throw new NDSRuntimeException("Must call setDisplaySetting before setRegExpresion for Column");
-//            }
-//
-//            if (this.displaySetting.getObjectType() == 12) {
-//                try {
-//                    JSONObject jo = JSONObject.parseObject(regExpression);
-//                    this.props = new Properties();
-//                    Iterator var3 = jo.keySet().iterator();
-//
-//                    while(var3.hasNext()) {
-//                        String key = (String)var3.next();
-//                        this.props.setProperty(key, jo.getString(key));
-//                    }
-//                } catch (Throwable var5) {
-//                    throw new NDSRuntimeException("Could not load regExpression as json object:" + var5, var5);
-//                }
-//            } else {
-//                this.regExpression = regExpression;
-//            }
-//        }
-//
-//    }
-//
-//    public String getRegExpression() {
-//        return this.regExpression;
-//    }
-//
-//    public String getErrorMessage() {
-//        return this.errorMessage;
-//    }
-//
-//    public void setErrorMessage(String errorMessage) {
-//        this.errorMessage = errorMessage;
-//    }
-//
-//    public boolean isVirtual() {
-//        return this.isVirtual;
-//    }
-//
-//    public String getSubTotalMethod() {
-//        return this.sumMethod;
-//    }
-//
-//    public void setSubTotalMethod(String method) {
-//        this.sumMethod = method;
-//    }
-//
-//    public String getSubTotalDesc() {
-//        return this.sumMethodDesc;
-//    }
-//
-//    void setIsFilteredByWildcard(boolean b) {
-//        this.isFilteredByWildcard = b;
-//    }
-//
-//    public List getReferenceColumnsInWildcardFilter() {
-//        return this.referenceColumnsInWildcardFilter;
-//    }
-//
-//    public void setReferenceColumnsInWildcardFilter(List columns) {
-//        this.referenceColumnsInWildcardFilter = columns;
-//    }
-//
-//    public String getFilter() {
-//        return this.filter;
-//    }
-//
-//    public void setFilter(String filter) {
-//        this.filter = filter;
-//        if (Validator.isNotNull(filter) && (this.getReferenceTable() != null || this.getDisplaySetting().getObjectType() == 12) && filter.indexOf(64) > -1) {
-//            this.isFilteredByWildcard = true;
-//        }
-//
-//    }
-//
-//    public DisplaySetting getDisplaySetting() {
-//        return this.displaySetting;
-//    }
-//
-//    public void setDisplaySetting(DisplaySetting setting) {
-//        this.displaySetting = setting;
-//    }
-//
-//    public String getSequenceHead() {
-//        return this.sequenceHead;
-//    }
-//
-//    public void setSequenceHead(String s) {
-//        this.sequenceHead = s;
-//    }
-//
-//    public boolean isColumnLink(TableManager tm) {
-//        if (this.name.indexOf(";") > -1) {
-//            try {
-//                this.getColumnLink(tm);
-//                return true;
-//            } catch (Exception var3) {
-//                return false;
-//            }
-//        } else {
-//            return false;
-//        }
-//    }
-//
-//    public ColumnLink getColumnLink(TableManager tm) throws QueryException {
-//        return new ColumnLink(this.table.getName() + "." + this.name, tm);
-//    }
-//
-//    public Object getUIConstructor() {
-//        Object uiConstructor = null;
-//        if (this.getDisplaySetting().getObjectType() == 10) {
-//            if (Validator.isNull(this.getValueInterpeter())) {
-//                throw new NDSRuntimeException("Not found interpreter of button column " + this);
-//            }
-//
-//            try {
-//                uiConstructor = ApplicationContextHandle.getBean(this.getValueInterpeter());
-//            } catch (Exception var5) {
-//                try {
-//                    uiConstructor = ApplicationContextHandle.getBean(InstanceUtil.getClass(this.getValueInterpeter()));
-//                } catch (Exception var4) {
-//                    log.debug("Found error in get ui constructor:" + var4);
-//                }
-//            }
-//        }
-//
-//        return uiConstructor;
-//    }
-//
-//    public Object getUIAlerter() {
-//        Object uiAlerter = null;
-//        if (Validator.isNotNull(this.getValueInterpeter())) {
-//            try {
-//                uiAlerter = ApplicationContextHandle.getBean(this.getValueInterpeter());
-//            } catch (Exception var5) {
-//                try {
-//                    uiAlerter = ApplicationContextHandle.getBean(InstanceUtil.getClass(this.getValueInterpeter()));
-//                } catch (Exception var4) {
-//                    log.debug("Found error in get ui alerter:" + var4);
-//                }
-//            }
-//        }
-//
-//        return uiAlerter;
-//    }
-//
-//    public void setIsUpperCase(boolean b) {
-//        this.isUpperCase = b;
-//    }
-//
-//    public boolean isUpperCase() {
-//        return this.isUpperCase;
-//    }
-//
-//    public int getSecurityGrade() {
-//        return this.securityGrade;
-//    }
-//
-//    public JSONObject toJSONSimpleObject() throws JSONException {
-//        JSONObject jo = new JSONObject();
-//        jo.put("id", this.id);
-//        jo.put("description", this.getDescription());
-//        jo.put("isNullable", this.isNullable);
-//        jo.put("refColumnId", this.getReferenceColumn() == null ? -1 : this.getReferenceColumn().getId());
-//        if (this.getReferenceColumn() != null) {
-//            jo.put("refTableAK", this.getReferenceTable().getAlternateKey().toJSONSimpleObject());
-//        }
-//
-//        jo.put("mask", this.mask);
-//        jo.put("isValueLimited", this.isValueLimited);
-//        jo.put("type", this.type);
-//        return jo;
-//    }
-//
-//    public JSONObject toJSONObject(Locale locale) throws JSONException {
-//        JSONObject jo = new JSONObject();
-//        jo.put("id", this.id);
-//        jo.put("name", this.name);
-//        jo.put("description", this.getDescription());
-//        jo.put("isNullable", this.isNullable);
-//        jo.put("obtainManner", this.obtainManner);
-//        jo.put("defaultValue", this.defaultValue);
-//        jo.put("refColumnId", this.getReferenceColumn() == null ? -1 : this.getReferenceColumn().getId());
-//        if (this.getReferenceColumn() != null) {
-//            jo.put("refTableAK", this.getReferenceTable().getAlternateKey().toJSONObject(locale));
-//        }
-//
-//        jo.put("refTableId", this.getReferenceTable() == null ? -1 : this.getReferenceTable().getId());
-//        jo.put("isAlternateKey", this.isAlternateKey);
-//        jo.put("mask", this.mask);
-//        jo.put("isValueLimited", this.isValueLimited);
-//        jo.put("values", this.values);
-//        jo.put("isUpperCase", this.isUpperCase);
-//        jo.put("filter", this.filter);
-//        jo.put("displaySetting", this.displaySetting.getObjectTypeString());
-//        jo.put("type", this.type);
-//        jo.put("length", this.length);
-//        jo.put("scale", this.scale);
-//        jo.put("valueInterpreter", this.valueInterpreter);
-//        jo.put("table", this.table.getId());
-//        jo.put("isVirtual", this.isVirtual);
-//        jo.put("isIndexed", this.isIndexed);
-//        jo.put("isAutoComplete", this.isAutoComplete);
-//        jo.put("props", this.jsonProps);
-//        return jo;
-//    }
-//
-//    public JSONObject getJSONProps() {
-//        return this.jsonProps;
-//    }
-//
-//    public void setJSONProps(JSONObject jo) {
-//        this.jsonProps = jo;
-//        if (jo != null) {
-//            this.securityGrade = jo.getIntValue("sgrade");
-//        }
-//
-//    }
-//
-//    public String getStrProps() {
-//        if (this.jsonProps == null) {
-//            this.jsonProps = new JSONObject();
-//        }
-//
-//        return this.jsonProps.toString();
-//    }
-//
-//    public String getShowcomment() {
-//        return this.showcomment;
-//    }
-//
-//    public Boolean getIsorder() {
-//        return this.isorder;
-//    }
-//
-//    public void setIsorder(Boolean isorder) {
-//        this.isorder = isorder;
-//    }
-//
-//    public void setShowcomment(String shcomment) {
-//        this.showcomment = shcomment;
-//    }
-//
-//    public Boolean getShowtitle() {
-//        return this.showtitle;
-//    }
-//
-//    public void setShowtitle(Boolean ishowtite) {
-//        this.showtitle = ishowtite;
-//    }
-//
-//    public Boolean getRowspan() {
-//        return this.isRowspan;
-//    }
-//
-//    public void setRowspan(Boolean isRowspan) {
-//        this.isRowspan = isRowspan;
-//    }
-//
-//    public String getFkdisplay() {
-//        return this.fkdisplay;
-//    }
-//
-//    public void setFkdisplay(String fkdisplay) {
-//        this.fkdisplay = fkdisplay;
-//    }
-//
-//    public String getQuerydefval() {
-//        return this.querydefval;
-//    }
-//
-//    public void setQuerydefval(String querydefval) {
-//        this.querydefval = querydefval;
-//    }
-//
-//    public boolean isComputed() {
-//        return "computed".equals(this.obtainManner);
-//    }
-//
-//    public LimitvalueGroup getLimitvalueGroup() {
-//        return this.limitvalueGroup;
-//    }
-//
-//    public void setLimitvalueGroup(LimitvalueGroup limitvalueGroup) {
-//        this.limitvalueGroup = limitvalueGroup;
-//    }
-//
-//    public String getSearchtype() {
-//        return this.searchtype;
-//    }
-//
-//    public void setSearchtype(String searchtype) {
-//        this.searchtype = searchtype;
-//    }
-//
-//    public boolean getIsremote() {
-//        return this.isremote;
-//    }
-//
-//    public void setIsremote(Boolean isremote) {
-//        this.isremote = isremote;
-//    }
-//
-//    public String getSearchmodel() {
-//        return this.searchmodel;
-//    }
-//
-//    public void setSearchmodel(String searchmodel) {
-//        this.searchmodel = searchmodel;
-//    }
-//
-//    public String getCommentstp() {
-//        return Tools.nvl(this.commentstp, "list");
-//    }
-//
-//    public void setCommentstp(String commentstp) {
-//        this.commentstp = commentstp;
-//    }
-//
-//    public Boolean getIsagfilter() {
-//        return this.isagfilter;
-//    }
-//
-//    public void setIsagfilter(Boolean isagfilter) {
-//        this.isagfilter = isagfilter;
-//    }
-//
-//    public String getAgfilter() {
-//        return this.agfilter;
-//    }
-//
-//    public void setAgfilter(String agfilter) {
-//        this.agfilter = agfilter;
-//    }
-}
-

+ 0 - 17
boman-modules/boman-system/src/main/java/com/boman/system/common/DbRowAction.java

@@ -1,17 +0,0 @@
-package com.boman.system.common;
-
-/**
- * @author lzm
- * @date 2018/9/21
- */
-public enum DbRowAction {
-    INSERT(0, "插入"), UPDATE(1, "更新"), DELETE(2, "删除");
-
-    private int value;
-    private String desc;
-
-    DbRowAction(int value, String desc) {
-        this.value = value;
-        this.desc = desc;
-    }
-}

+ 0 - 24
boman-modules/boman-system/src/main/java/com/boman/system/common/DefaultTableService.java

@@ -1,24 +0,0 @@
-//package com.boman.system.common;
-//
-//
-//import org.springframework.stereotype.Component;
-//
-///**
-// * @author shiqian
-// * @description
-// * @date 2021年03月22日 10:21
-// **/
-//@Component("defaultTableService-one")
-//public class DefaultTableService extends BaseTableService {
-//    public DefaultTableService() {
-//    }
-//
-//    public DefaultTableService(String tableName) {
-//        super(tableName);
-//    }
-//
-//    @Override
-//    public RowResult executeAction(TableServiceContext context, MainTableRecord row) {
-//        return null;
-//    }
-//}

+ 0 - 24
boman-modules/boman-system/src/main/java/com/boman/system/common/ExceptionFilter.java

@@ -1,24 +0,0 @@
-package com.boman.system.common;
-
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 11:01
- **/
-public abstract class ExceptionFilter extends BaseFilter {
-
-    public ExceptionFilter() {
-    }
-
-    /**
-     * 异常处理Filter,返回null,则表示本Filter不处理该异常(异常继续往下传递,如所有异常处理Filter都不处理,则往外抛出)
-     * 返回非null值,则表示本Filter处理了改异常,不往下传递(异常被吞)
-     *
-     * @param context
-     * @param row
-     * @param exception
-     * @return
-     */
-    public abstract RowResult handleException(TableServiceContext context, MainTableRecord row, Exception exception);
-}

+ 0 - 94
boman-modules/boman-system/src/main/java/com/boman/system/common/Feature.java

@@ -1,94 +0,0 @@
-package com.boman.system.common;
-
-
-import com.google.common.collect.Lists;
-import org.apache.commons.collections4.keyvalue.DefaultMapEntry;
-import org.springframework.beans.factory.InitializingBean;
-
-import java.util.Collection;
-import java.util.Map;
-import java.util.function.BiPredicate;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 10:42
- **/
-public abstract class Feature implements InitializingBean {
-    public static final BiPredicate<String, String> matchAll = (tableName, actionName) -> {
-        return true;
-    };
-    private String name;
-    private String description;
-    private boolean isSystem;
-    private Collection<Map.Entry<BiPredicate<String, String>, Validator>> validates;
-    private Collection<Map.Entry<BiPredicate<String, String>, Filter>> filters;
-
-    protected Feature() {
-        this.validates = Lists.newArrayList();
-        this.filters = Lists.newArrayList();
-        this.isSystem = false;
-    }
-
-    protected Feature(String name, String description, boolean isSystem) {
-        this();
-        this.name = name;
-        this.description = description;
-        this.isSystem = isSystem;
-    }
-
-    @Override
-    public final void afterPropertiesSet() throws Exception {
-        this.initialization();
-    }
-
-    protected abstract void initialization();
-
-    protected final void addValidator(Validator validator, BiPredicate<String, String> condition) {
-        this.validates.add(new DefaultMapEntry(condition, validator));
-    }
-
-    protected final void addFilter(Filter filter, BiPredicate<String, String> condition) {
-        this.filters.add(new DefaultMapEntry(condition, filter));
-    }
-
-    protected final void addGlobalValidator(Validator validator) {
-        this.addValidator(validator, matchAll);
-    }
-
-    protected final void addGlobalFilter(Filter filter) {
-        this.addFilter(filter, matchAll);
-    }
-
-    public String getName() {
-        return this.name;
-    }
-
-    protected void setName(final String name) {
-        this.name = name;
-    }
-
-    public String getDescription() {
-        return this.description;
-    }
-
-    protected void setDescription(final String description) {
-        this.description = description;
-    }
-
-    public boolean isSystem() {
-        return this.isSystem;
-    }
-
-    protected void setSystem(final boolean isSystem) {
-        this.isSystem = isSystem;
-    }
-
-    public Collection<Map.Entry<BiPredicate<String, String>, Validator>> getValidates() {
-        return this.validates;
-    }
-
-    public Collection<Map.Entry<BiPredicate<String, String>, Filter>> getFilters() {
-        return this.filters;
-    }
-}

+ 0 - 87
boman-modules/boman-system/src/main/java/com/boman/system/common/FeatureManager.java

@@ -1,87 +0,0 @@
-package com.boman.system.common;
-
-import com.google.common.collect.Lists;
-import com.google.common.collect.Maps;
-import com.google.common.collect.Sets;
-
-import java.util.Collection;
-import java.util.Map;
-import java.util.Set;
-import java.util.function.BiPredicate;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 10:02
- **/
-public class FeatureManager {
-
-    private static final Map<String, Feature> features = Maps.newHashMap();
-
-    private static final Map<String, Collection<Validator>> validatorCache = Maps.newHashMap();
-
-    private static final Map<String, Collection<Filter>> filterCache = Maps.newHashMap();
-
-    public static void addFeature(Feature feature) {
-        if (!features.containsKey(feature.getName())) {
-            features.put(feature.getName(), feature);
-            validatorCache.clear();
-            filterCache.clear();
-        }
-    }
-
-    public static void removeFeature(String featureName) {
-        if (null != features.remove(featureName)) {
-            validatorCache.clear(); //TODO:注意这里面要获取下写锁
-            filterCache.clear();
-        }
-    }
-
-    static Collection<Validator> getValidators(String tableName, String actionName) {
-        String cacheKey = getCacheKey(tableName, actionName);
-        Collection<Validator> result = validatorCache.get(cacheKey);
-        if (result == null) {
-            Set<Integer> temp = Sets.newHashSet();
-            result = Lists.newArrayList();
-            Collection<Feature> allFeatures = features.values();
-            for (Feature feature : allFeatures) {
-                for (Map.Entry<BiPredicate<String, String>, Validator> item : feature.getValidates()) {
-                    if (item.getKey() == null || item.getKey().test(tableName, actionName)) {
-                        Validator value = item.getValue();
-                        if (!temp.contains(value.hashCode())) {
-                            temp.add(value.hashCode());
-                            result.add(value);
-                        }
-                    }
-                }
-            }
-        }
-        return result;
-    }
-
-    static Collection<Filter> getFilters(String tableName, String actionName) {
-        String cacheKey = getCacheKey(tableName, actionName);
-        Collection<Filter> result = filterCache.get(cacheKey);
-        if (result == null) {
-            Set<Integer> temp = Sets.newHashSet();
-            result = Lists.newArrayList();
-            Collection<Feature> allFeatures = features.values();
-            for (Feature feature : allFeatures) {
-                for (Map.Entry<BiPredicate<String, String>, Filter> item : feature.getFilters()) {
-                    if (item.getKey() == null || item.getKey().test(tableName, actionName)) {
-                        Filter value = item.getValue();
-                        if (!temp.contains(value.hashCode())) {
-                            temp.add(value.hashCode());
-                            result.add(value);
-                        }
-                    }
-                }
-            }
-        }
-        return result;
-    }
-
-    private static String getCacheKey(String tableName, String actionName) {
-        return String.format("%s.%s", tableName, actionName);
-    }
-}

+ 0 - 12
boman-modules/boman-system/src/main/java/com/boman/system/common/Filter.java

@@ -1,12 +0,0 @@
-package com.boman.system.common;
-
-
-/**
- * @author lzm
- * @date 2018/9/27
- */
-public interface Filter {
-    void before(TableServiceContext context, MainTableRecord row);
-
-    void after(TableServiceContext context, MainTableRecord row);
-}

+ 3 - 117
boman-modules/boman-system/src/main/java/com/boman/system/common/MainTableRecord.java

@@ -26,127 +26,17 @@ public class MainTableRecord {
 
     private TableServiceContext context;
     private RowRecord mainData;
-    private Map<String, SubTableRecord> subTables;
-
-    /**
-     * 子表和对应的外健
-     */
-    private JSONObject fkColumns;
 
     @Setter
     @Getter
     private RowResult result;
 
 
-    public MainTableRecord(TableServiceContext context, GenTable genTable, Long id, JSONObject fkColumns, JSONObject fixedData, JSONObject delTables) {
+    public MainTableRecord(TableServiceContext context, GenTable genTable, Long id, JSONObject fixedData, JSONObject delTables) {
         this.context = context;
-        this.subTables = Maps.newHashMap();
-
-        //获取提交数据rowData
-        JSONObject rowData = fixedData;
-//        if (fixedData != null) {
-//            rowData = fixedData.getJSONObject("columns");
-////            rowData = fixedData.getJSONArray("columns");
-//        }
-//        if (rowData == null) {
-//            rowData = new JSONObject();
-//        }
-        if (fixedData == null) {
-            fixedData = new JSONObject();
-        }
-
-        if (fkColumns == null) {
-            //伪造下外键
-            fkColumns = new JSONObject();
-        }
-        this.fkColumns = fkColumns;
-
-        if (delTables == null) {
-            delTables = new JSONObject();
-        }
         this.mainData = new RowRecord(id, genTable, fixedData);
-
-//        for (String subTableName : fixedData.keySet()) {
-//            if (!subTableName.equalsIgnoreCase(genTable.getTableName())) {
-//                Table subTable = TableServiceContext.getTableByName(subTableName);
-//                String fkColumnName = fkColumns.getString(subTableName);
-//                SubTableRecord subRow = new SubTableRecord(subTable, fkColumnName, fixedData.getJSONArray(subTableName));
-//                subTables.put(subTableName, subRow);
-//            }
-//        }
-
-    }
-
-
-    public MainTableRecord(TableServiceContext context, Table table, Long id, JSONObject fkColumns, JSONObject tables, JSONObject delTables) {
-        this.context = context;
-        this.subTables = Maps.newHashMap();
-
-        //获取提交数据rowData
-        JSONObject rowData = null;
-        if (tables != null) {
-            rowData = tables.getJSONObject(table.getName());
-        }
-        if (rowData == null) {
-            rowData = new JSONObject();
-        }
-        if (tables == null) {
-            tables = new JSONObject();
-        }
-
-        if (fkColumns == null) {
-            //伪造下外键
-            fkColumns = new JSONObject();
-        }
-        this.fkColumns = fkColumns;
-
-        if (delTables == null) {
-            delTables = new JSONObject();
-        }
-
-//        if (Constants.ACTION_DELETE.equals(context.getActionName())) {
-//            LOGGER.debug("====>" + delTables.keySet());
-//            this.mainData = new RowRecord(id, table, rowData);
-//            for (String subTableName : delTables.keySet()) {
-//                if (!subTableName.equalsIgnoreCase(table.getName())) {
-//                    Table subTable = com.eboss.sys.srv.service.basetable.TableServiceContext.getTableByName(subTableName);
-//                    //外健
-//                    String fkColumnName = fkColumns.getString(subTableName);
-//                    if (fkColumnName == null || fkColumnName.isEmpty()) {
-//                        fkColumnName = findFkColumnName(subTable, table.getName());
-//                    }
-//                    SubTableRecord subRow = new SubTableRecord(subTable, fkColumnName, delTables.getJSONArray(subTableName));
-//                    subTables.put(subTableName, subRow);
-//                }
-//            }
-//        } else {
-            this.mainData = new RowRecord(id, table, rowData);
-            for (String subTableName : tables.keySet()) {
-                if (!subTableName.equalsIgnoreCase(table.getName())) {
-                    Table subTable = TableServiceContext.getTableByName(subTableName);
-//                    //外健
-                    String fkColumnName = fkColumns.getString(subTableName);
-//                    if (fkColumnName == null || fkColumnName.isEmpty()) {
-//                        fkColumnName = findFkColumnName(subTable, table.getName());
-//                    }
-                    SubTableRecord subRow = new SubTableRecord(subTable, fkColumnName, tables.getJSONArray(subTableName));
-                    subTables.put(subTableName, subRow);
-                }
-            }
-//        }
     }
 
-//    private String findFkColumnName(Table subtable, String mainTableName) {
-//        ArrayList<Column> columns = subtable.getAllColumns();
-//        for (Column col : columns) {
-//            Table refTable = col.getReferenceTable();
-//            if (refTable != null && mainTableName.equalsIgnoreCase(refTable.getName())) {
-//                return col.getName();
-//            }
-//        }
-//        return null;
-//    }
-
     public Long getId() {
         return mainData.getId();
     }
@@ -159,15 +49,11 @@ public class MainTableRecord {
         return mainData.getGenTable();
     }
 
-    public DbRowAction getAction() {
-        return mainData.getAction();
-    }
-
     public JSONObject getCommitData() {
         return mainData.getCommitData();
     }
 
-    public JSONObject getOrignalData() {
-        return mainData.getOrignalData();
+    public JSONObject getOriginalData() {
+        return mainData.getOriginalData();
     }
 }

+ 0 - 9
boman-modules/boman-system/src/main/java/com/boman/system/common/NDSException.java

@@ -1,9 +0,0 @@
-package com.boman.system.common;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 14:57
- **/
-public class NDSException {
-}

+ 0 - 46
boman-modules/boman-system/src/main/java/com/boman/system/common/OverlayJSONObject.java

@@ -1,46 +0,0 @@
-package com.boman.system.common;
-
-import com.alibaba.fastjson.JSONObject;
-
-import java.util.AbstractMap;
-import java.util.Set;
-import java.util.stream.Collectors;
-import java.util.stream.Stream;
-
-/**
- * @author lzm
- * @date 2018/10/29
- * 可被覆盖的
- */
-public class OverlayJSONObject extends AbstractMap {
-    private JSONObject baseData;
-    private JSONObject data;
-
-    public OverlayJSONObject(JSONObject base, JSONObject data) {
-        if (data == null) {
-            throw new IllegalArgumentException("入口的新集合不可为空!");
-        }
-        this.baseData = base;
-        this.data = data;
-    }
-
-    @Override
-    public Object remove(Object key) {
-        return data.remove(key);
-    }
-
-    @Override
-    public Object put(Object key, Object value) {
-        return data.put((String) key, value);
-    }
-
-    @Override
-    public Set<Entry<String, Object>> entrySet() {
-        if (this.baseData == null) {
-            return this.data.entrySet();
-        } else {
-            return Stream.concat(this.data.entrySet().stream(), this.baseData.entrySet().stream()
-                    .filter(pair -> !this.data.containsKey(pair.getKey()))).collect(Collectors.toSet());
-        }
-    }
-}

+ 0 - 47
boman-modules/boman-system/src/main/java/com/boman/system/common/QueryUtils.java

@@ -1,47 +0,0 @@
-package com.boman.system.common;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 11:42
- **/
-public class QueryUtils {
-
-    public static String replaceVariables(String sql, User user) {
-        if (user == null) {
-            return sql;
-        } else if (sql == null) {
-            return null;
-        } else {
-            StringBuilder sb = new StringBuilder();
-            int p = 0;
-
-            while (p < sql.length()) {
-                int p1 = sql.indexOf("$", p);
-                if (p1 > -1) {
-                    int p2 = sql.indexOf("$", p1 + 1);
-                    if (p2 > -1) {
-                        String n = sql.substring(p1, p2 + 1);
-                        Object v = user.getAttribute(n);
-                        if (v != null) {
-                            sb.append(sql.substring(p, p1)).append(v);
-                            p = p2 + 1;
-                        } else {
-                            sb.append(sql.substring(p, p2));
-                            p = p2;
-                        }
-                        continue;
-                    }
-
-                    sb.append(sql.substring(p));
-                    break;
-                }
-
-                sb.append(sql.substring(p));
-                break;
-            }
-
-            return sb.toString();
-        }
-    }
-}

+ 0 - 69
boman-modules/boman-system/src/main/java/com/boman/system/common/RequestUtil.java

@@ -1,69 +0,0 @@
-package com.boman.system.common;
-
-import org.springframework.web.context.request.RequestContextHolder;
-import org.springframework.web.context.request.ServletRequestAttributes;
-
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 09:38
- **/
-public class RequestUtil {
-
-    public RequestUtil() {
-    }
-
-    public static User getUser() {
-        ServletRequestAttributes attrs = (ServletRequestAttributes)RequestContextHolder.getRequestAttributes();
-        if (attrs != null) {
-            HttpServletRequest request = attrs.getRequest();
-            if (request.getAttribute("user") != null) {
-                return (User)request.getAttribute("user");
-            }
-        }
-
-        return null;
-    }
-
-    public static HttpServletRequest getRequest() {
-        ServletRequestAttributes attrs = (ServletRequestAttributes)RequestContextHolder.getRequestAttributes();
-        if (attrs != null) {
-            return attrs.getRequest();
-        } else {
-            return null;
-        }
-    }
-
-    public static Object getAttribute(String name) {
-        ServletRequestAttributes attrs = (ServletRequestAttributes) RequestContextHolder.getRequestAttributes();
-        if (attrs != null) {
-            HttpServletRequest request = attrs.getRequest();
-            return request.getAttribute(name);
-        } else {
-            return null;
-        }
-    }
-
-    public static String getParameter(String name) {
-        ServletRequestAttributes attrs = (ServletRequestAttributes)RequestContextHolder.getRequestAttributes();
-        if (attrs != null) {
-            HttpServletRequest request = attrs.getRequest();
-            return request.getParameter(name);
-        } else {
-            return null;
-        }
-    }
-
-    public static HttpServletRequest getRequet() {
-        ServletRequestAttributes attrs = (ServletRequestAttributes)RequestContextHolder.getRequestAttributes();
-        return attrs != null ? attrs.getRequest() : null;
-    }
-
-    public static HttpServletResponse getResponse() {
-        ServletRequestAttributes attrs = (ServletRequestAttributes)RequestContextHolder.getRequestAttributes();
-        return attrs != null ? attrs.getResponse() : null;
-    }
-}

+ 0 - 57
boman-modules/boman-system/src/main/java/com/boman/system/common/Resources.java

@@ -1,57 +0,0 @@
-package com.boman.system.common;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 13:54
- **/
-import java.util.HashMap;
-import java.util.Locale;
-import java.util.Map;
-import java.util.ResourceBundle;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.context.annotation.PropertySource;
-
-@PropertySource(
-        value = {"classpath:application.properties", "classpath:config/email.properties", "classpath:config/thirdParty.properties", "classpath:config/ebossCloud.properties", "classpath:i18n/messages*.properties"},
-        ignoreResourceNotFound = true
-)
-public final class Resources {
-    private static final Logger log = LoggerFactory.getLogger(Resources.class);
-    private static final Map<String, ResourceBundle> MESSAGES = new HashMap();
-
-    public Resources() {
-    }
-
-    public static String getMessage(String key, Object... params) {
-        return getMessage(key, (Locale)null, params);
-    }
-
-    public static String getMessage(String key, Locale plocale, Object... params) {
-        ResourceBundle pp = ResourceBundle.getBundle("application");
-        String defaultLocal = pp.getString("spring.locale.default");
-//        Locale locale = plocale != null ? plocale : Tools.getLocale("zh_CN");
-        Locale locale =  Locale.getDefault();
-        ResourceBundle message = (ResourceBundle)MESSAGES.get(locale.getLanguage());
-        if (message == null) {
-            synchronized(MESSAGES) {
-                message = (ResourceBundle)MESSAGES.get(locale.getLanguage());
-                if (message == null) {
-                    message = ResourceBundle.getBundle("i18n/messages", locale);
-                    MESSAGES.put(locale.getLanguage(), message);
-                }
-            }
-        }
-
-        try {
-            return params != null ? String.format(message.getString(key), params) : message.getString(key);
-        } catch (Exception var10) {
-            return locale.toString().equals(defaultLocal) && params.length == 1 ? String.valueOf(params[0]) : key;
-        }
-    }
-
-    public static void flushMessage() {
-        MESSAGES.clear();
-    }
-}

+ 0 - 12
boman-modules/boman-system/src/main/java/com/boman/system/common/ResultCode.java

@@ -1,12 +0,0 @@
-package com.boman.system.common;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 15:41
- **/
-public class ResultCode {
-
-    public static final int SUCCESS = 0;
-    public static final int FAIL = -1;
-}

+ 8 - 97
boman-modules/boman-system/src/main/java/com/boman/system/common/RowRecord.java

@@ -1,6 +1,7 @@
 package com.boman.system.common;
 
 import com.alibaba.fastjson.JSONObject;
+import com.boman.common.core.utils.SpringUtils;
 import com.boman.gen.domain.GenTable;
 import com.boman.system.mapper.StandardlyMapper;
 import lombok.Data;
@@ -18,41 +19,28 @@ public class RowRecord {
 
     private GenTable genTable;
 
-    private Table table;
-
     private Long id;
-    private DbRowAction action;
 
     //提交过来的数据
-    private JSONObject postData;
+    private JSONObject postData = new JSONObject();
 
     //原数据
-    private JSONObject orignalData;
+    private JSONObject originalData = new JSONObject();
 
     //新数据
     private JSONObject newData;
 
     //将要提交到数据库中的数据
-    private JSONObject commitData;
+    private JSONObject commitData = new JSONObject();
 
     public RowRecord(Long id, GenTable genTable, JSONObject fixedData) {
         this.id = id;
         this.genTable = genTable;
-        postData = new JSONObject();
-        orignalData = new JSONObject();
-        commitData = new JSONObject();
 
         if (fixedData == null) {
             fixedData = new JSONObject();
         }
-//        if (!fixedData.containsKey("ID") || fixedData.getLong("ID") == null || fixedData.getLong("ID") <= 0) {
-//            fixedData.put("ID", this.id);
-//        }else{
-//            //modify by nathan 导入修改
-//            this.id = fixedData.getLong("ID");
-//        }
 
-        action = (this.id == null || this.id <= 0) ? DbRowAction.INSERT : DbRowAction.UPDATE;
         fixedData.forEach((fieldName, fieldValue)->{
             postData.put(fieldName.toUpperCase(), fieldValue);
         });
@@ -61,87 +49,10 @@ public class RowRecord {
             commitData.put(key, postData.get(key));
         }
 
-        newData = new JSONObject(new OverlayJSONObject(orignalData, commitData));
-    }
-
-    public RowRecord(Long id, Table table, JSONObject postRow) {
-        this.id = id;
-        this.table = table;
-        postData = new JSONObject();
-        orignalData = new JSONObject();
-        commitData = new JSONObject();
-
-        if (postRow == null) {
-            postRow = new JSONObject();
-        }
-        if (!postRow.containsKey("ID") || postRow.getLong("ID") == null || postRow.getLong("ID") <= 0) {
-            postRow.put("ID", this.id);
-        }else{
-            //modify by nathan 导入修改
-            this.id = postRow.getLong("ID");
-        }
-        action = (this.id == null || this.id <= 0) ? DbRowAction.INSERT : DbRowAction.UPDATE;
-//        log.debug("postRow:" + postRow.toJSONString());
-//        log.debug("allColumns:" + table.getAllColumns().toString());
-        for (String key : postRow.keySet()) {
-            Column column = /*table.getColumn(key)*/null;
-            int type = -1;
-            if (column != null) {
-                type = /*column.getType()*/0;
-            } else {
-                log.debug("column is null key===>" + key);
-            }
-            try {
-                switch (type) {
-                    case Column.DATE:
-                        postData.put(key.toUpperCase(), postRow.getDate(key));
-                        break;
-//                    case Column.DATENUMBER:
-//                        postData.put(key.toUpperCase(), postRow.getDate(key));
-//                        break;
-//                    case Column.TIME:
-//                        postData.put(key.toUpperCase(), postRow.get(key));
-//                        break;
-                    case Column.NUMBER:
-                        postData.put(key.toUpperCase(), postRow.getBigDecimal(key));
-                        break;
-
-                    default:
-                        postData.put(key.toUpperCase(), postRow.get(key));
-                }
-            } catch (Exception e) {
-                //log.error(String.format("%s填充字段%s-%s出错,错误信息为%s", this.id, table.getRealTableName(), key, e.getMessage()));
-                throw e;
-            }
-        }
-
-        for (String key : postData.keySet()) {
-            commitData.put(key, postData.get(key));
-        }
-
-        if (this.getAction() == DbRowAction.UPDATE) {
-            StandardlyMapper mapper = ApplicationContextHandle.getBean(StandardlyMapper.class);
-            JSONObject oldData = mapper.getById(this.getRealTableName(), this.getId());
-            if (oldData != null) {
-                for (String key : oldData.keySet()) {
-//                    key = key.toUpperCase();
-                    orignalData.put(key.toUpperCase(), oldData.get(key));
-                }
-            }
-        }
-
-        newData = new JSONObject(new OverlayJSONObject(orignalData, commitData));
-    }
-
-    public String getTableName() {
-        return genTable.getTableName();
+        JSONObject jsonObject = new JSONObject();
+        jsonObject.put("baseData", originalData);
+        jsonObject.put("data", commitData);
+        newData = new JSONObject(jsonObject);
     }
 
-    public String getRealTableName() {
-        String realTableName = /*table.getRealTableName()*/"";
-        if (realTableName == null || realTableName.isEmpty()) {
-            realTableName = table.getName();
-        }
-        return realTableName;
-    }
 }

+ 1 - 18
boman-modules/boman-system/src/main/java/com/boman/system/common/RowResult.java

@@ -1,7 +1,5 @@
 package com.boman.system.common;
 
-import java.util.Locale;
-
 /**
  * @author shiqian
  * @description
@@ -20,10 +18,6 @@ public class RowResult {
         return this.code >= 0;
     }
 
-    public static RowResult ok(Locale locale) {
-        return ok(Resources.getMessage("成功", locale, new Object[0]));
-    }
-
     public static RowResult ok(String message) {
         return create(0, message);
     }
@@ -52,17 +46,6 @@ public class RowResult {
         return result;
     }
 
-    public ValueHolder toValueHolder() {
-        ValueHolder result = new ValueHolder();
-        result.setCode(this.code);
-        result.setMessage(this.message == null ? "" : this.message);
-        if (this.data != null) {
-            result.setData(this.data);
-        }
-
-        return result;
-    }
-
     public Integer getCode() {
         return this.code;
     }
@@ -80,7 +63,7 @@ public class RowResult {
     }
 
     public static boolean checkSuccess(RowResult rowResult){
-        return null != rowResult && ValueHolder.OK == rowResult.getCode();
+        return null != rowResult && 0 == rowResult.getCode();
     }
 
     public static boolean checkFail(RowResult rowResult){

+ 0 - 114
boman-modules/boman-system/src/main/java/com/boman/system/common/StoredProcedureService.java

@@ -1,114 +0,0 @@
-package com.boman.system.common;
-
-import com.boman.system.mapper.StoredProcedureMapper;
-import lombok.extern.slf4j.Slf4j;
-import org.apache.commons.lang3.StringUtils;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- * @author wmc
- * @date 2020/8/26 9:13
- */
-@Service
-@Slf4j
-public class StoredProcedureService {
-
-/*    @Autowired
-    private StoredProcedureMapper storedProcedureMapper;
-
-    *//**
-     * 增删改提交 统一存储过程
-     *
-     * @param state      是否启用存储过程
-     * @param storedName 存储过程名
-     * @param pId        对象ID
-     * @param tableName  表名
-     *//*
-    @Transactional(rollbackFor = Exception.class)
-    public void storedProcedure(String state, String storedName, Long pId, Long pIsAdd, String tableName) {
-        if (StringUtils.isNotBlank(state)) {
-            if ("Y".equalsIgnoreCase(state)) {
-                if (StringUtils.isBlank(storedName)) {
-                    throw new IllegalArgumentException("启用存储过程,但未设置存储过程名称");
-                } else {
-                    if (pId == null) {
-                        throw new IllegalArgumentException("storedProcedure==>pId为空");
-                    } else {
-                        //判断调用哪种存储过程 storedProcedure两个入参 storedProcedure2两个入参 两个出参
-                        if ("2".equalsIgnoreCase(storedName.substring(storedName.length() - 1))) {
-                            Map<String, Object> map = new HashMap<>();
-                            map.put("pId", pId);
-                            map.put("pIsAdd", pIsAdd);
-                            map.put("storedName", storedName);
-                            map.put("p_code", null);
-                            map.put("p_message", null);
-                            //storedProcedureMapper.storedProcedure2(map);
-                            if ("-1".equalsIgnoreCase(map.get("p_code").toString())) {
-                                //throw new NDSException("存储过程"+storedName+"异常:"+map.get("p_message").toString());
-//                                throw new NDSException(map.get("p_message").toString());
-                                throw new IllegalArgumentException(map.get("p_message").toString());
-                            }
-                        } else {
-                            //判断一下表名  因为数据库 表的存储过程参数不一样
-                            if ("C_PAYWAY".contains(tableName)) {
-                                //storedProcedureMapper.storedProcedure(pId, storedName);
-                            } else {
-                                //调用存储过程
-                               // storedProcedureMapper.storedProcedure1(pId, pIsAdd, storedName);
-                            }
-                        }
-                    }
-                }
-            }
-        }
-    }*/
-
-    /**
-     * 页面调用存储过程
-     */
-//    @Transactional(rollbackFor = Exception.class)
-//    public ValueHolder storedProcedure(JSONObject json) {
-//        //json里包含   isreturn是否有返回值  storedName存储过程名   params参数
-//        if (!json.containsKey("storedName")) {
-//            throw new NDSException("未找到存储过程名称");
-//        }
-//        if (!json.containsKey("isReturn")) {
-//            throw new NDSException("未找到存储过程是否需要返回值");
-//        }
-//        if (!json.containsKey("params")) {
-//            throw new NDSException("未找到存储过程参数");
-//        }
-//
-//        Boolean isReturn = json.getBoolean("isReturn");
-//        String storedName = json.getString("storedName");
-//        JSONObject params = json.getJSONObject("params");
-//        User user = RequestUtil.getUser();
-//        params.put("USERID", user == null ? "未找到用户id" : user.getId());
-//
-//        Map<String, Object> parmMap = new HashMap<>();
-//        parmMap.put("storedName", storedName);
-//        parmMap.put("params", params.toJSONString());
-//        ValueHolder valueHolder = new ValueHolder();
-//        if (isReturn) {
-//            //有返回值
-//            parmMap.put("datas", null);
-//            storedProcedureMapper.procedureGetValue(parmMap);
-//            try {
-//                JSONObject datas = JSONObject.parseObject(parmMap.get("datas").toString());
-//                valueHolder.setData(datas);
-//            } catch (Exception e) {
-//                throw new NDSException("存储过程返回值非标准json字符串");
-//            }
-//        } else {
-//            //没有返回值
-//            storedProcedureMapper.procedureNoValue(parmMap);
-//        }
-//        valueHolder.setCode(ResultCode.SUCCESS);
-//        return valueHolder;
-//    }
-}

+ 0 - 62
boman-modules/boman-system/src/main/java/com/boman/system/common/SubTableRecord.java

@@ -1,62 +0,0 @@
-package com.boman.system.common;
-
-import com.alibaba.fastjson.JSONArray;
-import com.alibaba.fastjson.JSONObject;
-import com.google.common.collect.Lists;
-import lombok.Getter;
-
-import java.util.Collection;
-import java.util.stream.Collectors;
-
-/**
- * @author lzm
- * @date 2018/10/29
- */
-@Getter
-public class SubTableRecord {
-    private Table table;
-//    private Column FK;
-    private Collection<RowRecord> rows;
-
-    public SubTableRecord(Table table, String fkColumnName, JSONArray jo) {
-        this.table = table;
-//        if (fkColumnName != null && !fkColumnName.isEmpty()) {
-//            this.FK = table.getColumn(fkColumnName);
-//        }
-        this.rows = Lists.newArrayList();
-        for (Integer i = 0; i < jo.size(); i++) {
-            try {
-                Long id = jo.getLong(i);
-                //只有id上传上来了
-                JSONObject tempPostData = new JSONObject();
-                tempPostData.put("ID", id);
-                RowRecord row = new RowRecord(id, table, tempPostData);
-                rows.add(row);
-            } catch (Exception e) {
-                JSONObject tempPostData = jo.getJSONObject(i);
-                RowRecord row = new RowRecord(tempPostData.getLong("ID"), table, tempPostData);
-                rows.add(row);
-            }
-        }
-    }
-
-//    public String getFKColumnName() {
-//        return FK.getName();
-//    }
-
-    public String getTableName() {
-        return table.getName();
-    }
-
-    public String getRealTableName() {
-//        String realTableName = table.getRealTableName();
-//        if (realTableName == null || realTableName.isEmpty()) {
-        String realTableName = table.getName();
-//        }
-        return realTableName;
-    }
-
-    public JSONArray getCommitDatas() {
-        return rows.stream().map(row -> row.getCommitData()).collect(Collectors.toCollection(JSONArray::new));
-    }
-}

+ 0 - 21
boman-modules/boman-system/src/main/java/com/boman/system/common/Table.java

@@ -1,21 +0,0 @@
-package com.boman.system.common;
-
-import com.boman.gen.domain.GenTableColumn;
-import lombok.Data;
-
-import java.util.List;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 15:06
- **/
-@Data
-public class Table {
-
-    private Object id;
-
-    private String name;
-
-    private List<GenTableColumn> columns;
-}

+ 0 - 18
boman-modules/boman-system/src/main/java/com/boman/system/common/TableService.java

@@ -1,18 +0,0 @@
-package com.boman.system.common;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 10:13
- **/
-public interface TableService {
-
-    Logger LOGGER = LoggerFactory.getLogger(TableService.class);
-
-    void configure(TableServiceContext context);
-
-    RowResult executeAction(TableServiceContext context, MainTableRecord row);
-}

+ 2 - 2
boman-modules/boman-system/src/main/java/com/boman/system/common/TableServiceCmdService.java

@@ -60,11 +60,11 @@ public class TableServiceCmdService {
     public final AjaxResult objectSave(BaseTableSaveDTO baseTableSaveDTO) {
         BaseTableDTO baseTableDTO = packTableDTO(baseTableSaveDTO);
         TableServiceContext context = TableServiceContext.createFrom(baseTableDTO);
-//        BaseSaveService baseSaveService = SpringUtils.getBean(BaseSaveService.class);
         // 拿到pkName和maxId
         List<GenTableColumn> columns = context.getTable().getColumns();
         String pkName = IdUtils.getPkName(columns);
-        StringUtils.requireNonNull(pkName);
+        requireNonNull(pkName);
+
         Long maxId = IdUtils.getMaxId(baseTableDTO.getTable(), pkName);
         RowResult rowResult = saveService.insertRow(context.getRealTableName(), pkName, maxId, context.getRows().get(0));
         if (RowResult.checkSuccess(rowResult)) {

+ 9 - 111
boman-modules/boman-system/src/main/java/com/boman/system/common/TableServiceContext.java

@@ -68,38 +68,12 @@ public class TableServiceContext {
         values = Maps.newHashMap();
     }
 
-//    /**
-//     * 表名
-//     * 与realTableName的含义有差异
-//     */
-//    public String getTableName() {
-//        return table.getName();
-//    }
-
-    private User user;
-
-    /**
-     * 附加的校验器
-     */
-    private Collection<Validator> validators;
-
-    /**
-     * 附加的过滤器
-     */
-    private Collection<Filter> filters;
-
 
     @Resource
     private RedisService redisService;
 
     public static TableServiceContext createFrom(BaseTableDTO baseTableDTO) {
         TableServiceContext result = new TableServiceContext();
-        result.user = RequestUtil.getUser();
-//        result.actionName = actionName.replace(PREFIX, "").toUpperCase();
-//        if (StringUtils.isEmpty(result.actionName)) {
-//            throw new IllegalArgumentException("actionName不能为空");
-//        }
-
         String tableName = baseTableDTO.getTable();
         if (StringUtils.isEmpty(tableName)) {
             throw new IllegalArgumentException("表名参数不能为空");
@@ -113,7 +87,6 @@ public class TableServiceContext {
             throw new IllegalArgumentException(tableName + "表信息不存在");
         }
 
-
         result.realTableName = result.table.getTableName();
         if (Strings.isNullOrEmpty(result.realTableName)) {
             throw new IllegalArgumentException(tableName + "表名不存在");
@@ -121,8 +94,6 @@ public class TableServiceContext {
 
         // 前台传过来的数据
         JSONObject fixedData = baseTableDTO.getFixedData();
-        //获取FK
-         JSONObject fkColumn = /*getFKColumn(fixColumn, tableName)*/null;
         //删除
         Boolean isdelmtable = baseTableDTO.getDelMTable();
         JSONObject tabItem = baseTableDTO.getTabItem();
@@ -134,70 +105,13 @@ public class TableServiceContext {
 
         // 获取objid判断 新增或更新
         Long objid = baseTableDTO.getObjId();
-        MainTableRecord mainRowData = new MainTableRecord(result, result.table, objid, fkColumn, fixedData, tabItem);
+        MainTableRecord mainRowData = new MainTableRecord(result, result.table, objid, fixedData, tabItem);
         result.rows = Lists.newArrayList();
         result.rows.add(mainRowData);
 
         return result;
     }
 
-    public static Table getTableByName(String tableName) {
-//        return TableManagerCache.getTableManager().getTable(tableName);
-        return null;
-    }
-//
-//    /**
-//     * 获取子表外健
-//     * @param fixColumn
-//     * @param tableName
-//     * @return
-//     */
-//    private static JSONObject getFKColumn(JSONObject fixColumn, String tableName) {
-//
-//        Table table = getTableByName(tableName);
-//        if (fixColumn == null || table == null) {
-//            return null;
-//        }
-//        //获取对应外键
-//        JSONObject fkcolumn = new JSONObject();
-//        Set<String> fixTable = fixColumn.keySet();
-//        Iterator it = fixTable.iterator();
-//        while (it.hasNext()) {
-//            tableName = (String) it.next();
-//            ArrayList<RefByTable> list = table.getRefByTables();
-//            for (int j = 0; j < list.size(); j++) {
-//                if (list.get(j).getReftable().getName().equals(tableName)) {
-//                    fkcolumn.put(tableName, TableManagerCache.getTableManager().getColumn(list.get(j).getRefByColumnId()).getName());
-//                }
-//            }
-//        }
-//
-//        return fkcolumn;
-//    }
-
-//    /**
-//     * 获取主表的明细表和外健
-//     *
-//     * @param tableName
-//     * @return
-//     */
-//    private static JSONObject getMainTableFKColumn(String tableName) {
-//
-//        Table table = getTableByName(tableName);
-//        if (table == null) {
-//            return null;
-//        }
-//        JSONObject fkcolumn = new JSONObject();
-//        //获取对应外键
-//        ArrayList<RefByTable> list = table.getRefByTables();
-//        for (int j = 0; j < list.size(); j++) {
-//            fkcolumn.put(list.get(j).getReftable().getName(), TableManagerCache.getTableManager().getColumn(list.get(j).getRefByColumnId()).getName());
-//        }
-//
-//        return fkcolumn;
-//    }
-
-
     public GenTable getTable() {
         return table;
     }
@@ -261,28 +175,12 @@ public class TableServiceContext {
     public void setInsertBacth(boolean insertBacth) {
         isInsertBacth = insertBacth;
     }
-
-    public User getUser() {
-        return user;
-    }
-
-    public void setUser(User user) {
-        this.user = user;
-    }
-
-    public Collection<Validator> getValidators() {
-        return validators;
-    }
-
-    public void setValidators(Collection<Validator> validators) {
-        this.validators = validators;
-    }
-
-    public Collection<Filter> getFilters() {
-        return filters;
-    }
-
-    public void setFilters(Collection<Filter> filters) {
-        this.filters = filters;
-    }
+//
+//    public Collection<Filter> getFilters() {
+//        return filters;
+//    }
+//
+//    public void setFilters(Collection<Filter> filters) {
+//        this.filters = filters;
+//    }
 }

+ 0 - 191
boman-modules/boman-system/src/main/java/com/boman/system/common/User.java

@@ -1,191 +0,0 @@
-package com.boman.system.common;
-
-//import com.eboss.sys.util.DateUtil;
-
-import java.util.*;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 09:44
- **/
-public class User {
-
-    private Long id;
-    private String name;
-    private String eName;
-    private String trueName;
-    private String passwordHash;
-    private int isEnabled;
-    private Boolean isActive;
-    private int isEmployee;
-    private Boolean isAdmin;
-    private String description;
-    private String email;
-    private String phone;
-    private String lastLoginIp;
-    private String headImg;
-
-    public Long getId() {
-        return id;
-    }
-
-    public void setId(Long id) {
-        this.id = id;
-    }
-
-    public String getName() {
-        return name;
-    }
-
-    public void setName(String name) {
-        this.name = name;
-    }
-
-    public String geteName() {
-        return eName;
-    }
-
-    public void seteName(String eName) {
-        this.eName = eName;
-    }
-
-    public String getTrueName() {
-        return trueName;
-    }
-
-    public void setTrueName(String trueName) {
-        this.trueName = trueName;
-    }
-
-    public String getPasswordHash() {
-        return passwordHash;
-    }
-
-    public void setPasswordHash(String passwordHash) {
-        this.passwordHash = passwordHash;
-    }
-
-    public int getIsEnabled() {
-        return isEnabled;
-    }
-
-    public void setIsEnabled(int isEnabled) {
-        this.isEnabled = isEnabled;
-    }
-
-    public Boolean getActive() {
-        return isActive;
-    }
-
-    public void setActive(Boolean active) {
-        isActive = active;
-    }
-
-    public int getIsEmployee() {
-        return isEmployee;
-    }
-
-    public void setIsEmployee(int isEmployee) {
-        this.isEmployee = isEmployee;
-    }
-
-    public Boolean getAdmin() {
-        return isAdmin;
-    }
-
-    public void setAdmin(Boolean admin) {
-        isAdmin = admin;
-    }
-
-    public String getDescription() {
-        return description;
-    }
-
-    public void setDescription(String description) {
-        this.description = description;
-    }
-
-    public String getEmail() {
-        return email;
-    }
-
-    public void setEmail(String email) {
-        this.email = email;
-    }
-
-    public String getPhone() {
-        return phone;
-    }
-
-    public void setPhone(String phone) {
-        this.phone = phone;
-    }
-
-    public String getLastLoginIp() {
-        return lastLoginIp;
-    }
-
-    public void setLastLoginIp(String lastLoginIp) {
-        this.lastLoginIp = lastLoginIp;
-    }
-
-    public String getHeadImg() {
-        return headImg;
-    }
-
-    public void setHeadImg(String headImg) {
-        this.headImg = headImg;
-    }
-
-    @Override
-    public boolean equals(Object o) {
-        if (this == o) {
-            return true;
-        }
-        if (!(o instanceof User)) {
-            return false;
-        }
-        User user = (User) o;
-        return getIsEnabled() == user.getIsEnabled() &&
-                getIsEmployee() == user.getIsEmployee() &&
-                Objects.equals(getId(), user.getId()) &&
-                Objects.equals(getName(), user.getName()) &&
-                Objects.equals(geteName(), user.geteName()) &&
-                Objects.equals(getTrueName(), user.getTrueName()) &&
-                Objects.equals(getPasswordHash(), user.getPasswordHash()) &&
-                Objects.equals(isActive, user.isActive) &&
-                Objects.equals(isAdmin, user.isAdmin) &&
-                Objects.equals(getDescription(), user.getDescription()) &&
-                Objects.equals(getEmail(), user.getEmail()) &&
-                Objects.equals(getPhone(), user.getPhone()) &&
-                Objects.equals(getLastLoginIp(), user.getLastLoginIp()) &&
-                Objects.equals(getHeadImg(), user.getHeadImg());
-    }
-
-    @Override
-    public int hashCode() {
-        return Objects.hash(getId(), getName(), geteName(), getTrueName(), getPasswordHash(), getIsEnabled(), isActive, getIsEmployee(), isAdmin, getDescription(), getEmail(), getPhone(), getLastLoginIp(), getHeadImg());
-    }
-
-    public Object getAttribute(String name) {
-//        name = name.toUpperCase().trim();
-//        if (this.userEnv == null) {
-//            return null;
-//        } else {
-//            Object o = this.userEnv.get(name);
-//            if (o == null) {
-//                if ("$SYSDATE$".equals(name)) {
-//                    o = DateUtil.dateFormatter.format(new Date());
-//                } else if ("$SYSDATENUM$".equals(name)) {
-//                    o = DateUtil.dateNumberFormatter.format(new Date());
-//                } else if ("$SYSDATETIME$".equals(name)) {
-//                    o = DateUtil.dateTimeSecondsFormatter.format(new Date());
-//                }
-//            }
-//
-//            return o;
-
-        return null;
-    }
-}

+ 0 - 54
boman-modules/boman-system/src/main/java/com/boman/system/common/ValidationResults.java

@@ -1,54 +0,0 @@
-package com.boman.system.common;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import java.util.ArrayList;
-import java.util.Collection;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 10:50
- **/
-public class ValidationResults {
-    private static final Logger log = LoggerFactory.getLogger(ValidationResults.class);
-    private static ValidationResults okResult = new ValidationResults();
-    private Collection<String> errors = new ArrayList();
-
-    public ValidationResults() {
-    }
-
-    public static ValidationResults ok() {
-        return okResult;
-    }
-
-    public boolean isOk() {
-        return this.errors == null || this.errors.size() <= 0;
-    }
-
-//    public RowResult toRowResult(MainTableRecord row) {
-//        return RowResult.error(String.join("\r\n", this.errors));
-//    }
-
-//    public void addError(Exception e) {
-//        String message = getMessage(e);
-//        this.errors.add(message);
-//    }
-
-//    private static String getMessage(Exception ex) {
-//        String message = ex.getMessage();
-//        if (!(ex instanceof NDSException)) {
-//            StringWriter sw = new StringWriter();
-//            PrintWriter pw = new PrintWriter(sw);
-//            ex.printStackTrace(pw);
-//            message = sw.toString().replace("\n", "<br/>").replace("\tat", "");
-//        }
-//
-//        return message;
-//    }
-
-    public Collection<String> getErrors() {
-        return this.errors;
-    }
-}

+ 0 - 8
boman-modules/boman-system/src/main/java/com/boman/system/common/Validator.java

@@ -1,8 +0,0 @@
-package com.boman.system.common;
-
-
-
-
-public interface Validator {
-    void validate(TableServiceContext context, MainTableRecord currentRow);
-}

+ 0 - 165
boman-modules/boman-system/src/main/java/com/boman/system/common/ValueHolder.java

@@ -1,165 +0,0 @@
-package com.boman.system.common;
-
-import com.alibaba.fastjson.JSONObject;
-import lombok.Data;
-
-import java.io.Serializable;
-
-/**
- * @author shiqian
- * @description
- * @date 2021年03月22日 09:26
- **/
-@Data
-public class ValueHolder<T> implements Serializable {
-
-    public static final int OK = 0;
-    public static final int FAIL = -1;
-
-    private T data;
-    private int code;
-    private String message;
-
-    public ValueHolder() {
-    }
-
-    public ValueHolder(int code, String message, T data) {
-        this.data = data;
-        this.code = code;
-        this.message = message;
-    }
-
-    public ValueHolder(int code, String message) {
-        this.code = code;
-        this.message = message;
-    }
-
-    public JSONObject toJSONObject() {
-        JSONObject obj = new JSONObject();
-        obj.put("code", this.code);
-        obj.put("message", this.message);
-        obj.put("data", this.data);
-        return obj;
-    }
-
-    public static <T> ValueHolder<T> ok(String message){
-        return new ValueHolder<>(OK, message);
-    }
-
-    public static <T> ValueHolder<T> ok(String message, T data){
-        return new ValueHolder<>(OK, message, data);
-    }
-
-
-    public static <T> ValueHolder<T> ok(T data){
-        return new ValueHolder<>(OK, "成功", data);
-    }
-
-
-    public static <T> ValueHolder<T> fail(String message, T data){
-        return new ValueHolder<>(FAIL, message, data);
-    }
-
-    public static <T> ValueHolder<T> fail(String message){
-        return new ValueHolder<>(FAIL, message);
-    }
-
-
-
-
-
-
-
-
-    public boolean isOK() {
-        return this.code == 0;
-    }
-
-    public String toDebugString() {
-        return this.toJSONObject().toString();
-    }
-
-    public T getData() {
-        return this.data;
-    }
-
-    public int getCode() {
-        return this.code;
-    }
-
-    public String getMessage() {
-        return this.message;
-    }
-
-    public void setData(final T data) {
-        this.data = data;
-    }
-
-    public void setCode(final int code) {
-        this.code = code;
-    }
-
-    public void setMessage(final String message) {
-        this.message = message;
-    }
-
-    @Override
-    public boolean equals(final Object o) {
-        if (o == this) {
-            return true;
-        } else if (!(o instanceof ValueHolder)) {
-            return false;
-        } else {
-            ValueHolder<?> other = (ValueHolder)o;
-            if (!other.canEqual(this)) {
-                return false;
-            } else {
-                label39: {
-                    Object this$data = this.getData();
-                    Object other$data = other.getData();
-                    if (this$data == null) {
-                        if (other$data == null) {
-                            break label39;
-                        }
-                    } else if (this$data.equals(other$data)) {
-                        break label39;
-                    }
-
-                    return false;
-                }
-
-                if (this.getCode() != other.getCode()) {
-                    return false;
-                } else {
-                    Object this$message = this.getMessage();
-                    Object other$message = other.getMessage();
-                    if (this$message == null) {
-                        return other$message == null;
-                    } else return this$message.equals(other$message);
-
-                }
-            }
-        }
-    }
-
-    protected boolean canEqual(final Object other) {
-        return other instanceof ValueHolder;
-    }
-
-    @Override
-    public int hashCode() {
-        int result = 1;
-        Object $data = this.getData();
-        result = result * 59 + ($data == null ? 43 : $data.hashCode());
-        result = result * 59 + this.getCode();
-        Object $message = this.getMessage();
-        result = result * 59 + ($message == null ? 43 : $message.hashCode());
-        return result;
-    }
-
-    @Override
-    public String toString() {
-        return "ValueHolder(data=" + this.getData() + ", code=" + this.getCode() + ", message=" + this.getMessage() + ")";
-    }
-}
-

+ 3 - 4
boman-modules/boman-system/src/main/java/com/boman/system/controller/ObjController.java

@@ -116,10 +116,9 @@ public class ObjController {
         return tableServiceCmdService.getObject(condition);
     }
 
-
-    @ApiOperation(value = "表单提交接口")
-    @PostMapping("/objectSubmit")
-    public AjaxResult objectSubmit(@RequestBody BaseTableSaveDTO condition) {
+    @ApiOperation(value = "获取表单列表数据")
+    @PostMapping("/queryList")
+    public AjaxResult queryList(@RequestBody BaseTableSaveDTO condition) {
         return tableServiceCmdService.getObject(condition);
     }
 

+ 1 - 4
boman-modules/boman-system/src/main/java/com/boman/system/service/impl/BaseSaveService.java

@@ -3,7 +3,6 @@ package com.boman.system.service.impl;
 import com.alibaba.fastjson.JSONObject;
 import com.boman.system.common.MainTableRecord;
 import com.boman.system.common.RowResult;
-import com.boman.system.common.TableService;
 import com.boman.system.common.TableServiceContext;
 import com.boman.system.mapper.StandardlyMapper;
 import org.slf4j.Logger;
@@ -20,11 +19,9 @@ import java.sql.Timestamp;
  **/
 @Component
 public class BaseSaveService {
-    private static final Logger LOGGER = LoggerFactory.getLogger(TableService.class);
 
+    private static final Logger LOGGER = LoggerFactory.getLogger(BaseSaveService.class);
 
-    //    @Resource
-//    StoredProcedureService storedProcedureService;
     @Autowired
     private StandardlyMapper mapper;