mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-03 20:40:26 +08:00
[安装]安装时可以选择手工输入API地址
This commit is contained in:
@@ -8,7 +8,6 @@ var isConfigured bool
|
||||
|
||||
// 判断系统是否已经配置过
|
||||
func IsConfigured() bool {
|
||||
return false//TODO
|
||||
if isConfigured {
|
||||
return true
|
||||
}
|
||||
|
||||
@@ -82,13 +82,20 @@
|
||||
<tr>
|
||||
<td>节点主机地址</td>
|
||||
<td>
|
||||
<div v-if="serverIPs.length > 0">
|
||||
<div class="ui fields inline">
|
||||
<div class="ui field">
|
||||
<div v-if="serverIPs.length > 0 && !apiHostInput">
|
||||
<select name="newHost" class="ui dropdown auto-width">
|
||||
<option v-for="ip in serverIPs" :value="ip">{{ip}}</option>
|
||||
</select>
|
||||
</div>
|
||||
<div v-else="">
|
||||
<input type="text" name="newHost" value=""/>
|
||||
<input type="text" name="newHost" value="" ref="newHostRef" placeholder="x.x.x.x"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ui field">
|
||||
<a href="" v-if="!apiHostInput" @click.prevent="inputAPIHost()">[手工输入]</a>
|
||||
</div>
|
||||
</div>
|
||||
<p class="comment">其他节点访问此API节点的主机地址,可以是IP或者域名,第一次安装时通常是<strong>当前服务器</strong>的IP地址。后期可以修改这个地址。</p>
|
||||
</td>
|
||||
|
||||
@@ -18,6 +18,8 @@ Tea.context(function () {
|
||||
this.newAPINodePort = "8001"
|
||||
this.apiRequesting = false
|
||||
|
||||
this.apiHostInput = false // 是否手工输入
|
||||
|
||||
this.apiSubmit = function () {
|
||||
this.apiRequesting = true
|
||||
}
|
||||
@@ -41,6 +43,13 @@ Tea.context(function () {
|
||||
this.step = this.STEP_INTRO
|
||||
}
|
||||
|
||||
this.inputAPIHost = function () {
|
||||
this.apiHostInput = true
|
||||
this.$delay(function () {
|
||||
this.$refs.newHostRef.focus()
|
||||
})
|
||||
}
|
||||
|
||||
// 数据库
|
||||
this.dbInfo = {}
|
||||
this.dbRequesting = false
|
||||
|
||||
Reference in New Issue
Block a user