mirror of
https://github.com/mailcow/mailcow-dockerized.git
synced 2026-08-10 16:26:19 -04:00
feat(user): add checkbox to include aliases in mobileconfig links
This commit is contained in:
parent
88d20055bb
commit
553a3bee5d
2 changed files with 27 additions and 4 deletions
|
|
@ -701,4 +701,18 @@ jQuery(function($){
|
|||
onVisible("[id^=sync_job_table]", () => draw_sync_job_table());
|
||||
onVisible("[id^=app_passwd_table]", () => draw_app_passwd_table());
|
||||
onVisible("[id^=recent-logins]", () => last_logins('get'));
|
||||
|
||||
// Toggle aliases in mobileconfig links
|
||||
$('#mobileconfig-with-aliases').on('change', function() {
|
||||
$('.mobileconfig-link').each(function() {
|
||||
var url = new URL($(this).attr('href'), window.location.origin);
|
||||
if ($('#mobileconfig-with-aliases').is(':checked')) {
|
||||
url.searchParams.set('with_aliases', '');
|
||||
} else {
|
||||
url.searchParams.delete('with_aliases');
|
||||
}
|
||||
var query = url.searchParams.toString();
|
||||
$(this).attr('href', query ? url.pathname + '?' + query : url.pathname);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
|
|||
|
|
@ -67,12 +67,12 @@
|
|||
<div class="col-12 col-md-8">
|
||||
<div class="d-flex">
|
||||
<i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill me-2" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.user.apple_connection_profile_mailonly }}"></i>
|
||||
<a href="/mobileconfig.php?only_email">{{ lang.user.email }} <small>[IMAP, SMTP]</small></a>
|
||||
<a class="mobileconfig-link" href="/mobileconfig.php?only_email">{{ lang.user.email }} <small>[IMAP, SMTP]</small></a>
|
||||
</div>
|
||||
{% if not skip_sogo %}
|
||||
<div class="d-flex">
|
||||
<i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill me-2" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.user.apple_connection_profile_complete }}"></i>
|
||||
<a href="/mobileconfig.php">{{ lang.user.email_and_dav }} <small>[IMAP, SMTP, Cal/CardDAV]</small></a>
|
||||
<a class="mobileconfig-link" href="/mobileconfig.php">{{ lang.user.email_and_dav }} <small>[IMAP, SMTP, Cal/CardDAV]</small></a>
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
|
@ -84,16 +84,25 @@
|
|||
<div class="col-12 col-md-9">
|
||||
<div class="d-flex">
|
||||
<i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill me-2" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.user.apple_connection_profile_mailonly }} {{ lang.user.apple_connection_profile_with_app_password }}"></i>
|
||||
<a href="/mobileconfig.php?only_email&app_password">{{ lang.user.email }} <small>[IMAP, SMTP]</small></a>
|
||||
<a class="mobileconfig-link" href="/mobileconfig.php?only_email&app_password">{{ lang.user.email }} <small>[IMAP, SMTP]</small></a>
|
||||
</div>
|
||||
{% if not skip_sogo %}
|
||||
<div class="d-flex">
|
||||
<i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill me-2" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.user.apple_connection_profile_complete }} {{ lang.user.apple_connection_profile_with_app_password }}"></i>
|
||||
<a href="/mobileconfig.php?app_password">{{ lang.user.email_and_dav }} <small>[IMAP, SMTP, Cal/CardDAV]</small></a>
|
||||
<a class="mobileconfig-link" href="/mobileconfig.php?app_password">{{ lang.user.email_and_dav }} <small>[IMAP, SMTP, Cal/CardDAV]</small></a>
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col-12 col-md-3 d-flex"></div>
|
||||
<div class="col-12 col-md-9">
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="checkbox" id="mobileconfig-with-aliases">
|
||||
<label class="form-check-label" for="mobileconfig-with-aliases">{{ lang.user.apple_connection_profile_include_aliases }}</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-12 d-flex flex-column text-center align-items-center mt-4">
|
||||
<a target="_blank" href="https://mailcow.github.io/mailcow-dockerized-docs/client/client/#{{ clientconfigstr }}">{{ lang.user.client_configuration }}</a>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue