优化申请证书界面

This commit is contained in:
GoEdgeLab
2022-10-27 19:44:50 +08:00
parent 1c0a2967f9
commit 7549ecd649
5 changed files with 13 additions and 5 deletions

View File

@@ -15,7 +15,11 @@ func (this *CreatePopupAction) Init() {
this.Nav("", "", "")
}
func (this *CreatePopupAction) RunGet(params struct{}) {
func (this *CreatePopupAction) RunGet(params struct {
ProviderCode string
}) {
this.Data["providerCode"] = params.ProviderCode
// 服务商
providersResp, err := this.RPC().ACMEProviderRPC().FindAllACMEProviders(this.AdminContext(), &pb.FindAllACMEProvidersRequest{})
if err != nil {

View File

@@ -9,6 +9,7 @@
<td>账号名称 *</td>
<td>
<input type="text" name="name" maxlength="50" ref="focus" tabindex="1"/>
<p class="comment">为当前账号起一个容易识别的名称。</p>
</td>
</tr>
<tr>

View File

@@ -124,7 +124,7 @@
</td>
</tr>
<tr>
<td>证书域名列表 *</td>
<td class="title">证书域名列表 *</td>
<td>
<values-box name="" placeholder="域名" size="30" @change="changeDomains"></values-box>
<p class="comment">需要申请的证书中包含的域名列表<span v-if="authType == 'dns'">,所有域名必须是同一个顶级域名</span><span v-if="authType == 'http'">使用HTTP认证方式时域名中不能含有通配符</span></p>

View File

@@ -27,8 +27,8 @@ Tea.context(function () {
this.createUser = function () {
let that = this
teaweb.popup("/servers/certs/acme/users/createPopup", {
height: "27em",
teaweb.popup("/servers/certs/acme/users/createPopup?providerCode=" + this.providerCode, {
height: "30em",
width: "44em",
callback: function (resp) {
teaweb.successToast("创建成功")

View File

@@ -1,5 +1,4 @@
Tea.context(function () {
this.providerCode = ""
this.selectedProvider = null
this.accounts = []
this.accountId = 0
@@ -30,6 +29,10 @@ Tea.context(function () {
})
}
if (this.providerCode.length > 0) {
this.changeProvider()
}
this.addAccount = function () {
let that = this
teaweb.popup("/servers/certs/acme/accounts/createPopup?providerCode=" + this.providerCode, {