叫号接口

This commit is contained in:
张松
2025-02-21 14:44:34 +08:00
parent 0e7475d894
commit 14a65c4787
31 changed files with 1594 additions and 1 deletions

View File

@@ -6,6 +6,8 @@ package com.czg.config;
* @author Administrator
*/
public interface RedisCst {
String LOCK_KEY = "LOCK:";
String LOGIN_CODE = "login:code:";
String SYS_LOG_KEY = "sys:log:";
@@ -14,4 +16,21 @@ public interface RedisCst {
String SMS_CODE = "sms:code:";
// 店铺会员动态支付码
String SHOP_USER_DYNAMIC_CODE = "shop:user:dynamic:code:";
// 排队取号全局号码
String TABLE_CALL_NUMBER = "TABLE_CALL_NUMBER:";
static String getLockKey(String sign, Object... args) {
StringBuilder key = new StringBuilder(LOCK_KEY + ":" + sign + ":");
for (Object arg : args) {
if (arg != null) {
key.append(":").append(arg);
}
}
return key.toString();
}
static String getTableCallNumKey(Long shopId, Long callTableId) {
return TABLE_CALL_NUMBER + shopId + ":" + callTableId;
}
}