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

Fix conditions for trigger validation #420

Merged
merged 4 commits into from
Sep 6, 2023

Conversation

Tetrergeru
Copy link
Member

No description provided.

@Tetrergeru Tetrergeru requested a review from a team as a code owner September 1, 2023 13:58
@@ -87,7 +89,7 @@ const TriggerAddContainer = (props: Props) => {
setTrigger({ ...trigger, ...update });
dispatch(setError(null));

if (update.is_remote) {
if (update?.trigger_source === TriggerSource.GRAPHITE_LOCAL) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if (update?.trigger_source === TriggerSource.GRAPHITE_LOCAL) {
if (update?.trigger_source) {

Здесь смысл в том, что если мы переключаем источник на любой другой, кнопка сохранения разблокируется. Поэтому сравнивать не надо, просто смотрим, менялось ли поле trigger_source

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Починил

@Tetrergeru
Copy link
Member Author

/build

@github-actions
Copy link

github-actions bot commented Sep 5, 2023

Build and push Docker images with tag: 2023-09-06.a8b050e

sol-un added 2 commits September 6, 2023 12:53
- fix ternary expression in TriggerEditContainer
- reset target validation state on switch data source
…nto fix/validate-on-metric-source

# Conflicts:
#	src/Containers/TriggerAddContainer.tsx
@Tetrergeru Tetrergeru merged commit a8b050e into master Sep 6, 2023
1 check passed
@Tetrergeru Tetrergeru deleted the fix/validate-on-metric-source branch September 6, 2023 12:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants