|
1 | 1 | @page
|
| 2 | +@using Metalama.Backstage.Pages.Shared |
2 | 3 | @using Metalama.Backstage.UserInterface
|
3 | 4 | @model ConsentsPageModel
|
4 | 5 | @inject WebLinks WebLinks;
|
|
21 | 22 | $('#AcceptAll').change(function() {
|
22 | 23 | // Check or uncheck all other checkboxes based on 'Accept All' state
|
23 | 24 | var isChecked = $(this).is(':checked');
|
24 |
| - $('input[type="checkbox"]').not(this).prop('checked', isChecked); |
| 25 | + $('input[type="checkbox"]:enabled').not(this).prop('checked', isChecked); |
25 | 26 | });
|
26 | 27 |
|
27 | 28 |
|
|
32 | 33 | <form method="post">
|
33 | 34 | @if (Model.IsDeviceOnline)
|
34 | 35 | {
|
35 |
| - <input id="recaptchaResponse" type="hidden" asp-for="RecaptchaResponse "/> |
| 36 | + <input id="recaptchaResponse" type="hidden" asp-for="RecaptchaResponse"/> |
36 | 37 |
|
37 | 38 | <div class="checkbox">
|
38 |
| - <input id="subscribeToNewsletterCheckbox" type="checkbox" asp-for="SubscribeToNewsletter "> |
| 39 | + <input id="subscribeToNewsletterCheckbox" type="checkbox" asp-for="SubscribeToNewsletter"> |
39 | 40 | <div class="label">
|
40 | 41 | <p>
|
41 |
| - <label asp-for="SubscribeToNewsletter ">Subscribe to the Metalama newsletter and the welcome e-mail course.</label> |
| 42 | + <label asp-for="SubscribeToNewsletter">Subscribe to the Metalama newsletter and the welcome e-mail course.</label> |
42 | 43 | <small>You can unsubscribe or change your preferences at any time.</small>
|
43 | 44 | </p>
|
44 | 45 | <p>
|
45 |
| - <label asp-for="EmailAddress ">Email:</label> <input type="text" asp-for="EmailAddress "> |
| 46 | + <label asp-for="EmailAddress">Email:</label> <input type="text" asp-for="EmailAddress"> |
46 | 47 | </p>
|
47 | 48 |
|
48 | 49 | </div>
|
49 | 50 | </div>
|
50 | 51 | }
|
51 | 52 | <div class="checkbox">
|
52 |
| - <input type="checkbox" asp-for="EnableTelemetry "> |
| 53 | + @{ |
| 54 | + var mandatoryTelemetry = GlobalState.LicenseKind == LicenseKind.Community; |
| 55 | + } |
| 56 | + |
| 57 | + <input type="checkbox" asp-for="EnableTelemetry" checked="@mandatoryTelemetry" disabled="@mandatoryTelemetry"> |
53 | 58 | <div class="label">
|
54 |
| - <label asp-for="EnableTelemetry ">Help improve Metalama by sending <a href="@WebLinks.PrivacyPolicy" target="_blank">anonymous usage and performance statistics</a>.</label> |
| 59 | + <label asp-for="EnableTelemetry"> |
| 60 | + Help improve Metalama by sending <a href="@WebLinks.PrivacyPolicy" target="_blank">anonymous usage and performance statistics</a>. |
| 61 | + |
| 62 | + @if (mandatoryTelemetry) |
| 63 | + { |
| 64 | + <small>Telemetry is mandatory for Metalama Community users.</small> |
| 65 | + } |
| 66 | + </label> |
55 | 67 | </div>
|
56 | 68 | </div>
|
57 | 69 |
|
58 | 70 | <div class="checkbox">
|
59 |
| - <input type="checkbox" asp-for="AcceptLicense "> |
| 71 | + <input type="checkbox" asp-for="AcceptLicense"> |
60 | 72 | <div class="label">
|
61 |
| - <label asp-for="AcceptLicense "> |
| 73 | + <label asp-for="AcceptLicense"> |
62 | 74 | I accept the terms of the <a href="@WebLinks.LicenseAgreement" target="_blank">License Agreement</a> and the <a href="@WebLinks.PrivacyPolicy" target="_blank">Privacy Policy</a>. I understand
|
63 | 75 | that the software is subject to License Audit and I consent with the collection of usage data.
|
64 | 76 | </label>
|
|
0 commit comments