Exemplo n.º 1
0
        public int Login()
        {
            List <Customer> calledlist = customerhandler.GetList();
            //Console.WriteLine(calledlist[0]);
            Program program = new Program();

            Console.WriteLine("Enter the Username and Password");
            string username = Console.ReadLine();
            string password = Console.ReadLine();
            int    count    = 0;

            //foreach (Customer c in calledlist)
            //{
            //    Console.WriteLine("Login Succesfull\n");
            //    count = 1;
            if ((username == "mail") && (password == "1329"))
            {
                count = 2;
                Console.WriteLine("Login Succesfull\n");
            }
            if (count != 2)
            {
                Console.WriteLine("Invalid Credentials");
            }
            //}
            //if (count == 1)
            //{
            //    Console.WriteLine("No User Found");
            //}
            return(count);
        }
Exemplo n.º 2
0
 public async Task <ActionResult> Paging(CustomerFindDTO findDTO)
 {
     return(PartialView(await handler.GetList(findDTO)));
 }