Ejemplo n.º 1
0
 private void LokSubject_SearchFilterChanged(object sender, MyCommonWPFControls.SearchFilterArg e)
 {
     if (e.SingleFilterValue != null)
     {
         if (!e.FilerBySelectedValue)
         {
             var subjects = bizSecuritySubject.GetSecuritySubjects(e.SingleFilterValue);
             e.ResultItemsSource = subjects;
         }
         else
         {
             var id = Convert.ToInt32(e.SingleFilterValue);
             if (id > 0)
             {
                 var subject = bizSecuritySubject.GetSecuritySubject(id);
                 e.ResultItemsSource = new List <SecuritySubjectDTO> {
                     subject
                 };
             }
             else
             {
                 e.ResultItemsSource = null;
             }
         }
     }
 }
Ejemplo n.º 2
0
        public void SearchSecuritySubjects()
        {
            BizSecuritySubject bizSecuritySubject = new BizSecuritySubject();

            dtgItems.ItemsSource = bizSecuritySubject.GetSecuritySubjects(txtName.Text);
        }