|
|
@ -90,16 +90,19 @@ public class MapperSupport extends MybatisPlugin {
|
|
|
|
String userID = currentUser().getId();
|
|
|
|
String userID = currentUser().getId();
|
|
|
|
switch (sqlType) {
|
|
|
|
switch (sqlType) {
|
|
|
|
case INSERT:
|
|
|
|
case INSERT:
|
|
|
|
|
|
|
|
if (!isEmpty(entity.getCreatedBy())) return;
|
|
|
|
entity.setCreatedBy(userID);
|
|
|
|
entity.setCreatedBy(userID);
|
|
|
|
entity.setCreatedAt(now);
|
|
|
|
entity.setCreatedAt(now);
|
|
|
|
entity.setModifiedBy(userID);
|
|
|
|
entity.setModifiedBy(userID);
|
|
|
|
entity.setLastModified(now);
|
|
|
|
entity.setLastModified(now);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case UPDATE:
|
|
|
|
case UPDATE:
|
|
|
|
|
|
|
|
if (!isEmpty(entity.getModifiedBy())) return;
|
|
|
|
entity.setModifiedBy(userID);
|
|
|
|
entity.setModifiedBy(userID);
|
|
|
|
entity.setLastModified(now);
|
|
|
|
entity.setLastModified(now);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case DELETE:
|
|
|
|
case DELETE:
|
|
|
|
|
|
|
|
if (!isEmpty(entity.getRemovedBy())) return;
|
|
|
|
entity.setRemovedBy(userID);
|
|
|
|
entity.setRemovedBy(userID);
|
|
|
|
entity.setRemovedAt(now);
|
|
|
|
entity.setRemovedAt(now);
|
|
|
|
entity.setUseYN("N");
|
|
|
|
entity.setUseYN("N");
|
|
|
|