Commit 514a5e1a authored by 张俊's avatar 张俊

Merge branch 'dev' of cloud.wodcloud.com:apaas/apaas-v3-ui into dev

parents 7af5aa76 61870034
......@@ -10,6 +10,7 @@
"build": "node build/build.js"
},
"dependencies": {
"@antv/g6": "^3.4.8",
"@fortawesome/fontawesome-free": "^5.8.0",
"ace-builds": "^1.4.11",
"babel-polyfill": "^6.26.0",
......
......@@ -9,12 +9,9 @@
<script>
import ace from "ace-builds";
import "ace-builds/webpack-resolver"; // 在 webpack 环境中使用必须要导入
import "ace-builds/src-noconflict/mode-yaml"; // 默认设置的语言模式
import "ace-builds/src-noconflict/mode-json"; // 默认设置的语言模式
import yaml from "json2yaml"; //json转yaml
import json from "js-yaml"; //yaml转json
export default {
props: ["items", "acemodePath"],
props: ["url"],
data() {
return {
aceEditor: null,
......@@ -33,27 +30,22 @@ export default {
tabSize: 4,
highlightActiveLine: false
});
if (this.acemodePath == "ace/mode/yaml") {
var obj = yaml.stringify(this.items);
this.aceEditor.getSession().setValue(obj);
} else if (this.acemodePath == "ace/mode/json") {
this.aceEditor
.getSession()
.setValue(JSON.stringify(this.items, null, "\t"));
}
this.getValue();
},
watch: {},
methods: {
// updatechild: function() {
// json.load(this.aceEditor.getSession().getValue());
// console.log(json.load(this.aceEditor.getSession().getValue()));
// },
parentHandleclick: function() {
this.$emit(
"jsonyamlvalue",
json.load(this.aceEditor.getSession().getValue())
);
getValue() {
this.$http
.get(this.url)
.then(response => {
this.aceEditor.setValue(JSON.stringify(response.data, null, "\t"));
})
.catch(function(response) {
console.log(response);
});
},
parentHandleclick() {
this.$emit("getEditValue", this.aceEditor.getValue());
}
}
};
......
This diff is collapsed.
This diff is collapsed.
<template>
<div>
<div v-if="!needCropper">
<div v-if="type != 'copper'">
<el-upload
action="ssurl"
:file-list="fileArray"
......@@ -53,10 +53,6 @@ export default {
type: Number,
default: 1
},
needCropper: {
type: Boolean,
default: false
},
list: {
type: Array,
default: []
......
<template>
<div class="code-main">
<v-apaas-code></v-apaas-code>
<v-apaas-code url="/static/data.json"></v-apaas-code>
</div>
</template>
......@@ -36,4 +36,7 @@ export default {
</script>
<style scoped>
.code-main {
margin-top: 100px;
}
</style>
\ No newline at end of file
......@@ -20,6 +20,7 @@
:emptyText="emptyText"
:stripe="true"
:pageSizeShow="true"
:filterList="filterList"
></ces-table>
<h3>可编辑表格,供服务测试用</h3>
<ces-table
......@@ -114,7 +115,29 @@ export default {
},
emptyText: "暂时没数据",
emptyText1: "可输入表格暂时没数据",
emptyText2: "树结构暂时没数据"
emptyText2: "树结构暂时没数据",
filterList: [
{
name: "服务类型",
prop: "fwlx",
data: ["数据服务", "时空服务", "视频服务", "感知服务", "综合服务"]
},
{
name: "服务领域",
prop: "fwly",
data: ["数据服务", "时空服务", "视频服务", "感知服务", "综合服务"]
},
{
name: "开放程度",
prop: "kfcd",
data: ["数据服务", "时空服务", "视频服务", "感知服务", "综合服务"]
},
{
name: "服务状态",
prop: "fwzt",
data: ["数据服务", "时空服务", "视频服务", "感知服务", "综合服务"]
},
]
}),
components: {
cesTable
......
<template>
<div class="topo_ex">
<Topology :datas="datas" />
</div>
</template>
<script>
// @ is an alias to /src
import Topology from "@/components/topology.vue";
export default {
components: {
Topology
},
data: () => ({
datas: {}
}),
mounted() {
this.getData();
},
methods: {
getData() {
let url = "./static/antv.json";
this.$http
.get(url)
.then(response => {
this.datas = response.data.elements;
})
.catch(function(response) {
this.error = true;
});
},
}
};
</script>
<style scoped>
.topo_ex {
margin-top: 100px;
}
</style>
\ No newline at end of file
......@@ -4,7 +4,6 @@
<upload-file
:multiple="false"
:max="4"
:needCropper="true"
type="cropper"
:readOnly="false"
:list="imgList"
......@@ -14,7 +13,6 @@
<upload-file
:multiple="false"
:max="4"
:needCropper="false"
type="picture"
:readOnly="false"
fit="fill"
......@@ -25,7 +23,6 @@
<upload-file
:multiple="false"
:max="4"
:needCropper="false"
type="mp3"
:readOnly="false"
fit="fill"
......
......@@ -2,7 +2,9 @@
<div class="fwcs">
<el-breadcrumb separator="/" class="bread_crumb">
<el-breadcrumb-item :to="{ path: '/fwzc' }">服务注册</el-breadcrumb-item>
<el-breadcrumb-item>服务测试</el-breadcrumb-item>
<el-breadcrumb-item v-if="!jcxxtx">服务测试</el-breadcrumb-item>
<el-breadcrumb-item v-else :to="{ path: '/fwzc' }">服务测试</el-breadcrumb-item>
<el-breadcrumb-item v-if="jcxxtx">基础信息填写</el-breadcrumb-item>
</el-breadcrumb>
<block-radius>
<el-row>
......@@ -14,6 +16,17 @@
>{{ item.text }}</el-button>
</el-row>
<div class="gray_line"></div>
<div v-if="activeBtn == 4">
<div class="sqxx_title">服务类型:</div>
<el-select v-model="zhyyVal" placeholder="请选择" class="zhyy_select">
<el-option
v-for="item in optionsZhyy"
:key="item.value"
:label="item.label"
:value="item.value"
></el-option>
</el-select>
</div>
<div class="fwcs_fwdz">服务地址:</div>
<div class="fwcs_fwdz_inner">
<el-input placeholder="请输入内容" v-model="input3" class="input-with-select">
......@@ -26,7 +39,7 @@
></el-option>
</el-select>
</el-input>
<el-button v-if="activeBtn == 0" @click="clickFwcs()" class="fwcs_btn_fwcs">服务测试</el-button>
<el-button v-if="activeBtn == 0 || activeBtn == 4" @click="clickFwcs()" class="fwcs_btn_fwcs">服务测试</el-button>
</div>
<div v-if="activeBtn == 0">
<el-tabs v-model="activeName" class="fwcs_tabs" @tab-click="clickTab">
......@@ -94,7 +107,8 @@
</div>
</div>
</block-radius>
<block-radius v-if="activeBtn == 0 && resultShow">
<block-radius v-if="resultShow">
<div v-if="activeBtn == 0">
<div class="sjfw_qqcstx">请求参数信息填写:</div>
<ces-table
ref="fwcs_sjfw_qqcs"
......@@ -135,17 +149,21 @@
:pageSizeShow="false"
headerCellClassName="th_pink"
></ces-table>
<div class="btn_footer">
<el-button class="reset" @click="resetSjfw">重置</el-button>
<el-button class="next" @click="nextJcxx">下一步</el-button>
</div>
</block-radius>
<block-radius v-if="activeBtn == 1 && resultShow">
<div v-else-if="activeBtn == 1 || activeBtn == 4">
<div class="skfw_csfwxx">测试服务信息:</div>
<div class="test_succ">
<div>测试成功</div>
<div v-if="skfwResult" class="skcs_jg">
<img src="../assets/imgs/test_icon_success.png" class="skcs_jg_img" />&nbsp;测试成功
</div>
<div v-else class="skcs_jg">
<img src="../assets/imgs/test_icon_error.png" class="skcs_jg_img" />&nbsp;测试失败
</div>
<div></div>
</div>
</div>
<div class="btn_footer">
<el-button class="reset" v-if="activeBtn == 0" @click="resetSjfw">重置</el-button>
<el-button class="next" @click="nextJcxx">下一步</el-button>
</div>
</block-radius>
......@@ -222,12 +240,22 @@ export default {
"OGS(WMTS)",
"OGS(WFS)",
"OGS(WCS)"
]
],
skfwResult: false,
optionsZhyy: [
{ label: "模型算法类", value: 0 },
{ label: "查询验证类", value: 1 },
{ label: "流程类", value: 2 },
{ label: "应用类", value: 3 },
],
zhyyVal: 0,
jcxxtx: false
}),
computed: {},
watch: {},
methods: {
clickBtn(val) {
this.resultShow = false;
this.activeBtn = val;
},
clickFwcs() {
......@@ -238,7 +266,9 @@ export default {
console.log(this.$refs.fwcs_sjfw_qq.getTableData());
},
resetSjfw() {},
nextJcxx() {},
nextJcxx() {
this.jcxxtx = true;
}
},
mounted() {}
};
......@@ -346,6 +376,21 @@ export default {
width: 100%;
margin: 0 auto;
}
.skcs_jg {
height: 100px;
display: flex;
align-items: center;
justify-content: center;
color: #0f2683;
font-size: 20px;
}
.skcs_jg_img {
position: relative;
top: 3px;
}
.zhyy_select {
width: 70%;
}
</style>
<style>
.bread_crumb .el-breadcrumb__inner {
......
......@@ -59,6 +59,11 @@ export default new Router({
path: "/example_icon", // svg 实例
name: "example_icon",
component: () => import("@/pages/example_icon")
},
{
path: "/example_topology", // 拓扑图实例
name: "example_topology",
component: () => import("@/pages/example_topology")
}
]
});
This diff is collapsed.
......@@ -410,7 +410,7 @@
{
"id": 3,
"unicode": "2016-05-01",
"type": "ssdNW",
"type": "ssdNWssdNWssdNWssdNWssdNWssdNWssdNW",
"name": "王小虎",
"explanation": "上海市普陀区金沙江路 1519 弄",
"children": [
......
<svg id="图层_1" data-name="图层 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><defs><style>.cls-1{fill:#a1b1f6;}.cls-2{fill:#495feb;}</style></defs><title>ic_画板 17</title><rect class="cls-1" x="4.22" y="4.22" width="13.56" height="13.56" transform="translate(-4.56 11) rotate(-45)"/><path class="cls-2" d="M11,2.83,19.17,11,11,19.17,2.83,11,11,2.83M11,0,0,11,11,22,22,11,11,0Z"/></svg>
\ No newline at end of file
<svg id="图层_1" data-name="图层 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"><defs><style>.cls-1{fill:#a1b1f6;}.cls-2{fill:#495feb;}</style></defs><title>ic_画板 15</title><path class="cls-1" d="M10,19a9,9,0,1,1,9-9A9,9,0,0,1,10,19Z"/><path class="cls-2" d="M10,2a8,8,0,1,1-8,8,8,8,0,0,1,8-8m0-2A10,10,0,1,0,20,10,10,10,0,0,0,10,0Z"/></svg>
\ No newline at end of file
<svg id="图层_1" data-name="图层 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 19.05"><defs><style>.cls-1{fill:#a1b1f6;}.cls-2{fill:#495feb;}</style></defs><title>ic_画板 16</title><polygon class="cls-1" points="1.73 18.05 11 2 20.27 18.05 1.73 18.05"/><path class="cls-2" d="M11,4l7.54,13.05H3.46L11,4m0-4L0,19.05H22L11,0Z"/></svg>
\ No newline at end of file
<svg id="图层_1" data-name="图层 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 18 18"><defs><style>.cls-1{fill:#a1b1f6;}.cls-2{fill:#495feb;}</style></defs><title>ic_画板 14</title><rect class="cls-1" x="1" y="1" width="16" height="16"/><path class="cls-2" d="M16,2V16H2V2H16m2-2H0V18H18V0Z"/></svg>
\ No newline at end of file
<svg id="图层_1" data-name="图层 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 20.92"><defs><style>.cls-1{fill:#a1b1f6;}.cls-2{fill:#495feb;}</style></defs><title>ic_画板 18</title><polygon class="cls-1" points="4.93 19.92 1.18 8.37 11 1.24 20.82 8.37 17.07 19.92 4.93 19.92"/><path class="cls-2" d="M11,2.47l8.65,6.28-3.3,10.17H5.65L2.35,8.76,11,2.47M11,0,0,8,4.2,20.92H17.8L22,8,11,0Z"/></svg>
\ No newline at end of file
This diff is collapsed.
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