DNS更新任务增加域名更新

This commit is contained in:
GoEdgeLab
2021-01-28 15:39:10 +08:00
parent 9d641281e8
commit aa27e221a9
2 changed files with 10 additions and 0 deletions

View File

@@ -40,6 +40,7 @@ func (this *ListPopupAction) retrieveTasks() {
var clusterMap maps.Map = nil
var nodeMap maps.Map = nil
var serverMap maps.Map = nil
var domainMap maps.Map = nil
if task.NodeCluster != nil {
clusterMap = maps.Map{
@@ -59,6 +60,12 @@ func (this *ListPopupAction) retrieveTasks() {
"name": task.Server.Name,
}
}
if task.DnsDomain != nil {
domainMap = maps.Map{
"id": task.DnsDomain.Id,
"name": task.DnsDomain.Name,
}
}
taskMaps = append(taskMaps, maps.Map{
"id": task.Id,
@@ -70,6 +77,7 @@ func (this *ListPopupAction) retrieveTasks() {
"cluster": clusterMap,
"node": nodeMap,
"server": serverMap,
"domain": domainMap,
})
}
this.Data["tasks"] = taskMaps

View File

@@ -18,11 +18,13 @@
<span v-if="task.type == 'clusterChange'">{{task.cluster.name}}</span>
<span v-if="task.type == 'nodeChange'">{{task.node.name}}</span>
<span v-if="task.type == 'serverChange'">{{task.server.name}}</span>
<span v-if="task.type == 'domainChange'">{{task.domain.name}}</span>
</td>
<td>
<span v-if="task.type == 'clusterChange'">集群</span>
<span v-if="task.type == 'nodeChange'">节点</span>
<span v-if="task.type == 'serverChange'">服务</span>
<span v-if="task.type == 'domainChange'">域名</span>
</td>
<td>
<span v-if="task.isDone" class="red">{{task.error}}</span>