//פונקציה לבדיקה האם הלקוח שמור במערכת
 public static bool CheckIfExist(clientsEntity c)
 {
     if (connectDB.entity.clientsTBL.FirstOrDefault(x => x.user_name == c.user_name && x.client_password == c.client_password) == null)
     {
         return(false);
     }
     return(true);
 }
        //פונקצית הוספת לקוח
        public static bool AddClient(clientsEntity c)
        {
            if (CheckIfExist(c) == false)//במקרה שהלקוח לא קיים ואכן מדובר בלקוח חדש
            {
                connectDB.entity.clientsTBL.Add(clientsEntity.ConvertEntityToDB(c));
                connectDB.entity.SaveChanges();
                var l_clients = connectDB.entity.clientsTBL;

                return(true);
            }
            return(false);
        }
 public bool CheckIfExist([FromBody] clientsEntity c)
 {
     return(ClientsBL.CheckIfExist(c));
 }
 public bool AddClient([FromBody] clientsEntity c)
 {
     return(ClientsBL.AddClient(c));
 }