From d298a3cf0e69a9a532811d8cb7d0bf606ec292b4 Mon Sep 17 00:00:00 2001 From: auaa Date: Sun, 15 Dec 2024 13:10:17 +0800 Subject: [PATCH 1/7] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=96=87=E6=A1=A3?= =?UTF-8?q?=E5=88=AB=E5=AD=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../current/query/paging/reverse-sorting.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/i18n/zh/docusaurus-plugin-content-docs/current/query/paging/reverse-sorting.mdx b/i18n/zh/docusaurus-plugin-content-docs/current/query/paging/reverse-sorting.mdx index 6a6c6192b..fc4d446b9 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/current/query/paging/reverse-sorting.mdx +++ b/i18n/zh/docusaurus-plugin-content-docs/current/query/paging/reverse-sorting.mdx @@ -8,9 +8,9 @@ import TabItem from '@theme/TabItem'; ## 概念 -随着页码的不断睁大,分页查询的效率会越来越低。为了解决这个问题,Jimmer支持了反排序优化。 +随着页码的不断增大,分页查询的效率会越来越低。为了解决这个问题,Jimmer支持了反排序优化。 -反排序优化必须在一下前提同时满足时才生效: +反排序优化必须在以下前提同时满足时才生效: 1. 此功能并不针对只关心页内数据而不关心分页前总行数的的查询,即`limit(limit, offset)`。必须是同时关心页内数据和总行数的查询。 From 9a1212fe411c381cc7787ccb851240d26af14237 Mon Sep 17 00:00:00 2001 From: Rover12421 Date: Sun, 15 Dec 2024 15:55:47 +0800 Subject: [PATCH 2/7] Fix the GeneratedValue annotation error in the BookStore code There is an extra '@' in the annotation. --- .../current/quick-view/precondition.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/precondition.mdx b/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/precondition.mdx index cdd3747d7..2f759d996 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/precondition.mdx +++ b/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/precondition.mdx @@ -63,7 +63,7 @@ public interface BookStore { interface BookStore { @Id - @@GeneratedValue(strategy = GenerationType.IDENTITY) + @GeneratedValue(strategy = GenerationType.IDENTITY) val id: Long val name: String @@ -208,4 +208,4 @@ enum class Gender { MALE, FEMALE } ``` - \ No newline at end of file + From ddce50fa5bfdba747bfba0af90b487c71425bc7e Mon Sep 17 00:00:00 2001 From: Rover12421 Date: Tue, 17 Dec 2024 16:35:46 +0800 Subject: [PATCH 3/7] [create-database] Corrected sql highlighting, keeping the style consistent between zh and en --- docs/quick-view/get-started/create-database.mdx | 2 +- .../current/quick-view/get-started/create-database.mdx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/quick-view/get-started/create-database.mdx b/docs/quick-view/get-started/create-database.mdx index ecfda0efd..38cbd014e 100644 --- a/docs/quick-view/get-started/create-database.mdx +++ b/docs/quick-view/get-started/create-database.mdx @@ -19,7 +19,7 @@ The examples in this tutorial require the following four entity types: This tutorial uses MySQL. Create a new SQL file `jimmer-demo.sql` with the following code: -```csharp +```sql title="jimmer-demo.sql" create database jimmer_demo; use jimmer_demo; diff --git a/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/create-database.mdx b/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/create-database.mdx index f848627b4..e761f79c4 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/create-database.mdx +++ b/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/create-database.mdx @@ -19,7 +19,7 @@ title: 创建数据库 本教程例子采用MySQL,新建SQL文件`jimmer-demo.sql`,代码如下 -```csharp title="jimmer-demo.sql" +```sql title="jimmer-demo.sql" create database jimmer_demo; use jimmer_demo; From c52b169b82e91311a3683f3a11001db621e862f9 Mon Sep 17 00:00:00 2001 From: Rover12421 Date: Tue, 17 Dec 2024 17:16:34 +0800 Subject: [PATCH 4/7] [define-entity] Corrected the title attribute in syntax highlighting --- docs/quick-view/get-started/define-entity.mdx | 8 ++++---- .../current/quick-view/get-started/define-entity.mdx | 10 +++++----- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/docs/quick-view/get-started/define-entity.mdx b/docs/quick-view/get-started/define-entity.mdx index 37cd3a853..982420cc9 100644 --- a/docs/quick-view/get-started/define-entity.mdx +++ b/docs/quick-view/get-started/define-entity.mdx @@ -191,7 +191,7 @@ Assume the entity package is "com.example.model". **Ignore associated properties - ```java title="Author.java" + ```java title="Gender.java" package com.example.model; import org.babyfish.jimmer.sql.EnumItem; @@ -210,7 +210,7 @@ Assume the entity package is "com.example.model". **Ignore associated properties - ```kotlin title="Author.kt" + ```kotlin title="Gender.kt" package com.example.model import org.babyfish.jimmer.sql.EnumItem @@ -325,8 +325,8 @@ package com.example.model; @Entity public interface Book { - ...other properties omitted... - + ...other properties omitted... + // highlight-next-line @ManyToOne @Nullable diff --git a/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/define-entity.mdx b/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/define-entity.mdx index 2a79f46ed..dec03dc7c 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/define-entity.mdx +++ b/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/define-entity.mdx @@ -161,7 +161,7 @@ import TabItem from '@theme/TabItem'; - ```kotlin title="Book.kt" + ```kotlin title="Author.kt" package com.example.model import org.babyfish.jimmer.sql.* @@ -200,7 +200,7 @@ import TabItem from '@theme/TabItem'; - ```java title="Author.java" + ```java title="Gender.java" package com.example.model; import org.babyfish.jimmer.sql.EnumItem; @@ -218,7 +218,7 @@ import TabItem from '@theme/TabItem'; - ```kotlin title="Book.kt" + ```kotlin title="Gender.kt" package com.example.model import org.babyfish.jimmer.sql.EnumItem @@ -265,7 +265,7 @@ import TabItem from '@theme/TabItem'; - ```kotlin title="Book.kt" + ```kotlin title="TreeNode.kt" package com.example.model import org.babyfish.jimmer.sql.* @@ -401,7 +401,7 @@ public interface BookStore { -```kotlin title="Book.kt" +```kotlin title="BookStore.kt" package com.example.model ...省略导入语句... From 3a71f0fb13ab242013cc823129bbd5e209556177 Mon Sep 17 00:00:00 2001 From: Rover12421 Date: Tue, 17 Dec 2024 22:58:49 +0800 Subject: [PATCH 5/7] =?UTF-8?q?[generate-code.mdx]=20=E7=BA=A0=E6=AD=A3?= =?UTF-8?q?=E4=B9=A6=E5=86=99=E8=A1=A8=E8=BE=BE=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../current/quick-view/get-started/generate-code.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/generate-code.mdx b/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/generate-code.mdx index 320369532..65dad2a3c 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/generate-code.mdx +++ b/i18n/zh/docusaurus-plugin-content-docs/current/quick-view/get-started/generate-code.mdx @@ -24,7 +24,7 @@ import Precompiler from '../../_shared/precompiler.mdx'; :::caution 注意,上面的代码,仅仅针对初次入门时项目结构没有切分的场景。 -如果把实实体的定义剥离成一个独立项目、和其他数据层业务层开,这套代码生成器需要配置到实体定义项目中。 +如果把实体的定义剥离成一个独立项目,和其他数据层业务层开,这套代码生成器需要配置到实体定义项目中。 为了保证实体定义项目的简单,原则上讲应该只添加一个最简单的的依赖:`jimmer-core`。 Jimmer定义数据类型需要如下4个注解之一 From aae18785aa4a9f7f12574f3724baee523d06f8bb Mon Sep 17 00:00:00 2001 From: SparrowAndSnow Date: Thu, 19 Dec 2024 20:38:17 +0800 Subject: [PATCH 6/7] Update concept.mdx MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Spring篇>Spring Data风格>定义RepositoryBookStoreRepository示例代码有误 --- .../current/spring/repository/concept.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/i18n/zh/docusaurus-plugin-content-docs/current/spring/repository/concept.mdx b/i18n/zh/docusaurus-plugin-content-docs/current/spring/repository/concept.mdx index 9c43d3452..8a62322f0 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/current/spring/repository/concept.mdx +++ b/i18n/zh/docusaurus-plugin-content-docs/current/spring/repository/concept.mdx @@ -38,7 +38,7 @@ Jimmer整合了spring data,为Java用户和Kotlin用户各自提供了一个Re import org.babyfish.jimmer.spring.repository.JRepository; - public interface BookRepository extends JRepository {} + public interface BookStoreRepository extends JRepository {} ``` @@ -51,7 +51,7 @@ Jimmer整合了spring data,为Java用户和Kotlin用户各自提供了一个Re import org.babyfish.jimmer.spring.repository.KRepository - interface BookRepository : KRepository + interface BookStoreRepository : KRepository ``` From f8a759e763c0fc2e9de9846a54c2d307389bac7f Mon Sep 17 00:00:00 2001 From: SparrowAndSnow Date: Thu, 19 Dec 2024 20:51:31 +0800 Subject: [PATCH 7/7] =?UTF-8?q?doc:=20Spring=E7=AF=87=E5=A4=8D=E6=9D=82?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2kotlin=E4=BB=A3=E7=A0=81=E6=9C=89=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Spring篇>Spring Data风格>复杂查询。kotlin的BookRepository示例代码有误 --- .../current/spring/repository/default.mdx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/i18n/zh/docusaurus-plugin-content-docs/current/spring/repository/default.mdx b/i18n/zh/docusaurus-plugin-content-docs/current/spring/repository/default.mdx index 1bbc4ffd0..e5203535c 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/current/spring/repository/default.mdx +++ b/i18n/zh/docusaurus-plugin-content-docs/current/spring/repository/default.mdx @@ -65,7 +65,7 @@ import com.example.model.Book import org.babyfish.jimmer.spring.repository.KRepository import org.babyfish.jimmer.sql.kt.ast.expression.* -interface BookRepository : KRepository { +interface BookRepository : KRepository { fun find(name: String? = null): List = sql ❷ @@ -257,7 +257,7 @@ import com.example.model.Book import org.babyfish.jimmer.spring.repository.KRepository import org.babyfish.jimmer.sql.kt.ast.expression.* -interface BookRepository : KRepository { +interface BookRepository : KRepository { fun find( name: String? = null, @@ -413,7 +413,7 @@ import com.example.model.Book import org.babyfish.jimmer.spring.repository.KRepository import org.babyfish.jimmer.sql.kt.ast.expression.* -interface BookRepository : KRepository { +interface BookRepository : KRepository { fun find( name: String? = null, @@ -597,7 +597,7 @@ import org.babyfish.jimmer.spring.repository.orderBy import org.babyfish.jimmer.sql.kt.ast.expression.* import org.springframework.data.domain.Sort -interface BookRepository : KRepository { +interface BookRepository : KRepository { fun find( name: String? = null, @@ -825,7 +825,7 @@ import org.babyfish.jimmer.sql.kt.ast.expression.* import org.springframework.data.domain.Page import org.springframework.data.domain.Pageable -interface BookRepository : KRepository { +interface BookRepository : KRepository { fun find( name: String? = null, @@ -1117,7 +1117,7 @@ import org.babyfish.jimmer.sql.kt.ast.expression.* import org.springframework.data.domain.Page import org.springframework.data.domain.Pageable -interface BookRepository : KRepository { +interface BookRepository : KRepository { fun find( name: String? = null,