Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
123 commits
Select commit Hold shift + click to select a range
b97583e
fix: update page history bug
lu-yg Dec 26, 2024
d30877c
fix: format code and fix style issue
lu-yg Jan 7, 2025
33316bf
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Jan 7, 2025
7fc6507
fix: modify page histiry entity
lu-yg Jan 7, 2025
64be7b4
Merge branch 'opentiny:develop' into develop
lu-yg Jan 9, 2025
24474b8
feat: add code submission rules
lu-yg Jan 9, 2025
9745b66
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Jan 9, 2025
239c624
Merge branch 'opentiny:develop' into develop
lu-yg Jan 9, 2025
b77f2f4
fix: modify app schema for test
lu-yg Jan 9, 2025
feeb8f7
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Jan 9, 2025
7d52937
fix: modify block group
lu-yg Jan 22, 2025
6559bec
fix: modify t_i18n_entry u_idx_i18n_entity
lu-yg Jan 22, 2025
2a7fc44
Merge branch 'opentiny:develop' into develop
lu-yg Jan 22, 2025
656a4a1
fix: modify t_i18n_entry u_idx_i18n_entity
lu-yg Jan 22, 2025
9de10c5
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Jan 22, 2025
e9aa592
fix: modify block update api
lu-yg Jan 23, 2025
aff95bb
Merge branch 'opentiny:develop' into develop
lu-yg Jan 23, 2025
02607e4
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Jan 23, 2025
ed7483d
fix: Modify code format
lu-yg Jan 23, 2025
48267d6
fix: Modify code format
lu-yg Jan 23, 2025
cabb309
fix: Modify code format
lu-yg Jan 23, 2025
83cb48a
fix: Modify code format
lu-yg Jan 24, 2025
486944b
fix: Modify code format
lu-yg Jan 24, 2025
751f331
Merge branch 'opentiny:develop' into develop
lu-yg Jan 26, 2025
48645e1
fix: modify block group api
lu-yg Jan 26, 2025
d2f2406
fix: modify block group mapper
lu-yg Jan 26, 2025
e24d0ec
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Jan 26, 2025
ee8219f
fix: modify workflows
lu-yg Jan 26, 2025
efad29b
fix: Update checkstyle.yml
lu-yg Jan 26, 2025
6868add
fix: modify workflows
lu-yg Jan 26, 2025
2e131ff
fix: Modify block create and update api
lu-yg Jan 27, 2025
9c1225a
Merge branch 'opentiny:develop' into develop
lu-yg Jan 27, 2025
8cc8ca5
fix: Modify code format
lu-yg Jan 27, 2025
4ba0818
fix: Modify code format
lu-yg Jan 27, 2025
6d978f1
fix: Modify block group
lu-yg Feb 6, 2025
b3f35a0
fix: Modify block group
lu-yg Feb 6, 2025
9717200
fix: Modify block group
lu-yg Feb 6, 2025
e757b29
fix: Modify block group
lu-yg Feb 6, 2025
7d90c86
fix: Modify block group api
lu-yg Feb 13, 2025
d6856ba
Merge branch 'opentiny:develop' into develop
lu-yg Feb 13, 2025
8a89475
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Feb 13, 2025
baa4eeb
fix: Modify block group api
lu-yg Feb 13, 2025
654da8b
fix: Modify block group api
lu-yg Feb 13, 2025
a230c24
feat: add code check
lu-yg Feb 27, 2025
6966946
Merge branch 'opentiny:develop' into develop
lu-yg Feb 27, 2025
d503c96
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Feb 27, 2025
7f9b378
feat: add code check
lu-yg Feb 27, 2025
2bdf54c
feat: add code check
lu-yg Feb 27, 2025
bef4adc
Merge branch 'opentiny:develop' into develop
lu-yg Feb 28, 2025
88dec60
feat: add code check
lu-yg Feb 28, 2025
63efa3c
Merge branch 'opentiny:develop' into develop
lu-yg Feb 28, 2025
f05a3ef
fix: Fix code check
lu-yg Feb 28, 2025
dbc910c
Merge branch 'opentiny:develop' into develop
lu-yg Mar 6, 2025
8a4041c
fix: Cross domain configuration
lu-yg Mar 6, 2025
57fd35a
fix: Cross domain configuration
lu-yg Mar 6, 2025
bff62cc
fix: i18n file upload
lu-yg Mar 7, 2025
ededae7
fix: i18n file upload
lu-yg Mar 7, 2025
1fa284b
Merge branch 'opentiny:develop' into develop
lu-yg Mar 20, 2025
7f17fb7
fix: page update api
lu-yg Mar 20, 2025
934130f
fix: page update api
lu-yg Mar 20, 2025
a920283
feat: material history api
lu-yg Apr 1, 2025
b1e0f83
feat: component library api
lu-yg Apr 2, 2025
5d244ba
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Apr 2, 2025
05f4473
feat: component library api
lu-yg Apr 7, 2025
58ed56b
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Apr 7, 2025
6a5269d
feat: component library api
lu-yg Apr 7, 2025
2f31f88
feat: component library api
lu-yg Apr 7, 2025
9ee1ef1
feat: component library api
lu-yg Apr 7, 2025
59c6ddc
feat: component library api
lu-yg Apr 7, 2025
8373484
feat: component library api
lu-yg Apr 7, 2025
fb123c6
feat: component library api
lu-yg Apr 7, 2025
0875559
feat: component library api
lu-yg Apr 7, 2025
4082626
fix: Mock data is changed to be obtained from loginUserContext
lu-yg Apr 7, 2025
b70579e
Merge branch 'opentiny:develop' into develop
lu-yg Apr 7, 2025
a25abab
Merge branch 'opentiny:develop' into develop
lu-yg Apr 10, 2025
72539c5
fix: Component library mapper
lu-yg Apr 10, 2025
a98b503
fix:Update t_component index
lu-yg Apr 11, 2025
9c82702
Merge branch 'opentiny:develop' into develop
lu-yg Apr 11, 2025
e1e1ef4
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Apr 11, 2025
8005656
fix:Update t_component index
lu-yg Apr 11, 2025
898e66d
Merge branch 'opentiny:develop' into develop
lu-yg Apr 16, 2025
3c66527
fix: Component and component library mapper
lu-yg Apr 16, 2025
267f667
fix: App v1 service
lu-yg Apr 16, 2025
75f0be1
fix: App v1 service
lu-yg Apr 16, 2025
40e6829
Merge branch 'opentiny:develop' into develop
lu-yg Apr 17, 2025
e7071e7
fix: Modify code format
lu-yg Apr 17, 2025
9a4e612
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Apr 17, 2025
0993e94
Merge branch 'opentiny:develop' into develop
lu-yg Apr 21, 2025
7d88f1c
fix: Modify mapper
lu-yg Apr 21, 2025
2265f07
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Apr 21, 2025
c35445f
Merge branch 'opentiny:develop' into develop
lu-yg Apr 23, 2025
cabc129
fix: Modify bundle split
lu-yg Apr 23, 2025
958c7b6
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg Apr 23, 2025
7e33a5d
Merge branch 'opentiny:develop' into develop
lu-yg Apr 27, 2025
2c60fa1
fix: format code and fix style issue
lu-yg Apr 27, 2025
e7e4be5
Merge branch 'opentiny:develop' into develop
lu-yg Apr 27, 2025
1a380b6
fix: fix getSchemaComponentsTree function bug
lu-yg Apr 30, 2025
15c6e8f
fix: Fix folder hierarchy restrictions and add AI models
lu-yg May 7, 2025
4ab18bd
Merge branch 'opentiny:develop' into develop
lu-yg May 8, 2025
243d8f9
fix: block lock issue
lu-yg May 8, 2025
818986d
Merge branch 'opentiny:develop' into develop
lu-yg May 9, 2025
b98e193
fead: platform API
lu-yg May 9, 2025
4ac65e2
feat: platform API
lu-yg May 9, 2025
16ad90d
Merge branch 'develop' of github.com:lu-yg/tiny-engine-backend-java i…
lu-yg May 13, 2025
7f875ce
feat: platform API
lu-yg May 13, 2025
091ed5e
feat: Add inspection file
lu-yg May 13, 2025
3438b96
feat: Add inspection file
lu-yg May 13, 2025
68b329a
feat: Add inspection file
lu-yg May 13, 2025
37e06a9
feat: Add inspection file
lu-yg May 13, 2025
2df5550
feat: Add inspection file
lu-yg May 13, 2025
c679a28
Merge branch 'opentiny:develop' into develop
lu-yg May 14, 2025
a20073b
fix: Modify the default values of table fields and page API
lu-yg May 14, 2025
0e44141
fix: Modify the default values of table fields and page API
lu-yg May 14, 2025
46f3277
fix: Format code and fix style issue
lu-yg May 22, 2025
385ca28
fix: Format code and fix style issue
lu-yg May 22, 2025
76a672d
fix: Format code and fix style issue
lu-yg May 23, 2025
0b9ce6c
fix: Modify database initialization data
lu-yg May 23, 2025
a654915
fix: Modify database initialization data
lu-yg May 23, 2025
6c08dcb
fix: Modify mapper xml
lu-yg May 26, 2025
f5dabe1
fix: Modify mapper xml
lu-yg May 26, 2025
09eb0ba
Merge branch 'opentiny:develop' into feat/deployment
lu-yg May 27, 2025
eac0afb
fix: Fix i18n bug
lu-yg May 27, 2025
00e7de8
fix: Fix i18n bug
lu-yg May 27, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -70,19 +70,20 @@ public class I18nEntryController {
private I18nEntryService i18nEntryService;

/**
* Gets all i 18 n entries.
* Gets all i 18 n entries by app.
*
* @return 获取国际化词条列表 all i 18 n entries
* @return 获取国际化词条列表 i 18 n entries
*/
@Operation(summary = "获取国际化词条列表", description = "获取国际化词条列表", responses = {
@Operation(summary = "通过app获取国际化词条列表", description = "通过app获取国际化词条列表", responses = {
@ApiResponse(responseCode = "200", description = "返回信息",
content = @Content(mediaType = "application/json", schema = @Schema())),
@ApiResponse(responseCode = "400", description = "请求失败")
})
@SystemControllerLog(description = "获取国际化词条列表")
@GetMapping("/i18n/entries")
public Result<I18nEntryListResult> getAllI18nEntries() {
I18nEntryListResult i18nEntriesList = i18nEntryService.findAllI18nEntry();
public Result<I18nEntryListResult> getI18nEntriesByApp( @RequestParam(value = "host", required = false) Integer host,
@RequestParam(value = "host_type", required = false) String hostType) {
I18nEntryListResult i18nEntriesList = i18nEntryService.findI18nEntryByApp(host, hostType);
return Result.success(i18nEntriesList);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -124,4 +124,11 @@ public interface I18nEntryService {
* @throws Exception the exception
*/
Result<FileResult> readFilesAndbulkCreate(String lang, MultipartFile file, int host) throws Exception;

/**
* 通过app查询表t_i18n_entry所有信息
*
* @return the 18 n entry list result
*/
I18nEntryListResult findI18nEntryByApp(Integer host, String hostType);
}
Original file line number Diff line number Diff line change
Expand Up @@ -375,6 +375,35 @@ public Result<FileResult> readFilesAndbulkCreate(String lang, MultipartFile file
return Result.success(i18nFileResult);
}

/**
* 通过app查询表t_i18n_entry所有信息
*
* @return the 18 n entry list result
*/
@Override
public I18nEntryListResult findI18nEntryByApp(Integer host, String hostType) {
I18nEntryListResult i18nEntriesListResult = new I18nEntryListResult();
// 获取所属应用/区块的 语言列表 getHostLangs
List<I18nLang> i18nLangsList = getHostLangs();
if (i18nLangsList == null || i18nLangsList.isEmpty()) {
return i18nEntriesListResult;
}
// 获取词条列表
List<I18nEntryDto> i18nEntriesList = i18nEntryMapper.findI18nEntriesByHostandHostType(host, hostType);
if (i18nEntriesList == null) {
return i18nEntriesListResult;
}
// 格式化词条列表
SchemaI18n messages = formatEntriesList(i18nEntriesList);
List<I18nLang> i18nLangsListTemp = i18nLangsList.stream()
.map(i18nLang -> new I18nLang(i18nLang.getLang(), i18nLang.getLabel()))
.collect(Collectors.toList());

i18nEntriesListResult.setI18nLangsList(i18nLangsListTemp);
i18nEntriesListResult.setMessages(messages);
return i18nEntriesListResult;
}

/**
* 批量创建或修改
*
Expand Down Expand Up @@ -449,7 +478,7 @@ public List<EntriesItem> parseZipFileStream(MultipartFile file) throws Exception
// 解压ZIP文件并处理
List<FileInfo> fileInfos = Utils.unzip(file);
for (FileInfo fileInfo : fileInfos) {
entriesItems = parseZip(fileInfo);
entriesItems.addAll(parseZip(fileInfo));
}
return entriesItems;
}
Expand Down Expand Up @@ -530,7 +559,7 @@ private EntriesItem setLang(String fileName) {
} else {
name = fileName.substring(0, lastDotIndex); // 返回不带扩展名的文件名
}
if (Enums.I18nFileName.EN_US.getValue().equals(name)) {
if (name.contains(Enums.I18nFileName.EN_US.getValue())) {
entriesItem.setLang(2);
} else {
entriesItem.setLang(1);
Expand Down
Loading