Skip to content

Commit

Permalink
[INLONG-10215][DashBoard] Add default value for file data source in d…
Browse files Browse the repository at this point in the history
…ata access module (#10216)

Co-authored-by: v_shuomqiu <v_shuomqiu@tencent>
  • Loading branch information
wohainilaodou and v_shuomqiu committed May 14, 2024
1 parent 3b6600b commit 974ef70
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion inlong-dashboard/src/plugins/sources/defaults/File.ts
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ export default class PulsarSource
@FieldDecorator({
type: 'inputnumber',
rules: [{ required: true }],
initialValue: 20,
props: values => ({
min: 1,
max: 100,
Expand All @@ -152,6 +153,7 @@ export default class PulsarSource

@FieldDecorator({
type: 'radio',
initialValue: 'H',
props: values => ({
disabled: Boolean(values.id),
options: [
Expand All @@ -177,9 +179,11 @@ export default class PulsarSource
@FieldDecorator({
type: 'input',
tooltip: i18n.t('meta.Sources.File.TimeOffsetHelp'),
initialValue: '0h',
rules: [
{
pattern: /[0-9][mhd]$/,
pattern: /-?[0-9][mhd]$/,
required: true,
message: i18n.t('meta.Sources.File.TimeOffsetRules'),
},
],
Expand Down

0 comments on commit 974ef70

Please sign in to comment.