You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by pa...@apache.org on 2020/07/21 09:32:54 UTC

[shardingsphere-elasticjob-ui] 07/29: Add help page

This is an automated email from the ASF dual-hosted git repository.

panjuan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere-elasticjob-ui.git

commit b01bfcc10635fed41ee56b3b6c01db7c68ddd3ae
Author: menghaoranss <lo...@163.com>
AuthorDate: Fri Jul 17 17:16:52 2020 +0800

    Add help page
---
 shardingsphere-elasticjob-ui-frontend/package.json |   2 -
 .../src/components/ChartBase/index.vue             | 305 ---------------------
 .../src/lang/en-US.js                              |  98 +------
 .../src/lang/zh-CN.js                              |  98 +------
 .../src/router/index.js                            |   6 +
 .../src/views/help/index.vue                       |  48 ++++
 .../registry-center/module/registryCenter.vue      | 125 +--------
 7 files changed, 81 insertions(+), 601 deletions(-)

diff --git a/shardingsphere-elasticjob-ui-frontend/package.json b/shardingsphere-elasticjob-ui-frontend/package.json
index 2758060..5c6b1f4 100644
--- a/shardingsphere-elasticjob-ui-frontend/package.json
+++ b/shardingsphere-elasticjob-ui-frontend/package.json
@@ -14,8 +14,6 @@
   },
   "dependencies": {
     "axios": "^0.18.0",
-    "echarts": "^4.6.0",
-    "echarts-liquidfill": "^2.0.5",
     "element-ui": "^2.4.9",
     "js-yaml": "^3.12.0",
     "lodash": "^4.17.11",
diff --git a/shardingsphere-elasticjob-ui-frontend/src/components/ChartBase/index.vue b/shardingsphere-elasticjob-ui-frontend/src/components/ChartBase/index.vue
deleted file mode 100644
index 81817e5..0000000
--- a/shardingsphere-elasticjob-ui-frontend/src/components/ChartBase/index.vue
+++ /dev/null
@@ -1,305 +0,0 @@
-<!--
-  - Licensed to the Apache Software Foundation (ASF) under one or more
-  - contributor license agreements.  See the NOTICE file distributed with
-  - this work for additional information regarding copyright ownership.
-  - The ASF licenses this file to You under the Apache License, Version 2.0
-  - (the "License") you may not use this file except in compliance with
-  - the License.  You may obtain a copy of the License at
-  -
-  -     http://www.apache.org/licenses/LICENSE-2.0
-  -
-  - Unless required by applicable law or agreed to in writing, software
-  - distributed under the License is distributed on an "AS IS" BASIS,
-  - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-  - See the License for the specific language governing permissions and
-  - limitations under the License.
-  -->
-
-<template>
-  <div class="echarts"></div>
-</template>
-
-<script>
-import echarts from 'echarts'
-import debounce from 'lodash/debounce'
-import { addListener, removeListener } from 'resize-detector'
-import Vue from 'vue'
-
-// enumerating ECharts events for now
-const EVENTS = [
-  'legendselectchanged',
-  'legendselected',
-  'legendunselected',
-  'datazoom',
-  'datarangeselected',
-  'timelinechanged',
-  'timelineplaychanged',
-  'restore',
-  'dataviewchanged',
-  'magictypechanged',
-  'geoselectchanged',
-  'geoselected',
-  'geounselected',
-  'pieselectchanged',
-  'pieselected',
-  'pieunselected',
-  'mapselectchanged',
-  'mapselected',
-  'mapunselected',
-  'axisareaselected',
-  'focusnodeadjacency',
-  'unfocusnodeadjacency',
-  'brush',
-  'brushselected',
-  'click',
-  'dblclick',
-  'mouseover',
-  'mouseout',
-  'mousedown',
-  'mouseup',
-  'globalout'
-]
-
-export default {
-  props: {
-    options: {
-      type: Object,
-      default() {
-        return {}
-      }
-    },
-    theme: {
-      type: [String, Object],
-      default: ''
-    },
-    initOptions: {
-      type: Object,
-      default() {
-        return {}
-      }
-    },
-    group: {
-      type: String,
-      default: ''
-    },
-    autoResize: {
-      type: Boolean,
-      default: true
-    },
-    watchShallow: {
-      type: Boolean,
-      default: false
-    }
-  },
-  data() {
-    return {
-      chart: null
-    }
-  },
-  computed: {
-    // Only recalculated when accessed from JavaScript.
-    // Won't update DOM on value change because getters
-    // don't depend on reactive values
-    width: {
-      cache: false,
-      get() {
-        return this.delegateGet('width', 'getWidth')
-      }
-    },
-    height: {
-      cache: false,
-      get() {
-        return this.delegateGet('height', 'getHeight')
-      }
-    },
-    isDisposed: {
-      cache: false,
-      get() {
-        return !!this.delegateGet('isDisposed', 'isDisposed')
-      }
-    },
-    computedOptions: {
-      cache: false,
-      get() {
-        return this.delegateGet('computedOptions', 'getOption')
-      }
-    }
-  },
-  watch: {
-    group(group) {
-      this.chart.group = group
-    }
-  },
-  created() {
-    this.$watch(
-      'options',
-      options => {
-        if (!this.chart && options) {
-          this.init()
-        } else {
-          this.chart.setOption(this.options, true)
-        }
-      },
-      { deep: !this.watchShallow }
-    )
-    const watched = ['theme', 'initOptions', 'autoResize', 'watchShallow']
-    watched.forEach(prop => {
-      this.$watch(
-        prop,
-        () => {
-          this.refresh()
-        },
-        { deep: true }
-      )
-    })
-  },
-  mounted() {
-    // auto init if `options` is already provided
-    if (this.options) {
-      this.init()
-    }
-  },
-  activated() {
-    if (this.autoResize) {
-      this.chart && this.chart.resize()
-    }
-  },
-  beforeDestroy() {
-    if (!this.chart) {
-      return
-    }
-    this.destroy()
-  },
-  methods: {
-    // provide a explicit merge option method
-    mergeOptions(options, notMerge, lazyUpdate) {
-      this.delegateMethod('setOption', options, notMerge, lazyUpdate)
-    },
-    // just delegates ECharts methods to Vue component
-    // use explicit params to reduce transpiled size for now
-    appendData(params) {
-      this.delegateMethod('appendData', params)
-    },
-    resize(options) {
-      this.delegateMethod('resize', options)
-    },
-    dispatchAction(payload) {
-      this.delegateMethod('dispatchAction', payload)
-    },
-    convertToPixel(finder, value) {
-      return this.delegateMethod('convertToPixel', finder, value)
-    },
-    convertFromPixel(finder, value) {
-      return this.delegateMethod('convertFromPixel', finder, value)
-    },
-    containPixel(finder, value) {
-      return this.delegateMethod('containPixel', finder, value)
-    },
-    showLoading(type, options) {
-      this.delegateMethod('showLoading', type, options)
-    },
-    hideLoading() {
-      this.delegateMethod('hideLoading')
-    },
-    getDataURL(options) {
-      return this.delegateMethod('getDataURL', options)
-    },
-    getConnectedDataURL(options) {
-      return this.delegateMethod('getConnectedDataURL', options)
-    },
-    clear() {
-      this.delegateMethod('clear')
-    },
-    dispose() {
-      this.delegateMethod('dispose')
-    },
-    delegateMethod(name, ...args) {
-      if (!this.chart) {
-        Vue.util.warn(
-          `Cannot call [${name}] before the chart is initialized. Set prop [options] first.`,
-          this
-        )
-        return
-      }
-      return this.chart[name](...args)
-    },
-    delegateGet(name, method) {
-      if (!this.chart) {
-        Vue.util.warn(
-          `Cannot get [${name}] before the chart is initialized. Set prop [options] first.`,
-          this
-        )
-      }
-      return this.chart[method]()
-    },
-    init() {
-      if (this.chart) {
-        return
-      }
-
-      const chart = echarts.init(this.$el, this.theme, this.initOptions)
-
-      if (this.group) {
-        chart.group = this.group
-      }
-
-      chart.setOption(this.options, true)
-
-      // expose ECharts events as custom events
-      EVENTS.forEach(event => {
-        chart.on(event, params => {
-          this.$emit(event, params)
-        })
-      })
-
-      if (this.autoResize) {
-        this.__resizeHanlder = debounce(
-          () => {
-            chart.resize()
-          },
-          100,
-          { leading: true }
-        )
-        addListener(this.$el, this.__resizeHanlder)
-      }
-
-      this.chart = chart
-    },
-    destroy() {
-      if (this.autoResize) {
-        removeListener(this.$el, this.__resizeHanlder)
-      }
-      this.dispose()
-      this.chart = null
-    },
-    refresh() {
-      this.destroy()
-      this.init()
-    }
-  },
-  connect(group) {
-    if (typeof group !== 'string') {
-      group = group.map(chart => chart.chart)
-    }
-    echarts.connect(group)
-  },
-  disconnect(group) {
-    echarts.disConnect(group)
-  },
-  registerMap(mapName, geoJSON, specialAreas) {
-    echarts.registerMap(mapName, geoJSON, specialAreas)
-  },
-  registerTheme(name, theme) {
-    echarts.registerTheme(name, theme)
-  },
-  graphic: echarts.graphic,
-  format: echarts.format
-}
-</script>
-
-<style>
-.echarts {
-  width: auto;
-  height: 400px;
-}
-</style>
diff --git a/shardingsphere-elasticjob-ui-frontend/src/lang/en-US.js b/shardingsphere-elasticjob-ui-frontend/src/lang/en-US.js
index 7dff279..0b7ca29 100644
--- a/shardingsphere-elasticjob-ui-frontend/src/lang/en-US.js
+++ b/shardingsphere-elasticjob-ui-frontend/src/lang/en-US.js
@@ -163,91 +163,17 @@ export default {
       password: 'Please enter the password of the data source'
     }
   },
