Skip to content

Commit

Permalink
细调表单页尾处 创建、更新、备注 的样式
Browse files Browse the repository at this point in the history
  • Loading branch information
nnhy committed Sep 20, 2016
1 parent 3fdc526 commit de32e6e
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 25 deletions.
4 changes: 2 additions & 2 deletions NewLife.Cube/Common/HtmlExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ public static MvcHtmlString ForString(this HtmlHelper Html, String name, String
}
else if (length < 0 || length > 300)
{
txt = Html.TextArea(name, value, atts);
txt = Html.TextArea(name, value, 3, 20, atts);
}
else
{
Expand Down Expand Up @@ -365,7 +365,7 @@ public static MvcHtmlString ForDouble(this HtmlHelper Html, String name, Double
{
var atts = HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes);
if (!atts.ContainsKey("class")) atts.Add("class", "form-control");

var txt = Html.TextBox(name, value, format, atts);

return txt;
Expand Down
16 changes: 8 additions & 8 deletions NewLife.Cube/Views/Shared/_Form_Footer.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@
var cip = fact.Table.FindByName("CreateIP") as FieldItem;
var uip = fact.Table.FindByName("UpdateIP") as FieldItem;
var remark = fact.Table.FindByName("Remark") as FieldItem;
if (remark != null) { remark = fact.Table.FindByName("Description"); }
if (remark == null) { remark = fact.Table.FindByName("Description"); }
}
@if (cid != null)
{
var user = fact.Table.FindByName("CreateUserName") as FieldItem;
var time = fact.Table.FindByName("CreateTime") as FieldItem;
<div class="form-group col-sm-12 col-md-6">
<label class="control-label col-md-2">创建</label>
<div class="control-label col-md-10" style="text-align: left;">
<label class="control-label col-xs-2 col-sm-2 col-md-2">创建</label>
<div class="control-label col-xs-8 col-sm-8 col-md-10" style="text-align: left;">
@if (user != null)
{
<span class="text-primary">@entity[user.Name]</span>
Expand All @@ -41,8 +41,8 @@
var user = fact.Table.FindByName("UpdateUserName") as FieldItem;
var time = fact.Table.FindByName("UpdateTime") as FieldItem;
<div class="form-group col-sm-12 col-md-6">
<label class="control-label col-md-2">更新</label>
<div class="control-label col-md-10" style="text-align: left;">
<label class="control-label col-xs-2 col-sm-2 col-md-2">更新</label>
<div class="control-label col-xs-8 col-sm-8 col-md-10" style="text-align: left;">
@if (user != null)
{
<span class="text-primary">@entity[user.Name]</span>
Expand All @@ -63,10 +63,10 @@
@if (remark != null && !fields.Contains(remark))
{
<div class="form-group col-sm-12 col-md-12">
<label class="control-label col-md-2">@remark.DisplayName</label>
<div class="input-group col-md-6">
<label class="control-label col-xs-2 col-sm-2 col-md-1">@remark.DisplayName</label>
<div class="col-xs-8 col-sm-8 col-md-8">
@Html.ForString(remark.Name, (String)entity[remark.Name], -1)
@Html.ForDescription(remark)
</div>
</div>
}
}
29 changes: 14 additions & 15 deletions NewLife.Cube/Views/Shared/_Form_Footer.generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public override void Execute()
var cip = fact.Table.FindByName("CreateIP") as FieldItem;
var uip = fact.Table.FindByName("UpdateIP") as FieldItem;
var remark = fact.Table.FindByName("Remark") as FieldItem;
if (remark != null) { remark = fact.Table.FindByName("Description"); }
if (remark == null) { remark = fact.Table.FindByName("Description"); }


#line default
Expand All @@ -88,11 +88,11 @@ public override void Execute()

WriteLiteral(">\r\n <label");

WriteLiteral(" class=\"control-label col-md-2\"");
WriteLiteral(" class=\"control-label col-xs-2 col-sm-2 col-md-2\"");

WriteLiteral(">创建</label>\r\n <div");

WriteLiteral(" class=\"control-label col-md-10\"");
WriteLiteral(" class=\"control-label col-xs-8 col-sm-8 col-md-10\"");

WriteLiteral(" style=\"text-align: left;\"");

Expand Down Expand Up @@ -182,14 +182,14 @@ public override void Execute()

WriteLiteral(" class=\"text-primary\"");

WriteAttribute("title", Tuple.Create(" title=\"", 1426), Tuple.Create("\"", 1437)
WriteAttribute("title", Tuple.Create(" title=\"", 1462), Tuple.Create("\"", 1473)

#line 34 "..\..\Views\Shared\_Form_Footer.cshtml"
, Tuple.Create(Tuple.Create("", 1434), Tuple.Create<System.Object, System.Int32>(ip
, Tuple.Create(Tuple.Create("", 1470), Tuple.Create<System.Object, System.Int32>(ip

#line default
#line hidden
, 1434), false)
, 1470), false)
);

WriteLiteral(">");
Expand Down Expand Up @@ -235,11 +235,11 @@ public override void Execute()

WriteLiteral(">\r\n <label");

WriteLiteral(" class=\"control-label col-md-2\"");
WriteLiteral(" class=\"control-label col-xs-2 col-sm-2 col-md-2\"");

WriteLiteral(">更新</label>\r\n <div");

WriteLiteral(" class=\"control-label col-md-10\"");
WriteLiteral(" class=\"control-label col-xs-8 col-sm-8 col-md-10\"");

WriteLiteral(" style=\"text-align: left;\"");

Expand Down Expand Up @@ -329,14 +329,14 @@ public override void Execute()

WriteLiteral(" class=\"text-primary\"");

WriteAttribute("title", Tuple.Create(" title=\"", 2325), Tuple.Create("\"", 2336)
WriteAttribute("title", Tuple.Create(" title=\"", 2397), Tuple.Create("\"", 2408)

#line 58 "..\..\Views\Shared\_Form_Footer.cshtml"
, Tuple.Create(Tuple.Create("", 2333), Tuple.Create<System.Object, System.Int32>(ip
, Tuple.Create(Tuple.Create("", 2405), Tuple.Create<System.Object, System.Int32>(ip

#line default
#line hidden
, 2333), false)
, 2405), false)
);

WriteLiteral(">");
Expand Down Expand Up @@ -380,20 +380,20 @@ public override void Execute()

WriteLiteral(">\r\n <label");

WriteLiteral(" class=\"control-label col-md-2\"");
WriteLiteral(" class=\"control-label col-xs-2 col-sm-2 col-md-1\"");

WriteLiteral(">");


#line 66 "..\..\Views\Shared\_Form_Footer.cshtml"
Write(remark.DisplayName);
Write(remark.DisplayName);


#line default
#line hidden
WriteLiteral("</label>\r\n <div");

WriteLiteral(" class=\"input-group col-md-6\"");
WriteLiteral(" class=\"col-xs-8 col-sm-8 col-md-8\"");

WriteLiteral(">\r\n");

Expand Down Expand Up @@ -422,7 +422,6 @@ public override void Execute()

#line 72 "..\..\Views\Shared\_Form_Footer.cshtml"
}


#line default
#line hidden
Expand Down

0 comments on commit de32e6e

Please sign in to comment.