mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-09-22 20:13:50 +08:00
@@ -47,7 +47,7 @@ namespace Orchard.Core.Routable.Services {
|
||||
}
|
||||
|
||||
public void FillSlugFromTitle<TModel>(TModel model) where TModel : IRoutableAspect {
|
||||
if (!string.IsNullOrEmpty(model.Slug) || string.IsNullOrEmpty(model.Title))
|
||||
if ((model.Slug != null && !string.IsNullOrEmpty(model.Slug.Trim())) || string.IsNullOrEmpty(model.Title))
|
||||
return;
|
||||
|
||||
FillSlugContext slugContext = new FillSlugContext(model.Title);
|
||||
|
@@ -10,7 +10,6 @@ namespace Orchard.Core.Routable.ViewModels {
|
||||
[StringLength(1024)]
|
||||
public string Title { get; set; }
|
||||
[StringLength(1024)]
|
||||
[Required(AllowEmptyStrings = false)]
|
||||
public string Slug { get; set; }
|
||||
public int? ContainerId { get; set; }
|
||||
public bool PromoteToHomePage { get; set; }
|
||||
|
Reference in New Issue
Block a user