Пример #1
0
        public static Boolean checkIfInsertedProductTypeIDValid(int ID)
        {
            ProductType pt = ProductTypeRepo.get(ID);

            if (pt == null)
            {
                return(false);
            }
            else
            {
                return(true);
            }
        }
Пример #2
0
        public static Boolean checkIfProductTypeIDValid(int ID)
        {
            ProductType pt      = ProductTypeRepo.get(ID);
            Product     product = ProductRepo.getByProductTypeID(ID);

            if (pt == null || product != null)
            {
                return(false);
            }
            else
            {
                return(true);
            }
        }
Пример #3
0
 public static ProductType get(int ID)
 {
     return(ProductTypeRepo.get(ID));
 }
Пример #4
0
 public static void remove(int ID)
 {
     ProductTypeRepo.remove(ProductTypeRepo.get(ID));
 }