File History: src/main/java/com/paymentlink/model/entity/Translation.java

← View file content

File Content at Commit f0438c2

1 package com.paymentlink.model.entity;
2
3 import jakarta.persistence.*;
4 import lombok.AllArgsConstructor;
5 import lombok.Builder;
6 import lombok.Data;
7 import lombok.NoArgsConstructor;
8 import org.hibernate.annotations.CreationTimestamp;
9 import org.hibernate.annotations.UpdateTimestamp;
10
11 import java.time.LocalDateTime;
12
13 @Entity
14 @Table(name = "translations",
15 indexes = @Index(name = "idx_translation_lookup",
16 columnList = "entityType,entityId,fieldName,languageCode"))
17 @Data
18 @NoArgsConstructor
19 @AllArgsConstructor
20 @Builder
21 public class Translation {
22
23 @Id
24 @GeneratedValue(strategy = GenerationType.IDENTITY)
25 private Long id;
26
27 @Column(nullable = false, length = 50)
28 private String entityType; // "product", "category", "ui"
29
30 @Column(nullable = false, length = 100)
31 private String entityId; // Product ID, category name, or UI key
32
33 @Column(nullable = false, length = 50)
34 private String fieldName; // "name", "description", etc.
35
36 @Column(length = 2, nullable = false)
37 private String languageCode; // ISO 639-1 (e.g., "en", "es", "fr")
38
39 @Column(columnDefinition = "TEXT", nullable = false)
40 private String translatedText;
41
42 @CreationTimestamp
43 @Column(name = "created_at", updatable = false)
44 private LocalDateTime createdAt;
45
46 @UpdateTimestamp
47 @Column(name = "updated_at")
48 private LocalDateTime updatedAt;
49 }
50

Commits

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