Esempio n. 1
0
        public bool isUserDataCorrect(string login, string password)
        {
            bool   isDataCorrect = false;
            string _password     = String.Empty;

            try
            {
                using (var reader = doQuery.Start(SqlQueries.PasswordByLogin(login)))
                    _password = reader.GetString(0);
            }
            catch (Exception err)
            {
                System.Windows.Forms.MessageBox.Show(err.Message);
                return(isDataCorrect);
            }

            if (_password == password)
            {
                isDataCorrect = true;
            }

            return(isDataCorrect);
        }
Esempio n. 2
0
 public long NewOutputInvoiceNumber()
 {
     using (var reader = doQuery.Start(SqlQueries.OutputInvoiceNumber()))
         return(reader.GetLong(0));
 }
Esempio n. 3
0
 public void AddClient(string Name, string PhoneNumber, decimal Discount, string ExtraData)
 {
     doQuery.Start(SqlQueries.AddProduct(Name, PhoneNumber, Discount, ExtraData));
 }