Skip to content
This repository has been archived by the owner on Sep 15, 2022. It is now read-only.

Commit

Permalink
Ensure the user enters a trigger body if creating an edb-spl trigger.
Browse files Browse the repository at this point in the history
git-svn-id: svn://svn.pgadmin.org/trunk@7820 a7884b65-44f6-0310-8a51-81a127f17b15
  • Loading branch information
dpage committed Apr 24, 2009
1 parent ec6d4cd commit 3e79188
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pgadmin/dlg/dlgTrigger.cpp
Expand Up @@ -289,9 +289,13 @@ void dlgTrigger::CheckChange()

CheckValid(enable, !name.IsEmpty(), _("Please specify name."));
CheckValid(enable, !function.IsEmpty(), _("Please specify trigger function."));

CheckValid(enable, chkInsert->GetValue() || chkUpdate->GetValue() ||chkDelete->GetValue() ||chkTruncate->GetValue(),
_("Please specify at least one action."));

if (cbFunction->GetValue() == wxString::Format(wxT("<%s>"), _("Inline EDB-SPL")))
CheckValid(enable, !txtBody->GetText().IsEmpty(), _("Please specify trigger body."));

if (trigger)
{
EnableOK(enable &&
Expand Down

0 comments on commit 3e79188

Please sign in to comment.