项目初始化

This commit is contained in:
2025-07-17 18:07:48 +08:00
parent c74ce366c7
commit 6550a64884
1179 changed files with 3407 additions and 3447 deletions

View File

@@ -0,0 +1,39 @@
package com.klp.common.annotation;
import com.fasterxml.jackson.annotation.JacksonAnnotationsInside;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.klp.common.translation.handler.TranslationHandler;
import java.lang.annotation.*;
/**
* 通用翻译注解
*
* @author Lion Li
*/
@Inherited
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.FIELD, ElementType.METHOD})
@Documented
@JacksonAnnotationsInside
@JsonSerialize(using = TranslationHandler.class)
public @interface Translation {
/**
* 类型 (需与实现类上的 {@link com.klp.common.annotation.TranslationType} 注解type对应)
* <p>
* 默认取当前字段的值 如果设置了 @{@link Translation#mapper()} 则取映射字段的值
*/
String type();
/**
* 映射字段 (如果不为空则取此字段的值)
*/
String mapper() default "";
/**
* 其他条件 例如: 字典type(sys_user_sex)
*/
String other() default "";
}