Example #1
0
        private ListPengguna()
        {
            InitializeComponent();
            penggunaService = new PenggunaService();

            dataGridViewPengguna.DataSource         = penggunaService.FindWithRole();
            dataGridViewPengguna.Columns[0].Visible = false;
        }
Example #2
0
        public LoginAndWelcome()
        {
            InitializeComponent();
            penggunaService    = new PenggunaService();
            this.ActiveControl = this.textBoxUsername;

            progressBar.Style = ProgressBarStyle.Marquee;
            progressBar.MarqueeAnimationSpeed = 50;
        }
Example #3
0
        public UbahPengguna()
        {
            InitializeComponent();
            this.ActiveControl = this.textBoxNamaPengguna;
            penggunaService    = new PenggunaService();
            roleService        = new RoleService();

            comboBoxRole.DataSource    = roleService.Get();
            comboBoxRole.ValueMember   = "Id";
            comboBoxRole.DisplayMember = "NamaRole";
        }
Example #4
0
        private async void BtnLogin_Clicked(object sender, EventArgs e)
        {
            PenggunaService penggunaService = new PenggunaService();
            Pengguna        objPengguna     = new Pengguna
            {
                Username = entryUsername.Text,
                Password = entryPassword.Text
            };

            Pengguna result = await penggunaService.GetLogin(objPengguna);

            if (result != null)
            {
                Application.Current.Properties["profil"] = result;
                //await DisplayAlert("Keterangan", "Berhasil Login", "OK");
                await Navigation.PushAsync(new COISummaryPage());
            }
            else
            {
                await DisplayAlert("Keterangan", "Gagal Melakukan Login", "OK");
            }
        }