Fees and structures added

This commit is contained in:
RIT Services
2026-08-20 06:43:00 +00:00
parent 9d83dec681
commit 6e52735484
9 changed files with 909 additions and 44 deletions

View File

@@ -42,6 +42,14 @@ public class SessionService {
userStates.put(phoneNumber, state);
}
public boolean isSessionCached(String phoneNumber) {
return sessionTokens.containsKey(phoneNumber);
}
public boolean hasSavedCredentials(String phoneNumber) {
return userRepository.existsById(phoneNumber);
}
public void resetState(String phoneNumber) {
userStates.remove(phoneNumber);
}
@@ -104,6 +112,20 @@ public class SessionService {
return name;
}
private final Map<String, Map<String, String>> receiptIdMappings = new ConcurrentHashMap<>();
public void storeReceiptIdMappings(String phoneNumber, Map<String, String> mappings) {
receiptIdMappings.put(phoneNumber, mappings);
}
public String getReceiptIdMapping(String phoneNumber, String shortId) {
Map<String, String> mappings = receiptIdMappings.get(phoneNumber);
if (mappings != null) {
return mappings.get(shortId);
}
return null;
}
public void setTempLoginId(String phoneNumber, String tempId) {
temporaryLoginIds.put(phoneNumber, tempId);
}