-  runtimeStatus: {
-    serviceNode: 'Service Node',
-    slaveDataSourceName: 'Slave DataSource Info',
-    dataSource: {
-      schema: 'Schema',
-      masterDataSourceName: 'Master DataSource Name',
-      slaveDataSourceName: 'Slave DataSource Name'
-    },
-    instance: {
-      instanceId: 'Instance Id',
-      serverIp: 'Server Ip'
-    }
-  },
-  ruleConfig: {
-    form: {
-      inputPlaceholder: 'Please enter content'
-    },
-    schema: {
-      title: 'Add Schema',
-      name: 'Name',
-      ruleConfig: 'Rule Config',
-      dataSourceConfig: 'Data Source Config'
-    },
-    schemaRules: {
-      name: 'Please enter the name of the schema',
-      ruleConfig: 'Please enter the rule config of the schema',
-      dataSourceConfig: 'Please enter the data source config of the schema'
-    },
-    radioBtn: {
-      schema: 'Schema',
-      authentication: 'Authentication',
-      props: 'Props'
-    }
-  },
-  dataScaling: {
-    btnTxt: 'ADD',
-    tableList: {
-      jobId: 'jobId',
-      jobName: 'jobName',
-      status: 'status',
-      operate: 'operate',
-      operateStop: 'stop',
-      operateSee: 'see'
-    },
-    registDialog: {
-      title: 'Add a job',
-      source: 'Source',
-      target: 'Target',
-      jobCount: 'JobCount',
-      jobCountPlaceholder: 'Please enter jobCount',
-      username: 'Username',
-      usernamePlaceholder: 'Please enter username',
-      password: 'Password',
-      passwordPlaceholder: 'Please enter password',
-      url: 'Url',
-      urlPlaceholder: 'Please enter url',
-      btnConfirmTxt: 'Confirm',
-      btnCancelTxt: 'Cancel'
-    },
-    rules: {
-      source: 'Please select the source of the registration center',
-      target: 'Please select a target',
-      serviceUrl: 'ServiceUrl must fill'
-    },
-    notify: {
-      title: 'Prompt',
-      conSucMessage: 'Add Succeeded',
-      conFailMessage: 'Add Failed',
-      delSucMessage: 'Delete Succeeded',
-      delFailMessage: 'Delete Failed'
-    },
-    serviceDialog: {
-      title: 'Data Scaling Setting',
-      serviceName: 'Service Name',
-      serviceUrl: 'Service Url',
-      serviceNamePlaceholder: 'Please enter serviceName',
-      serviceUrlPlaceholder: 'Please enter serviceUrl'
-    }
-  },
-  clusterState: {
-    legendLabel: {
-      onLine: 'ONLINE',
-      offLine: 'OFFLINE',
-      disabled: 'DISABLED',
-      unknown: 'UNKNOWN'
-    }
+  help: {
+    design_concept_title: 'Design concept',
+    design_concept_info_1: 'Console is not related to Elastic Job, it just reading data from registry center and showing the status of jobs, or updating data to registry center which will change the configuration.',
+    design_concept_info_2: "Console can operate lifecycle for jobs, such as enable and disable, but can not the start and stop job's process, because of console server and job servers are completely distributed, console can not control the job servers.",
+    major_features_title: 'Major features',
+    major_features_info_1: 'View status of jobs and servers',
+    major_features_info_2: 'Quick update and delete jobs',
+    major_features_info_3: 'Disable and enable Jobs',
+    major_features_info_4: 'Multiple registry centers supported',
+    major_features_info_5: 'Trace jobs execute history',
+    unsupported_title: 'Unsupported',
+    unsupported_info: 'Add job. Because of job is added at first running time automatically, it is unnecessary to add job from console. So just start the job app.'
   }
 }
