From a33898c2a0374c249862a2b996e33352e30c8caf Mon Sep 17 00:00:00 2001 From: KonBAI <1527468660@qq.com> Date: 星期六, 02 四月 2022 13:02:56 +0800 Subject: [PATCH] !167 update 修改角色"菜单树选择项"和"部门树选择项"是否关联显示字段为Boolean类型 * fix 修改 postgres sql脚本,处理角色表字段类型错误问题。 * fix 修复postgreSQL新增或更新角色信息报错。修改角色"菜单树选择项"和"部门树选择项"是否关联显示字段为Boolean类型。 --- ruoyi-demo/src/main/java/com/ruoyi/demo/controller/TestSensitiveController.java | 34 +++++++++++++++++++++++----------- 1 files changed, 23 insertions(+), 11 deletions(-) diff --git a/ruoyi-demo/src/main/java/com/ruoyi/demo/controller/TestSensitiveController.java b/ruoyi-demo/src/main/java/com/ruoyi/demo/controller/TestSensitiveController.java index 2458747..1f34f9c 100644 --- a/ruoyi-demo/src/main/java/com/ruoyi/demo/controller/TestSensitiveController.java +++ b/ruoyi-demo/src/main/java/com/ruoyi/demo/controller/TestSensitiveController.java @@ -2,25 +2,24 @@ import com.ruoyi.common.annotation.Sensitive; import com.ruoyi.common.core.controller.BaseController; -import com.ruoyi.common.core.domain.AjaxResult; +import com.ruoyi.common.core.domain.R; import com.ruoyi.common.enums.SensitiveStrategy; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import lombok.Data; -import lombok.experimental.Accessors; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; /** * 娴嬭瘯鏁版嵁鑴辨晱鎺у埗鍣� - * + * <p> * 榛樿绠$悊鍛樹笉杩囨护 * 闇�鑷鏍规嵁涓氬姟閲嶅啓瀹炵幇 * - * @see com.ruoyi.common.core.service.SensitiveService * @author Lion Li * @version 3.6.0 + * @see com.ruoyi.common.core.service.SensitiveService */ @Api(value = "娴嬭瘯鏁版嵁鑴辨晱鎺у埗鍣�", tags = {"娴嬭瘯鏁版嵁鑴辨晱绠$悊"}) @RestController @@ -32,16 +31,17 @@ */ @ApiOperation("鏌ヨ娴嬭瘯鍗曡〃鍒楄〃") @GetMapping("/test") - public AjaxResult<TestSensitive> test() { - TestSensitive testSensitive = new TestSensitive() - .setIdCard("3333199910101212") - .setPhone("18888888888") - .setAddress("鍖椾含甯傛湞闃冲尯鏌愭煇鍥涘悎闄�1203瀹�"); - return AjaxResult.success(testSensitive); + public R<TestSensitive> test() { + TestSensitive testSensitive = new TestSensitive(); + testSensitive.setIdCard("210397198608215431"); + testSensitive.setPhone("17640125371"); + testSensitive.setAddress("鍖椾含甯傛湞闃冲尯鏌愭煇鍥涘悎闄�1203瀹�"); + testSensitive.setEmail("17640125371@163.com"); + testSensitive.setBankCard("6226456952351452853"); + return R.ok(testSensitive); } @Data - @Accessors(chain = true) static class TestSensitive { /** @@ -62,6 +62,18 @@ @Sensitive(strategy = SensitiveStrategy.ADDRESS) private String address; + /** + * 閭 + */ + @Sensitive(strategy = SensitiveStrategy.EMAIL) + private String email; + + /** + * 閾惰鍗� + */ + @Sensitive(strategy = SensitiveStrategy.BANK_CARD) + private String bankCard; + } } -- Gitblit v1.9.3