示例#1
0
        public List <wsBaseItem> ws_selectTreeItemsList(int?ID, out string OpStatus, out string Path)
        {
            try
            {
                DeviceDataManager DDM = new DeviceDataManager();

                OpStatus = Resources.Messages.m_OpStatusDone;
                Path     = DDM.selectDeviceParents(ID);
                return(DDM.selectItemsList(ID));
            }
            catch (Exception err)
            {
                OpStatus = err.Message.ToString();
                Path     = "";
                return(null);
            }
        }
示例#2
0
        public wsPassportExtended ws_selectPassport_EX(int?ID, out string OpStatus)
        {
            try
            {
                wsPassportExtended  P_EX = new wsPassportExtended();
                CatalogsDataManager CDM  = new CatalogsDataManager();
                DeviceDataManager   DDM  = new DeviceDataManager();
                if (ID != null)
                {
                    P_EX              = DDM.selectPasport((int)ID);
                    P_EX.DevPath      = DDM.selectDeviceParents(P_EX.DevTypeID);
                    P_EX.DevPlacePath = DDM.selectPlaceParents(P_EX.DevPlaceID);
                }

                P_EX.list_Producers = CDM.GetProducerList();

                DBTree DBT = new DBTree(2); // 2 = models tree
                //wsNode NNODE = new wsNode(DBTREE.GetAnyNodeinDB);

                P_EX.tbl_Models = DBT.DBDATA;

                List <string>     s     = new List <string>();
                List <wsBaseItem> blist = new List <wsBaseItem>();
                blist = DDM.selectItemsList(null);
                foreach (wsBaseItem b in blist)
                {
                    s.Add(b.Description);
                }

                P_EX.helper_DevDescr = s;

                OpStatus = Resources.Messages.m_OpStatusDone;
                return(P_EX);
            }
            catch (Exception err)
            {
                OpStatus = err.ToString();
                return(null);
            }
        }
示例#3
0
        public List <string> ws_selectDevDescrList(out string OpStatus)
        {
            try
            {
                List <string>     s     = new List <string>();
                List <wsBaseItem> blist = new List <wsBaseItem>();
                DeviceDataManager DDM   = new DeviceDataManager();
                blist = DDM.selectItemsList(null);
                foreach (wsBaseItem b in blist)
                {
                    s.Add(b.Description);
                }

                OpStatus = Resources.Messages.m_OpStatusDone;
                return(s);
            }
            catch (Exception err)
            {
                OpStatus = err.Message.ToString();
                return(null);
            }
        }
示例#4
0
        public wsPassportExtended ws_selectPassport_EX(int? ID, out string OpStatus)
        {
            try
            {
                wsPassportExtended P_EX = new wsPassportExtended();
                CatalogsDataManager CDM = new CatalogsDataManager();
                DeviceDataManager DDM = new DeviceDataManager();
                if (ID != null)
                {
                    P_EX = DDM.selectPasport((int)ID);
                    P_EX.DevPath = DDM.selectDeviceParents(P_EX.DevTypeID);
                    P_EX.DevPlacePath = DDM.selectPlaceParents(P_EX.DevPlaceID);
                }

                P_EX.list_Producers = CDM.GetProducerList();

                DBTree DBT = new DBTree(2); // 2 = models tree        
                //wsNode NNODE = new wsNode(DBTREE.GetAnyNodeinDB);
               
                P_EX.tbl_Models = DBT.DBDATA;

                List<string> s = new List<string>();
                List<wsBaseItem> blist = new List<wsBaseItem>();
                blist = DDM.selectItemsList(null);
                foreach (wsBaseItem b in blist)
                {
                    s.Add(b.Description);
                }

                P_EX.helper_DevDescr = s;

                OpStatus = Resources.Messages.m_OpStatusDone;
                return P_EX;
            }
            catch (Exception err)
            {
                OpStatus = err.ToString();
                return null;
            }
        }
示例#5
0
        public List<string> ws_selectDevDescrList(out string OpStatus)
        {
            try
            {
                List<string> s = new List<string>();
                List<wsBaseItem> blist = new List<wsBaseItem>();
                DeviceDataManager DDM = new DeviceDataManager();             
                blist = DDM.selectItemsList(null);
                foreach (wsBaseItem b in blist)
                {
                    s.Add(b.Description);
                }

                OpStatus = Resources.Messages.m_OpStatusDone;
                return s;
            }
            catch (Exception err)
            {
                OpStatus = err.Message.ToString();
                return null;
            }
        }
示例#6
0
        public List<wsBaseItem> ws_selectTreeItemsList(int? ID, out string OpStatus, out string Path)
        {
            try
            {
                DeviceDataManager DDM = new DeviceDataManager();

                OpStatus = Resources.Messages.m_OpStatusDone;
                Path = DDM.selectDeviceParents(ID);
                return DDM.selectItemsList(ID);
            }
            catch (Exception err)
            {
                OpStatus = err.Message.ToString();
                Path = "";
                return null;
            }
        }