Пример #1
0
        /// <summary>
        ///     Sorts the ProductVariations VariantId by toggling Tab3VariantIdsOrder int
        /// </summary>
        public void SortTab3VariantIds()
        {
            List <KeyValuePair <string, string> > SortedList = new List <KeyValuePair <string, string> >();

            if (Tab3VariantIdsOrder == 0)
            {
                SortedList          = ProductVariations.OrderByDescending(o => o.Key).ToList();
                Tab3VariantIdsOrder = 1;
            }
            else
            {
                SortedList          = ProductVariations.OrderBy(o => o.Key).ToList();
                Tab3VariantIdsOrder = 0;
            }
            this.ProductVariations = SortedList;
        }