指标加入全局变量字段选项
This commit is contained in:
@@ -76,7 +76,7 @@ switch (process.env.NODE_ENV) {
|
||||
case 'wang': // 汪环境
|
||||
proxyObj = {
|
||||
'/Riskmanage': {
|
||||
target: 'http://192.168.50.228:8080', // 生产环境
|
||||
target: 'http://192.168.50.223:8080', // 生产环境
|
||||
changeOrigin: true, // 是否跨域
|
||||
pathRewrite: {
|
||||
'^/Riskmanage': '/Riskmanage'
|
||||
|
||||
2029
h5-datax-manager/package-lock.json
generated
2029
h5-datax-manager/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -324,6 +324,7 @@
|
||||
type: 'success'
|
||||
});
|
||||
this.getlist()
|
||||
this.selection = []
|
||||
this.$store.dispatch('reGetfielduser')
|
||||
}
|
||||
})
|
||||
|
||||
@@ -1,46 +1,46 @@
|
||||
<style>
|
||||
.dataManageRedact {
|
||||
.dataManageRedact {
|
||||
width: 100%;
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
|
||||
.MR_checkbox {
|
||||
.MR_checkbox {
|
||||
padding: 20px;
|
||||
border-bottom: 1px solid #ddd;
|
||||
}
|
||||
}
|
||||
|
||||
.MR_scope {
|
||||
.MR_scope {
|
||||
padding: 20px;
|
||||
border-bottom: 1px solid #ddd;
|
||||
}
|
||||
}
|
||||
|
||||
.MR_scope>div {
|
||||
.MR_scope>div {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
|
||||
.MR_scope>div>p {
|
||||
.MR_scope>div>p {
|
||||
width: 10%;
|
||||
}
|
||||
}
|
||||
|
||||
.MR_derive {
|
||||
.MR_derive {
|
||||
|
||||
margin: 0 40px 0 30px;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.MR_rule_home {
|
||||
.MR_rule_home {
|
||||
overflow: scroll;
|
||||
overflow-x: hidden;
|
||||
height: 350px;
|
||||
}
|
||||
}
|
||||
|
||||
.MR_rule_home::-webkit-scrollbar {
|
||||
.MR_rule_home::-webkit-scrollbar {
|
||||
display: none;
|
||||
/* Chrome Safari */
|
||||
}
|
||||
}
|
||||
|
||||
.MR_toolbar {
|
||||
.MR_toolbar {
|
||||
background-color: #F0F0F0;
|
||||
height: 40px;
|
||||
display: flex;
|
||||
@@ -54,46 +54,46 @@
|
||||
-khtml-user-select: none;
|
||||
user-select: none;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.MR_toolbar>p:hover {
|
||||
.MR_toolbar>p:hover {
|
||||
color: #fff;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.codemirrirPs {
|
||||
.codemirrirPs {
|
||||
padding: 5px;
|
||||
margin: 30px 0;
|
||||
background-color: #999;
|
||||
border-radius: 10px;
|
||||
}
|
||||
}
|
||||
|
||||
.codemirrirPs>span:nth-of-type(1) {
|
||||
.codemirrirPs>span:nth-of-type(1) {
|
||||
font-size: 12px;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<template>
|
||||
<div class="dataManageRedact" v-loading="loading">
|
||||
<div :class="smallHeader?'MR_header MR_headerSmall':'MR_header'">
|
||||
<div :class="smallHeader ? 'MR_header MR_headerSmall' : 'MR_header'">
|
||||
<div>
|
||||
<div>
|
||||
<el-button type="primary" icon="el-icon-arrow-left" circle @click="$emit('close')"></el-button>
|
||||
</div>
|
||||
<div>
|
||||
<span v-if="id===0">新增字段 :</span>
|
||||
<span v-if="id === 0">新增字段 :</span>
|
||||
<span v-else>编辑字段 :</span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
|
||||
<el-button :icon="smallHeader?'el-icon-bottom':'el-icon-top'" circle @click="openHeader">
|
||||
<el-button :icon="smallHeader ? 'el-icon-bottom' : 'el-icon-top'" circle @click="openHeader">
|
||||
</el-button>
|
||||
<el-button type="success" icon="el-icon-check" circle @click="submit"></el-button>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div :class="smallHeader?'MR_input MR_inputSmall':'MR_input'">
|
||||
<div :class="smallHeader ? 'MR_input MR_inputSmall' : 'MR_input'">
|
||||
<div>
|
||||
<p>字段名称: </p>
|
||||
<el-input placeholder="请输入字段名" maxlength="30" v-model="fieldEn" clearable></el-input>
|
||||
@@ -104,19 +104,23 @@
|
||||
</div>
|
||||
<div>
|
||||
<p>值类型 : </p>
|
||||
<el-select v-model="valueType" placeholder="请选择">
|
||||
<el-option label="数值型" :value="1" v-if="ftype!=5" />
|
||||
<el-option label="字符型" :value="2" v-if="ftype!=5" />
|
||||
<el-select v-model="valueType" placeholder="请选择" style="width: 100%;">
|
||||
<el-option label="数值型" :value="1" v-if="ftype != 5" />
|
||||
<el-option label="字符型" :value="2" v-if="ftype != 5" />
|
||||
<!-- <el-option label="枚举型" :value="3" /> -->
|
||||
<!-- <el-option label="小数型" :value="4" /> -->
|
||||
<!-- <el-option label="数组型" :value="5" /> -->
|
||||
<el-option label="JSON型" :value="6" />
|
||||
</el-select>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div style="margin: 10px 30px;">
|
||||
<el-checkbox v-model="isLocalVariable">是否局部变量</el-checkbox>
|
||||
</div>
|
||||
<div style="flex: 1;overflow: auto;">
|
||||
|
||||
<div v-show="isDerivative=='Derivative'" class="MR_derive">
|
||||
<div v-show="isDerivative == 'Derivative'" class="MR_derive">
|
||||
|
||||
<el-tabs v-model="activeName">
|
||||
<!-- <el-tab-pane label="条件区域" name="first">
|
||||
@@ -132,15 +136,15 @@
|
||||
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
<div v-show="activeName!=='first'">
|
||||
<teV2 v-model="formula" :hint="activeName=='second'">
|
||||
<div v-show="activeName !== 'first'">
|
||||
<teV2 v-model="formula" :hint="activeName == 'second'">
|
||||
|
||||
</teV2>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div v-if="Sourcelist">
|
||||
<div v-if="isDerivative=='SQL'" class="MR_derive">
|
||||
<div v-if="isDerivative == 'SQL'" class="MR_derive">
|
||||
|
||||
<el-select v-model="SQLType" placeholder="请选择数据源类型" style="margin-top: 20px;width: 200px;"
|
||||
@change="SQLName = ''">
|
||||
@@ -161,19 +165,19 @@
|
||||
|
||||
<div class="codemirrirPs">
|
||||
<span>
|
||||
{{sqlplaceholder[SQLType]&&sqlplaceholder[SQLType].placeholder}} 按Ctrl唤醒提示
|
||||
{{ sqlplaceholder[SQLType] && sqlplaceholder[SQLType].placeholder }} 按Ctrl唤醒提示
|
||||
|
||||
|
||||
</span>
|
||||
<codemirror v-model="SQLItem" :MYname="sqlplaceholder[SQLType]&&sqlplaceholder[SQLType].mime"
|
||||
:mime="sqlplaceholder[SQLType]&&sqlplaceholder[SQLType].mime"></codemirror>
|
||||
<codemirror v-model="SQLItem" :MYname="sqlplaceholder[SQLType] && sqlplaceholder[SQLType].mime"
|
||||
:mime="sqlplaceholder[SQLType] && sqlplaceholder[SQLType].mime"></codemirror>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="ftype==4">
|
||||
<div v-if="ftype == 4">
|
||||
<el-select v-model="interfaceId" placeholder="请选择接口" style="margin-top: 20px;margin-left: 20px;">
|
||||
<el-option v-for="item in interfaceList" :key="item.id" :label="item.name" :value="item.id">
|
||||
</el-option>
|
||||
@@ -181,7 +185,7 @@
|
||||
<el-cascader style="margin-left: 20px;" placeholder="请选择接口下的字段" v-model="interfaceParseField"
|
||||
:key="keynum" :options="dataJson" :props="{ checkStrictly: true }" clearable></el-cascader>
|
||||
</div>
|
||||
<div v-if="valueType==6" class="MR_derive">
|
||||
<div v-if="valueType == 6" class="MR_derive">
|
||||
<p style="margin-top: 20px;">JSON:</p>
|
||||
<!-- <el-input type="textarea" v-model="jsonValue" :rows="9" style="margin-top: 20px;"
|
||||
placeholder="请输入格式JSON">
|
||||
@@ -197,13 +201,12 @@
|
||||
<!-- </p> -->
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="ftype==6">
|
||||
<div v-if="ftype == 6">
|
||||
<div v-if="codeKey" class="MR_derive">
|
||||
|
||||
<el-select v-model="MqType" placeholder="请选择类型" style="margin-top: 20px;width: 200px;"
|
||||
@change="MqId = ''">
|
||||
<el-option v-for="item in MqlistType" :key="item.type" :label="item.type"
|
||||
:value="item.type">
|
||||
<el-option v-for="item in MqlistType" :key="item.type" :label="item.type" :value="item.type">
|
||||
</el-option>
|
||||
</el-select>
|
||||
|
||||
@@ -239,17 +242,17 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import codemirror from '@/components/common/codemirror.vue'
|
||||
// import fieldUserTable from './fieldUserTable.vue'
|
||||
import bindParam from '@/components/common/bindParam.vue'
|
||||
import '@/assets/css/ManageRedact.css'
|
||||
import teV2 from '@/components/common/teV2.vue'
|
||||
import mangeRedactMixin from '@/utils/contminxin/MangeRedactMixin.js'
|
||||
// import {
|
||||
// getInterfaceList
|
||||
// } from '@/api/index.js'
|
||||
import rule from './rule.vue'
|
||||
export default {
|
||||
import codemirror from '@/components/common/codemirror.vue'
|
||||
// import fieldUserTable from './fieldUserTable.vue'
|
||||
import bindParam from '@/components/common/bindParam.vue'
|
||||
import '@/assets/css/ManageRedact.css'
|
||||
import teV2 from '@/components/common/teV2.vue'
|
||||
import mangeRedactMixin from '@/utils/contminxin/MangeRedactMixin.js'
|
||||
// import {
|
||||
// getInterfaceList
|
||||
// } from '@/api/index.js'
|
||||
import rule from './rule.vue'
|
||||
export default {
|
||||
mixins: [mangeRedactMixin],
|
||||
components: {
|
||||
// getInterfaceList,
|
||||
@@ -266,7 +269,7 @@
|
||||
},
|
||||
setsave: {
|
||||
type: Function,
|
||||
default: () => {}
|
||||
default: () => { }
|
||||
},
|
||||
id: {
|
||||
type: Number,
|
||||
@@ -274,11 +277,11 @@
|
||||
},
|
||||
getInfo: {
|
||||
type: Function,
|
||||
default: () => {}
|
||||
default: () => { }
|
||||
},
|
||||
updata: {
|
||||
type: Function,
|
||||
default: () => {}
|
||||
default: () => { }
|
||||
},
|
||||
ftype: {
|
||||
type: Number,
|
||||
@@ -288,7 +291,7 @@
|
||||
|
||||
data() {
|
||||
return {
|
||||
codeKey:0, //方便code输入框重新渲染
|
||||
codeKey: 0, //方便code输入框重新渲染
|
||||
sqlVariable: [],
|
||||
interfaceParseField: [],
|
||||
keynum: 1,
|
||||
@@ -314,6 +317,7 @@
|
||||
lest: "", //暂存末尾
|
||||
isshow: false,
|
||||
islest: true,
|
||||
isLocalVariable: false,//是否为局部变量
|
||||
isStaticJsonValue: 0, //json是否为静态的 0为否
|
||||
// interfaceList: [],
|
||||
ruledata: [{
|
||||
@@ -363,7 +367,7 @@
|
||||
.interfaceParseField.split('.') : ''
|
||||
this.fid = res.data.fieldVo.fieldTypeId
|
||||
this.isOutput = res.data.fieldVo.isOutput == 1 ? true : false
|
||||
|
||||
this.isLocalVariable = res.data.fieldVo.isLocalVariable
|
||||
if (res.data.fieldVo.isDerivative) {
|
||||
this.isDerivative = 'Derivative'
|
||||
} else if (res.data.fieldVo.useSql) {
|
||||
@@ -403,12 +407,12 @@
|
||||
|
||||
|
||||
}
|
||||
if(this.ftype ==6){
|
||||
if (this.ftype == 6) {
|
||||
this.MqType = this.$store.state.Mqlist.find(x => x.id == res.data.fieldVo
|
||||
.mqSourceId).type
|
||||
this.MqId = res.data.fieldVo.mqSourceId
|
||||
this.SQLItem = res.data.fieldVo.sqlStatement
|
||||
console.log(res.data.fieldVo.sqlStatement,this.SQLItem)
|
||||
console.log(res.data.fieldVo.sqlStatement, this.SQLItem)
|
||||
}
|
||||
// console.log(res.data.fieldVo.fieldCondList)
|
||||
}
|
||||
@@ -651,6 +655,7 @@
|
||||
dataSourceId: 0,
|
||||
sqlStatement: '', //sql语句
|
||||
sourceType: this.ftype,
|
||||
isLocalVariable: this.isLocalVariable
|
||||
|
||||
}
|
||||
if (this.valueType == 6) {
|
||||
@@ -705,7 +710,7 @@
|
||||
obj.sqlStatement = this.SQLItem
|
||||
|
||||
}
|
||||
if(this.ftype == 6){
|
||||
if (this.ftype == 6) {
|
||||
obj.mqSourceId = this.MqId
|
||||
obj.sqlStatement = this.SQLItem
|
||||
}
|
||||
@@ -899,5 +904,5 @@
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user