Example #1
0
        internal static EDVMyFittings CommonNavigateMarketGroup(int id, int selFitId, string selFitName, string userName)
        {
            EDVMyFittings   edv;
            EDVFittingsList edvFitlist;

            AgenteFittings agente = new AgenteFittings();
            IEnumerable <ShipMarketGroup> marketItems = agente.SelectMarketGroupsByParentID(id, userName);
            IList <invMarketGroup>        marketChain = agente.GetParentGroupsChainForShips(id);

            invMarketGroup groupActual = marketChain.Last();

            marketChain.Remove(groupActual);

            edv                        = new EDVMyFittings();
            edv.MarketItems            = marketItems;
            edv.MarketChain            = marketChain;
            edv.GroupName              = groupActual.marketGroupName;
            edv.ContextSelectedFitID   = selFitId;
            edv.ContextSelectedFitName = selFitName;
            edvFitlist                 = new EDVFittingsList();
            edv.Fittings               = edvFitlist;
            edvFitlist.Fittings        = agente.SelectFitsByMarketGroup(userName, groupActual.marketGroupID);

            return(edv);
        }
Example #2
0
        internal static EDVMyFittings GetEDVMyFittingsByUser(string userName)
        {
            EDVMyFittings  edv    = new EDVMyFittings();
            AgenteFittings agente = new AgenteFittings();
            IEnumerable <ShipMarketGroup> marketItems = agente.SelectMarketGroupsByParentID(4, userName);

            edv.MarketItems = marketItems;
            EDVFittingsList edvFitList = new EDVFittingsList();

            edvFitList.Fittings = new List <EVFitting>();
            edv.Fittings        = edvFitList;
            return(edv);
        }