Commit beebeef7 authored by 智勇's avatar 智勇

新建服务增加debug

parent 9c704982
...@@ -149,14 +149,15 @@ ...@@ -149,14 +149,15 @@
<svg-icon icon-class="f5"/> <svg-icon icon-class="f5"/>
更新服务 更新服务
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item @click.native="updateDomain(scope.row)">
<svg-icon icon-class="doamin"/>
更新域名
</el-dropdown-item>
<el-dropdown-item @click.native="restartService(scope.row)"> <el-dropdown-item @click.native="restartService(scope.row)">
<svg-icon icon-class="restart"/> <svg-icon icon-class="restart"/>
重置服务 重置服务
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item @click.native="updateDomain(scope.row)">
<svg-icon icon-class="doamin"/>
更新域名
</el-dropdown-item>
<el-dropdown-item style="color: red" @click.native="deleteService(scope.row, item) "> <el-dropdown-item style="color: red" @click.native="deleteService(scope.row, item) ">
<svg-icon icon-class="delete"/> <svg-icon icon-class="delete"/>
删除服务 删除服务
...@@ -185,7 +186,7 @@ ...@@ -185,7 +186,7 @@
clearable clearable
filterable filterable
class="elSelect" class="elSelect"
placeholder="请选择服务,支持模糊搜索" placeholder="请选择服务支持模糊搜索"
@change="getTag"> @change="getTag">
<el-option <el-option
v-for="(item,index) in options" v-for="(item,index) in options"
...@@ -195,10 +196,11 @@ ...@@ -195,10 +196,11 @@
</el-select> </el-select>
</el-col> </el-col>
</el-row> </el-row>
<p class="title-sub">选择镜像</p> <p class="title-sub">选择镜像</p>
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="14"> <el-col :span="14">
<el-select v-model="tagName" filterable clearable class="elSelect" placeholder="请选择镜像,支持模糊搜索"> <el-select v-model="tagName" filterable clearable class="elSelect" placeholder="请选择镜像支持模糊搜索">
<el-option <el-option
v-for="(item,index) in tagOptions" v-for="(item,index) in tagOptions"
:key="index" :key="index"
...@@ -207,11 +209,22 @@ ...@@ -207,11 +209,22 @@
</el-select> </el-select>
</el-col> </el-col>
</el-row> </el-row>
<p v-if="label==='node'||label==='java'" class="title-sub">是否调试模式(执行测试时选择默认选项否即可) </p>
<el-row v-if="label==='node'||label==='java'" :gutter="20">
<el-col :span="14">
<el-select v-model="debug.key" filterable clearable class="elSelect" placeholder="请选择是否调试模式,执行测试时请选择否">
<el-option v-for="item in debugOptions" :key="item.key" :label="item.display_name" :value="item.key"/>
</el-select>
</el-col>
</el-row>
<span slot="footer" class="dialog-footer"> <span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">取 消</el-button> <el-button @click="dialogVisible = false">取 消</el-button>
<el-button type="primary" @click="createClusterService">确 定</el-button> <el-button type="primary" @click="createClusterService">确 定</el-button>
</span> </span>
</el-dialog> </el-dialog>
<!--更新服务的弹框--> <!--更新服务的弹框-->
<el-dialog <el-dialog
:visible.sync="updateDialog" :visible.sync="updateDialog"
...@@ -231,6 +244,7 @@ ...@@ -231,6 +244,7 @@
placeholder="请输入内容"/> placeholder="请输入内容"/>
</el-col> </el-col>
</el-row> </el-row>
<p class="title-sub">选择镜像</p> <p class="title-sub">选择镜像</p>
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="14"> <el-col :span="14">
...@@ -243,6 +257,7 @@ ...@@ -243,6 +257,7 @@
</el-select> </el-select>
</el-col> </el-col>
</el-row> </el-row>
<span slot="footer" class="dialog-footer"> <span slot="footer" class="dialog-footer">
<el-button @click="updateDialog = false">取 消</el-button> <el-button @click="updateDialog = false">取 消</el-button>
<el-button type="primary" @click="updateClusterService()">确 定</el-button> <el-button type="primary" @click="updateClusterService()">确 定</el-button>
...@@ -298,6 +313,11 @@ export default { ...@@ -298,6 +313,11 @@ export default {
components: { JsonEditor }, components: { JsonEditor },
data() { data() {
return { return {
debugOptions: [
{ key: 1, display_name: '' },
{ key: 0, display_name: '' }
],
debug: {},
centerDialogVisible: false, centerDialogVisible: false,
namespace: null, namespace: null,
tableData: [], tableData: [],
...@@ -308,7 +328,7 @@ export default { ...@@ -308,7 +328,7 @@ export default {
typeList: [], typeList: [],
tagName: '', tagName: '',
server: '', server: '',
lable: '', label: '',
domain: '', domain: '',
type: '', type: '',
value: null, value: null,
...@@ -360,6 +380,7 @@ export default { ...@@ -360,6 +380,7 @@ export default {
this.tagName = '' this.tagName = ''
this.options = [] this.options = []
this.tagOptions = [] this.tagOptions = []
this.debug = { key: 0, display_name: '' }
fetchUserrepository({ 'namespace': 'qa-' + label }).then(res => { fetchUserrepository({ 'namespace': 'qa-' + label }).then(res => {
this.options = res.data.repoInfo this.options = res.data.repoInfo
this.server = res.data.server this.server = res.data.server
...@@ -387,7 +408,8 @@ export default { ...@@ -387,7 +408,8 @@ export default {
image: this.tagName, image: this.tagName,
label: this.label, label: this.label,
type: this.type, type: this.type,
domain: this.domain.split('.')[0] domain: this.domain.split('.')[0],
debug: this.debug.key
}).then(res => { }).then(res => {
this.$message({ this.$message({
message: res.data, message: res.data,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment