Browse Source

Merge branch 'FIXBUG_createDate_is_null_after_draft_saved' of wy/zdqy_ibps into matser

吴懿 2 năm trước cách đây
mục cha
commit
ad5210c6b4

+ 9 - 0
ibps-form-root/modules/bo-biz/src/main/java/com/lc/ibps/base/bo/handler/impl/PhysicalTableDataHandlerImpl.java

@@ -72,6 +72,9 @@ public class PhysicalTableDataHandlerImpl implements PhysicalTableDataHandler {
 	private static final Logger logger = LoggerFactory.getLogger(PhysicalTableDataHandlerImpl.class);
 	private static final String WHERE_CLAUSE = " WHERE 1 = 1 ";
 
+	private static final List<String> INSERTABLE_COLUMNS = Arrays.asList(BoTableConstants.BUSINESS_COLUMN_CREATE_BY,
+			BoTableConstants.BUSINESS_COLUMN_CREATE_TIME);
+
 	@Resource
 	private BoAttrColumnQueryDao boAttrColumnQueryDao;
 	@Resource
@@ -642,6 +645,12 @@ public class PhysicalTableDataHandlerImpl implements PhysicalTableDataHandler {
 			}
 			
 			String colName = col.getName();
+
+			//skip create_date and create_by column for update
+			if(INSERTABLE_COLUMNS.contains(colName.toUpperCase())){
+				continue;
+			}
+
 			String attrCode = col.getAttrCode();
 			Object colValue = subDataMap.get(attrCode);