diff --git a/shardingsphere-elasticjob-ui-frontend/src/lang/zh-CN.js b/shardingsphere-elasticjob-ui-frontend/src/lang/zh-CN.js
index 7e02847..dc8f255 100644
--- a/shardingsphere-elasticjob-ui-frontend/src/lang/zh-CN.js
+++ b/shardingsphere-elasticjob-ui-frontend/src/lang/zh-CN.js
@@ -163,91 +163,17 @@ export default {
       password: '请输入数据源密码'
     }
   },
-  runtimeStatus: {
-    serviceNode: '服务节点',
-    slaveDataSourceName: '从库信息',
-    dataSource: {
-      schema: '逻辑库名',
-      masterDataSourceName: '主库名',
-      slaveDataSourceName: '从库名'
-    },
-    instance: {
-      instanceId: '节点标识',
-      serverIp: '服务ip'
-    }
-  },
-  ruleConfig: {
-    form: {
-      inputPlaceholder: '请输入内容'
-    },
-    schema: {
-      title: '添加Schema',
-      name: '名称',
-      ruleConfig: '分片配置规则',
-      dataSourceConfig: '数据源配置规则'
-    },
-    schemaRules: {
-      name: '请输入名称',
-      ruleConfig: '请输入数据分片配置规则',
-      dataSourceConfig: '请输入数据源配置规则'
-    },
-    radioBtn: {
-      schema: '数据源',
-      authentication: '认证信息',
-      props: '属性配置'
-    }
-  },
-  dataScaling: {
-    btnTxt: '添加',
-    tableList: {
-      jobId: '任务Id',
-      jobName: '任务名称',
-      status: '状态',
-      operate: '操作',
-      operateStop: '停止',
-      operateSee: '查看'
-    },
-    registDialog: {
-      title: '添加一个任务',
-      source: '源',
-      target: '目标',
-      jobCount: '任务数量',
-      jobCountPlaceholder: '请输入任务数量',
-      username: '用户名',
-      usernamePlaceholder: '请输入用户名',
-      password: '密码',
-      passwordPlaceholder: '请输入密码',
-      url: '地址',
-      urlPlaceholder: '请输入 url',
-      btnConfirmTxt: '确认',
-      btnCancelTxt: '取消'
-    },
-    rules: {
-      source: '请选择注册中心的来源',
-      target: '请选择目标',
-      serviceUrl: '服务地址必填'
-    },
-    notify: {
-      title: '提示',
-      conSucMessage: '添加成功',
-      conFailMessage: '添加失败',
-      delSucMessage: '删除成功',
-      delFailMessage: '删除失败'
-    },
-    serviceDialog: {
-      title: '数据扩容配置',
-      serviceName: '服务名称',
-      serviceUrl: '服务地址',
-      serviceNamePlaceholder: '请输入服务名称',
-      serviceUrlPlaceholder: '请输入服务地址'
-    }
-  },
-  clusterState: {
-    legendLabel: {
-      onLine: '正常',
-      offLine: '下线',
-      disabled: '禁用',
-      unknown: '未知'
-    }
+  help: {
+    design_concept_title: '设计理念',
+    design_concept_info_1: '本控制台和Elastic Job并无直接关系,是通过读取Elastic Job的注册中心数据展现作业状态,或更新注册中心数据修改全局配置。',
+    design_concept_info_2: '控制台只能控制作业本身是否运行,但不能控制作业进程的启停,因为控制台和作业本身服务器是完全分布式的,控制台并不能控制作业服务器。',
+    major_features_title: '主要功能',
+    major_features_info_1: '查看作业以及服务器状态',
+    major_features_info_2: '快捷的修改以及删除作业设置',
+    major_features_info_3: '启用和禁用作业',
+    major_features_info_4: '跨注册中心查看作业',
+    major_features_info_5: '查看作业运行轨迹和运行状态',
+    unsupported_title: '不支持项',
+    unsupported_info: '添加作业。因为作业都是在首次运行时自动添加,使用控制台添加作业并无必要。直接在作业服务器启动包含Elastic Job的作业进程即可。',
   }
 }
