Ejemplo n.º 1
0
        internal static void UpdateCustomer()
        {
            var customerMobileNumber = UserInterfaceSetupFunctions.GetMobileNumber();
            var customerEmail        = UserInterfaceSetupFunctions.GetCustomerEmail();
            int updateCount          = DBInterface.UpdateCustomer(customerMobileNumber, customerEmail);

            if (updateCount == 0)
            {
                Console.WriteLine("Update Customer Not Successful");
            }
            else
            {
                Console.WriteLine("Updated Customer successfully");
            }
        }
Ejemplo n.º 2
0
        internal static void AddCustomer()
        {
            var customerMobileNumber = UserInterfaceSetupFunctions.GetMobileNumber();
            var customerName         = UserInterfaceSetupFunctions.GetCustomerName();
            var customerEmail        = UserInterfaceSetupFunctions.GetCustomerEmail();
            var employeeId           = UserInterfaceSetupFunctions.GetEmployeeId();
            var customerIdentity     = UserInterfaceSetupFunctions.GetCustomerIdentity();
            int insertCount          = DBInterface.AddCutomer(customerMobileNumber, customerName, customerEmail,
                                                              employeeId, customerIdentity);

            if (insertCount > 0)
            {
                Console.WriteLine("Inserted Customer Successfully");
            }
        }