版权信息输出.net运行时,例如9.0.6,而不是框架9.0
This commit is contained in:
parent
02d4cf2926
commit
64568c7bdd
|
@ -67,12 +67,12 @@
|
|||
}
|
||||
|
||||
<!-- 登录校验信息 -->
|
||||
@if (Html.ValidationSummary(true).ToDictionary().Count()>1)
|
||||
@if (Html.ValidationSummary(true).ToDictionary().Count() > 1)
|
||||
{
|
||||
<div class="alert alert-dismissible bg-light-danger border border-danger border-dashed d-flex flex-column flex-sm-row m-10">
|
||||
<!--begin::Icon-->
|
||||
<!--begin::Svg Icon | path: icons/duotone/Interface/Comment.svg-->
|
||||
<span class="svg-icon svg-icon-2hx svg-icon-danger me-4 mb-5 mb-sm-0">
|
||||
<span class="svg-icon svg-icon-2hx svg-icon-danger me-4 mb-5 mb-sm-0">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none">
|
||||
<path opacity="0.25" fill-rule="evenodd" clip-rule="evenodd" d="M5.69477 2.48932C4.00472 2.74648 2.66565 3.98488 2.37546 5.66957C2.17321 6.84372 2 8.33525 2 10C2 11.6647 2.17321 13.1563 2.37546 14.3304C2.62456 15.7766 3.64656 16.8939 5 17.344V20.7476C5 21.5219 5.84211 22.0024 6.50873 21.6085L12.6241 17.9949C14.8384 17.9586 16.8238 17.7361 18.3052 17.5107C19.9953 17.2535 21.3344 16.0151 21.6245 14.3304C21.8268 13.1563 22 11.6647 22 10C22 8.33525 21.8268 6.84372 21.6245 5.66957C21.3344 3.98488 19.9953 2.74648 18.3052 2.48932C16.6859 2.24293 14.4644 2 12 2C9.53559 2 7.31411 2.24293 5.69477 2.48932Z" fill="#191213"></path>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M7 7C6.44772 7 6 7.44772 6 8C6 8.55228 6.44772 9 7 9H17C17.5523 9 18 8.55228 18 8C18 7.44772 17.5523 7 17 7H7ZM7 11C6.44772 11 6 11.4477 6 12C6 12.5523 6.44772 13 7 13H11C11.5523 13 12 12.5523 12 12C12 11.4477 11.5523 11 11 11H7Z" fill="#121319"></path>
|
||||
|
@ -81,17 +81,17 @@
|
|||
<!--end::Svg Icon-->
|
||||
<!--end::Icon-->
|
||||
<!--begin::Content-->
|
||||
<div class="d-flex flex-column pe-0 pe-sm-10">
|
||||
<div class="d-flex flex-column pe-0 pe-sm-10">
|
||||
<h5 class="mb-1 text-danger">信息</h5>
|
||||
<span class="text-danger">@Html.ValidationSummary()</span>
|
||||
</div>
|
||||
<!--end::Content-->
|
||||
<!--begin::Close-->
|
||||
<button type="button" class="position-absolute position-sm-relative m-2 m-sm-0 top-0 end-0 btn btn-icon ms-sm-auto" data-bs-dismiss="alert">
|
||||
<button type="button" class="position-absolute position-sm-relative m-2 m-sm-0 top-0 end-0 btn btn-icon ms-sm-auto" data-bs-dismiss="alert">
|
||||
<i class="fas fa-times fs-1 text-danger"></i>
|
||||
</button>
|
||||
<!--end::Close-->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
}
|
||||
<!--begin::Content-->
|
||||
|
@ -133,10 +133,10 @@
|
|||
<span class="spinner-border spinner-border-sm align-middle ms-2"></span>
|
||||
</span>
|
||||
</button>
|
||||
|
||||
|
||||
@if (set.AllowRegister)
|
||||
{
|
||||
<a id="btnRegister" href="#Pane_Register" class="btn btn-lg btn-bg-light btn-active-info w-100 mb-5 nav-link" onclick="register()">注册</a>
|
||||
<a id="btnRegister" href="#Pane_Register" class="btn btn-lg btn-bg-light btn-active-info w-100 mb-5 nav-link" onclick="register()">注册</a>
|
||||
}
|
||||
</div>
|
||||
</form>
|
||||
|
@ -144,11 +144,10 @@
|
|||
</div>
|
||||
<!-- 找回密码 -->
|
||||
<div id="Pane_Forgot" class="tab-pane fade">
|
||||
|
||||
</div>
|
||||
<!-- 注册用户 -->
|
||||
<div id="Pane_Register" class="tab-pane fade">
|
||||
<form action="@Url.Action("Register", "User", new {r = set.ReturnUrl })" method="post">
|
||||
<form action="@Url.Action("Register", "User", new { r = set.ReturnUrl })" method="post">
|
||||
<div class="fv-row mb-5">
|
||||
<input class="form-control form-control-lg" type="email" name="email" id="reg_email" placeholder="输入您的邮箱地址" autocomplete="off" />
|
||||
</div>
|
||||
|
@ -180,19 +179,19 @@
|
|||
|
||||
@await Html.PartialAsync("Login_OAuth")
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<!--end::Wrapper-->
|
||||
<!--end::Content-->
|
||||
|
||||
<div class="d-flex flex-center flex-column flex-wrap p-5 pb-3">
|
||||
<div class="d-flex flex-center fs-10 text-muted">
|
||||
<a>@config.GetCopyright()</a>
|
||||
@Html.Raw(config.GetCopyright())
|
||||
<a> VER: @SysConfig.Current.Version</a>
|
||||
</div>
|
||||
<div class="d-flex flex-center fw-bold fs-10">
|
||||
<a href="https://www.beianx.cn/" class="text-muted text-hover-primary">
|
||||
@NewLife.Cube.CubeSetting.Current.Registration
|
||||
@NewLife.Cube.CubeSetting.Current.Registration
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -35,7 +35,7 @@
|
|||
<!--begin::Footer-->
|
||||
<div class="d-flex flex-center flex-column flex-wrap p-5 pb-3">
|
||||
<div class="d-flex flex-center fs-10 text-muted">
|
||||
<a>@copyright</a>
|
||||
@Html.Raw(copyright)
|
||||
<a> VER: @SysConfig.Current.Version</a>
|
||||
</div>
|
||||
<div class="d-flex flex-center fw-bold fs-10">
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
<div class="col-12 col-lg-auto mt-3 mt-lg-0">
|
||||
<ul class="list-inline list-inline-dots mb-0">
|
||||
<li class="list-inline-item">
|
||||
@copyright
|
||||
@Html.Raw(copyright)
|
||||
</li>
|
||||
@if (!set.Registration.IsNullOrEmpty())
|
||||
{
|
||||
|
|
|
@ -247,8 +247,8 @@ public class CubeSetting : Config<CubeSetting>
|
|||
[Category("界面配置")]
|
||||
public Int32 MaxDropDownList { get; set; } = 50;
|
||||
|
||||
/// <summary>版权。留空表示不显示版权信息</summary>
|
||||
[Description("版权。留空表示不显示版权信息")]
|
||||
/// <summary>版权。留空表示不显示版权信息,支持变量now/runtime/framework,其中now支持格式化字符串如{now:yyyy}</summary>
|
||||
[Description("版权。留空表示不显示版权信息,支持变量now/runtime/framework,其中now支持格式化字符串如{now:yyyy}")]
|
||||
[Category("界面配置")]
|
||||
public String Copyright { get; set; }
|
||||
|
||||
|
@ -355,7 +355,7 @@ public class CubeSetting : Config<CubeSetting>
|
|||
var att = asm.GetCustomAttribute<AssemblyCopyrightAttribute>();
|
||||
if (att != null)
|
||||
{
|
||||
Copyright = att.Copyright;
|
||||
Copyright = att.Copyright + " {runtime}";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -386,9 +386,13 @@ public class CubeSetting : Config<CubeSetting>
|
|||
if (cr.IsNullOrEmpty()) return null;
|
||||
|
||||
// 处理运行时
|
||||
if (cr.Contains("{runtime}"))
|
||||
{
|
||||
cr = cr.Replace("{runtime}", $"<a href=\"https://get.dot.net\" target=\"_blank\">.NET {Environment.Version}</a>");
|
||||
}
|
||||
if (cr.Contains("{framework}"))
|
||||
{
|
||||
cr = cr.Replace("{framework}", RuntimeInformation.FrameworkDescription);
|
||||
cr = cr.Replace("{framework}", $"<a href=\"https://get.dot.net\" target=\"_blank\">{RuntimeInformation.FrameworkDescription}</a>");
|
||||
}
|
||||
|
||||
// 处理今年时间
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<div style="margin-top:20px;" class="text-center">
|
||||
@if (!copyright.IsNullOrEmpty())
|
||||
{
|
||||
<span>@copyright</span>
|
||||
<span>@Html.Raw(copyright)</span>
|
||||
}
|
||||
@if (!set.Registration.IsNullOrEmpty())
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue