|
|
|
@ -9,36 +9,33 @@
|
|
|
|
|
var hasPermissions = (User.Identity as ClaimsIdentity).Claims.Any(o => o.Value.EndsWith($"-{scope}-{entityName}"));
|
|
|
|
|
}
|
|
|
|
|
<form action="" method="post" class="form-horizontal">
|
|
|
|
|
@if (hasPermissions)
|
|
|
|
|
{
|
|
|
|
|
<div class="card">
|
|
|
|
|
<div class="card-header">
|
|
|
|
|
网站配置
|
|
|
|
|
</div>
|
|
|
|
|
<div class="card-body">
|
|
|
|
|
<div class="pull-left">
|
|
|
|
|
<a class="btn btn-primary" href="@Url.Action("Add")">
|
|
|
|
|
新建
|
|
|
|
|
</a>
|
|
|
|
|
@*@if (User.IsInRole($"Edit-{entityName}"))
|
|
|
|
|
{
|
|
|
|
|
<button type="submit" class="confirm btn btn-primary" data-action="@Url.Action("Remove")">
|
|
|
|
|
移除
|
|
|
|
|
</button>
|
|
|
|
|
}
|
|
|
|
|
@if (User.IsInRole($"Edit-{entityName}"))
|
|
|
|
|
{
|
|
|
|
|
<button type="submit" class="confirm btn btn-primary" data-action="@Url.Action("Restore")">
|
|
|
|
|
还原
|
|
|
|
|
</button>
|
|
|
|
|
}*@
|
|
|
|
|
<button type="submit" class="confirm btn btn-danger" data-action="@Url.Action("Delete")">
|
|
|
|
|
删除
|
|
|
|
|
</button>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="card">
|
|
|
|
|
<div class="card-header">
|
|
|
|
|
网站配置
|
|
|
|
|
</div>
|
|
|
|
|
<div class="card-body">
|
|
|
|
|
<div class="pull-left">
|
|
|
|
|
<a class="btn btn-primary" href="@Url.Action("Add")">
|
|
|
|
|
新建
|
|
|
|
|
</a>
|
|
|
|
|
@*@if (User.IsInRole($"Edit-{entityName}"))
|
|
|
|
|
{
|
|
|
|
|
<button type="submit" class="confirm btn btn-primary" data-action="@Url.Action("Remove")">
|
|
|
|
|
移除
|
|
|
|
|
</button>
|
|
|
|
|
}
|
|
|
|
|
@if (User.IsInRole($"Edit-{entityName}"))
|
|
|
|
|
{
|
|
|
|
|
<button type="submit" class="confirm btn btn-primary" data-action="@Url.Action("Restore")">
|
|
|
|
|
还原
|
|
|
|
|
</button>
|
|
|
|
|
}*@
|
|
|
|
|
<button type="submit" class="confirm btn btn-danger" data-action="@Url.Action("Delete")">
|
|
|
|
|
删除
|
|
|
|
|
</button>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
}
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="card">
|
|
|
|
|
<div class="card-body">
|
|
|
|
|