Adding data versioning capabilities which content parts may opt-into. Still needs query support though.

--HG--
extra : convert_revision : svn%3A5ff7c347-ad56-4c35-b696-ccb81de16e03/trunk%4044752
This commit is contained in:
loudej
2009-12-30 00:36:35 +00:00
parent 8051ac212a
commit 556ab3c99f
52 changed files with 1683 additions and 2008 deletions

View File

@@ -5,7 +5,6 @@ using Orchard.Localization;
using Orchard.ContentManagement;
using Orchard.Settings;
using Orchard.UI.Notify;
using Orchard.ContentManagement.Handlers;
namespace Orchard.Core.Settings.Controllers {
[ValidateInput(false)]
@@ -24,18 +23,19 @@ namespace Orchard.Core.Settings.Controllers {
public Localizer T { get; set; }
public ActionResult Index(string tabName) {
var model = new Orchard.Core.Settings.ViewModels.SettingsIndexViewModel {
Site = _siteService.GetSiteSettings().As<SiteSettings>() };
var model = new Orchard.Core.Settings.ViewModels.SettingsIndexViewModel {
Site = _siteService.GetSiteSettings().As<SiteSettings>()
};
model.EditorModel = _modelManager.BuildEditorModel(model.Site);
return View(model);
}
[AcceptVerbs(HttpVerbs.Post)]
public ActionResult Index(string tabName, FormCollection input) {
[HttpPost, ActionName("Index")]
public ActionResult IndexPOST(string tabName) {
var viewModel = new SettingsIndexViewModel { Site = _siteService.GetSiteSettings().As<SiteSettings>() };
viewModel.EditorModel = _modelManager.UpdateEditorModel(viewModel.Site.ContentItem, this);
if (!TryUpdateModel(viewModel, input.ToValueProvider())) {
if (!TryUpdateModel(viewModel)) {
return View(viewModel);
}