diff --git a/shardingsphere-elasticjob-ui-frontend/src/router/index.js b/shardingsphere-elasticjob-ui-frontend/src/router/index.js
index f8780fa..8e74cf0 100644
--- a/shardingsphere-elasticjob-ui-frontend/src/router/index.js
+++ b/shardingsphere-elasticjob-ui-frontend/src/router/index.js
@@ -38,6 +38,12 @@ export const constantRouterMap = [
     hidden: true,
     name: 'Data source'
   },
+  {
+    path: '/job-help',
+    component: () => import('@/views/help'),
+    hidden: true,
+    name: 'Help'
+  },
 ]
 
 export default new Router({
diff --git a/shardingsphere-elasticjob-ui-frontend/src/views/help/index.vue b/shardingsphere-elasticjob-ui-frontend/src/views/help/index.vue
new file mode 100644
index 0000000..a6874d8
--- /dev/null
+++ b/shardingsphere-elasticjob-ui-frontend/src/views/help/index.vue
@@ -0,0 +1,48 @@
+<!--
+  - Licensed to the Apache Software Foundation (ASF) under one or more
+  - contributor license agreements.  See the NOTICE file distributed with
+  - this work for additional information regarding copyright ownership.
+  - The ASF licenses this file to You under the Apache License, Version 2.0
+  - (the "License"); you may not use this file except in compliance with
+  - the License.  You may obtain a copy of the License at
+  -
+  -     http://www.apache.org/licenses/LICENSE-2.0
+  -
+  - Unless required by applicable law or agreed to in writing, software
+  - distributed under the License is distributed on an "AS IS" BASIS,
+  - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  - See the License for the specific language governing permissions and
+  - limitations under the License.
+  -->
+
+<template>
+  <div class="help-content">
+    <section class="content">
+      <h2>{{$t('help.design_concept_title')}}</h2>
+      <ol>
+        <li>{{$t('help.design_concept_info_1')}}</li>
+        <li>{{$t('help.design_concept_info_2')}}</li>
+      </ol>
+      <h2>{{$t('help.major_features_title')}}</h2>
+      <ol>
+        <li>{{$t('help.major_features_info_1')}}</li>
+        <li>{{$t('help.major_features_info_2')}}</li>
+        <li>{{$t('help.major_features_info_3')}}</li>
+        <li>{{$t('help.major_features_info_4')}}</li>
+        <li>{{$t('help.major_features_info_5')}}</li>
+      </ol>
+      <h2>{{$t('help.unsupported_title')}}</h2>
+      <ol>
+        <li>{{$t('help.unsupported_info')}}</li>
+      </ol>
+    </section>
+  </div>
+</template>
+<style>
+  .help-content {
+    padding-top: 10px;
+  }
+  .help-content li {
+    list-style: inside;
+  }
+</style>
diff --git a/shardingsphere-elasticjob-ui-frontend/src/views/registry-center/module/registryCenter.vue b/shardingsphere-elasticjob-ui-frontend/src/views/registry-center/module/registryCenter.vue
index 14be74f..13669f8 100644
--- a/shardingsphere-elasticjob-ui-frontend/src/views/registry-center/module/registryCenter.vue
+++ b/shardingsphere-elasticjob-ui-frontend/src/views/registry-center/module/registryCenter.vue
@@ -36,20 +36,6 @@
         />
         <el-table-column :label="$t('registryCenter.table.operate')" fixed="right" width="200">
           <template slot-scope="scope">
-            <!--<el-tooltip
-              :content="$t('registryCenter.table.operateEdit')"
-              class="item"
-              effect="dark"
-              placement="top"
-            >
-              <el-button
-                :disabled="scope.row.activated"
-                size="small"
-                type="primary"
-                icon="el-icon-edit"
-                @click="handleEdit(scope.row)"
-              />
-            </el-tooltip>-->
             <el-tooltip
               :content="!scope.row.activated ? $t('registryCenter.table.operateConnect'): $t('registryCenter.table.operateConnected')"
               class="item"
@@ -98,12 +84,6 @@
         <el-form-item :label="$t('registryCenter.registDialog.name')" prop="name">
           <el-input :placeholder="$t('registryCenter.rules.name')" v-model="form.name" autocomplete="off" />
         </el-form-item>
-        <!--<el-form-item :label="$t('registryCenter.registDialog.centerType')" prop="instanceType">
-          <el-radio-group v-model="form.instanceType">
-            <el-radio label="Zookeeper">Zookeeper</el-radio>
-            <el-radio label="Etcd">Etcd</el-radio>
-          </el-radio-group>
-        </el-form-item>-->
         <el-form-item :label="$t('registryCenter.registDialog.address')" prop="serverLists">
           <el-input
             :placeholder="$t('registryCenter.rules.address')"
@@ -111,13 +91,6 @@
             autocomplete="off"
           />
         </el-form-item>
-        <!--<el-form-item :label="$t('registryCenter.registDialog.orchestrationName')" prop="orchestrationName">
-          <el-input
-            :placeholder="$t('registryCenter.rules.orchestrationName')"
-            v-model="form.orchestrationName"
-            autocomplete="off"
-          />
-        </el-form-item>-->
         <el-form-item :label="$t('registryCenter.registDialog.namespaces')" prop="namespace">
           <el-input
             :placeholder="$t('registryCenter.rules.namespaces')"
@@ -141,58 +114,6 @@
         >{{ $t("registryCenter.registDialog.btnConfirmTxt") }}</el-button>
       </div>
     </el-dialog>
-    <el-dialog
-      :title="$t('registryCenter.registDialog.editTitle')"
-      :visible.sync="editDialogVisible"
-      width="1010px"
-    >
-      <el-form ref="editForm" :model="editForm" :rules="rules" label-width="170px">
-        <el-form-item :label="$t('registryCenter.registDialog.name')" prop="name">
-          <el-input :placeholder="$t('registryCenter.rules.name')" v-model="editForm.name" autocomplete="off" />
-        </el-form-item>
-        <el-form-item :label="$t('registryCenter.registDialog.centerType')" prop="instanceType">
-          <el-radio-group v-model="editForm.instanceType">
-            <el-radio label="Zookeeper">Zookeeper</el-radio>
-            <el-radio label="Etcd">Etcd</el-radio>
-          </el-radio-group>
-        </el-form-item>
-        <el-form-item :label="$t('registryCenter.registDialog.address')" prop="serverLists">
-          <el-input
-            :placeholder="$t('registryCenter.rules.address')"
-            v-model="editForm.serverLists"
-            autocomplete="off"
-          />
-        </el-form-item>
-        <el-form-item :label="$t('registryCenter.registDialog.orchestrationName')" prop="orchestrationName">
-          <el-input
-            :placeholder="$t('registryCenter.rules.orchestrationName')"
-            v-model="editForm.orchestrationName"
-            autocomplete="off"
-          />
-        </el-form-item>
-        <el-form-item :label="$t('registryCenter.registDialog.namespaces')" prop="namespace">
-          <el-input
-            :placeholder="$t('registryCenter.rules.namespaces')"
-            v-model="editForm.namespace"
-            autocomplete="off"
-          />
-        </el-form-item>
-        <el-form-item :label="$t('registryCenter.registDialog.digest')">
-          <el-input
-            :placeholder="$t('registryCenter.rules.digest')"
-            v-model="editForm.digest"
-            autocomplete="off"
-          />
-        </el-form-item>
-      </el-form>
-      <div slot="footer" class="dialog-footer">
-        <el-button @click="cancelEdit">{{ $t("registryCenter.registDialog.btnCancelTxt") }}</el-button>
-        <el-button
-          type="primary"
-          @click="confirmEdit('editForm')"
-        >{{ $t("registryCenter.registDialog.btnConfirmTxt") }}</el-button>
-      </div>
-    </el-dialog>
   </el-row>
 </template>
 <script>
@@ -203,8 +124,7 @@ export default {
   name: 'RegistryCenter',
   data() {
     return {
-      regustDialogVisible: false,
-      editDialogVisible: false,
+      addDialogVisible: false,
       column: [
         {
           label: this.$t('registryCenter').registDialog.name,
@@ -223,19 +143,6 @@ export default {
         name: '',
         zkAddressList: '',
         namespace: '',
-        // instanceType: 'Zookeeper',
-        // orchestrationName: '',
-        // orchestrationType: 'registry_center',
-        digest: ''
-      },
-      editForm: {
-        primaryName: '',
-        name: '',
-        serverLists: '',
-        namespace: '',
-        instanceType: 'Zookeeper',
-        orchestrationName: '',
-        orchestrationType: 'registry_center',
         digest: ''
       },
       rules: {
@@ -343,7 +250,7 @@ export default {
       this.$refs[formName].validate(valid => {
         if (valid) {
           API.postRegCenter(this.form).then(res => {
-            this.regustDialogVisible = false
+            this.addDialogVisible = false
             this.$notify({
               title: this.$t('common').notify.title,
               message: this.$t('common').notify.addSucMessage,
@@ -358,33 +265,7 @@ export default {
       })
     },
     add() {
-      this.regustDialogVisible = true
-    },
-    handleEdit(row) {
-      this.editDialogVisible = true
-      this.editForm = Object.assign({}, row)
-      this.editForm.primaryName = row.name
-    },
-    confirmEdit(formName) {
-      this.$refs[formName].validate(valid => {
-        if (valid) {
-          API.updateRegCenter(this.editForm).then(res => {
-            this.editDialogVisible = false
-            this.$notify({
-              title: this.$t('common').notify.title,
-              message: this.$t('common').notify.editSucMessage,
-              type: 'success'
-            })
-            this.getRegCenter()
-          })
-        } else {
-          console.log('error submit!!')
-          return false
-        }
-      })
-    },
-    cancelEdit() {
-      this.editDialogVisible = false
+      this.addDialogVisible = true
     }
   }
 }