private void AddRule(SimpleWizardRule rule)
{
rule.ID = Guid.NewGuid().ToString();
rule.Owner = m_owner;
rule.DialPlanID = m_dialPlan.ID;
m_riaContext.SimpleWizardRules.Add(rule);
if (rule.Direction == SIPCallDirection.Out.ToString())
{
m_outgoingRulesUpdateControl.SetStatusMessage("Saving...", true);
}
else
{
m_incomingRulesUpdateControl.SetStatusMessage("Saving...", true);
}
m_riaContext.SubmitChanges(AddRuleComplete, rule);
}