Example #1
0
 private void xapFormControl1_RefFilter(object sender, xap.rui.control.refcontrol.events.RefActivatingEventArgs e)
 {
     if (e.BindingFieldName.Equals("No_pathgy_old"))
     {
         e.WherePart = string.Format(" B.id_pat='{0}' and A.no_pathgy is not null", this.GetViewModel().GetEnt4BannerDTO().Id_pat);
     }
 }
Example #2
0
        void xapFormControl1_RefFilter(object sender, xap.rui.control.refcontrol.events.RefActivatingEventArgs e)
        {
            string fieldName = e.BindingFieldName;

            if ("Name_dep_nur_to".Equals(fieldName))
            {
                string id_dep = this.EmsHeadDO.Emsaptrans.Id_dep_to;
                if (id_dep == null)
                {
                    e.WherePart = "1=1";
                    return;
                }
                string nurids = model.getNurAreaOfDep(id_dep);
                if (nurids == null || nurids == "")
                {
                    e.Cancel = true;
                }
                e.WherePart = string.Format("id_dep in ({0}) and sd_depttp like '02%'", nurids);
            }
            if ("Name_dep_to".Equals(fieldName))
            {
                string id_dep = this.EmsHeadDO.Emsaptrans.Id_dep_from;
                if (id_dep == null)
                {
                    return;
                }
                e.WherePart = string.Format("id_dep <> '{0}' and sd_depttp like '01%'", id_dep);
            }
        }
Example #3
0
 private void XapFormControl_RefFilter(object sender, xap.rui.control.refcontrol.events.RefActivatingEventArgs e)
 {
     if (e.BindingFieldName.Equals("Name_dep") && !string.IsNullOrWhiteSpace(idWfdeps))
     {
         e.WherePart = string.Format("id_dep in ({0})", idWfdeps);
     }
 }