File History: src/main/java/com/paymentlink/repository/TranslationRepository.java

← View file content

File Content at Commit f0438c2

1 package com.paymentlink.repository;
2
3 import com.paymentlink.model.entity.Translation;
4 import org.springframework.data.jpa.repository.JpaRepository;
5 import org.springframework.data.jpa.repository.Query;
6 import org.springframework.data.repository.query.Param;
7 import org.springframework.stereotype.Repository;
8
9 import java.util.List;
10 import java.util.Optional;
11
12 @Repository
13 public interface TranslationRepository extends JpaRepository<Translation, Long> {
14
15 Optional<Translation> findByEntityTypeAndEntityIdAndFieldNameAndLanguageCode(
16 String entityType, String entityId, String fieldName, String languageCode);
17
18 List<Translation> findByEntityTypeAndEntityIdAndLanguageCode(
19 String entityType, String entityId, String languageCode);
20
21 List<Translation> findByEntityTypeAndEntityId(String entityType, String entityId);
22
23 @Query("SELECT t FROM Translation t WHERE t.entityType = :entityType " +
24 "AND t.entityId IN :entityIds AND t.languageCode = :languageCode")
25 List<Translation> findBulkTranslations(
26 @Param("entityType") String entityType,
27 @Param("entityIds") List<String> entityIds,
28 @Param("languageCode") String languageCode);
29
30 void deleteByEntityTypeAndEntityId(String entityType, String entityId);
31 }
32

Commits

Commit Author Date Message File SHA Actions
f0438c2 <f69e50@finnacloud.com> 1766443042 +0300 12/22/2025, 10:37:22 PM increment once more c6adc08 Hide
188fc92 <f69e50@finnacloud.com> 1766442998 +0300 12/22/2025, 10:36:38 PM increment c6adc08 View
4617f76 <f69e50@finnacloud.com> 1766442953 +0300 12/22/2025, 10:35:53 PM rename branch from main to master oops c6adc08 View
e6d1548 <f69e50@finnacloud.com> 1766442769 +0300 12/22/2025, 10:32:49 PM add initial test workflow file c6adc08 View
9c24ca4 <f69e50@finnacloud.com> 1766442705 +0300 12/22/2025, 10:31:45 PM add CI configuration and test script for Jenkins build c6adc08 View
690c1f6 <f69e50@finnacloud.com> 1766368110 +0300 12/22/2025, 1:48:30 AM initialize backend structure with controllers, DTOs, and configuration files c6adc08 View