Added support for File descriptions, Folder capacity and image sizes. Added image resizing capability using ImageSharp - implemented in user profile. Added parameter to disable image preview in FileManager component. Overhauled Pager component and added Columns parameter for Grid mode. Populated PageState.User.IsAuthenticated in SiteRouter. Added support for zero price commercial extentions.
This commit is contained in:
@ -40,6 +40,8 @@ namespace Oqtane.Shared {
|
||||
public const string DefaultSiteTemplate = "Oqtane.SiteTemplates.DefaultSiteTemplate, Oqtane.Server";
|
||||
|
||||
public const string ContentUrl = "/api/file/download/";
|
||||
public const string ImageUrl = "/api/file/image/";
|
||||
public const int UserFolderCapacity = 20; // megabytes
|
||||
|
||||
[Obsolete("Use UserNames.Host instead.")]
|
||||
public const string HostUser = UserNames.Host;
|
||||
|
@ -112,6 +112,12 @@ namespace Oqtane.Shared
|
||||
return $"{aliasUrl}{Constants.ContentUrl}{fileId}{method}";
|
||||
}
|
||||
|
||||
public static string ImageUrl(Alias alias, int fileId, string size, string mode)
|
||||
{
|
||||
var aliasUrl = (alias != null && !string.IsNullOrEmpty(alias.Path)) ? "/" + alias.Path : "";
|
||||
return $"{aliasUrl}{Constants.ImageUrl}{fileId}/{size}/{mode}";
|
||||
}
|
||||
|
||||
public static string TenantUrl(Alias alias, string url)
|
||||
{
|
||||
url = (!url.StartsWith("/")) ? "/" + url : url;
|
||||
|
Reference in New Issue
Block a user