Ejemplo n.º 1
0
 public ProfilSettings(SellerHomePage sellerHomePage, ISellerService sellerService, SellerInformationResponse seller)
 {
     InitializeComponent();
     this.sellerHomePage = sellerHomePage;
     this.sellerService  = sellerService;
     this.seller         = seller;
 }
Ejemplo n.º 2
0
        private void SellerLogIn_Click(object sender, EventArgs e)
        {
            try
            {
                if (!(sellerEmail.Text.Contains("@") && sellerEmail.Text.Contains(".com")))
                {
                    MessageBox.Show("Please,enter a correct email", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                }
                else
                {
                    if (sellerPassword.Text == "")
                    {
                        MessageBox.Show("Please,enter a correct password", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                    }
                    else
                    {
                        if (sellerService.LogIn(new Contracts.Request.Seller.SellerLogInRequest(sellerEmail.Text, sellerPassword.Text)))
                        {
                            ShowAutoClosingMessageBox("Log In successfull! ", "Successfull");

                            SellerHomePage sellerHomePage = new SellerHomePage(this, sellerEmail.Text, sellerPassword.Text);
                            clear();
                            this.Hide();
                            sellerHomePage.Show();
                        }
                        else
                        {
                            MessageBox.Show("Incorrect email or password", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                        }
                    }
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
Ejemplo n.º 3
0
 public ProductSettingScreen(SellerHomePage sellerHomePage, SellerInformationResponse seller)
 {
     InitializeComponent();
     this.sellerHomePage = sellerHomePage;
     this.seller         = seller;
 }
Ejemplo n.º 4
0
 public PastOperations(SellerHomePage sellerHomePage, SellerInformationResponse seller)
 {
     InitializeComponent();
     this.sellerHomePage = sellerHomePage;
     this.seller         = seller;
 }