Commit 3ec5b19a77ad7282660a1fc4ff020a3cfd085ecc
Committed by
Gitee
!1200 BPM:更多设置-流程编码
Merge pull request !1200 from Lesan/feature/bpm-流程编码
Showing
2 changed files
with
16 additions
and
4 deletions
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/dal/redis/BpmProcessIdRedisDAO.java
| ... | ... | @@ -17,9 +17,6 @@ import java.time.LocalDateTime; |
| 17 | 17 | @Repository |
| 18 | 18 | public class BpmProcessIdRedisDAO { |
| 19 | 19 | |
| 20 | - // TODO @lesan:要枚举到 rediskeyconstants 哈 | |
| 21 | - public static final String BPM_PROCESS_ID_PREFIX = "BPMPID"; | |
| 22 | - | |
| 23 | 20 | @Resource |
| 24 | 21 | private StringRedisTemplate stringRedisTemplate; |
| 25 | 22 | |
| ... | ... | @@ -49,7 +46,7 @@ public class BpmProcessIdRedisDAO { |
| 49 | 46 | |
| 50 | 47 | // 生成序号 |
| 51 | 48 | String noPrefix = processIdRule.getPrefix() + infix + processIdRule.getPostfix(); |
| 52 | - String key = BPM_PROCESS_ID_PREFIX + noPrefix; | |
| 49 | + String key = RedisKeyConstants.BPM_PROCESS_ID + noPrefix; | |
| 53 | 50 | Long no = stringRedisTemplate.opsForValue().increment(key); |
| 54 | 51 | stringRedisTemplate.expire(key, Duration.ofDays(1L)); |
| 55 | 52 | return noPrefix + String.format("%0" + processIdRule.getLength() + "d", no); | ... | ... |
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/dal/redis/RedisKeyConstants.java
0 → 100644