Exemplo n.º 1
0
        public FrmMain()
        {
            InitializeComponent();
            string document_path  = Application.StartupPath + "/renthouse.txt";
            string document_path2 = Application.StartupPath + "/salehouse.txt";

            rentHouseOperations = new TDRentHouseDal(document_path);
            saleHouseOperations = new TDSaleHouseDal(document_path2);

            DataGridViewButtonColumn btn = new DataGridViewButtonColumn();

            dgvRentHouses.Columns.Add(btn);
            btn.HeaderText = "Resimler";
            btn.Text       = "Resimler";
            btn.UseColumnTextForButtonValue = true;
            DataGridViewButtonColumn btn1 = new DataGridViewButtonColumn();

            dgvSaleHouses.Columns.Add(btn1);
            btn1.HeaderText = "Resimler";
            btn1.Text       = "Resimler";
            btn1.UseColumnTextForButtonValue = true;

            var singletonUser = SingletonUser.CreateAsSingleton();

            lblUser.Text = singletonUser.ReadUsername();
        }
Exemplo n.º 2
0
 public dotSettingsModel(SingletonUser s, IDotService d, IRideService r, IUserService u)
 {
     User     = s;
     dService = d;
     rService = r;
     uService = u;
 }
Exemplo n.º 3
0
        private void btnLogin_Click(object sender, EventArgs e)
        {
            if (txtUsername.Text.Length > 0 && txtPassword.Text.Length > 0)
            {
                User user   = new User(txtUsername.Text, txtPassword.Text);
                bool status = userOperations.Login(user);
                if (status == true)
                {
                    var singletonUser = SingletonUser.CreateAsSingleton();
                    singletonUser.WriteUsername(txtUsername.Text);

                    FrmMain frmMain = new FrmMain();
                    frmMain.Show();
                    this.Hide();
                }
                else
                {
                    MessageBox.Show("Kullanıcı Adı Veya Şifre Hatalı.");
                }
            }
            else
            {
                MessageBox.Show("Lütfen Gerekli Alanları Doldurunuz.");
            }
        }
Exemplo n.º 4
0
 //[BindProperty]
 //public List<Dot> Dots { get; set; }
 public MapViewModel(SingletonUser s, IDotService d, JsonDotService j)
 {
     User     = s;
     dService = d;
     //Dots = d.GetAllDots();
     jSon = j;
     jSon.UpdateJson();
 }
Exemplo n.º 5
0
 public ProfileModel(SingletonUser s, IUserService i)
 {
     User    = s;
     service = i;
 }
Exemplo n.º 6
0
 public RegisterModel(IUserService i, SingletonUser u)
 {
     service = i;
     User    = u;
 }
Exemplo n.º 7
0
 public IndexModel(ILogger <IndexModel> logger, SingletonUser s)
 {
     _logger = logger;
     User    = s;
 }
Exemplo n.º 8
0
 public LoginModel(IUserService s, SingletonUser su)
 {
     service = s;
     User    = su;
 }
Exemplo n.º 9
0
 public LogoutModel(SingletonUser s)
 {
     User = s;
 }