Exemplo n.º 1
0
        public void BuildStatNavigation()
        {
            FirstFloor.ModernUI.Presentation.LinkGroup emailLinkGroup = new FirstFloor.ModernUI.Presentation.LinkGroup();
            FirstFloor.ModernUI.Presentation.Link hubLink = new FirstFloor.ModernUI.Presentation.Link();
            string hubLinkSource = "/Pages/Stats/StatsHub.xaml";

            emailLinkGroup.DisplayName = "stats";

            hubLink.DisplayName = "hub";
            hubLink.Source = new Uri(hubLinkSource, UriKind.Relative);
            emailLinkGroup.Links.Add(hubLink);

            this.MenuLinkGroups.Add(emailLinkGroup);
        }
Exemplo n.º 2
0
        private void Button_Click(object sender, RoutedEventArgs e)
        {
            string          ad       = txtkad.Text;
            string          sifre    = txtsifre.Password;
            MySqlConnection baglanti = new MySqlConnection("Server = localhost; Database = test; Uid = root; Pwd=;");

            baglanti.Open();

            MySqlCommand    girisyap = new MySqlCommand("SELECT * FROM uyelik where kullaniciad='" + txtkad.Text + "' and sifre='" + Convert.ToString(txtsifre.Password) + "'", baglanti);
            MySqlDataReader dr       = girisyap.ExecuteReader();


            if (dr.Read())
            {
                FirstFloor.ModernUI.Presentation.LinkGroup menuler = new FirstFloor.ModernUI.Presentation.LinkGroup();

                FirstFloor.ModernUI.Presentation.Link menuekle = new FirstFloor.ModernUI.Presentation.Link();
                FirstFloor.ModernUI.Presentation.Link ekle     = new FirstFloor.ModernUI.Presentation.Link();
                FirstFloor.ModernUI.Presentation.Link sil      = new FirstFloor.ModernUI.Presentation.Link();

                menuekle.DisplayName = "KİTAP KİRALAMA SAYFASI";
                ekle.DisplayName     = " KİTAP EKLEME SAYFASI";
                sil.DisplayName      = " KİTAP SİLME SAYFASI";


                menuekle.Source = new Uri("Pages/girissayfasi.xaml", UriKind.Relative);
                ekle.Source     = new Uri("Pages/kitapekle.xaml", UriKind.Relative);
                sil.Source      = new Uri("Pages/kitapsil.xaml", UriKind.Relative);

                menuler.Links.Add(menuekle);
                menuler.Links.Add(ekle);
                menuler.Links.Add(sil);

                MainWindow ab = Application.Current.MainWindow as MainWindow;
                ab.MenuLinkGroups.Clear();
                ab.MenuLinkGroups.Add(menuler);
            }
            else
            {
                MessageBox.Show("Kullanıcı adı veya şifre yanlış");
            }
        }
Exemplo n.º 3
0
        public void BuildEmailNavigation()
        {
            FirstFloor.ModernUI.Presentation.LinkGroup emailLinkGroup = new FirstFloor.ModernUI.Presentation.LinkGroup();
            FirstFloor.ModernUI.Presentation.Link hubLink = new FirstFloor.ModernUI.Presentation.Link();
            FirstFloor.ModernUI.Presentation.Link emailLocatorLink = new FirstFloor.ModernUI.Presentation.Link();
            string hubLinkSource = "/Pages/Email/Hub.xaml";
            string emailLocatorSource = "/Pages/Email/EmailLocator.xaml";

            emailLinkGroup.DisplayName = "email";

            hubLink.DisplayName = "hub";
            hubLink.Source = new Uri(hubLinkSource, UriKind.Relative);

            emailLocatorLink.DisplayName = "email locator";
            emailLocatorLink.Source = new Uri(emailLocatorSource, UriKind.Relative);

            emailLinkGroup.Links.Add(hubLink);
            emailLinkGroup.Links.Add(emailLocatorLink);

            this.MenuLinkGroups.Add(emailLinkGroup);
        }
Exemplo n.º 4
0
        private void kiralamasayfası_Click(object sender, RoutedEventArgs e)
        {
            FirstFloor.ModernUI.Presentation.LinkGroup menuler  = new FirstFloor.ModernUI.Presentation.LinkGroup();
            FirstFloor.ModernUI.Presentation.Link      menuekle = new FirstFloor.ModernUI.Presentation.Link();
            menuekle.DisplayName = "KİRALA ";
            menuekle.Source      = new Uri("Pages/kitapkirala.xaml", UriKind.Relative);
            menuler.Links.Add(menuekle);

            FirstFloor.ModernUI.Presentation.Link ekle = new FirstFloor.ModernUI.Presentation.Link();
            ekle.DisplayName = " KİTAP EKLE";
            ekle.Source      = new Uri("Pages/kitapekle.xaml", UriKind.Relative);
            menuler.Links.Add(ekle);

            FirstFloor.ModernUI.Presentation.Link sil = new FirstFloor.ModernUI.Presentation.Link();
            sil.DisplayName = " kitap SİL";
            sil.Source      = new Uri("Pages/kitapsil.xaml", UriKind.Relative);
            menuler.Links.Add(sil);

            MainWindow ab = Application.Current.MainWindow as MainWindow;

            ab.MenuLinkGroups.Clear();
            ab.MenuLinkGroups.Add(menuler);
        }