Skip to content

Commit

Permalink
perf($MyBatisPlus): enable logic delete
Browse files Browse the repository at this point in the history
[skip ci]
  • Loading branch information
Johnny Miller (锺俊) committed Jan 13, 2021
1 parent 31564ca commit e48fafa
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 0 deletions.
3 changes: 3 additions & 0 deletions auth-center/src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ management:
show-details: ALWAYS

mybatis-plus:
global-config:
db-config:
logic-delete-field: deleted
configuration:
map-underscore-to-camel-case: true
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
package com.jmsoftware.maf.common.domain;

import lombok.Getter;
import lombok.extern.slf4j.Slf4j;

/**
* Description: DeleteField, change description here.
*
* @author 钟俊 (zhongjun), email: zhongjun@toguide.cn, date: 1/13/2021 6:32 PM
*/
@Slf4j
@Getter
public enum DeleteField {
/**
* Not deleted
*/
NOT_DELETED((byte) 0, "not deleted"),
/**
* Deleted
*/
DELETED((byte) 1, "deleted");

/**
* The Value.
*/
private final Byte value;
/**
* The Description.
*/
private final String description;

/**
* Instantiates a new Delete field.
*
* @param value the value
* @param description the description
*/
DeleteField(Byte value, String description) {
this.value = value;
this.description = description;
}
}

0 comments on commit e48fafa

Please sign in to comment.