//Hakkımızda Ekleme-Post public ActionResult Aboutadd(about about, int type) { if (online() == false) { return(RedirectToAction("Login", "Security")); } try { string s = ""; if (type == 1) { about.aboutType = true; s = "Misyon Eklendi"; } else { about.aboutType = false; s = "Vizyon Eklendi"; } db.abouts.Add(about); db.SaveChanges(); var usr = db.abouts.Where(x => x.abouts == about.abouts && x.aboutType == about.aboutType).FirstOrDefault(); process(usr.aboutId, "About", s); return(RedirectToAction("About", "Admin")); } catch (Exception ex) { return(RedirectToAction("Error", "Home", new { ex = ex })); } }
//none #else void App_CommandsRequested(SettingsPane sender, SettingsPaneCommandsRequestedEventArgs args) { // Add an About command var about = new SettingsCommand("About", "About", (handler) => { about flyout = new about(); flyout.Title = "About"; flyout.Show(); //var settings = new SettingsFlyout(); //settings.Content = new about(); //settings.HeaderBrush = new SolidColorBrush(_background); //settings.Background = new SolidColorBrush(_background); //settings.HeaderText = "About"; //settings.IsOpen = true; }); args.Request.ApplicationCommands.Add(about); // add a Privacy and policy command var privacy = new SettingsCommand("Privacy Policy", "Privacy Policy", (handler) => { var uri = new Uri("//your link of privacy and policy"); //hena hn7oot el elink ely feh el Privacy policy IAsyncOperation <bool> x = Windows.System.Launcher.LaunchUriAsync(uri); }); args.Request.ApplicationCommands.Add(privacy); }
private void aboutUsToolStripMenuItem_Click(object sender, EventArgs e) { about add = new about(); add.MdiParent = this; add.Visible = true; add.Show(); }
private void button1_Click(object sender, EventArgs e) { this.Hide(); about about = new about(); about.ShowDialog(); this.Show(); }
private void 关于ToolStripMenuItem_Click(object sender, EventArgs e) { if (about == null || about.IsDisposed == true) { about = new about(); } //this.Hide();//隐藏现在这个窗口 about.Show();//新窗口显现 about.Activate(); }
public ActionResult Edit(about updateAbout) { var updated = new AboutsModel().updateAboutById(updateAbout.id, updateAbout); if (updated) { return(RedirectToAction("Index", "About")); } return(View()); }
//Hakkımızda Güncelleme-Post public ActionResult Aboutupdate(about ab, int type) { if (online() == false) { return(RedirectToAction("Login", "Security")); } var a = db.abouts.FirstOrDefault(x => x.aboutId == ab.aboutId); a.abouts = ab.abouts; db.SaveChanges(); process(a.aboutId, "About", "Güncellendi"); return(RedirectToAction("About", "Admin")); }
public ActionResult Create(about newAbout) { newAbout.content = newAbout.content; newAbout.start_time = DateTime.Now; newAbout.status = false; var created = new AboutsModel().createAbout(newAbout); if (created) { return(RedirectToAction("Index", "About")); } return(View()); }
public ActionResult Edit(about gioithieu) { if (ModelState.IsValid) { var dao = new GioiThieuDao(); var result = dao.Update(gioithieu); if (result) { return(RedirectToAction("Index", "GioiThieu")); } else { ModelState.AddModelError("", "Cập nhật không thành công"); } } return(View("Index")); }
public ActionResult Create(about gioithieu) // Tạo tài khoản { if (ModelState.IsValid) { var dao = new GioiThieuDao(); long id = dao.Insert(gioithieu); if (id > 0) { return(RedirectToAction("Index", "GioiThieu")); } else { ModelState.AddModelError("", "Thêm không thành công"); } } return(View("Index")); }
public bool Update(about entity) { try { var about = db.abouts.Find(entity.ID); //Bổ sung update about.Images = entity.Images; about.MetaTitle = entity.MetaTitle; about.Mota = entity.Mota; about.Ten = entity.Ten; about.Trangthai = entity.Trangthai; db.SaveChanges(); return(true); } catch (Exception ex) { return(false); } }
private void ToolStripMenuItemAbout_Click(object sender, EventArgs e) { about m_objabout = new about(); m_objabout.ShowDialog(); }
private void aToolStripMenuItem_Click(object sender, EventArgs e) { about sobre = new about(); sobre.Show(); }
public long Insert(about entity) { db.abouts.Add(entity); db.SaveChanges(); return(entity.ID); }
/* * MENU ITEMS */ private void menuItem_about(object sender, RoutedEventArgs e) { about aboutWin = new about(); aboutWin.Show(); }
private void toolstrip_about_click(object o, EventArgs e) { using (about about = new about()) about.ShowDialog(); }
private void aboutToolStripMenuItem_Click(object sender, EventArgs e) { about about_win = new about(); about_win.ShowDialog(); }
private void pictureBox8_Click(object sender, EventArgs e) { panel2.Location = new Point(0, -50); form3 = new about(); form3.ShowDialog(); }
private void button3_Click(object sender, EventArgs e) { Form about = new about(); about.Show(); }
private void button1_Click(object sender, EventArgs e) { about ab = new about(); ab.Show(); }
void about(object sender, EventArgs e) { about frm = new about(); frm.ShowDialog(this); }
private void button1_Click(object sender, EventArgs e) { about frm = new about(); frm.ShowDialog(); }
//四、帮助 private void 帮助ToolStripMenuItem_Click(object sender, EventArgs e) { about about = new about(); about.Show(); }