Changing the usage of "slug" in error messages to "permalink" to match the field's label.

work item: 17417

--HG--
branch : 1.x
This commit is contained in:
Nathan Heskew
2011-04-04 10:50:04 -07:00
parent 0605f0db28
commit 38f1039b7d
3 changed files with 5 additions and 5 deletions

View File

@@ -87,9 +87,9 @@ namespace Orchard.Core.Routable.Drivers {
if ( !_routableService.IsSlugValid(part.Slug) ) {
var slug = (part.Slug ?? String.Empty);
if ( slug.StartsWith(".") || slug.EndsWith(".") )
updater.AddModelError("Routable.Slug", T("The \".\" can't be used around routes."));
updater.AddModelError("Routable.Slug", T("The \".\" can't be used at either end of the permalink."));
else
updater.AddModelError("Routable.Slug", T("Please do not use any of the following characters in your slugs: \":\", \"?\", \"#\", \"[\", \"]\", \"@\", \"!\", \"$\", \"&\", \"'\", \"(\", \")\", \"*\", \"+\", \",\", \";\", \"=\", \", \"<\", \">\". No spaces are allowed (please use dashes or underscores instead)."));
updater.AddModelError("Routable.Slug", T("Please do not use any of the following characters in your permalink: \":\", \"?\", \"#\", \"[\", \"]\", \"@\", \"!\", \"$\", \"&\", \"'\", \"(\", \")\", \"*\", \"+\", \",\", \";\", \"=\", \", \"<\", \">\". No spaces are allowed (please use dashes or underscores instead)."));
}
return Editor(part, shapeHelper);

View File

@@ -41,7 +41,7 @@ namespace Orchard.Core.Routable.Handlers {
Action<RoutePart> processSlug = (
routable => {
if (!_routableService.ProcessSlug(routable))
_services.Notifier.Warning(T("Slugs in conflict. \"{0}\" is already set for a previously created {2} so now it has the slug \"{1}\"",
_services.Notifier.Warning(T("Permalinks in conflict. \"{0}\" is already set for a previously created {2} so now it has the slug \"{1}\"",
routable.Slug, routable.GetEffectiveSlug(), routable.ContentItem.ContentType));
});