feat: Globale Konstante isReadOnly-Wert erstellt.
- Constraint für ReadOnly-Schaltfläche mit isReadOnly-Wert hinzugefügt
This commit is contained in:
@@ -3,6 +3,10 @@
|
||||
@using Newtonsoft.Json.Serialization
|
||||
@{
|
||||
var nonce = _accessor.HttpContext?.Items["csp-nonce"] as string;
|
||||
|
||||
var isReadOnly = false;
|
||||
if (ViewData["IsReadOnly"] is bool isReadOnly_bool)
|
||||
isReadOnly = isReadOnly_bool;
|
||||
}
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
@@ -27,10 +31,15 @@
|
||||
font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24
|
||||
}
|
||||
</style>
|
||||
|
||||
<script nonce="@nonce">
|
||||
@if (ViewData["EnvelopeKey"] is string envelopeKey)
|
||||
{
|
||||
<script nonce="@nonce">const ENV_KEY = "@envelopeKey.TrySanitize(_sanitizer)"</script>
|
||||
@: const ENV_KEY = "@envelopeKey.TrySanitize(_sanitizer)"
|
||||
}
|
||||
const IS_READONLY = @isReadOnly.ToString().ToLower();
|
||||
</script>
|
||||
|
||||
<script src="~/lib/jquery/dist/jquery.min.js"></script>
|
||||
<script src="~/lib/popper/dist/umd/popper.min.js"></script>
|
||||
<script src="~/lib/bootstrap/dist/js/bootstrap.min.js"></script>
|
||||
|
||||
Reference in New Issue
Block a user