[Web] Set desc == domain name, when desc is empty, implements #3341

master
andryyy 2020-02-21 08:59:50 +01:00
parent b9d7519ec2
commit ebf292531d
No known key found for this signature in database
GPG Key ID: 8EC34FF2794E25EF
2 changed files with 4 additions and 1 deletions

View File

@ -324,6 +324,9 @@ function mailbox($_action, $_type, $_data = null, $_extra = null) {
}
$domain = idn_to_ascii(strtolower(trim($_data['domain'])), 0, INTL_IDNA_VARIANT_UTS46);
$description = $_data['description'];
if (empty($description)) {
$description = $domain;
}
$aliases = $_data['aliases'];
$mailboxes = $_data['mailboxes'];
$defquota = $_data['defquota'];

View File

@ -95,7 +95,7 @@ if (!isset($_SESSION['mailcow_cc_role'])) {
<div class="form-group">
<label class="control-label col-sm-2" for="description"><?=$lang['add']['description'];?></label>
<div class="col-sm-10">
<input type="text" class="form-control" name="description" required>
<input type="text" class="form-control" name="description">
</div>
</div>
<div class="form-group">