Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Backport 2.x] Bug Fixes in Snapshot Policy: Schedule Editing and Index Expression Display #1208

Merged
merged 3 commits into from
Dec 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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 @@ -88,20 +88,20 @@ const CronSchedule = ({

function onDayOfWeekChange(dayOfWeek: string) {
setWeek(dayOfWeek);
// changeCron({ dayOfWeek });
changeCron({ dayOfWeek });
}

function onDayOfMonthChange(dayOfMonth: number) {
setMonth(dayOfMonth);
// changeCron({ dayOfMonth });
changeCron({ dayOfMonth });
}

function onStartTimeChange(date: moment.Moment) {
const minute = date.minute();
const hour = date.hour();
setMinute(minute);
setHour(hour);
// changeCron({ minute, hour });
changeCron({ minute, hour });
}

function onTypeChange(e: ChangeEvent<HTMLSelectElement>) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ export class CreateSnapshotPolicy extends MDSEnabledComponent<CreateSMPolicyProp
const selectedIndexOptions = [...this.state.selectedIndexOptions, newOption];
this.setState({
selectedIndexOptions: selectedIndexOptions,
policy: this.setPolicyHelper("snapshot_config.indices", selectedIndexOptions.toString()),
policy: this.setPolicyHelper("snapshot_config.indices", selectedIndexOptions.map((option) => option.label).join(", ")),
});
};

Expand Down
Loading