-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ContentVersion cleanup backoffice UI (#11637)
* init rollback ui prototype * add busy state to button, deselect version, add pagination status * add localisation * style current version * disable rollback button when nothing is selected * stop click event * Endpoints for paginated content versions. Light on tests, tight on time. * Endpoints to "pin" content versions * camel case json output. Not sure why json formatter not set for controller, bit risky to add it now * wire up paging * wire up pin/unpin * rename getPagedRollbackVersions to getPagedContentVersions * prevent selection of current version and current draft * add current draft and current version to UI * remove pointer if the row is not selectable * Improve warning for globally disabled cleanup feature. * Fix current loses prevent cleanup state on publish. * Added umbracoLog audit entries for "pin" / "unpin" * Match v9 defaults for keepVersions settings * Fix - losing preventCleanup on save current with content changes * update pin/unpin button labels * fix pagination bug * add missing " * always send culture when a doc type can vary Co-authored-by: Mads Rasmussen <[email protected]>
- Loading branch information
1 parent
1fbf02d
commit d89725b
Showing
28 changed files
with
805 additions
and
175 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
using System; | ||
|
||
namespace Umbraco.Core.Models | ||
{ | ||
public class ContentVersionMeta | ||
{ | ||
public int ContentId { get; } | ||
public int ContentTypeId { get; } | ||
public int VersionId { get; } | ||
public int UserId { get; } | ||
|
||
public DateTime VersionDate { get; } | ||
public bool CurrentPublishedVersion { get; } | ||
public bool CurrentDraftVersion { get; } | ||
public bool PreventCleanup { get; } | ||
public string Username { get; } | ||
|
||
public ContentVersionMeta() { } | ||
|
||
public ContentVersionMeta( | ||
int versionId, | ||
int contentId, | ||
int contentTypeId, | ||
int userId, | ||
DateTime versionDate, | ||
bool currentPublishedVersion, | ||
bool currentDraftVersion, | ||
bool preventCleanup, | ||
string username) | ||
{ | ||
VersionId = versionId; | ||
ContentId = contentId; | ||
ContentTypeId = contentTypeId; | ||
|
||
UserId = userId; | ||
VersionDate = versionDate; | ||
CurrentPublishedVersion = currentPublishedVersion; | ||
CurrentDraftVersion = currentDraftVersion; | ||
PreventCleanup = preventCleanup; | ||
Username = username; | ||
} | ||
|
||
public override string ToString() => $"ContentVersionMeta(versionId: {VersionId}, versionDate: {VersionDate:s}"; | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.