@inject Microsoft.AspNetCore.Hosting.IWebHostEnvironment env
@inject Microsoft.AspNetCore.Antiforgery.IAntiforgery Xsrf
@using NewLife
@using System.Runtime;
@using System.Diagnostics;
@{
Layout = null;
Admin my = ViewBag.admin;
var mi = MachineInfo.Current ?? new MachineInfo();
var process = Process.GetCurrentProcess();
}
@functions {
public string GetAntiXsrfRequestToken()
{
return Xsrf.GetAndStoreTokens(Context).RequestToken;
}
}
@(DateTime.Now.ToString("yyyy年MM月dd日"))
网站文章数量
@(Article.FindCount(null,null,null,0,0))
系统总的文章数量
全部
总产品数量
@(Product.FindCount(null,null,null,0,0))
系统总产品数量
总会员数量
@(Member.FindCount(null,null,null,0,0))
系统总会员数量
未读留言
@(Guestbook.FindCount(Guestbook._.IsRead==0, null,null,0,0))
未读留言数量
@if(my.Roles.IsSuperAdmin == 1)
{
服务器信息
| 服务器名称 |
@Environment.MachineName
|
| 操作系统 |
@mi.OSName @mi.OSVersion @System.Runtime.InteropServices.RuntimeInformation.OSArchitecture
|
| 处理器/核心数 |
@mi.Processor / @Environment.ProcessorCount 核 (占用:{{info.cpuRate}}%)
|
| 服务器内存 |
{{info.availableMemory}} (可用) / @((mi.Memory / 1024 / 1024).ToString("n0"))M (总) ({{info.memoryUsage}}% 空闲)
|
应用程序信息
| 本程序绝对路径 |
@ViewBag.contentPath
|
| 站点物理路径 |
@ViewBag.rootPath
|
| 服务器地址 |
@Utils.GetServerUrl():@(ViewBag.port)
|
| 客户端IP地址 |
@(Utils.GetIP())
|
.NET Core 信息
| .NET 版本 |
@Environment.Version
|
| 环境变量 |
@Html.Raw(env.EnvironmentName)
|
| 内存 |
工作/提交:{{info.workingSet64}}/{{info.privateMemorySize64}}
GC: {{info.gCMemory}} 释放内存
|
| 启动时间 |
@System.Diagnostics.Process.GetCurrentProcess().StartTime.ToString("yyyy-MM-dd HH:mm:ss")
|
}