Skip to content

Commit

Permalink
PullRequest: 423 Fixes oceanbase/odc#2308
Browse files Browse the repository at this point in the history
Merge branch fix/dev-4.2.4-bugfix-2308 of [email protected]:oceanbase/oceanbase-developer-center.git into dev-4.2.4
https://code.alipay.com/oceanbase/oceanbase-developer-center/pull_requests/423

Signed-off-by: 晓康 <[email protected]>


* Fixes oceanbase/odc#2308
  • Loading branch information
yezaoshu authored and 晓康 committed Apr 30, 2024
1 parent 0af25a3 commit 04f4042
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/component/Task/component/PartitionPolicyTable/ConfigTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import { IPartitionKeyConfig, PARTITION_KEY_INVOKER } from '@/d.ts';
import { Descriptions, Tooltip } from 'antd';
import React from 'react';
import styles from './index.less';
import { intervalPrecisionOptions } from '@/component/Task/component/PartitionPolicyFormTable/configModal';

const getFromCurrentTimeLabel = (fromCurrentTime: boolean, baseTimestampMillis: number) => {
const labels = [
Expand Down Expand Up @@ -54,6 +55,9 @@ const columns = [
render: (_, record) => {
const intervalGenerateExpr =
record?.partitionKeyInvokerParameters?.generateParameter?.intervalGenerateExpr;
const interval = record?.partitionKeyInvokerParameters?.generateParameter?.interval;
const intervalPrecision =
record?.partitionKeyInvokerParameters?.generateParameter?.intervalPrecision;
return (
<Descriptions className={styles.rules} column={1} size="small">
<Descriptions.Item
Expand Down Expand Up @@ -110,6 +114,18 @@ const columns = [
{intervalGenerateExpr}
</Descriptions.Item>
)}
{!!interval && (
<Descriptions.Item
label={
formatMessage({
id: 'src.component.Task.component.PartitionPolicyTable.D509725F',
}) /*"间隔"*/
}
>
{interval}
{intervalPrecisionOptions.find((i) => i.value === intervalPrecision)?.label}
</Descriptions.Item>
)}
</Descriptions>
);
},
Expand Down

0 comments on commit 04f4042

Please sign in to comment.