Exemple #1
0
        private void treeList1_DoubleClick(object sender, EventArgs e)
        {
            if (treeList1.FocusedNode == null)
            {
                return;
            }

            FrmEditProject fep = new FrmEditProject();

            fep.IsStuff  = true;
            fep.FlagId   = typeFlag2;
            fep.PowerUId = treeList1.FocusedNode["ID"].ToString();
            string   uid1 = treeList1.FocusedNode["ID"].ToString();
            LineInfo li   = Common.Services.BaseService.GetOneByKey <LineInfo>(treeList1.FocusedNode["Code"].ToString());

            if (li != null)
            {
                fep.IsLine = true;
            }
            substation li1 = Common.Services.BaseService.GetOneByKey <substation>(treeList1.FocusedNode["ID"].ToString());

            if (li1 != null)
            {
                fep.IsPower = true;
            }

            if (fep.ShowDialog() == DialogResult.OK)
            {
                LoadData();
                treeList1.ExpandAll();
                FoucsLocation(uid1, treeList1.Nodes);
            }
        }
Exemple #2
0
        private void barButtonItem5_ItemClick_1(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            FrmEditProject fep = new FrmEditProject();

            fep.FlagId   = typeFlag2;
            fep.PowerUId = treeList1.FocusedNode["ID"].ToString();
            LineInfo li = Common.Services.BaseService.GetOneByKey <LineInfo>(treeList1.FocusedNode["Code"].ToString());

            if (li != null)
            {
                fep.IsLine = true;
            }
            substation li1 = Common.Services.BaseService.GetOneByKey <substation>(treeList1.FocusedNode["ID"].ToString());

            if (li1 != null)
            {
                fep.IsPower = true;
            }
            if (fep.ShowDialog() == DialogResult.OK)
            {
                LoadData();
                treeList1.ExpandAll();
            }
        }
Exemple #3
0
 private void barButtonItem5_ItemClick_1(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
 {
     FrmEditProject fep = new FrmEditProject();
     fep.IsStuff = true;
     fep.FlagId = typeFlag2;
     fep.PowerUId = treeList1.FocusedNode["ID"].ToString();
     string uid1 = treeList1.FocusedNode["ID"].ToString();
     LineInfo li = Common.Services.BaseService.GetOneByKey<LineInfo>(treeList1.FocusedNode["Code"].ToString());
     if (li != null)
         fep.IsLine = true;
     substation li1 = Common.Services.BaseService.GetOneByKey<substation>(treeList1.FocusedNode["ID"].ToString());
     if (li1 != null)
         fep.IsPower = true;
     if (fep.ShowDialog() == DialogResult.OK)
     {
         LoadData();
         treeList1.ExpandAll();
         FoucsLocation(uid1, treeList1.Nodes);
     }
 }
Exemple #4
0
        private void treeList1_DoubleClick(object sender, EventArgs e)
        {
            if (treeList1.FocusedNode == null)
                return;

            FrmEditProject fep = new FrmEditProject();
            fep.FlagId = typeFlag2;
            fep.PowerUId = treeList1.FocusedNode["ID"].ToString();
            LineInfo li = Common.Services.BaseService.GetOneByKey<LineInfo>(treeList1.FocusedNode["Code"].ToString());
            if (li != null)
                fep.IsLine = true;
            substation li1 = Common.Services.BaseService.GetOneByKey<substation>(treeList1.FocusedNode["ID"].ToString());
            if (li1 != null)
                fep.IsPower = true;

            if (fep.ShowDialog() == DialogResult.OK)
            {
                LoadData();
                treeList1.ExpandAll();
            }
        }