Ejemplo n.º 1
0
        //  MainTabBlockSubitem



        private static void SetupBlockAndBlockSubitem(SqlConnection conn)
        {
            List <PdmBlockClrDto>        blockList        = PdmBlockDal.GetAllList(conn);
            List <PdmBlockSubItemClrDto> blockSubitemList = PdmBlockSubItemDal.GetAllList(conn);

            foreach (PdmBlockClrDto aPdmBlockClrDto in blockList)
            {
                DictBlockCache.Add(aPdmBlockClrDto.BlockId, aPdmBlockClrDto);
                aPdmBlockClrDto.PdmBlockSubItemList = blockSubitemList.Where(o => o.BlockId == aPdmBlockClrDto.BlockId).ToList();

                //aPdmBlockClrDto
            }

            foreach (PdmBlockSubItemClrDto aPdmBlockSubItemClrDto in blockSubitemList)
            {
                DictBlockSubItemCache.Add(aPdmBlockSubItemClrDto.SubItemId, aPdmBlockSubItemClrDto);
            }

            foreach (PdmBlockSubItemClrDto aPdmBlockSubItemClrDto in blockSubitemList)
            {
                if (!string.IsNullOrEmpty(aPdmBlockSubItemClrDto.InternalCode))
                {
                    DictInternalCodeBlockSubItemCache[aPdmBlockSubItemClrDto.InternalCode] = aPdmBlockSubItemClrDto;
                }
                // DictBlockSubItemCache.Add(aPdmBlockSubItemClrDto.SubItemId, aPdmBlockSubItemClrDto);
            }
        }
Ejemplo n.º 2
0
        //  MainTabBlockSubitem



        private static void SetupBlockAndBlockSubitem(SqlConnection conn)
        {
            List <PdmBlockClrDto>        blockList        = PdmBlockDal.GetAllList(conn);
            List <PdmBlockSubItemClrDto> blockSubitemList = PdmBlockSubItemDal.GetAllList(conn);

            foreach (PdmBlockClrDto aPdmBlockClrDto in blockList)
            {
                DictBlockCache.Add(aPdmBlockClrDto.BlockId, aPdmBlockClrDto);
                aPdmBlockClrDto.PdmBlockSubItemList = blockSubitemList.Where(o => o.BlockId == aPdmBlockClrDto.BlockId).ToList();

                //aPdmBlockClrDto
            }

            foreach (PdmBlockSubItemClrDto aPdmBlockSubItemClrDto in blockSubitemList)
            {
                DictBlockSubItemCache.Add(aPdmBlockSubItemClrDto.SubItemId, aPdmBlockSubItemClrDto);
            }
        }