mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2026-02-09 09:16:41 +08:00
ContentTypes: Code styling and page title standardization (with encoding fix) in Admin templates
This commit is contained in:
@@ -1,9 +1,11 @@
|
|||||||
@using Orchard.Utility.Extensions
|
@using Orchard.Utility.Extensions
|
||||||
|
|
||||||
@model Orchard.ContentTypes.ViewModels.AddFieldViewModel
|
@model Orchard.ContentTypes.ViewModels.AddFieldViewModel
|
||||||
|
|
||||||
@{
|
@{
|
||||||
Style.Require("ContentTypesAdmin");
|
Style.Require("ContentTypesAdmin");
|
||||||
|
|
||||||
Layout.Title = T("Add New Field To \"{0}\"", Model.Part.DisplayName).ToString();
|
Layout.Title = T("Add New Field To \"{0}\"", Html.Raw(Model.Part.DisplayName)).Text;
|
||||||
|
|
||||||
var returnUrl = Request.QueryString["returnUrl"];
|
var returnUrl = Request.QueryString["returnUrl"];
|
||||||
}
|
}
|
||||||
@@ -31,48 +33,48 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
@using(Script.Foot()){
|
@using(Script.Foot()){
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
//<![CDATA[
|
//<![CDATA[
|
||||||
$(function(){
|
$(function(){
|
||||||
var $name = $("#@Html.FieldIdFor(m=>m.Name)");
|
var $name = $("#@Html.FieldIdFor(m=>m.Name)");
|
||||||
var $displayName = $("#@Html.FieldIdFor(m=>m.DisplayName)");
|
var $displayName = $("#@Html.FieldIdFor(m=>m.DisplayName)");
|
||||||
var partName = "@Model.Part.Name";
|
var partName = "@Model.Part.Name";
|
||||||
|
|
||||||
var jsonUrl = "@Url.Action("FieldName", "Admin", new RouteValueDictionary { {"Area","Orchard.ContentTypes"} } )";
|
var jsonUrl = "@Url.Action("FieldName", "Admin", new RouteValueDictionary { {"Area","Orchard.ContentTypes"} } )";
|
||||||
var version = 0;
|
var version = 0;
|
||||||
|
|
||||||
var nameAltered;
|
var nameAltered;
|
||||||
$name.keypress(function() {
|
$name.keypress(function() {
|
||||||
nameAltered = true;
|
nameAltered = true;
|
||||||
});
|
});
|
||||||
|
|
||||||
var compute = function() {
|
var compute = function() {
|
||||||
// stop processing automatically if altered by the user
|
// stop processing automatically if altered by the user
|
||||||
if(nameAltered) {
|
if(nameAltered) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
$.post(jsonUrl, {
|
$.post(jsonUrl, {
|
||||||
partName: partName,
|
partName: partName,
|
||||||
displayName: $displayName.val(),
|
displayName: $displayName.val(),
|
||||||
version: ++version,
|
version: ++version,
|
||||||
__RequestVerificationToken: $("input[name=__RequestVerificationToken]").val()
|
__RequestVerificationToken: $("input[name=__RequestVerificationToken]").val()
|
||||||
},
|
},
|
||||||
function(data) {
|
function(data) {
|
||||||
if(version == data.version) {
|
if(version == data.version) {
|
||||||
$name.val(data.result);
|
$name.val(data.result);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"json"
|
"json"
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
//pull technical name input from tab order
|
//pull technical name input from tab order
|
||||||
$name.attr("tabindex", -1);
|
$name.attr("tabindex", -1);
|
||||||
|
|
||||||
$displayName.keyup(compute);
|
$displayName.keyup(compute);
|
||||||
$displayName.blur(compute);
|
$displayName.blur(compute);
|
||||||
})
|
})
|
||||||
//]]>
|
//]]>
|
||||||
</script>
|
</script>
|
||||||
}
|
}
|
||||||
@@ -1,9 +1,12 @@
|
|||||||
@model Orchard.ContentTypes.ViewModels.AddPartsViewModel
|
@model Orchard.ContentTypes.ViewModels.AddPartsViewModel
|
||||||
|
|
||||||
@{
|
@{
|
||||||
Style.Require("ContentTypesAdmin");
|
Style.Require("ContentTypesAdmin");
|
||||||
Layout.Title = T("Add Parts To \"{0}\"", Model.Type.DisplayName).ToString();
|
Layout.Title = T("Add Parts To \"{0}\"", Html.Raw(Model.Type.DisplayName)).Text;
|
||||||
}
|
}
|
||||||
|
|
||||||
@T("Choose the Parts to add to this Content Type.")
|
@T("Choose the Parts to add to this Content Type.")
|
||||||
|
|
||||||
@using (Html.BeginFormAntiForgeryPost()) {
|
@using (Html.BeginFormAntiForgeryPost()) {
|
||||||
@Html.ValidationSummary()
|
@Html.ValidationSummary()
|
||||||
<fieldset>
|
<fieldset>
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
@model Orchard.ContentTypes.ViewModels.CreateTypeViewModel
|
@model Orchard.ContentTypes.ViewModels.CreateTypeViewModel
|
||||||
|
|
||||||
@{ Layout.Title = T("New Content Type").ToString(); }
|
@{
|
||||||
|
Layout.Title = T("New Content Type").Text;
|
||||||
|
}
|
||||||
|
|
||||||
@using (Html.BeginFormAntiForgeryPost()) {
|
@using (Html.BeginFormAntiForgeryPost()) {
|
||||||
@Html.ValidationSummary()
|
@Html.ValidationSummary()
|
||||||
@@ -14,48 +16,49 @@
|
|||||||
</fieldset>
|
</fieldset>
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<button class="primaryAction" type="submit">@T("Create")</button>
|
<button class="primaryAction" type="submit">@T("Create")</button>
|
||||||
</fieldset>}
|
</fieldset>
|
||||||
|
}
|
||||||
|
|
||||||
@using(Script.Foot()){
|
@using(Script.Foot()){
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
//<![CDATA[
|
//<![CDATA[
|
||||||
$(function(){
|
$(function(){
|
||||||
var $name = $("#@Html.FieldIdFor(m=>m.Name)");
|
var $name = $("#@Html.FieldIdFor(m=>m.Name)");
|
||||||
var $displayName = $("#@Html.FieldIdFor(m=>m.DisplayName)");
|
var $displayName = $("#@Html.FieldIdFor(m=>m.DisplayName)");
|
||||||
var jsonUrl = "@Url.Action("ContentTypeName", "Admin", new RouteValueDictionary { {"Area","Orchard.ContentTypes"} } )";
|
var jsonUrl = "@Url.Action("ContentTypeName", "Admin", new RouteValueDictionary { {"Area","Orchard.ContentTypes"} } )";
|
||||||
var version = 0;
|
var version = 0;
|
||||||
|
|
||||||
var nameAltered;
|
var nameAltered;
|
||||||
$name.keypress(function() {
|
$name.keypress(function() {
|
||||||
nameAltered = true;
|
nameAltered = true;
|
||||||
});
|
});
|
||||||
|
|
||||||
var compute = function() {
|
var compute = function() {
|
||||||
// stop processing automatically if altered by the user
|
// stop processing automatically if altered by the user
|
||||||
if(nameAltered) {
|
if(nameAltered) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
$.post(jsonUrl, {
|
$.post(jsonUrl, {
|
||||||
displayName: $displayName.val(),
|
displayName: $displayName.val(),
|
||||||
version: ++version,
|
version: ++version,
|
||||||
__RequestVerificationToken: $("input[name=__RequestVerificationToken]").val()
|
__RequestVerificationToken: $("input[name=__RequestVerificationToken]").val()
|
||||||
},
|
},
|
||||||
function(data) {
|
function(data) {
|
||||||
if(version == data.version) {
|
if(version == data.version) {
|
||||||
$name.val(data.result);
|
$name.val(data.result);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"json"
|
"json"
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
//pull technical name input from tab order
|
//pull technical name input from tab order
|
||||||
$name.attr("tabindex", -1);
|
$name.attr("tabindex", -1);
|
||||||
|
|
||||||
$displayName.keyup(compute);
|
$displayName.keyup(compute);
|
||||||
$displayName.blur(compute);
|
$displayName.blur(compute);
|
||||||
})
|
})
|
||||||
//]]>
|
//]]>
|
||||||
</script>
|
</script>
|
||||||
}
|
}
|
||||||
@@ -1,6 +1,8 @@
|
|||||||
@model Orchard.ContentTypes.ViewModels.CreatePartViewModel
|
@model Orchard.ContentTypes.ViewModels.CreatePartViewModel
|
||||||
|
|
||||||
@{ Layout.Title = T("New Content Part").ToString(); }
|
@{
|
||||||
|
Layout.Title = T("New Content Part").Text;
|
||||||
|
}
|
||||||
|
|
||||||
@using (Html.BeginFormAntiForgeryPost()) {
|
@using (Html.BeginFormAntiForgeryPost()) {
|
||||||
@Html.ValidationSummary()
|
@Html.ValidationSummary()
|
||||||
@@ -11,4 +13,5 @@
|
|||||||
</fieldset>
|
</fieldset>
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<button class="primaryAction" type="submit">@T("Create")</button>
|
<button class="primaryAction" type="submit">@T("Create")</button>
|
||||||
</fieldset>}
|
</fieldset>
|
||||||
|
}
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
@using Orchard.Utility.Extensions;
|
|
||||||
@model Orchard.ContentTypes.ViewModels.EditTypeViewModel
|
@model Orchard.ContentTypes.ViewModels.EditTypeViewModel
|
||||||
|
|
||||||
@{
|
@{
|
||||||
Style.Require("ContentTypesAdmin");
|
Style.Require("ContentTypesAdmin");
|
||||||
Script.Require("jQuery");
|
Script.Require("jQuery");
|
||||||
@@ -45,13 +45,13 @@
|
|||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
|
|
||||||
@using(Script.Foot()){
|
@using(Script.Foot()) {
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
//<![CDATA[
|
//<![CDATA[
|
||||||
(function ($) {
|
(function ($) {
|
||||||
$(".manage-field h3,.manage-part h3").expandoControl(function (controller) { return controller.nextAll(".details"); }, { collapse: true, remember: false });
|
$(".manage-field h3,.manage-part h3").expandoControl(function (controller) { return controller.nextAll(".details"); }, { collapse: true, remember: false });
|
||||||
$(".manage-field h4").expandoControl(function (controller) { return controller.nextAll(".settings"); }, { collapse: true, remember: false });
|
$(".manage-field h4").expandoControl(function (controller) { return controller.nextAll(".settings"); }, { collapse: true, remember: false });
|
||||||
})(jQuery);
|
})(jQuery);
|
||||||
//]]>
|
//]]>
|
||||||
</script>
|
</script>
|
||||||
}
|
}
|
||||||
@@ -1,9 +1,11 @@
|
|||||||
@using Orchard.Utility.Extensions
|
@using Orchard.Utility.Extensions
|
||||||
|
|
||||||
@model Orchard.ContentTypes.ViewModels.EditFieldNameViewModel
|
@model Orchard.ContentTypes.ViewModels.EditFieldNameViewModel
|
||||||
|
|
||||||
@{
|
@{
|
||||||
Style.Require("ContentTypesAdmin");
|
Style.Require("ContentTypesAdmin");
|
||||||
|
|
||||||
Layout.Title = T("Edit Field \"{0}\"", Html.Raw(Model.DisplayName)).ToString();
|
Layout.Title = T("Edit Content Field - {0}", Html.Raw(Model.DisplayName)).Text;
|
||||||
|
|
||||||
var returnUrl = Request.QueryString["returnUrl"];
|
var returnUrl = Request.QueryString["returnUrl"];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
@model Orchard.ContentTypes.ViewModels.EditPartViewModel
|
@model Orchard.ContentTypes.ViewModels.EditPartViewModel
|
||||||
|
|
||||||
@{
|
@{
|
||||||
Style.Require("ContentTypesAdmin");
|
Style.Require("ContentTypesAdmin");
|
||||||
Script.Require("jQuery");
|
Script.Require("jQuery");
|
||||||
Layout.Title = T("Edit Part").ToString();
|
Layout.Title = T("Edit Content Part - {0}", Html.Raw(Model.DisplayName)).Text;
|
||||||
}
|
}
|
||||||
|
|
||||||
@using (Html.BeginFormAntiForgeryPost()) {
|
@using (Html.BeginFormAntiForgeryPost()) {
|
||||||
@@ -28,12 +29,12 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
@using(Script.Foot()){
|
@using(Script.Foot()){
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
//<![CDATA[
|
//<![CDATA[
|
||||||
(function ($) {
|
(function ($) {
|
||||||
$(".manage-field h3,.manage-part h3").expandoControl(function (controller) { return controller.nextAll(".details"); }, { collapse: true, remember: false });
|
$(".manage-field h3,.manage-part h3").expandoControl(function (controller) { return controller.nextAll(".details"); }, { collapse: true, remember: false });
|
||||||
$(".manage-field h4").expandoControl(function (controller) { return controller.nextAll(".settings"); }, { collapse: true, remember: false });
|
$(".manage-field h4").expandoControl(function (controller) { return controller.nextAll(".settings"); }, { collapse: true, remember: false });
|
||||||
})(jQuery);
|
})(jQuery);
|
||||||
//]]>
|
//]]>
|
||||||
</script>
|
</script>
|
||||||
}
|
}
|
||||||
@@ -1,8 +1,9 @@
|
|||||||
@model Orchard.ContentTypes.ViewModels.EditPlacementViewModel
|
@model Orchard.ContentTypes.ViewModels.EditPlacementViewModel
|
||||||
|
|
||||||
@{
|
@{
|
||||||
Style.Require("ContentTypesAdmin");
|
Style.Require("ContentTypesAdmin");
|
||||||
Script.Require("jQueryUI_Sortable");
|
Script.Require("jQueryUI_Sortable");
|
||||||
Layout.Title = T("Edit Placement - {0}", Model.ContentTypeDefinition.DisplayName).ToString();
|
Layout.Title = T("Edit Placement - {0}", Html.Raw(Model.ContentTypeDefinition.DisplayName)).Text;
|
||||||
|
|
||||||
var hiddenShapes = Model.AllPlacements.Where(x => String.IsNullOrEmpty(x.PlacementSettings.Zone) && (String.IsNullOrWhiteSpace(x.PlacementSettings.Position) || x.PlacementSettings.Position == "-"));
|
var hiddenShapes = Model.AllPlacements.Where(x => String.IsNullOrEmpty(x.PlacementSettings.Zone) && (String.IsNullOrWhiteSpace(x.PlacementSettings.Position) || x.PlacementSettings.Position == "-"));
|
||||||
}
|
}
|
||||||
@@ -12,7 +13,6 @@
|
|||||||
@using (Html.BeginFormAntiForgeryPost()) {
|
@using (Html.BeginFormAntiForgeryPost()) {
|
||||||
@Html.ValidationSummary()
|
@Html.ValidationSummary()
|
||||||
|
|
||||||
|
|
||||||
<ul id="placement">
|
<ul id="placement">
|
||||||
@for (int i = 0; i < Model.AllPlacements.Count; i++ ) {
|
@for (int i = 0; i < Model.AllPlacements.Count; i++ ) {
|
||||||
|
|
||||||
@@ -24,13 +24,13 @@
|
|||||||
|
|
||||||
<li data-shape-type="@placement.ShapeType" data-shape-differentiator="@placement.Differentiator" data-shape-zone="Content" data-shape-position="@placement.Position">
|
<li data-shape-type="@placement.ShapeType" data-shape-differentiator="@placement.Differentiator" data-shape-zone="Content" data-shape-position="@placement.Position">
|
||||||
<div class="shape-type"><h3>@placement.ShapeType @placement.Differentiator</h3></div>
|
<div class="shape-type"><h3>@placement.ShapeType @placement.Differentiator</h3></div>
|
||||||
<div class="shape-editor">
|
<div class="shape-editor">
|
||||||
@try {
|
@try {
|
||||||
@Display(Model.AllPlacements[i].Shape)
|
@Display(Model.AllPlacements[i].Shape)
|
||||||
}
|
}
|
||||||
catch {
|
catch {
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@* @shape.Position @(Model.PlacementSettings.Any(x => x.Equals(shape)))*@
|
@* @shape.Position @(Model.PlacementSettings.Any(x => x.Equals(shape)))*@
|
||||||
@Html.HiddenFor(m => m.AllPlacements[i].PlacementSettings.ShapeType, new { @class = "type" })
|
@Html.HiddenFor(m => m.AllPlacements[i].PlacementSettings.ShapeType, new { @class = "type" })
|
||||||
@@ -45,63 +45,62 @@
|
|||||||
<button class="primaryAction" type="submit" name="submit.Save" value="Save">@T("Save")</button>
|
<button class="primaryAction" type="submit" name="submit.Save" value="Save">@T("Save")</button>
|
||||||
<button class="primaryAction" type="submit" name="submit.Restore" value="Restore" itemprop="RemoveUrl" data-message="@T("Are you sure you want to restore these placements?")">@T("Restore")</button>
|
<button class="primaryAction" type="submit" name="submit.Restore" value="Restore" itemprop="RemoveUrl" data-message="@T("Are you sure you want to restore these placements?")">@T("Restore")</button>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@using (Script.Foot()) {
|
@using (Script.Foot()) {
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
//<![CDATA[
|
//<![CDATA[
|
||||||
(function ($) {
|
(function ($) {
|
||||||
|
|
||||||
var assignPositions = function () {
|
var assignPositions = function () {
|
||||||
var position = 0;
|
var position = 0;
|
||||||
$('.type').each(function () {
|
$('.type').each(function () {
|
||||||
var input = $(this);
|
var input = $(this);
|
||||||
reAssignIdName(input, position); // type
|
reAssignIdName(input, position); // type
|
||||||
|
|
||||||
input = input.next();
|
input = input.next();
|
||||||
reAssignIdName(input, position); // differentiator
|
reAssignIdName(input, position); // differentiator
|
||||||
|
|
||||||
input = input.next();
|
input = input.next();
|
||||||
reAssignIdName(input, position); // zone
|
reAssignIdName(input, position); // zone
|
||||||
|
|
||||||
input = input.next();
|
input = input.next();
|
||||||
reAssignIdName(input, position); // position
|
reAssignIdName(input, position); // position
|
||||||
|
|
||||||
input.val(++position);
|
input.val(++position);
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
var reAssignIdName = function (input, pos) {
|
var reAssignIdName = function (input, pos) {
|
||||||
var name = input.attr('name');
|
var name = input.attr('name');
|
||||||
input.attr('name', name.replace(new RegExp("\\[.*\\]", 'gi'), '[' + pos + ']'));
|
input.attr('name', name.replace(new RegExp("\\[.*\\]", 'gi'), '[' + pos + ']'));
|
||||||
|
|
||||||
var id = input.attr('id');
|
var id = input.attr('id');
|
||||||
input.attr('id', id.replace(new RegExp('_.*__', 'i'), '_' + pos + '__'));
|
input.attr('id', id.replace(new RegExp('_.*__', 'i'), '_' + pos + '__'));
|
||||||
};
|
};
|
||||||
|
|
||||||
assignPositions();
|
assignPositions();
|
||||||
|
|
||||||
var startPos;
|
var startPos;
|
||||||
|
|
||||||
$('#placement').sortable({
|
$('#placement').sortable({
|
||||||
placeholder: "placement-placeholder",
|
placeholder: "placement-placeholder",
|
||||||
start: function (event, ui) {
|
start: function (event, ui) {
|
||||||
var self = $(ui.item);
|
var self = $(ui.item);
|
||||||
startPos = self.prevAll().size();
|
startPos = self.prevAll().size();
|
||||||
},
|
},
|
||||||
stop: function (event, ui) {
|
stop: function (event, ui) {
|
||||||
assignPositions();
|
assignPositions();
|
||||||
$('#save-message').show();
|
$('#save-message').show();
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
$('.shape-editor *').attr('disabled', 'disabled');
|
$('.shape-editor *').attr('disabled', 'disabled');
|
||||||
|
|
||||||
$("#placement").disableSelection();
|
$("#placement").disableSelection();
|
||||||
|
|
||||||
})(jQuery);
|
})(jQuery);
|
||||||
//]]>
|
//]]>
|
||||||
</script>
|
</script>
|
||||||
}
|
}
|
||||||
@@ -1,22 +1,25 @@
|
|||||||
@model Orchard.ContentTypes.ViewModels.ListContentTypesViewModel
|
@model Orchard.ContentTypes.ViewModels.ListContentTypesViewModel
|
||||||
|
|
||||||
@{
|
@{
|
||||||
Style.Require("ContentTypesAdmin");
|
Style.Require("ContentTypesAdmin");
|
||||||
Script.Require("jQuery");
|
Script.Require("jQuery");
|
||||||
Script.Include("admin-contenttypes.js");
|
Script.Include("admin-contenttypes.js");
|
||||||
Layout.Title = T("Manage Content Types").ToString();
|
Layout.Title = T("Manage Content Types").Text;
|
||||||
}
|
}
|
||||||
|
|
||||||
<div class="manage">
|
<div class="manage">
|
||||||
@Html.ActionLink(T("Create new type").ToString(), "Create", new{Controller="Admin",Area="Orchard.ContentTypes"}, new { @class = "button primaryAction" })
|
@Html.ActionLink(T("Create new type").Text, "Create", new { Controller = "Admin", Area = "Orchard.ContentTypes" }, new { @class = "button primaryAction" })
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<fieldset class="bulk-actions">
|
<fieldset class="bulk-actions">
|
||||||
<label for="search-box">@T("Filter:")</label>
|
<label for="search-box">@T("Filter:")</label>
|
||||||
<input id="search-box" class="text" type="text" autofocus="autofocus" />
|
<input id="search-box" class="text" type="text" autofocus="autofocus" />
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
<ul class="contentItems">
|
<ul class="contentItems">
|
||||||
@foreach (var type in Model.Types) {
|
@foreach (var type in Model.Types) {
|
||||||
<li data-record-text="@type.DisplayName">
|
<li data-record-text="@type.DisplayName">
|
||||||
@Html.DisplayFor(m => type)
|
@Html.DisplayFor(m => type)
|
||||||
</li>
|
</li>
|
||||||
}
|
}
|
||||||
</ul>
|
</ul>
|
||||||
@@ -1,20 +1,25 @@
|
|||||||
@model Orchard.ContentTypes.ViewModels.ListContentPartsViewModel
|
@model Orchard.ContentTypes.ViewModels.ListContentPartsViewModel
|
||||||
|
|
||||||
@{
|
@{
|
||||||
Script.Require("jQuery");
|
Script.Require("jQuery");
|
||||||
Script.Include("admin-contenttypes.js");
|
Script.Include("admin-contenttypes.js");
|
||||||
Layout.Title = T("Content Parts").ToString();
|
Layout.Title = T("Content Parts").Text;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
<div class="manage">
|
<div class="manage">
|
||||||
@Html.ActionLink(T("Create new part").ToString(), "CreatePart", new{Controller="Admin",Area="Orchard.ContentTypes"}, new { @class = "button primaryAction" })
|
@Html.ActionLink(T("Create new part").Text, "CreatePart", new { Controller = "Admin", Area = "Orchard.ContentTypes" }, new { @class = "button primaryAction" })
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<fieldset class="bulk-actions">
|
<fieldset class="bulk-actions">
|
||||||
<label for="search-box">@T("Filter:")</label>
|
<label for="search-box">@T("Filter:")</label>
|
||||||
<input id="search-box" class="text" type="text" autofocus="autofocus" />
|
<input id="search-box" class="text" type="text" autofocus="autofocus" />
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
<ul class="contentItems">
|
<ul class="contentItems">
|
||||||
@foreach (var type in Model.Parts) {
|
@foreach (var type in Model.Parts) {
|
||||||
<li data-record-text="@type.DisplayName">
|
<li data-record-text="@type.DisplayName">
|
||||||
@Html.DisplayFor(m => type)
|
@Html.DisplayFor(m => type)
|
||||||
</li>
|
</li>
|
||||||
}
|
}
|
||||||
</ul>
|
</ul>
|
||||||
|
|||||||
@@ -1,7 +1,8 @@
|
|||||||
@model Orchard.ContentTypes.ViewModels.RemoveFieldViewModel
|
@model Orchard.ContentTypes.ViewModels.RemoveFieldViewModel
|
||||||
|
|
||||||
@{
|
@{
|
||||||
Style.Require("ContentTypesAdmin");
|
Style.Require("ContentTypesAdmin");
|
||||||
Layout.Title = T("Remove the \"{0}\" part from \"{1}\"", Model.Name, Model.Part.DisplayName).ToString();
|
Layout.Title = T("Remove the \"{0}\" Content Field from \"{1}\"", Model.Name, Html.Raw(Model.Part.DisplayName)).Text;
|
||||||
}
|
}
|
||||||
|
|
||||||
@using (Html.BeginFormAntiForgeryPost()) {
|
@using (Html.BeginFormAntiForgeryPost()) {
|
||||||
|
|||||||
@@ -1,7 +1,8 @@
|
|||||||
@model Orchard.ContentTypes.ViewModels.RemovePartViewModel
|
@model Orchard.ContentTypes.ViewModels.RemovePartViewModel
|
||||||
|
|
||||||
@{
|
@{
|
||||||
Style.Require("ContentTypesAdmin");
|
Style.Require("ContentTypesAdmin");
|
||||||
Layout.Title = T("Remove the \"{0}\" part from \"{1}\"", Model.Name, Model.Type.DisplayName).ToString();
|
Layout.Title = T("Remove the \"{0}\" Content Part from \"{1}\"", Model.Name, Html.Raw(Model.Type.DisplayName)).Text;
|
||||||
}
|
}
|
||||||
|
|
||||||
@using (Html.BeginFormAntiForgeryPost()) {
|
@using (Html.BeginFormAntiForgeryPost()) {
|
||||||
|
|||||||
Reference in New Issue
Block a user