This commit is contained in:
shiziyuan9527 2021-01-08 10:22:58 +08:00
commit 0caf64769a
19 changed files with 392 additions and 259 deletions

View File

@ -44,7 +44,8 @@
"vuedraggable": "^2.23.2",
"vuex": "^3.1.2",
"xml-js": "^1.6.11",
"yan-progress": "^1.0.3"
"yan-progress": "^1.0.3",
"vue-jsonpath-picker": "^1.1.5"
},
"devDependencies": {
"@vue/cli-plugin-babel": "^4.1.0",

View File

@ -48,11 +48,15 @@
</el-col>
</el-row>
</div>
<api-json-path-suggest-button @open="suggestJsonOpen" @clear="clearJson"/>
<ms-api-assertions-edit :is-read-only="isReadOnly" :assertions="assertions" :reloadData="reloadData" style="margin-bottom: 20px"/>
</div>
</el-collapse-transition>
</el-card>
<ms-api-jsonpath-suggest :tip="$t('api_test.request.extract.suggest_tip')" @addSuggest="addJsonPathSuggest" :data="suggestData" ref="jsonpathSuggest"/>
</div>
</template>
@ -67,11 +71,15 @@
import MsApiJsonpathSuggestList from "./ApiJsonpathSuggestList";
import MsApiAssertionXPath2 from "./ApiAssertionXPath2";
import {getUUID} from "@/common/js/utils";
import ApiJsonPathSuggestButton from "./ApiJsonPathSuggestButton";
import MsApiJsonpathSuggest from "./ApiJsonpathSuggest";
export default {
name: "MsApiAssertions",
components: {
MsApiJsonpathSuggest,
ApiJsonPathSuggestButton,
MsApiAssertionXPath2,
MsApiAssertionJsr223,
MsApiJsonpathSuggestList,
@ -83,6 +91,7 @@
assertions: {},
node: {},
request: {},
response: {},
customizeStyle: {
type: String,
default: "margin-top: 10px"
@ -101,6 +110,7 @@
type: "",
loading: false,
reloadData: "",
suggestData: {}
}
},
@ -114,11 +124,17 @@
this.$emit('copyRow', this.assertions, this.node);
},
suggestJsonOpen() {
if (!this.request.debugRequestResult) {
if (!this.response || !this.response.responseResult || !this.response.responseResult.body) {
this.$message(this.$t('api_test.request.assertions.debug_first'));
return;
}
this.$refs.jsonpathSuggestList.open();
try {
this.suggestData = JSON.parse(this.response.responseResult.body);
} catch (e) {
this.$error(this.$t('api_test.request.assertions.json_path_err'));
return;
}
this.$refs.jsonpathSuggest.open();
},
reload() {
this.loading = true
@ -133,14 +149,12 @@
remove() {
this.$emit('remove', this.assertions, this.node);
},
addJsonpathSuggest(jsonPathList) {
jsonPathList.forEach(jsonPath => {
let jsonItem = new JSONPath();
jsonItem.expression = jsonPath.json_path;
jsonItem.expect = jsonPath.json_value;
jsonItem.setJSONPathDescription();
this.assertions.jsonPath.push(jsonItem);
});
addJsonPathSuggest(data) {
let jsonItem = new JSONPath();
jsonItem.expression = data.path;
jsonItem.expect = data.value;
jsonItem.setJSONPathDescription();
this.assertions.jsonPath.push(jsonItem);
},
clearJson() {
this.assertions.jsonPath = [];
@ -159,6 +173,7 @@
padding: 10px;
margin: 5px 0;
border-radius: 5px;
border: #DCDFE6 solid 1px;
}
.icon.is-active {
@ -168,4 +183,5 @@
/deep/ .el-card__body {
padding: 15px;
}
</style>

View File

@ -0,0 +1,24 @@
<template>
<el-row :gutter="10" class="json-path-suggest-button">
<el-button size="small" type="primary" @click="$emit('open')">
{{ $t('api_test.request.assertions.json_path_suggest') }}
</el-button>
<el-button size="small" type="danger" @click="$emit('clear')">
{{ $t('api_test.request.assertions.json_path_clear') }}
</el-button>
</el-row>
</template>
<script>
export default {
name: "ApiJsonPathSuggestButton"
}
</script>
<style scoped>
.json-path-suggest-button {
text-align: right;
}
</style>

View File

@ -0,0 +1,93 @@
<template>
<ms-drawer class="json-path-picker" :visible="visible" :size="30" @close="close" direction="right">
<template v-slot:header>
<ms-instructions-icon :content="tip"/>
{{tip}}
</template>
<jsonpath-picker :code="data" v-on:path="pathChangeHandler" ref="jsonpathPicker"/>
</ms-drawer>
</template>
<script>
import MsDrawer from "../../../../common/components/MsDrawer";
import MsInstructionsIcon from "../../../../common/components/MsInstructionsIcon";
export default {
name: "MsApiJsonpathSuggest",
components: {MsInstructionsIcon, MsDrawer},
data() {
return {
visible: false,
isCheckAll: false,
};
},
props: {
data: {},
tip: {
type: String,
default() {
return ""
}
}
},
methods: {
close() {
this.visible = false;
},
open() {
this.visible = true;
},
pathChangeHandler(data) {
let paramNames = data.split('.');
let result = this.getParamValue(this.data, 0, paramNames);
result.path = '$.' + data;
this.$emit('addSuggest', result);
},
getParamValue(obj, index, params) {
if (params.length < 1) {
return "";
}
let param = params[index];
let childObj;
let reg = /\[\d\]$/;
let regIndex = param.search(reg);
if (regIndex > -1) {
let paramName = param.substring(0, regIndex);
let paramIndex = param.substring(regIndex + 1, param.length - 1);
param = paramIndex;
childObj = obj[paramName][paramIndex];
} else {
childObj = obj[params[index]];
}
if (index === params.length - 1) {
if (childObj instanceof Object) {
childObj = JSON.stringify(childObj);
} else if (childObj == null) {
childObj = "null";
}
return {
key: param,
value: childObj
};
}
index++;
return this.getParamValue(childObj, index, params);
}
}
}
</script>
<style scoped>
.json-path-picker {
padding: 10px 13px;
}
.json-path-picker >>> .json-tree {
margin-top: 0px;
margin-left: 6px;
}
</style>

View File

@ -26,7 +26,7 @@
<p class="tip">{{$t('api_test.definition.request.req_param')}} </p>
<!-- HTTP 请求参数 -->
<ms-api-request-form :headers="request.headers" :request="request"/>
<ms-api-request-form :headers="request.headers" :request="request" :response="responseData"/>
</el-form>
<!-- HTTP 请求返回数据 -->

View File

@ -76,12 +76,10 @@
<ms-jsr233-processor v-if="row.label ==='JSR223 PostProcessor'" @copyRow="copyRow" @remove="remove" :is-read-only="false" :title="$t('api_test.definition.request.post_script')" style-type="color: #783887;background-color: #F2ECF3"
:jsr223-processor="row"/>
<!--断言规则-->
<ms-api-assertions v-if="row.type==='Assertions'" @copyRow="copyRow" @remove="remove" :is-read-only="isReadOnly" :assertions="row"/>
<ms-api-assertions :response="response" v-if="row.type==='Assertions'" @copyRow="copyRow" @remove="remove" :is-read-only="isReadOnly" :assertions="row"/>
<!--提取规则-->
<ms-api-extract :is-read-only="isReadOnly" @copyRow="copyRow" @remove="remove" v-if="row.type==='Extract'" :extract="row"/>
</div>
</div>
</el-col>
<!--操作按钮-->
@ -131,6 +129,7 @@
},
props: {
request: {},
response: {},
showScript: Boolean,
headers: {
type: Array,

View File

@ -1,6 +1,6 @@
<template>
<div class="request-form">
<component :is="component" :showScript="showScript" :is-read-only="isReadOnly" :referenced="referenced" :request="request" :headers="headers" :isShowEnable="isShowEnable"/>
<component :is="component" :showScript="showScript" :is-read-only="isReadOnly" :referenced="referenced" :request="request" :response="response" :headers="headers" :isShowEnable="isShowEnable"/>
</div>
</template>
@ -12,6 +12,7 @@
components: {MsApiHttpRequestForm},
props: {
request: {},
response: {},
headers: Array,
isShowEnable: {
type: Boolean,

View File

@ -77,7 +77,7 @@ import {Request, Scenario} from "../model/ScenarioModel";
import draggable from 'vuedraggable';
import MsApiScenarioSelect from "@/business/components/api/test/components/ApiScenarioSelect";
import {parseEnvironment} from "../model/EnvironmentModel";
import MsHorizontalDragBar from "../../../common/components/MsHorizontalDragBar";
import MsHorizontalDragBar from "../../../common/components/dragbar/MsLeft2RightDragBar";
export default {
name: "MsApiScenarioConfig",

View File

@ -11,7 +11,7 @@
</template>
<script>
import MsHorizontalDragBar from "./MsHorizontalDragBar";
import MsHorizontalDragBar from "./dragbar/MsLeft2RightDragBar";
export default {
name: "MsAsideContainer",
components: {MsHorizontalDragBar},

View File

@ -1,90 +0,0 @@
<template>
<div direction="vertical" :class="direction" @mousedown="mouseDown"></div>
</template>
<script>
export default {
name: "MsDragMoveBar",
data() {
return {
lastX: '',
lastY: '',
};
},
props: {
direction: {
type: String,
default() {
return 'vertical';
}
}
},
created() {
document.addEventListener("mouseup", this.mouseUp);
},
destroyed() {
document.removeEventListener("mouseup", this.mouseUp);
},
methods: {
mouseDown(event) {
document.addEventListener("mousemove", this.mouseMove);
this.lastX = event.screenX;
this.lastY = event.screenY;
},
mouseMove(event) {
this.$emit("widthChange", this.lastX - event.screenX);
this.$emit("heightChange", this.lastY - event.screenY);
this.lastX = event.screenX;
this.lastY = event.screenY;
},
mouseUp() {
this.lastX = "";
this.lastY = "";
document.removeEventListener("mousemove", this.mouseMove);
}
}
};
</script>
<style >
.drag-bar {
width: 100%;
height: 2px;
cursor: row-resize;
z-index: 10;
background: #ccc;
}
.horizontal {
width: 2px;
height: 100%;
cursor: col-resize;
z-index: 10;
}
.vertical {
width: 100%;
height: 2px;
cursor: row-resize;
z-index: 10;
}
.vertical:hover {
height: 3px;
background-color: #ccc;
/*-webkit-box-shadow: 0 8px 10px -5px rgba(0,0,0,.2), 0 16px 24px 2px rgba(0,0,0,.14), 0 6px 30px 5px rgba(0,0,0,.12);*/
/*box-shadow: 0 8px 10px -5px rgba(0,0,0,.2), 0 16px 24px 2px rgba(0,0,0,.14), 0 6px 30px 5px rgba(0,0,0,.12);*/
}
.horizontal:hover {
width: 3px;
/*background-color: #7C3985;*/
background-color: #ccc;
}
</style>

View File

@ -1,21 +1,29 @@
<template>
<div id="ms-drawer" class="ms-drawer" :class="directionStyle" :style="{width: w + 'px', height: h + 'px'}" ref="msDrawer">
<ms-drag-move-bar :direction="dragBarDirection" @widthChange="widthChange" @heightChange="heightChange"/>
<div class="ms-drawer-header" >
<div v-if="visible" id="ms-drawer" class="ms-drawer" :class="directionStyle" :style="{width: w + 'px', height: h + 'px'}" ref="msDrawer">
<ms-bottom2-top-drag-bar v-if="direction == 'bottom'"/>
<ms-right2-left-drag-bar v-if="direction == 'right'"/>
<div class="ms-drawer-header">
<slot name="header"></slot>
<i class="el-icon-close" @click="close"/>
</div>
<div class="ms-drawer-body">
<slot></slot>
</div>
<ms-left2-right-drag-bar v-if="direction == 'left'"/>
</div>
</template>
<script>
import MsDragMoveBar from "./MsDragMoveBar";
import MsRight2LeftDragBar from "./dragbar/MsRight2LeftDragBar";
import MsLeft2RightDragBar from "./dragbar/MsLeft2RightDragBar";
import MsBottom2TopDragBar from "./dragbar/MsBottom2TopDragBar";
export default {
name: "MsDrawer",
components: {MsDragMoveBar},
components: {MsBottom2TopDragBar, MsLeft2RightDragBar, MsRight2LeftDragBar},
data() {
return {
x: 0,
@ -33,6 +41,12 @@
return "left";
}
},
visible: {
type: Boolean,
default() {
return true;
}
},
size: {
type: Number,
default() {
@ -81,58 +95,12 @@
break;
}
},
resize() {
},
getWidthPercentage(per) {
return document.body.clientWidth * per / 100.0;
},
getHeightPercentage(per) {
return document.body.clientHeight * per / 100.0;
},
widthChange(movement) {
if (this.direction != 'left' && this.direction != 'right') {
return;
}
switch (this.direction) {
case 'top':
this.w -= movement;
break;
case 'bottom':
this.w += movement;
break;
}
this._widthChange();
},
heightChange(movement) {
if (this.direction != 'top' && this.direction != 'bottom') {
return;
}
switch (this.direction) {
case 'top':
this.h -= movement;
break;
case 'bottom':
this.h += movement;
break;
}
this._heightChange();
},
_heightChange() {
if (this.h < 0) {
this.h = 0;
}
if (this.h > document.body.clientHeight) {
this.h = document.body.clientHeight;
}
},
_widthChange() {
if (this.w < 0) {
this.w = 0;
}
if (this.w > document.body.clientWidth) {
this.w = document.body.clientWidth;
}
},
close() {
this.$emit('close')
}
@ -178,17 +146,31 @@
}
.ms-drawer-header {
position: fixed;
width: 100%;
z-index: 999;
width: 100%;
}
.bottom-style .ms-drawer-header {
position: fixed;
}
.el-icon-close {
position: absolute;
font-size: 20px;
right: 10px;
top: 10px;
color: gray;
}
.bottom-style .el-icon-close {
right: 10px;
top: 13px;
color: gray;
font-size: 20px;
}
.right-style .el-icon-close {
position: fixed;
right: 10px;
top: 10px;
}
.el-icon-close:hover {

View File

@ -0,0 +1,27 @@
<template>
<div class="drag-bar" v-bottom-to-top-drag/>
</template>
<script>
export default {
name: "MsBottom2TopDragBar"
}
</script>
<style scoped>
.drag-bar {
height: 1px;
width: 100%;
z-index: 9999;
cursor: row-resize;
position: fixed;
background-color: #E6E6E6;
border: 0px;
}
.drag-bar:hover {
height: 3px;
}
</style>

View File

@ -1,10 +1,10 @@
<template>
<div class="drag-bar" v-horizontal-drag/>
<div class="drag-bar" v-left-to-right-drag/>
</template>
<script>
export default {
name: "MsHorizontalDragBar"
name: "MsLeft2RightDragBar"
}
</script>

View File

@ -0,0 +1,28 @@
<template>
<div class="drag-bar" v-right-to-left-drag/>
</template>
<script>
export default {
name: "MsRight2LeftDragBar"
}
</script>
<style scoped>
.drag-bar {
height: 100%;
width: 1px;
position: absolute;
left: 0px;
top: 0;
cursor: col-resize;
background-color: #E6E6E6;
border: 0px;
}
.drag-bar:hover {
width: 3px;
}
</style>

View File

@ -18,10 +18,11 @@ import '../common/css/menu-header.css';
import '../common/css/main.css';
import CKEditor from '@ckeditor/ckeditor5-vue';
import VueFab from 'vue-float-action-button'
import {horizontalDrag} from "../common/js/directive";
import {left2RightDrag, bottom2TopDrag, right2LeftDrag} from "../common/js/directive";
import JsonSchemaEditor from './components/common/json-schema/schema/index';
Vue.use(JsonSchemaEditor);
import JSONPathPicker from 'vue-jsonpath-picker';
Vue.use(JsonSchemaEditor);
Vue.config.productionTip = false;
Vue.use(icon);
Vue.use(ElementUI, {
@ -35,6 +36,7 @@ Vue.use(message);
Vue.use(CKEditor);
Vue.use(YanProgress);
Vue.use(VueFab);
Vue.use(JSONPathPicker);
// v-permission
Vue.directive('permission', permission);
@ -47,7 +49,9 @@ Vue.directive('xpack', xpack);
Vue.directive('tester', tester);
//支持左右拖拽
Vue.directive('horizontal-drag', horizontalDrag);
Vue.directive('left-to-right-drag', left2RightDrag);
Vue.directive('right-to-left-drag', right2LeftDrag);
Vue.directive('bottom-to-top-drag', bottom2TopDrag);
new Vue({
el: '#app',

View File

@ -1,4 +1,4 @@
export const horizontalDrag = {
export const left2RightDrag = {
inserted(el, binding) {
el.onmousedown = function (e) {
const init = e.clientX;
@ -7,7 +7,49 @@ export const horizontalDrag = {
document.onmousemove = function (e) {
const end = e.clientX;
const newWidth = end - init + initWidth;
parent.style.width = newWidth + "px";
if (newWidth < document.body.clientWidth - 10 && newWidth > 10) {
parent.style.width = newWidth + "px";
}
};
document.onmouseup = function () {
document.onmousemove = document.onmouseup = null;
};
};
}
};
export const right2LeftDrag = {
inserted(el, binding) {
el.onmousedown = function (e) {
const init = e.clientX;
const parent = el.parentNode;
const initWidth = parent.offsetWidth;
document.onmousemove = function (e) {
const end = e.clientX;
const newWidth = initWidth - (end - init);
if (newWidth < document.body.clientWidth - 10 && newWidth > 10) {
parent.style.width = newWidth + "px";
}
};
document.onmouseup = function () {
document.onmousemove = document.onmouseup = null;
};
};
}
};
export const bottom2TopDrag = {
inserted(el, binding) {
el.onmousedown = function (e) {
const init = e.clientY;
const parent = el.parentNode;
const initHeight = parent.offsetHeight;
document.onmousemove = function (e) {
const end = e.clientY;
const newHeight = initHeight - (end - init);
if (newHeight < document.body.clientHeight - 10 && newHeight > 10) {
parent.style.height = newHeight + "px";
}
};
document.onmouseup = function () {
document.onmousemove = document.onmouseup = null;

View File

@ -732,6 +732,7 @@ export default {
json_path_suggest: "JSONPath Assertion Suggest",
json_path_clear: "Clear JSONPath Assertion",
debug_first: "First, debug to get the response",
suggest_tip: "Click the note to add the JSONPath assertion",
},
extract: {
label: "Extract from response",
@ -742,6 +743,7 @@ export default {
regex_expression: "Regular expression",
json_path_expression: "JSONPath expression",
xpath_expression: "XPath expression",
suggest_tip: "Click the note to add the JSONPath extraction",
},
processor: {
pre_exec_script: "PreProcessor",

View File

@ -732,6 +732,7 @@ export default {
variable_name: "变量名称",
set_failure_status: "设置失败状态",
set_failure_msg: "设置失败消息",
suggest_tip: "点击便签添加JSONPath断言",
},
extract: {
label: "提取",
@ -742,6 +743,7 @@ export default {
regex_expression: "Perl型正则表达式",
json_path_expression: "JSONPath表达式",
xpath_expression: "XPath表达式",
suggest_tip: "点击便签添加JSONPath提取",
},
processor: {
pre_exec_script: "预执行脚本",

View File

@ -65,7 +65,7 @@ export default {
refresh: '刷新',
remark: '備註',
delete: '刪除',
reduction: '恢',
reduction: '恢',
not_filled: '未填寫',
please_select: '請選擇',
search_by_name: '根據名稱搜索',
@ -250,9 +250,9 @@ export default {
mail: '郵件',
nail_robot: '釘釘機器人',
enterprise_wechat_robot: '企業微信機器人',
notes: '1.事件,接收方式,接收人為必填項;\n' +
' 2.接收方式除郵件外webhook為必填\n' +
' 3.機器人選擇為群機器人,安全驗證選擇“自定義關鍵詞” "任務通知"',
notes: '1.釘釘和企業群裏新建壹個自定義機器人,然後復制 webhook 地址在我們平臺上;\n' +
' 2.機器人選擇為群機器人,安全驗證選擇“自定義關鍵詞” "任務通知";\n' +
' 3.選擇接收人時必須是妳所建的群裏包含的人,接收人手機號為必填項且為釘釘企業所使用的手機號,',
message: '事件,接收人,接收方式為必填項',
message_webhook: '接收方式為釘釘和企業機器人時webhook為必填項',
template: "模版"
@ -307,7 +307,7 @@ export default {
manager: '項目管理',
no_data: '無數據',
select: '選擇項目',
repeatable: '接口定义URL可重复'
repeatable: '接口定義URL可重復'
},
member: {
create: '添加成員',
@ -377,9 +377,9 @@ export default {
test_stop_now: '立即停止',
test_stop_now_confirm: '確定要立即停止當前測試嗎?',
test_rerun_confirm: '確定要再次執行當前測試嗎?',
downloadJtl: '下載JTL',
test_stop_success: '停止成功',
test_execute_again: '再次執行',
downloadJtl: '下載JTL',
export: '導出',
compare: '比較',
generation_error: '報告生成錯誤, 無法查看, 請檢查日誌詳情!',
@ -436,9 +436,9 @@ export default {
ramp_up_time_within: '在',
ramp_up_time_minutes: '秒內,分',
ramp_up_time_seconds: '秒內增加並發用戶',
iterate_num: '代次數 (次): ',
by_iteration: '按代次數',
by_duration: '按壓測時長',
iterate_num: '代次數 (次): ',
by_iteration: '按代次數',
by_duration: '按持續時間',
ramp_up_time_times: '次增加並發用戶',
advanced_config_error: '高級配置校驗失敗',
domain_bind: '域名綁定',
@ -514,18 +514,18 @@ export default {
add_data: "去添加"
},
request: {
grade_info: "按等級筛选",
grade_info: "按等級篩選",
run_env: "運行環境",
select_case: "搜索用例",
case: "用例",
responsible: "任人",
title: "建接口",
responsible: "任人",
title: "建接口",
path_info: "請輸入接口的URL如/api/demo/#{id}其中id為路徑參數",
path_all_info: "請輸入完整測試地址",
fast_debug: "快捷調試",
close_all_label: "關閉所有標簽",
save_as: "另存為新接口",
load_case: "加用例",
load_case: "加用例",
save_as_case: "另存為新用例",
update_api: "更新接口",
body_form_data: "form-data",
@ -541,10 +541,10 @@ export default {
verified: "認證",
encryption: "加密",
req_param: "請求參數",
res_param: "響應容",
batch_delete: "批量除",
res_param: "響應容",
batch_delete: "批量除",
delete_confirm: "確認刪除接口",
delete_confirm_step: "確認刪除步",
delete_confirm_step: "確認刪除步",
assertions_rule: "斷言規則",
response_header: "響應頭",
response_body: "響應體",
@ -557,12 +557,12 @@ export default {
post_script: "後置腳本",
extract_param: "提取參數",
add_module: "創建模塊",
edit_api: "编辑接口",
edit_api: "編輯接口",
test_plan_select: "請選擇測試計劃",
create_info: '創建',
update_info: '更新',
batch_edit: "批量編輯",
path_valid_info: "請求路径无效",
path_valid_info: "請求路徑無效",
}
},
automation: {
@ -575,15 +575,15 @@ export default {
external_import: "外部導入",
wait_controller: "等待控制器",
if_controller: "條件控制器",
loop_controller: "循控制器",
loop_controller: "循控制器",
scenario_import: "場景導入",
customize_script: "自定義本",
customize_script: "自定義本",
customize_req: "自定義請求",
reference_info: "請選擇接口或用例",
scenario_test: "場景",
add_scenario: "建場景",
scenario_name: "場景名",
case_level: "用例等",
add_scenario: "建場景",
scenario_name: "場景名",
case_level: "用例等",
tag: "標簽",
creator: "創建人",
update_time: "最後更新時間",
@ -597,14 +597,14 @@ export default {
edit: "編輯",
execute: "執行",
copy: "復制",
remove: "除",
remove: "除",
view_ref: "查看引用",
case_ref: "用例引用",
schedule: "定時任務",
scenario_ref: "景引用",
plan_ref: "测试计划引用",
batch_add_plan: "添加到测试计划",
batch_execute: "批量行",
scenario_ref: "景引用",
plan_ref: "測試計劃引用",
batch_add_plan: "添加到測試計劃",
batch_execute: "批量行",
scenario: {
principal: "責任人",
select_principal: "請選擇責任人",
@ -614,7 +614,7 @@ export default {
},
report_name_info: '請輸入報告名稱',
save_case_info: '請先保存用例',
reference_deleted: '引用已除',
reference_deleted: '引用已除',
},
environment: {
name: "環境名稱",
@ -707,6 +707,7 @@ export default {
text: "文本",
regex: "正則",
response_time: "響應時間",
jsr223: "腳本",
select_type: "請選擇類型",
select_subject: "請選擇對象",
select_condition: "請選擇條件",
@ -731,6 +732,7 @@ export default {
variable_name: "變量名稱",
set_failure_status: "設置失敗狀態",
set_failure_msg: "設置失敗消息",
suggest_tip: "點擊便簽添加JSONPath斷言",
},
extract: {
label: "提取",
@ -741,6 +743,7 @@ export default {
regex_expression: "Perl型正則表達式",
json_path_expression: "JSONPath表達式",
xpath_expression: "XPath表達式",
suggest_tip: "點擊便簽添加JSONPath提取",
},
processor: {
pre_exec_script: "預執行腳本",
@ -791,7 +794,7 @@ export default {
close_connection: "關閉連接",
so_linger: "SO LINGER",
eol_byte: "行尾(EOL)字節值",
request: "發送文本",
request: "發送文本",
username: "用戶名",
password: "密碼",
login: "登錄設置",
@ -808,7 +811,7 @@ export default {
ms_tip: "支持 Metersphere json 格式",
ms_export_tip: "通過 Metersphere 接口測試頁面或者瀏覽器插件導出 json 格式文件",
postman_tip: "只支持 Postman Collection v2.1 格式的 json 文件",
swagger_tip: "支持 Swagger 2.0 與 3.0版本的 json 文件",
swagger_tip: "支持 Swagger 2.0 與 3.0 版本的 json 文件",
post_export_tip: "通過 Postman 導出測試集合",
swagger_export_tip: "通過 Swagger 頁面導出",
suffixFormatErr: "文件格式不符合要求",
@ -850,42 +853,42 @@ export default {
},
api_details_card: {
title: "接口",
this_week_add: "本新增:",
this_week_add: "本新增:",
},
test_case_details_card: {
title: "用例",
this_week_add: "本新增:",
this_week_execute: "本執行: {0}次",
this_week_add: "本新增:",
this_week_execute: "本執行: {0}次",
executed: "歷史總執行: {0}次",
this_week_add_sm: "本新增:",
this_week_execute_sm: "本執行:<br/>{0}次",
this_week_add_sm: "本新增:",
this_week_execute_sm: "本執行:<br/>{0}次",
executed_sm: "歷史總執行:<br/>{0}次",
},
test_scene_details_card: {
title: "場景",
this_week_add: "本新增:",
this_week_execute: "本執行: {0}次",
this_week_add: "本新增:",
this_week_execute: "本執行: {0}次",
executed: "歷史總執行: {0}次",
this_week_add_sm: "本新增:",
this_week_execute_sm: "本執行:<br/>{0}次",
this_week_add_sm: "本新增:",
this_week_execute_sm: "本執行:<br/>{0}次",
executed_sm: "歷史總執行:<br/>{0}次",
},
schedule_task_details_card: {
title: "定時任務",
this_week_add: "本週新增: {0}个",
this_week_execute: "本執行: {0}次",
this_week_add: "本周新增: {0}個",
this_week_execute: "本執行: {0}次",
executed: "歷史總執行: {0}次",
this_week_add_sm: "本週新增:<br/>{0}个",
this_week_execute_sm: "本執行:<br/>{0}次",
this_week_add_sm: "本周新增:<br/>{0}個",
this_week_execute_sm: "本執行:<br/>{0}次",
executed_sm: "歷史總執行:<br/>{0}次",
},
failed_case_list: {
title: "過去7天測試計失敗用例TOP 10",
title: "過去7天測試計失敗用例TOP 10",
table_coloum: {
index: "排名",
case_name: "用例名稱",
case_type: "用例類型",
test_plan: "所屬測試計",
test_plan: "所屬測試計",
failure_times: "失敗次數",
},
table_value: {
@ -949,11 +952,11 @@ export default {
not_exist: "測試報告不存在",
},
api_monitor: {
to: "",
start_time: "開始時間",
end_time: "結束時間",
today: "今",
this_week: "本",
to: "",
start_time: "開始日期",
end_time: "結束日期",
today: "今",
this_week: "本",
this_mouth: "本月",
please_search: "請搜索",
date: "日期"
@ -1124,8 +1127,8 @@ export default {
send: "發送",
description_is_null: "評論內容不能為空!",
send_success: "評論成功!",
cannot_edit: "無法編輯此評論!",
cannot_delete: "無法刪除此評論!",
cannot_edit: "無法編輯此評論",
cannot_delete: "無法刪除此評論",
},
review_view: {
review: "評審",
@ -1363,7 +1366,7 @@ export default {
performance: "性能測試數量",
resource_pool: "可用測試資源池",
max_threads: "最大並發數",
duration: "壓測時長(分鐘",
duration: "壓測時長(",
use_default: "使用默認配額",
yes: "是",
no: "否",
@ -1376,55 +1379,54 @@ export default {
clean: "清空"
},
schema: {
title: "标题",
import_json: "入 json",
base_setting: "基础设置",
all_setting: "编辑源码",
default: "默值",
title: "標題",
import_json: "入 json",
base_setting: "基礎設置",
all_setting: "編輯源碼",
default: "默值",
description: "描述",
adv_setting: "高级设置",
add_child_node: "添加子节点",
add_sibling_node: "添加兄弟节点",
add_node: "添加兄弟/子节点",
remove_node: "删除节点",
child_node: "子节点",
sibling_node: "兄弟节点",
ok: "定",
adv_setting: "高級設置",
add_child_node: "添加子節點",
add_sibling_node: "添加兄弟節點",
add_node: "添加兄弟/子節點",
remove_node: "刪除節點",
child_node: "子節點",
sibling_node: "兄弟節點",
ok: "定",
cancel: "取消",
minLength: "最小度",
maxLength: "最大度",
pattern: "用正则表达式约束字符串",
exclusiveMinimum: "开启后,数据必须大于最小值",
exclusiveMaximum: "开启后,数据必须小于最大值",
minLength: "最小度",
maxLength: "最大度",
pattern: "用正則表達式約束字符串",
exclusiveMinimum: "開啟後,數據必須大於最小值",
exclusiveMaximum: "開啟後,數據必須小於最大值",
minimum: "最小值",
maximum: "最大值",
uniqueItems: "开启后,每个元素都不相同",
minItems: "最小元素个数",
maxItems: "最大元素个数",
minProperties: "最小元素个数",
maxProperties: "最大元素个数",
checked_all: "全",
uniqueItems: "開啟後,每個元素都不相同",
minItems: "最小元素個數",
maxItems: "最大元素個數",
minProperties: "最小元素個數",
maxProperties: "最大元素個數",
checked_all: "全",
valid_json: "不是合法的json字符串",
enum: "枚",
enum_msg: "每行只能写一个值",
enum_desc: "备注",
enum_desc_msg: "备注描述信息",
required: "是否必",
enum: "枚",
enum_msg: "每行只能寫壹個值",
enum_desc: "備註",
enum_desc_msg: "備註描述信息",
required: "是否必",
mock: "mock",
mockLink: "查看文",
mockLink: "查看文",
format: "格式化",
nothing: "",
preview: "预览",
add_custom: "添加自定义属性"
nothing: "",
preview: "預覽",
add_custom: "添加自定義屬性"
},
loop: {
loops_title: "次數循環",
foreach: "ForEach 循環",
while: "While 循環",
loops: "循環次",
loops: "循環次",
interval: "循環間隔",
proceed: "成功後繼續循環",
timeout: "循環超時時間",
}
};