From 12ba06f89ae458ff2eb2e06d8822d31046a1d00d Mon Sep 17 00:00:00 2001 From: chenos Date: Wed, 25 Aug 2021 09:56:01 +0800 Subject: [PATCH] improve code --- packages/client/src/schemas/add-new/index.tsx | 14 +++++++------- .../client/src/schemas/database-field/index.tsx | 2 +- .../database-field/interfaces/chinaRegion.ts | 2 +- packages/client/src/schemas/table/index.tsx | 4 ++-- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/packages/client/src/schemas/add-new/index.tsx b/packages/client/src/schemas/add-new/index.tsx index dc1f9cd65..8bb2f1528 100644 --- a/packages/client/src/schemas/add-new/index.tsx +++ b/packages/client/src/schemas/add-new/index.tsx @@ -959,7 +959,7 @@ AddNew.CardItem = observer((props: any) => { let collectionName = null; let isNew = false; if (['addNewTable', 'addNewForm'].includes(info.key)) { - const values = await FormDialog(`新建数据表`, () => { + const values = await FormDialog(`创建数据表`, () => { return ( @@ -1046,7 +1046,7 @@ AddNew.CardItem = observer((props: any) => { } key={`addNew${view.key}`}> - 新建数据表 + 创建数据表 ))} @@ -1174,7 +1174,7 @@ AddNew.CardItem = observer((props: any) => { {/* */} {/* } key={`addNew${view.key}`}> - 新建数据表 + 创建数据表 */} ))} @@ -1269,7 +1269,7 @@ AddNew.CardItem = observer((props: any) => { {/* } key={`addNew${view.key}`}> - 新建数据表 + 创建数据表 */} ))} @@ -1326,7 +1326,7 @@ AddNew.CardItem = observer((props: any) => { - 新建模板 + 创建模板 @@ -1423,7 +1423,7 @@ AddNew.FormItem = observer((props: any) => { {options.map( (option) => @@ -1435,7 +1435,7 @@ AddNew.FormItem = observer((props: any) => { key={item.name} onClick={async () => { setVisible(false); - const values = await FormDialog(`创建字段`, () => { + const values = await FormDialog(`添加字段`, () => { return ( diff --git a/packages/client/src/schemas/database-field/index.tsx b/packages/client/src/schemas/database-field/index.tsx index 08910e4dd..568aa3917 100644 --- a/packages/client/src/schemas/database-field/index.tsx +++ b/packages/client/src/schemas/database-field/index.tsx @@ -486,7 +486,7 @@ export const DatabaseField: any = observer((props) => { icon={} style={{ marginTop: 10 }} > - 创建字段 + 添加字段 diff --git a/packages/client/src/schemas/database-field/interfaces/chinaRegion.ts b/packages/client/src/schemas/database-field/interfaces/chinaRegion.ts index 658c4130a..b9c8ef8f0 100644 --- a/packages/client/src/schemas/database-field/interfaces/chinaRegion.ts +++ b/packages/client/src/schemas/database-field/interfaces/chinaRegion.ts @@ -38,7 +38,7 @@ export const chinaRegion: FieldOptions = { type: 'number', 'x-component': 'Radio.Group', 'x-decorator': 'FormItem', - title: '层级', + title: '可选择的层级', default: 3, enum: [ { value: 1, label: '省' }, diff --git a/packages/client/src/schemas/table/index.tsx b/packages/client/src/schemas/table/index.tsx index 777ff116c..23c7e2983 100644 --- a/packages/client/src/schemas/table/index.tsx +++ b/packages/client/src/schemas/table/index.tsx @@ -471,7 +471,7 @@ function AddColumn() { {options.map((option) => ( @@ -481,7 +481,7 @@ function AddColumn() { key={item.name} onClick={async () => { setVisible(false); - const values = await FormDialog(`创建字段`, () => { + const values = await FormDialog(`添加字段`, () => { return (