mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Added Recipe Category to Recipe Metadata builder step.
This commit is contained in:
@@ -31,6 +31,7 @@ namespace Orchard.Recipes.Providers.Builders {
|
||||
public string RecipeAuthor { get; set; }
|
||||
public string RecipeWebsite { get; set; }
|
||||
public string RecipeTags { get; set; }
|
||||
public string RecipeCategory { get; set; }
|
||||
public string RecipeVersion { get; set; }
|
||||
public bool IsSetupRecipe { get; set; }
|
||||
|
||||
@@ -49,6 +50,7 @@ namespace Orchard.Recipes.Providers.Builders {
|
||||
RecipeAuthor = viewModel.RecipeAuthor;
|
||||
RecipeWebsite = viewModel.RecipeWebsite;
|
||||
RecipeTags = viewModel.RecipeTags;
|
||||
RecipeCategory = viewModel.RecipeCategory;
|
||||
RecipeVersion = viewModel.RecipeVersion;
|
||||
IsSetupRecipe = viewModel.IsSetupRecipe;
|
||||
}
|
||||
@@ -62,6 +64,7 @@ namespace Orchard.Recipes.Providers.Builders {
|
||||
RecipeAuthor = context.ConfigurationElement.Attr("RecipeAuthor");
|
||||
RecipeWebsite = context.ConfigurationElement.Attr("RecipeWebsite");
|
||||
RecipeTags = context.ConfigurationElement.Attr("RecipeTags");
|
||||
RecipeCategory = context.ConfigurationElement.Attr("RecipeCategory");
|
||||
RecipeVersion = context.ConfigurationElement.Attr("RecipeVersion");
|
||||
IsSetupRecipe = context.ConfigurationElement.Attr<bool>("IsSetupRecipe");
|
||||
}
|
||||
@@ -74,6 +77,7 @@ namespace Orchard.Recipes.Providers.Builders {
|
||||
recipeElement.SetElementValue("Author", RecipeAuthor);
|
||||
recipeElement.SetElementValue("WebSite", RecipeWebsite);
|
||||
recipeElement.SetElementValue("Tags", RecipeTags);
|
||||
recipeElement.SetElementValue("Category", RecipeCategory);
|
||||
recipeElement.SetElementValue("Version", RecipeVersion);
|
||||
recipeElement.SetElementValue("IsSetupRecipe", IsSetupRecipe);
|
||||
}
|
||||
|
@@ -5,6 +5,7 @@ namespace Orchard.Recipes.ViewModels {
|
||||
public string RecipeAuthor { get; set; }
|
||||
public string RecipeWebsite { get; set; }
|
||||
public string RecipeTags { get; set; }
|
||||
public string RecipeCategory { get; set; }
|
||||
public string RecipeVersion { get; set; }
|
||||
public bool IsSetupRecipe { get; set; }
|
||||
}
|
||||
|
@@ -2,32 +2,37 @@
|
||||
<div>
|
||||
@Html.LabelFor(m => m.RecipeName, T("Name"))
|
||||
@Html.TextBoxFor(m => m.RecipeName, new { @class = "text medium" })
|
||||
@Html.Hint(T("Optionally provide a name for the setup recipe."))
|
||||
@Html.Hint(T("Optionally provide a name for the recipe."))
|
||||
</div>
|
||||
<div>
|
||||
@Html.LabelFor(m => m.RecipeDescription, T("Description"))
|
||||
@Html.TextBoxFor(m => m.RecipeDescription, new {@class = "text large"})
|
||||
@Html.Hint(T("Optionally provide a description for the setup recipe."))
|
||||
@Html.Hint(T("Optionally provide a description for the recipe."))
|
||||
</div>
|
||||
<div>
|
||||
@Html.LabelFor(m => m.RecipeAuthor, T("Author"))
|
||||
@Html.TextBoxFor(m => m.RecipeAuthor, new { @class = "text large" })
|
||||
@Html.Hint(T("Optionally provide the name of the author for the setup recipe."))
|
||||
@Html.Hint(T("Optionally provide the name of the author for the recipe."))
|
||||
</div>
|
||||
<div>
|
||||
@Html.LabelFor(m => m.RecipeWebsite, T("Website"))
|
||||
@Html.TextBoxFor(m => m.RecipeWebsite, new { @class = "text large" })
|
||||
@Html.Hint(T("Optionally provide a website URL for the setup recipe."))
|
||||
@Html.Hint(T("Optionally provide a website URL for the recipe."))
|
||||
</div>
|
||||
<div>
|
||||
@Html.LabelFor(m => m.RecipeTags, T("Tags"))
|
||||
@Html.TextBoxFor(m => m.RecipeTags, new { @class = "text large" })
|
||||
@Html.Hint(T("Optionally provide tags for the setup recipe."))
|
||||
@Html.TextBoxFor(m => m.RecipeTags, new {@class = "text large"})
|
||||
@Html.Hint(T("Optionally provide tags for the recipe."))
|
||||
</div>
|
||||
<div>
|
||||
@Html.LabelFor(m => m.RecipeCategory, T("Category"))
|
||||
@Html.TextBoxFor(m => m.RecipeCategory, new { @class = "text large" })
|
||||
@Html.Hint(T("Optionally provide a category for the recipe."))
|
||||
</div>
|
||||
<div>
|
||||
@Html.LabelFor(m => m.RecipeVersion, T("Version"))
|
||||
@Html.TextBoxFor(m => m.RecipeVersion, new {@class = "text small"})
|
||||
@Html.Hint(T("Optionally provide a version for the setup recipe."))
|
||||
@Html.Hint(T("Optionally provide a version for the recipe."))
|
||||
</div>
|
||||
<div>
|
||||
@Html.CheckBoxFor(m => m.IsSetupRecipe)
|
||||
|
Reference in New Issue
Block a user