Commit ab6029de by 李耀琨

修复bug

parent 74cbec0a
......@@ -2,13 +2,15 @@ ENV = 'development'
VUE_APP_BASE_API = 'http://192.168.0.44:9888/'
VUE_APP_WS_API = 'ws://192.168.0.44:9888/'
# 接口地址
# VUE_APP_BASE_API = 'http://192.168.0.200'
# VUE_APP_WS_API = 'ws://192.168.0.200'
#V1UE_APP_BASE_API = 'http://192.168.0.44'
#VUE_APP_WS_API = 'ws://192.168.0.44'
VUE_APP_FILE_API = ''
......
......@@ -85,6 +85,8 @@ export default {
// if (node.level > this.PopupFrom.length) return resolve([]);
},
handleNodeClick(data, node) {
console.log("点击当前节点node===", node);
console.log("点击当前节点data===", data);
......
......@@ -6,6 +6,12 @@
width="800px"
:before-close="handleClose"
> -->
<el-dialog
title="自定义常量数据"
:visible.sync="ConstantDialog"
width="800px"
:before-close="handleCloseFun"
>
<el-form ref="form" :model="form" label-width="120px">
......@@ -90,13 +96,20 @@
</el-table>
</el-tab-pane>
</el-tabs>
<span slot="footer" class="dialog-footer">
<el-button @click="handleCloseFun">取 消</el-button>
<el-button type="primary" @click="ConstantDialogFun">确 定</el-button>
</span>
</el-dialog>
<el-dialog
title="添加元数据"
:visible.sync="metadata"
width="500px"
:before-close="handleClose"
:modal="false"
>
<el-form ref="form" :model="metadataForm" label-width="160px">
<el-form-item label="名称:">
......@@ -187,13 +200,7 @@
</el-dialog>
<!-- <span slot="footer" class="dialog-footer">
<el-button @click="ConstantDialog = false">取 消</el-button>
<el-button type="primary" @click="myConfirm"
>确 定</el-button
>
</span> -->
<!-- </el-dialog> -->
</div>
</template>
......@@ -202,27 +209,31 @@
import { valueFormat, valueMeta } from "@/api/kettle/link";
export default {
props: ["form"],
props: ["form","ConstantDialog","saveOutputDialog"],
data() {
return {
metadataForm: {
},
metadataForm: {},
metadata: false,
addValue: false,
ValueForm: {},
activeName: "first",
data: this.form.data,
fields: this.form.fields,
data:[],
fields:[],
fieldFormat: {},
fieldType: {},
dataStatus:false,
newGraph:[],
};
},
watch:{
// from(n,o){
// console.log(n.fields,'fileds');
// this.fields=n.fields
// }
// myForm(n, o) {
// console.log("回显的表单数据===",n);
// if(n){
......@@ -233,27 +244,39 @@ export default {
// }
// },
},
// props:["ConstantDialog","saveOutputDialog","doubleClickCell","myForm"],
created() {
this.valueFormatFun();
this.valueMetaFun();
},
methods: {
clickFun(graph,val){
console.log(graph,'双击获取值')
this.newGraph = graph;
console.log(val,"拿到form");
this.fields = JSON.parse(val.fields)
this.data = JSON.parse(val.data)
},
addDetermine(){
this.metadata = !this.metadata
console.log(this.metadataForm,787987987987987);
console.log(this.form,"form");
console.log(this.fields)
if (this.dataStatus) {
this.fields.push(this.metadataForm)
console.log(this.fields,12345)
// this.fields.push(this.metadataForm)
//
}else{
}
},
......@@ -261,7 +284,6 @@ export default {
this.addValue = !this.addValue
if (this.dataStatus) {
this.data.push(this.ValueForm);
//
}else{
}
......@@ -293,6 +315,8 @@ this.addValue = !this.addValue
},
// 关闭弹框
handleClose(done) {
this.$confirm("确认关闭?")
......@@ -325,22 +349,19 @@ this.addValue = !this.addValue
this.fieldType = res;
});
},
handleCloseFun(){
this.$emit("update:ConstantDialog", false);
},
ConstantDialogFun() {
this.handleCloseFun()
this.form.data = JSON.stringify(this.data);
this.form.fields = JSON.stringify(this.fields);
this.saveOutputDialog(this.form)
},
// mxl=========================
// myConfirm(){
// this.myForm.fields=JSON.stringify(this.tableData);//查询字段
// this.myForm.data=JSON.stringify(this.data);//更新字段
// this.myForm.label=this.form.name;
// console.log('弹窗数据===',this.myForm);
// this.saveOutputDialog(this.myForm);
// this.handleClose();//关闭弹窗
// },
// handleClose(){
// this.$emit("update:ConstantDialog", false);
// },
// mxl=========================
},
};
</script>
......
<template>
<div class="customConstant">
<el-dialog
title="生成记录"
:visible.sync="RowGeneratorDialog"
width="800px"
:before-close="handleCloseFun"
>
<el-form ref="form" :model="form" label-width="120px">
<el-form-item label="步骤名称:">
<el-input v-model="form.label"></el-input>
......@@ -78,6 +85,14 @@
</el-table-column>
</el-table>
</el-card>
<span slot="footer" class="dialog-footer">
<el-button @click="handleCloseFun">取 消</el-button>
<el-button type="primary" @click="RowGeneratorDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<el-dialog
title="添加字段"
......@@ -157,17 +172,19 @@
import { valueFormat, valueMeta } from "@/api/kettle/link";
export default {
props: ["custom","form"],
props: ["custom","form","RowGeneratorDialog","saveOutputDialog"],
data() {
return {
metadataForm: {},
metadata: false,
activeName: "first",
data: [],
fields: this.form.fields,
fields: [],
fieldFormat: {},
fieldType: {},
dataState: false,
newGraph:[],
};
},
......@@ -178,6 +195,16 @@ export default {
methods: {
clickFun(graph,val){
console.log(graph,'双击获取值')
this.newGraph = graph;
console.log(val,"拿到form");
this.fields = JSON.parse(val.fields)
},
addMetadata(){
this.metadata = !this.metadata
if (this.dataState) {
......@@ -189,6 +216,16 @@ this.metadata = !this.metadata
}
},
handleCloseFun(){
this.$emit("update:RowGeneratorDialog", false);
},
RowGeneratorDialogFun() {
this.handleCloseFun()
this.form.fields = JSON.stringify(this.fields);
this.saveOutputDialog(this.form)
},
addField(state, val) {
......
<template>
<div class="getSystemInformation">
<el-dialog
title="获取系统信息"
:visible.sync="SystemInfoDialog"
width="800px"
:before-close="handleCloseFun"
>
<el-form ref="form" :model="form" label-width="120px">
<el-form-item label="步骤名称:">
......@@ -38,6 +43,11 @@
</el-table>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button @click="handleCloseFun">取 消</el-button>
<el-button type="primary" @click="SystemInfoDialogFun">确 定</el-button>
</span>
</el-dialog>
<el-dialog
title="添加字段"
......@@ -75,11 +85,11 @@
import { systemDataTypes } from "@/api/kettle/link";
export default {
props: ["form"],
props: ["form","SystemInfoDialog","saveOutputDialog","nodeData"],
data() {
return {
addField: false,
fields: this.form.fields,
fields: [],
type: {},
dataStatus:false,
fiel:{},
......@@ -95,6 +105,25 @@ export default {
methods: {
clickFun(graph,val){
console.log(graph,'双击获取值')
this.newGraph = graph;
console.log(val,"拿到form");
this.fields = JSON.parse(val.fields)
},
handleCloseFun(){
this.$emit("update:SystemInfoDialog", false);
},
SystemInfoDialogFun() {
this.handleCloseFun()
this.form.fields = JSON.stringify(this.fields);
this.saveOutputDialog(this.form)
},
addFieldDetermine(){
this.addField = !this.addField
if (this.dataStatus) {
......
<template>
<div class="customConstant">
<el-dialog
title="获取变量"
:visible.sync="getVariableDialog"
width="800px"
:before-close="handleCloseFun"
>
<el-form ref="from" :model="form" label-width="120px">
<el-form-item label="步骤名称:">
<el-input v-model="form.label"></el-input>
......@@ -37,6 +44,15 @@
</el-table-column>
</el-table>
<span slot="footer" class="dialog-footer">
<el-button @click="handleCloseFun">取 消</el-button>
<el-button type="primary" @click="getVariableDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<el-dialog
title="添加字段"
:visible.sync="fieldBox"
......@@ -118,7 +134,7 @@ import {
variableType
} from "@/api/kettle/link";
export default {
props: ["connectionNode", "form", "nodeData"], //从父组件传过来的值
props: ["connectionNode", "form", "nodeData","getVariableDialog","saveOutputDialog"], //从父组件传过来的值
components: {
browseFiles,
......@@ -127,7 +143,7 @@ export default {
return {
newGraph: [],
fieldBox: false,
fields: this.form.fields,
fields: [],
metadataForm: {},
fieldFormat: {},
fieldCompress: {},
......@@ -152,9 +168,20 @@ export default {
},
methods: {
clickFun(graph) {
clickFun(graph,val) {
console.log(graph, 1);
this.newGraph = graph;
this.fields = JSON.parse(val.fields)
},
handleCloseFun(){
this.$emit("update:getVariableDialog", false);
},
getVariableDialogFun() {
this.form.fields = JSON.stringify(this.fields);
this.saveOutputDialog(this.form)
this.handleCloseFun()
},
getTheField() {
......
<template>
<div class="customConstant">
<el-dialog
title="合并行(比较)"
:visible.sync="mergeRecordsDialog"
width="800px"
:before-close="handleCloseFun"
>
<el-form ref="from" :model="form" label-width="120px">
<el-form-item label="步骤名称:">
<el-input v-model="form.label"></el-input>
......@@ -97,6 +105,16 @@
</el-card>
</el-col>
</el-row>
<span slot="footer" class="dialog-footer">
<el-button @click="handleCloseFun">取 消</el-button>
<el-button type="primary" @click="mergeRecordsDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<el-dialog
......@@ -169,7 +187,7 @@ import {
previousSteps,
} from "@/api/kettle/link";
export default {
props: ["connectionNode", "form", "nodeData"], //从父组件传过来的值
props: ["connectionNode", "form", "nodeData","saveOutputDialog","mergeRecordsDialog"], //从父组件传过来的值
components: {
browseFiles,
......@@ -179,8 +197,8 @@ export default {
newGraph: [],
fieldBox: false,
matchingFieldBox:false,
values:this.form.values,
keys:this.form.keys,
values:[],
keys:[],
metadataForm: {},
matchingFieldForm:{},
filterForm: {},
......@@ -206,9 +224,25 @@ export default {
},
methods: {
clickFun(graph) {
clickFun(graph,val) {
console.log(graph, 1);
this.newGraph = graph;
this.values = JSON.parse(val.values)
this.keys = JSON.parse(val.keys)
},
handleCloseFun(){
this.$emit("update:mergeRecordsDialog", false);
},
mergeRecordsDialogFun() {
this.handleCloseFun()
this.form.keys = JSON.stringify(this.keys);
this.form.values = JSON.stringify(this.values);
this.saveOutputDialog(this.form)
},
route(flowData) {
......
<template>
<div class="randomNumber">
<el-dialog
title="生成随机数"
:visible.sync="RandomValueDialog"
width="800px"
:before-close="handleCloseFun"
>
<el-form ref="from" :model="form" label-width="120px">
<el-form-item label="步骤名称:">
<el-input v-model="form.label"></el-input>
......@@ -41,7 +46,13 @@
</el-table>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button @click="handleCloseFun">取 消</el-button>
<el-button type="primary" @click="RandomValueDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<el-dialog
......@@ -80,10 +91,10 @@
import { randomValueFunc } from "@/api/kettle/link";
export default {
props: ["form"],
props: ["form","saveOutputDialog","RandomValueDialog"],
data() {
return {
fields: this.form.fields,
fields: [],
fiel:{},
random:{},
dataState:false,
......@@ -97,6 +108,26 @@ export default {
methods: {
clickFun(graph,val){
console.log(graph,'双击获取值')
this.newGraph = graph;
console.log(val,"拿到form");
this.fields = JSON.parse(val.fields)
},
handleCloseFun(){
this.$emit("update:RandomValueDialog", false);
},
RandomValueDialogFun() {
this.handleCloseFun()
this.form.fields = JSON.stringify(this.fields);
this.saveOutputDialog(this.form)
},
addSheet(state,val) {
this.addField = !this.addField;
this.dataState = state
......
<template>
<div class="customConstant">
<el-dialog
title="选择/改名值"
:visible.sync="selectFieldDialog"
width="800px"
:before-close="handleCloseFun"
>
<el-form ref="from" :model="form" label-width="120px">
<el-form-item label="步骤名称:">
<el-input v-model="form.label"></el-input>
......@@ -112,6 +118,15 @@
</el-tab-pane>
</el-tabs>
<span slot="footer" class="dialog-footer">
<el-button @click="handleCloseFun">取 消</el-button>
<el-button type="primary" @click="selectFieldDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<el-dialog
title="选择和修改"
......@@ -333,7 +348,7 @@ import {
inputOutputFields,
} from "@/api/kettle/link";
export default {
props: ["connectionNode", "form", "nodeData"], //从父组件传过来的值
props: ["connectionNode", "form", "nodeData","saveOutputDialog","selectFieldDialog"], //从父组件传过来的值
components: {
browseFiles,
......@@ -346,12 +361,10 @@ export default {
metadataBox: false,
selectModifyBox:false,
removeFieldBox:false,
filter: this.form.filter,
inputFields: this.form.inputFields,
fields:this.form.fields,
remove:this.form.remove,
meta:this.form.meta,
fields:[],
remove:[],
meta:[],
metadataForm:{},
selectModifyForm:{},
removeFieldForm:{},
......@@ -379,9 +392,27 @@ export default {
},
methods: {
clickFun(graph) {
console.log(graph, 1);
clickFun(graph,val) {
console.log(graph);
this.newGraph = graph;
this.fields= JSON.parse(val.fields)
this.remove= JSON.parse(val.remove)
this.meta= JSON.parse(val.meta)
},
handleCloseFun(){
this.$emit("update:selectFieldDialog", false);
},
selectFieldDialogFun(){
this.form.fields = JSON.stringify(this.fields);
this.form.remove = JSON.stringify(this.remove);
this.form.meta = JSON.stringify(this.meta);
this.saveOutputDialog(this.form)
this.handleCloseFun()
},
selectModifyGetTheField() {
......@@ -467,15 +498,6 @@ export default {
},
addFilterBox() {
this.filterBox = !this.filterBox;
if (this.dataState) {
this.filter.push(this.filterForm);
this.$emit("filter", this.filter);
} else {
}
},
deleteField(index, rows) {
......
<template>
<div class="customConstant">
<el-dialog
title="设置变量"
:visible.sync="setVariableDialog"
width="800px"
:before-close="handleCloseFun"
>
<el-form ref="from" :model="form" label-width="120px">
<el-form-item label="步骤名称:">
<el-input v-model="form.label"></el-input>
......@@ -37,6 +43,16 @@
</el-table-column>
</el-table>
<span slot="footer" class="dialog-footer">
<el-button @click="handleCloseFun">取 消</el-button>
<el-button type="primary" @click="setVariableDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<el-dialog
title="添加字段"
:visible.sync="fieldBox"
......@@ -118,7 +134,7 @@ import {
variableType
} from "@/api/kettle/link";
export default {
props: ["connectionNode", "form", "nodeData"], //从父组件传过来的值
props: ["connectionNode", "form", "nodeData","saveOutputDialog","setVariableDialog"], //从父组件传过来的值
components: {
browseFiles,
......@@ -127,7 +143,7 @@ export default {
return {
newGraph: [],
fieldBox: false,
fields: this.form.fields,
fields: [],
metadataForm: {},
fieldFormat: {},
fieldCompress: {},
......@@ -152,9 +168,20 @@ export default {
},
methods: {
clickFun(graph) {
clickFun(graph,val) {
console.log(graph, 1);
this.newGraph = graph;
this.fields = JSON.parse(val.fields)
},
handleCloseFun(){
this.$emit("update:setVariableDialog", false);
},
setVariableDialogFun() {
this.form.fields = JSON.stringify(this.fields);
this.saveOutputDialog(this.form)
this.handleCloseFun()
},
getTheField() {
......
<template>
<div class="customConstant">
<el-dialog
title="排序记录"
:visible.sync="sortRecordDialog"
width="800px"
:before-close="handleCloseFun"
>
<el-form ref="from" :model="form" label-width="120px">
<el-form-item label="步骤名称:">
<el-input v-model="form.label"></el-input>
......@@ -77,6 +83,12 @@
</el-table-column>
</el-table>
</el-card>
<span slot="footer" class="dialog-footer">
<el-button @click="handleCloseFun">取 消</el-button>
<el-button type="primary" @click="sortRecordDialogFun">确 定</el-button>
</span>
</el-dialog>
<el-dialog
title="添加字段"
......@@ -182,7 +194,7 @@ import {
inputOutputFields,
} from "@/api/kettle/link";
export default {
props: ["connectionNode", "form", "nodeData"], //从父组件传过来的值
props: ["connectionNode", "form", "nodeData","sortRecordDialog","saveOutputDialog"], //从父组件传过来的值
components: {
browseFiles,
......@@ -193,7 +205,7 @@ export default {
fileBox: false,
filterBox: false,
fieldBox: false,
fields: this.form.fields,
fields: [],
metadataForm: {},
filterForm: {},
fieldFormat: {},
......@@ -205,7 +217,7 @@ export default {
routeState: 0,
filePathSelection: false,
localPath: {},
fileSelection: this.form,
fileSelection: {},
fielForm: {},
fieldsName:[],
};
......@@ -217,7 +229,6 @@ export default {
this.formatMapperLineTerminatorFun();
this.availableCharsetsFun();
this.compressionProviderNamesFun();
console.log(this.form,79879798798);
},
methods: {
......@@ -225,9 +236,21 @@ export default {
this.filePathSelection = !this.filePathSelection;
},
clickFun(graph) {
clickFun(graph,val) {
console.log(graph, 1);
this.newGraph = graph;
this.fields = JSON.parse(val.fields)
this.fileSelection = val
},
handleCloseFun(){
this.$emit("update:sortRecordDialog", false);
},
sortRecordDialogFun() {
this.handleCloseFun()
this.form.fields = JSON.stringify(this.fields);
this.saveOutputDialog(this.form)
},
getTheField() {
......
<template>
<div class="customConstant">
<el-dialog
title="文本文件输入"
:visible.sync="TextFileInputDialog"
width="800px"
:before-close="handleCloseFun"
>
<el-form ref="from" :model="form" label-width="120px">
<el-form-item label="步骤名称:">
<el-input v-model="form.label"></el-input>
......@@ -555,6 +561,17 @@
</el-tabs>
<span slot="footer" class="dialog-footer">
<el-button @click="handleCloseFun">取 消</el-button>
<el-button type="primary" @click="TextFileInputDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<el-dialog
title="修改文件内容"
:visible.sync="fileBox"
......@@ -770,7 +787,7 @@ const {
import { valueFormat, valueMeta,formatMapperLineTerminator,availableCharsets,compressionProviderNames,inputOutputFields } from "@/api/kettle/link";
export default {
props: ["connectionNode","form","nodeData"], //从父组件传过来的值
props: ["connectionNode","form","nodeData","TextFileInputDialog","saveOutputDialog"], //从父组件传过来的值
components: {
browseFiles,
......@@ -781,9 +798,9 @@ export default {
fileBox:false,
filterBox: false,
fieldBox: false,
fileNameStore: this.form.fileNameStore,
filter: this.form.filter,
inputFields: this.form.inputFields,
fileNameStore:[],
filter: [],
inputFields: [],
metadataForm: {},
filterForm: {},
fieldFormat: {},
......@@ -813,9 +830,31 @@ export default {
methods: {
clickFun(graph) {
clickFun(graph,val) {
console.log(graph, 1);
this.newGraph = graph;
this.fileNameStore=JSON.parse(val.fileNameStore)
this.filter=JSON.parse(val.filter)
this.inputFields=JSON.parse(val.inputFields)
},
handleCloseFun(){
this.$emit("update:TextFileInputDialog", false);
},
TextFileInputDialogFun() {
this.handleCloseFun()
this.form.filter = JSON.stringify(this.filter);
this.form.inputFields = JSON.stringify(
this.inputFields
);
this.form.fileNameStore = JSON.stringify(
this.fileNameStore
);
this.saveOutputDialog(this.form)
},
getTheField(){
......
......@@ -719,7 +719,7 @@
:form="form"
:graphXml="graphXml"
:nodeData="nodeData"
ref="tableInputDialog"
ref="tableInput"
>
</tableInput>
......@@ -731,197 +731,131 @@
</el-dialog>
<!-- 获取系统信息-->
<el-dialog
title="获取系统信息"
:visible.sync="SystemInfoDialog"
width="800px"
:before-close="handleClose"
>
<getSystemInformation
ref="SystemInfoDialog"
ref="SystemInfo"
:disabled="true"
:form="form"
:nodeData="nodeData"
:SystemInfoDialog.sync="SystemInfoDialog"
:saveOutputDialog="saveOutputDialog"
>
</getSystemInformation>
<span slot="footer" class="dialog-footer">
<el-button @click="SystemInfoDialog = false">取 消</el-button>
<el-button type="primary" @click="SystemInfoDialogFun">确 定</el-button>
</span>
</el-dialog>
<!-- 自定义常量数据-->
<el-dialog
title="自定义常量数据"
:visible.sync="ConstantDialog"
width="800px"
:before-close="handleClose"
>
<customConstant ref="ConstantDialog" :disabled="true" :form="form">
<customConstant
ref="Constant"
:disabled="true"
:form="form"
:nodeData="nodeData"
:ConstantDialog.sync="ConstantDialog"
:saveOutputDialog="saveOutputDialog"
>
</customConstant>
<span slot="footer" class="dialog-footer">
<el-button @click="ConstantDialog = false">取 消</el-button>
<el-button type="primary" @click="ConstantDialogFun">确 定</el-button>
</span>
</el-dialog>
<!-- 自定义常量数据弹窗 -->
<!-- <customConstant :ConstantDialog.sync="ConstantDialog" :saveOutputDialog="saveOutputDialog" :doubleClickCell="doubleClickCell" :myForm="myoutPutFormData" > </customConstant> -->
<!-- 生成随机数-->
<el-dialog
<!-- <el-dialog
title="生成随机数"
:visible.sync="RandomValueDialog"
width="800px"
:before-close="handleClose"
>
<randomNumber ref="RandomValueDialog" :disabled="true" :form="form">
> -->
<randomNumber ref="RandomValue"
:disabled="true"
:form="form"
:RandomValueDialog.sync="RandomValueDialog"
:saveOutputDialog="saveOutputDialog">
</randomNumber>
<span slot="footer" class="dialog-footer">
<!-- <span slot="footer" class="dialog-footer">
<el-button @click="RandomValueDialog = false">取 消</el-button>
<el-button type="primary" @click="RandomValueDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
</el-dialog> -->
<!-- 生成记录-->
<el-dialog
title="生成记录"
:visible.sync="RowGeneratorDialog"
width="800px"
:before-close="handleClose"
>
<generatingRecords
ref="RowGeneratorDialog"
ref="RowGenerator"
:disabed="true"
:form="form"
:nodeData="nodeData"
:RowGeneratorDialog.sync="RowGeneratorDialog"
:saveOutputDialog="saveOutputDialog"
></generatingRecords>
<span slot="footer" class="dialog-footer">
<el-button @click="RowGeneratorDialog = false">取 消</el-button>
<el-button type="primary" @click="RowGeneratorDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<!-- 文本文件输入-->
<el-dialog
title="文本文件输入"
:visible.sync="TextFileInputDialog"
width="800px"
:before-close="handleClose"
>
<textFileInput
ref="TextFileInputDialog"
ref="TextFileInput"
:disabed="true"
:connectionNode="connectionNode"
:form="form"
:nodeData="nodeData"
:TextFileInputDialog.sync="TextFileInputDialog"
:saveOutputDialog="saveOutputDialog"
></textFileInput>
<span slot="footer" class="dialog-footer">
<el-button @click="TextFileInputDialog = false">取 消</el-button>
<el-button type="primary" @click="TextFileInputDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<!-- 排序记录-->
<el-dialog
title="排序记录"
:visible.sync="sortRecordDialog"
width="800px"
:before-close="handleClose"
>
<sortRecord
ref="sortRecordDialog"
ref="sortRecord"
:disabed="true"
:form="form"
:nodeData="nodeData"
:sortRecordDialog.sync="sortRecordDialog"
:saveOutputDialog="saveOutputDialog"
></sortRecord>
<span slot="footer" class="dialog-footer">
<el-button @click="sortRecordDialog = false">取 消</el-button>
<el-button type="primary" @click="sortRecordDialogFun">确 定</el-button>
</span>
</el-dialog>
<!-- 设置变量-->
<el-dialog
title="设置变量"
:visible.sync="setVariableDialog"
width="800px"
:before-close="handleClose"
>
<setVariable
ref="setVariableDialog"
ref="setVariable"
:disabed="true"
:form="form"
:nodeData="nodeData"
:setVariableDialog.sync="setVariableDialog"
:saveOutputDialog="saveOutputDialog"
></setVariable>
<span slot="footer" class="dialog-footer">
<el-button @click="setVariableDialog = false">取 消</el-button>
<el-button type="primary" @click="setVariableDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<!-- 获取变量-->
<el-dialog
title="获取变量"
:visible.sync="getVariableDialog"
width="800px"
:before-close="handleClose"
>
<setVariable
ref="getVariableDialog"
<getVariable
ref="getVariable"
:disabed="true"
:form="form"
:nodeData="nodeData"
></setVariable>
<span slot="footer" class="dialog-footer">
<el-button @click="getVariableDialog = false">取 消</el-button>
:getVariableDialog.sync="getVariableDialog"
:saveOutputDialog="saveOutputDialog"
></getVariable>
<el-button type="primary" @click="getVariableDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<!-- 合并记录-->
<el-dialog
title="合并行(比较)"
:visible.sync="mergeRecordsDialog"
width="800px"
:before-close="handleClose"
>
<mergeRecords
ref="mergeRecordsDialog"
ref="mergeRecords"
:disabed="true"
:form="form"
:nodeData="nodeData"
:mergeRecordsDialog.sync="mergeRecordsDialog"
:saveOutputDialog="saveOutputDialog"
></mergeRecords>
<span slot="footer" class="dialog-footer">
<el-button @click="mergeRecordsDialog = false">取 消</el-button>
<el-button type="primary" @click="mergeRecordsDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
<!-- 改变开始复制的数量 -->
......@@ -944,29 +878,17 @@
</span>
</el-dialog>
<!-- 字段选择-->
<el-dialog
title="选择/改名值"
:visible.sync="selectFieldDialog"
width="800px"
:before-close="handleClose"
>
<!-- 选择字段 -->
<selectField
ref="selectFieldDialog"
ref="selectField"
:disabed="true"
:form="form"
:nodeData="nodeData"
:selectFieldDialog.sync="selectFieldDialog"
:saveOutputDialog="saveOutputDialog"
></selectField>
<span slot="footer" class="dialog-footer">
<el-button @click="selectFieldDialog = false">取 消</el-button>
<el-button type="primary" @click="selectFieldDialogFun"
>确 定</el-button
>
</span>
</el-dialog>
......@@ -1114,14 +1036,14 @@
<!-- 脚本弹窗组件end -->
<!-- 转换弹窗组件start -->
<columnChoose
<!-- <columnChoose
ref="insertOrdate"
:columnVisible.sync="columnVisible"
:saveOutputDialog="saveOutputDialog"
:doubleClickCell="doubleClickCell"
:getXmlVal="getXmlVal"
:insertOrUpdateFormSend="outPutFormData2"
></columnChoose>
></columnChoose> -->
<!-- 转换弹窗组件end -->
......@@ -1232,7 +1154,6 @@ import sqlScriptDialog from "../../../script-dialog/sql-script";
// 脚本弹窗组件end-----------------------
// 转换弹窗组件start----------
import columnChoose from "../../../trans-dialog/column-choose";
// 转换弹窗组件end------------
import mxgraph from "@/utils/mxgraph";
......@@ -1438,7 +1359,6 @@ export default {
// 脚本弹窗组件---
// 转换弹窗组件start---
columnChoose,
// 转换弹窗组件end-----
},
//自定义指令 https://www.jb51.net/article/108047.htm
......@@ -1616,78 +1536,78 @@ export default {
}
},
ConstantDialogFun() {
this.ConstantDialog = !this.ConstantDialog;
console.log(this.$refs.ConstantDialog.data, "asghaksghk");
console.log(this.$refs.ConstantDialog.fields, "asghaksghk");
this.form.data = JSON.stringify(this.$refs.ConstantDialog.data);
this.form.fields = JSON.stringify(this.$refs.ConstantDialog.fields);
for (let name in this.form) {
var edit = new mxCellAttributeChange(
this.nodeData,
name,
this.form[name]
);
this.graph.getModel().execute(edit);
}
},
SystemInfoDialogFun() {
this.SystemInfoDialog = !this.SystemInfoDialog;
console.log(this.$refs.SystemInfoDialog.fields, 456753275328);
this.form.fields = JSON.stringify(this.$refs.SystemInfoDialog.fields);
for (let name in this.form) {
var edit = new mxCellAttributeChange(
this.nodeData,
name,
this.form[name]
);
this.graph.getModel().execute(edit);
}
},
// ConstantDialogFun() {
// this.ConstantDialog = !this.ConstantDialog;
// console.log(this.$refs.ConstantDialog.data, "asghaksghk");
// console.log(this.$refs.ConstantDialog.fields, "asghaksghk");
// this.form.data = JSON.stringify(this.$refs.ConstantDialog.data);
// this.form.fields = JSON.stringify(this.$refs.ConstantDialog.fields);
// for (let name in this.form) {
// var edit = new mxCellAttributeChange(
// this.nodeData,
// name,
// this.form[name]
// );
// this.graph.getModel().execute(edit);
// }
// },
RandomValueDialogFun() {
this.RandomValueDialog = !this.RandomValueDialog;
// SystemInfoDialogFun() {
// this.SystemInfoDialog = !this.SystemInfoDialog;
// console.log(this.$refs.SystemInfoDialog.fields, 456753275328);
// this.form.fields = JSON.stringify(this.$refs.SystemInfoDialog.fields);
// for (let name in this.form) {
// var edit = new mxCellAttributeChange(
// this.nodeData,
// name,
// this.form[name]
// );
// this.graph.getModel().execute(edit);
// }
// },
console.log(this.$refs.RandomValueDialog.fields, 4564654654);
this.form.fields = JSON.stringify(this.$refs.RandomValueDialog.fields);
for (let name in this.form) {
var edit = new mxCellAttributeChange(
this.nodeData,
name,
this.form[name]
);
this.graph.getModel().execute(edit);
}
},
// RandomValueDialogFun() {
// this.RandomValueDialog = !this.RandomValueDialog;
// console.log(this.$refs.RandomValueDialog.fields, 4564654654);
// this.form.fields = JSON.stringify(this.$refs.RandomValueDialog.fields);
// for (let name in this.form) {
// var edit = new mxCellAttributeChange(
// this.nodeData,
// name,
// this.form[name]
// );
// this.graph.getModel().execute(edit);
// }
// },
RowGeneratorDialogFun() {
this.RowGeneratorDialog = !this.RowGeneratorDialog;
console.log(this.$refs.RowGeneratorDialog.fields, 4564654654);
this.form.fields = JSON.stringify(this.$refs.RowGeneratorDialog.fields);
for (let name in this.form) {
var edit = new mxCellAttributeChange(
this.nodeData,
name,
this.form[name]
);
this.graph.getModel().execute(edit);
}
},
selectFieldDialogFun(){
this.selectFieldDialog = !this.selectFieldDialog
this.form.fields = JSON.stringify(this.$refs.selectFieldDialog.fields);
this.form.remove = JSON.stringify(this.$refs.selectFieldDialog.remove);
this.form.meta = JSON.stringify(this.$refs.selectFieldDialog.meta);
for (let name in this.form) {
var edit = new mxCellAttributeChange(
this.nodeData,
name,
this.form[name]
);
this.graph.getModel().execute(edit);
}
},
// RowGeneratorDialogFun() {
// this.RowGeneratorDialog = !this.RowGeneratorDialog;
// console.log(this.$refs.RowGeneratorDialog.fields, 4564654654);
// this.form.fields = JSON.stringify(this.$refs.RowGeneratorDialog.fields);
// for (let name in this.form) {
// var edit = new mxCellAttributeChange(
// this.nodeData,
// name,
// this.form[name]
// );
// this.graph.getModel().execute(edit);
// }
// },
// selectFieldDialogFun(){
// this.selectFieldDialog = !this.selectFieldDialog
// this.form.fields = JSON.stringify(this.$refs.selectFieldDialog.fields);
// this.form.remove = JSON.stringify(this.$refs.selectFieldDialog.remove);
// this.form.meta = JSON.stringify(this.$refs.selectFieldDialog.meta);
// for (let name in this.form) {
// var edit = new mxCellAttributeChange(
// this.nodeData,
// name,
// this.form[name]
// );
// this.graph.getModel().execute(edit);
// }
// },
mergeRecordsDialogFun() {
......@@ -1704,9 +1624,12 @@ export default {
}
},
copyNumberFun(){
console.log(this.form,"数据");
this.copyNumber = !this.copyNumber
for (let name in this.form) {
var edit = new mxCellAttributeChange(
this.nodeData,
......@@ -1716,65 +1639,66 @@ export default {
this.graph.getModel().execute(edit);
}
this.form = []
this.form = {}
console.log(this.form,"7798798798");
},
getVariableDialogFun() {
this.getVariableDialog = !this.getVariableDialog;
this.form.fields = JSON.stringify(this.$refs.getVariableDialog.fields);
for (let name in this.form) {
var edit = new mxCellAttributeChange(
this.nodeData,
name,
this.form[name]
);
this.graph.getModel().execute(edit);
}
},
// getVariableDialogFun() {
// this.getVariableDialog = !this.getVariableDialog;
// this.form.fields = JSON.stringify(this.$refs.getVariableDialog.fields);
// for (let name in this.form) {
// var edit = new mxCellAttributeChange(
// this.nodeData,
// name,
// this.form[name]
// );
// this.graph.getModel().execute(edit);
// }
// },
setVariableDialogFun() {
this.setVariableDialog = !this.setVariableDialog;
this.form.fields = JSON.stringify(this.$refs.setVariableDialog.fields);
for (let name in this.form) {
var edit = new mxCellAttributeChange(
this.nodeData,
name,
this.form[name]
);
this.graph.getModel().execute(edit);
}
},
sortRecordDialogFun() {
this.sortRecordDialog = !this.sortRecordDialog;
this.form.fields = JSON.stringify(this.$refs.sortRecordDialog.fields);
for (let name in this.form) {
var edit = new mxCellAttributeChange(
this.nodeData,
name,
this.form[name]
);
this.graph.getModel().execute(edit);
}
},
// setVariableDialogFun() {
// this.setVariableDialog = !this.setVariableDialog;
// this.form.fields = JSON.stringify(this.$refs.setVariableDialog.fields);
// for (let name in this.form) {
// var edit = new mxCellAttributeChange(
// this.nodeData,
// name,
// this.form[name]
// );
// this.graph.getModel().execute(edit);
// }
// },
// sortRecordDialogFun() {
// this.sortRecordDialog = !this.sortRecordDialog;
// this.form.fields = JSON.stringify(this.$refs.sortRecordDialog.fields);
// for (let name in this.form) {
// var edit = new mxCellAttributeChange(
// this.nodeData,
// name,
// this.form[name]
// );
// this.graph.getModel().execute(edit);
// }
// },
TextFileInputDialogFun() {
this.TextFileInputDialog = !this.TextFileInputDialog;
this.form.filter = JSON.stringify(this.$refs.TextFileInputDialog.filter);
this.form.inputFields = JSON.stringify(
this.$refs.TextFileInputDialog.inputFields
);
this.form.fileNameStore = JSON.stringify(
this.$refs.TextFileInputDialog.fileNameStore
);
for (let name in this.form) {
var edit = new mxCellAttributeChange(
this.nodeData,
name,
this.form[name]
);
this.graph.getModel().execute(edit);
}
},
// TextFileInputDialogFun() {
// this.TextFileInputDialog = !this.TextFileInputDialog;
// this.form.filter = JSON.stringify(this.$refs.TextFileInputDialog.filter);
// this.form.inputFields = JSON.stringify(
// this.$refs.TextFileInputDialog.inputFields
// );
// this.form.fileNameStore = JSON.stringify(
// this.$refs.TextFileInputDialog.fileNameStore
// );
// for (let name in this.form) {
// var edit = new mxCellAttributeChange(
// this.nodeData,
// name,
// this.form[name]
// );
// this.graph.getModel().execute(edit);
// }
// },
excelLnputDetermine() {
this.excelLnput = !this.excelLnput;
......@@ -2127,39 +2051,19 @@ export default {
if ( cell.dis == "step27" ||
cell.value.attributes.ctype.value == "SelectValues") {
this.selectFieldDialog = !this.selectFieldDialog
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
q.fields = JSON.parse(q.fields);
q.remove = JSON.parse(q.remove);
q.meta = JSON.parse(q.meta);
console.log(q, 45646546464);
this.form = q;
this.form = this.showDataFunc()
setTimeout(() => {
this.$refs.selectFieldDialog.clickFun(this.graph);
this.$refs.selectField.clickFun(this.graph,this.form);
}, 500);
}else if (
cell.dis == "step50" ||
cell.value.attributes.ctype.value == "MergeRows"
) {
this.mergeRecordsDialog = !this.mergeRecordsDialog;
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
q.keys = JSON.parse(q.keys);
q.values = JSON.parse(q.values);
console.log(q, 45646546464);
this.form = q;
this.form = this.showDataFunc()
setTimeout(() => {
this.$refs.mergeRecordsDialog.clickFun(this.graph);
this.$refs.mergeRecords.clickFun(this.graph,this.form);
}, 500);
return;
} else if (
......@@ -2167,18 +2071,9 @@ export default {
cell.value.attributes.ctype.value == "GetVariable"
) {
this.getVariableDialog = !this.getVariableDialog;
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
q.fields = JSON.parse(q.fields);
console.log(q, 45646546464);
this.form = q;
this.form = this.showDataFunc()
setTimeout(() => {
this.$refs.setVariableDialog.clickFun(this.graph);
this.$refs.getVariable.clickFun(this.graph,this.form);
}, 500);
return;
} else if (
......@@ -2186,18 +2081,9 @@ export default {
cell.value.attributes.ctype.value == "SetVariable"
) {
this.setVariableDialog = !this.setVariableDialog;
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
q.fields = JSON.parse(q.fields);
console.log(q, 45646546464);
this.form = q;
this.form = this.showDataFunc()
setTimeout(() => {
this.$refs.setVariableDialog.clickFun(this.graph);
this.$refs.setVariable.clickFun(this.graph,this.form);
}, 500);
return;
}
......@@ -2206,18 +2092,9 @@ export default {
cell.value.attributes.ctype.value == "SortRows"
) {
this.sortRecordDialog = !this.sortRecordDialog;
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
q.fields = JSON.parse(q.fields);
console.log(q, 45646546464);
this.form = q;
this.form = this.showDataFunc()
setTimeout(() => {
this.$refs.sortRecordDialog.clickFun(this.graph);
this.$refs.sortRecord.clickFun(this.graph,this.form);
}, 500);
return;
} else if (
......@@ -2246,23 +2123,10 @@ export default {
cell.value.attributes.ctype.value == "TableInput"
) {
this.TableInputDialog = !this.TableInputDialog;
var enc = new mxCodec(mxUtils.createXmlDocument());
var node = enc.encode(this.graph.getModel());
this.graphXml = mxUtils.getPrettyXml(node);
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
this.form = q;
this.form = this.showDataFunc();
this.form.sql = decodeURIComponent(this.form.sql);
setTimeout(() => {
this.$refs.tableInputDialog.clickFun(this.graph);
this.$refs.tableInput.clickFun(this.graph);
}, 500);
return;
......@@ -2271,83 +2135,51 @@ export default {
cell.value.attributes.ctype.value == "SystemInfo"
) {
this.SystemInfoDialog = !this.SystemInfoDialog;
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
q.fields = JSON.parse(q.fields);
this.form = q;
this.form = this.showDataFunc();
setTimeout(() => {
this.$refs.SystemInfo.clickFun(this.graph,this.form); //向子组件传递画布
}, 500);
return;
} else if (
(this.curFileType == "transformation" && cell.ids == "step5") ||
cell.value.attributes.ctype.value == "DataGrid"
) {
this.ConstantDialog = !this.ConstantDialog;
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
q.data = JSON.parse(q.data);
q.fields = JSON.parse(q.fields);
this.form = q;
this.form = this.showDataFunc();
setTimeout(() => {
this.$refs.Constant.clickFun(this.graph,this.form); //向子组件传递画布
}, 500);
return;
} else if (
(this.curFileType == "transformation" && cell.ids == "step4") ||
cell.value.attributes.ctype.value == "RandomValue"
) {
this.RandomValueDialog = !this.RandomValueDialog;
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
q.fields = JSON.parse(q.fields);
this.form = q;
this.form = this.showDataFunc();
setTimeout(() => {
this.$refs.RandomValue.clickFun(this.graph,this.form); //向子组件传递画布
}, 500);
return;
} else if (
(this.curFileType == "transformation" && cell.ids == "step3") ||
cell.value.attributes.ctype.value == "RowGenerator"
) {
this.RowGeneratorDialog = !this.RowGeneratorDialog;
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
q.fields = JSON.parse(q.fields);
this.form = q;
this.form = this.showDataFunc();
setTimeout(() => {
this.$refs.RowGenerator.clickFun(this.graph,this.form);
}, 500);
return;
} else if (
(this.curFileType == "transformation" && cell.ids == "step2") ||
cell.value.attributes.ctype.value == "TextFileInput"
) {
this.TextFileInputDialog = !this.TextFileInputDialog;
this.form = {};
let q = {};
let obj = cell.value.attributes;
for (let vel in obj) {
let key = obj[vel];
q[key.name] = key.value;
}
console.log(q.fileNameStore, "sghywkglaslkhygslu");
q.fileNameStore = JSON.parse(q.fileNameStore);
q.inputFields = JSON.parse(q.inputFields);
q.filter = JSON.parse(q.filter);
this.form = q;
this.form = this.showDataFunc();
setTimeout(() => {
this.$refs.TextFileInputDialog.clickFun(this.graph);
this.$refs.TextFileInput.clickFun(this.graph,this.form);
}, 500);
return;
} else if (
......@@ -2610,7 +2442,7 @@ export default {
q[key.name] = key.value;
}
return this.form = q;
return q;
},
addCell(toolItem, x, y) {
......
......@@ -1209,17 +1209,22 @@ props: ["dragItem"],
},
// 新建任务
createJob(){
if(this.curNodeIconCls =='imageFolder'){
this.estabDialogVisible=true;
this.estabTitle='任务';
}else{
this.$message.error('请选择资源库中的一个目录');
}
},
// 新建目录
createFile(){
if(this.curNodeIconCls =='imageFolder'){
this.estabDialogVisible=true;
this.estabTitle='目录';
}else{
this.$message.error('请选择资源库中的一个目录');
}
},
// 删除资源库文件
......@@ -1252,7 +1257,6 @@ props: ["dragItem"],
this.curNode=node;//当前选中节点
this.nodePath=data.path;//当前选择数
this.curNodeIconCls=node.data.iconCls;
console.log('当前节点的文件夹路径:',this.nodePath);
if(node.data.leaf){
this.curNodeText=node.data.text;//当前节点
......@@ -1266,12 +1270,12 @@ props: ["dragItem"],
// this.tabShowFlag=true;//核心对象显项卡显示
//mxl判断作业和转换----------------------
if(node.data.type=="transformation"){
this.$refs.nodeMenu2.stepsFun();
let that=this;
setTimeout(function(){
that.$refs.graphContainer.initGraphClick("transformation");
},500)
})
}else if(node.data.type=="job"){
this.$refs.nodeMenu2.jobentrysFun();
let that=this;
......@@ -1293,16 +1297,16 @@ props: ["dragItem"],
})
}
// else{
// this.$message.error('请选择一个资源库!');
// return;
// }
// console.log(data,'当前节点的父节点:',node.parent.data);
},
//修改资源库
......@@ -1337,7 +1341,7 @@ props: ["dragItem"],
console.log('导出资源库====');
this.exportDialogVisible=true;
},
// 导入资源库弹窗
importTreeDialog(){
console.log('导入资源库====');
......
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