diff --git a/app/controller/Domain.php b/app/controller/Domain.php index 425d25a..7bb3381 100644 --- a/app/controller/Domain.php +++ b/app/controller/Domain.php @@ -198,7 +198,7 @@ class Domain extends BaseController if (!empty($id)) { $select->where('A.id', $id); } elseif (!empty($kw)) { - $select->whereLike('name|A.remark', '%' . $kw . '%'); + $select->whereLike('A.name|A.remark', '%' . $kw . '%'); } if (!empty($aid)) { $select->where('A.aid', $aid); diff --git a/app/lib/cert/customacme.php b/app/lib/cert/customacme.php index 1467167..b41ae67 100644 --- a/app/lib/cert/customacme.php +++ b/app/lib/cert/customacme.php @@ -62,10 +62,14 @@ class customacme implements CertInterface $dnsList = []; if (!empty($order['challenges'])) { + $keys = []; foreach ($order['challenges'] as $opts) { + $key = $opts['key'] . '|' .$opts['value']; + if (in_array($key, $keys)) continue; $mainDomain = getMainDomain($opts['domain']); $name = substr($opts['key'], 0, -(strlen($mainDomain) + 1)); $dnsList[$mainDomain][] = ['name' => $name, 'type' => 'TXT', 'value' => $opts['value']]; + $keys[] = $key; } } diff --git a/app/lib/cert/litessl.php b/app/lib/cert/litessl.php index 3d529b6..11f07a9 100644 --- a/app/lib/cert/litessl.php +++ b/app/lib/cert/litessl.php @@ -59,13 +59,17 @@ class litessl implements CertInterface $dnsList = []; if (!empty($order['challenges'])) { + $keys = []; foreach ($order['challenges'] as $opts) { + $key = $opts['key'] . '|' .$opts['value']; + if (in_array($key, $keys)) continue; $mainDomain = getMainDomain($opts['domain']); $name = substr($opts['key'], 0, -(strlen($mainDomain) + 1)); /*if (!array_key_exists($mainDomain, $dnsList)) { $dnsList[$mainDomain][] = ['name' => '@', 'type' => 'CAA', 'value' => '0 issue "litessl.cn"']; }*/ $dnsList[$mainDomain][] = ['name' => $name, 'type' => 'TXT', 'value' => $opts['value']]; + $keys[] = $key; } } diff --git a/app/view/domain/account.html b/app/view/domain/account.html index 47cb63c..aa6445c 100644 --- a/app/view/domain/account.html +++ b/app/view/domain/account.html @@ -9,7 +9,7 @@