Ejemplo n.º 1
0
        public void AddCategoryFliter(CategoryFliter CategoryFliter)
        {
            try
            {
                object maxOrder = DataCollection.CategoryFliterInstance.GetFeildValue("max(order)", new Equal(MYDBLogic.AND, "cId", CategoryFliter.cId.ToString()));
                CategoryFliter.order = maxOrder != null?Convert.ToInt32(maxOrder) + 1 : 1;

                DataCollection.CategoryFliterInstance.Insert(CategoryFliter);
            }
            catch (Exception)
            {
                throw;
            }
        }
Ejemplo n.º 2
0
 public void ChangeOrder(CategoryFliter categoryFliter1, CategoryFliter categoryFliter2)
 {
     try
     {
         int tmp = categoryFliter1.order;
         categoryFliter1.order = categoryFliter2.order;
         categoryFliter2.order = tmp;
         DataCollection.CategoryFliterInstance.Update(categoryFliter1);
         DataCollection.CategoryFliterInstance.Update(categoryFliter2);
     }
     catch (Exception)
     {
         throw;
     }
 }
Ejemplo n.º 3
0
 public void RemoveCategoryFliter(CategoryFliter CategoryFliter)
 {
     DataCollection.CategoryFliterInstance.Remove(CategoryFliter);
 }
Ejemplo n.º 4
0
 public void ModifyCategoryFliter(CategoryFliter CategoryFliter)
 {
     DataCollection.CategoryFliterInstance.Update(CategoryFliter);
 }