// GET api/stockcard
        public IEnumerable<StockCard> Get()
        {
            string[] queryStrings = this.Request.RequestUri.Query.Remove(0, 1).Split('&');
            int tenantId = int.Parse(queryStrings[0].Split('=')[1]);
            string groupCode = queryStrings[1].Split('=')[1];

            List<StockCard> result = new StockCardRepository().FindByGroup(tenantId, groupCode);
            result.Sort(new StockCardAscOrder());
            return result;
        }
        // GET api/stockcardmovement
        public IEnumerable<StockcardMovement> Get()
        {
            string[] queryStrings = this.Request.RequestUri.Query.Remove(0, 1).Split('&');
            int tenantId = int.Parse(queryStrings[0].Split('=')[1]);
            string productId = queryStrings[1].Split('=')[1];

            StockCard sc = new StockCardRepository().FindByProductId(tenantId, productId);
            List<StockcardMovement> scMovement = new StockcardMovementRepository().FindByProductId(tenantId, productId, sc.Period);
            CalculateRuningTotal(sc, scMovement);

            return scMovement;
        }