Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
ETL-admin
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
莫晓莉
ETL-admin
Commits
4cf30d89
Commit
4cf30d89
authored
Apr 09, 2021
by
莫晓莉
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交xml获取
parent
261a9af1
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
90 additions
and
32 deletions
+90
-32
src/views/dashboard-kettle/components/designer/mxgraphDesigner.vue
+3
-1
src/views/dialogs-components/global/database-choose/main.vue
+10
-2
src/views/dialogs-components/global/establish/main.vue
+18
-5
src/views/dialogs-components/global/trans-graph/main.vue
+13
-11
src/views/output-dialog/delete.vue
+3
-1
src/views/output-dialog/insertOrUpdate.vue
+4
-2
src/views/output-dialog/synchronize.vue
+4
-2
src/views/output-dialog/table-out.vue
+14
-5
src/views/output-dialog/text-file-output.vue
+16
-1
src/views/output-dialog/update.vue
+5
-2
No files found.
src/views/dashboard-kettle/components/designer/mxgraphDesigner.vue
View file @
4cf30d89
...
@@ -42,7 +42,7 @@
...
@@ -42,7 +42,7 @@
<el-tooltip
<el-tooltip
class=
"item"
class=
"item"
effect=
"dark"
effect=
"dark"
content=
"
重新绘制
"
content=
"
执行转换
"
placement=
"bottom"
placement=
"bottom"
>
>
<el-button
<el-button
...
@@ -1644,6 +1644,7 @@ export default {
...
@@ -1644,6 +1644,7 @@ export default {
//文本文件输出
//文本文件输出
this
.
fileVisible
=
!
this
.
fileVisible
;
this
.
fileVisible
=
!
this
.
fileVisible
;
this
.
outPutFormData8
=
this
.
showDataFunc
();
this
.
outPutFormData8
=
this
.
showDataFunc
();
this
.
$refs
.
textFile
.
clickFun
(
this
.
graph
);
//向子组件传递画布
return
;
return
;
}
else
if
(
cell
.
ids
==
"step14"
||
cell
.
value
.
attributes
.
ctype
.
value
==
"SynchronizeAfterMerge"
)
{
}
else
if
(
cell
.
ids
==
"step14"
||
cell
.
value
.
attributes
.
ctype
.
value
==
"SynchronizeAfterMerge"
)
{
//数据同步
//数据同步
...
@@ -1767,6 +1768,7 @@ export default {
...
@@ -1767,6 +1768,7 @@ export default {
getXml
()
{
getXml
()
{
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
graph
.
getModel
());
const
encodedModel
=
codec
.
encode
(
this
.
graph
.
getModel
());
console
.
log
(
encodedModel
,
46546465456
);
this
.
getXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
this
.
getXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
let
w
=
""
let
w
=
""
w
=
JSON
.
stringify
(
this
.
getXmlVal
)
w
=
JSON
.
stringify
(
this
.
getXmlVal
)
...
...
src/views/dialogs-components/global/database-choose/main.vue
View file @
4cf30d89
...
@@ -95,8 +95,16 @@ export default {
...
@@ -95,8 +95,16 @@ export default {
methods
:
{
methods
:
{
clickFun
(
graph
){
clickFun
(
graph
){
console
.
log
(
graph
,
'数据库编辑====='
)
let
codec
=
new
mxCodec
();
this
.
newGraph
=
graph
let
encodedModel
=
codec
.
encode
(
graph
.
getModel
());
let
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
console
.
log
(
'myXmlVal2'
,
myXmlVal
)
// console.log(graph,2)
// this.newGraph = graph;
// this.$refs.establishDia.clickFun(graph);
},
},
//获取新建弹窗返回来的值
//获取新建弹窗返回来的值
...
...
src/views/dialogs-components/global/establish/main.vue
View file @
4cf30d89
...
@@ -476,8 +476,13 @@ export default {
...
@@ -476,8 +476,13 @@ export default {
// },
// },
clickFun
(
graph
){
clickFun
(
graph
){
console
.
log
(
graph
,
'最内层'
)
console
.
log
(
graph
,
3
)
this
.
newGraph
=
graph
this
.
newGraph
=
graph
;
let
codec
=
new
mxCodec
();
let
encodedModel
=
codec
.
encode
(
graph
.
getModel
());
let
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
console
.
log
(
'myXmlVal3'
,
myXmlVal
)
},
},
...
@@ -501,9 +506,12 @@ export default {
...
@@ -501,9 +506,12 @@ export default {
// data.append("graphXml", this.getXmlVal);
// data.append("graphXml", this.getXmlVal);
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
console
.
log
(
"🚀 ~ file: main.vue ~ line 514 ~ getTransDatabase ~ this.newGraph.getModel()"
,
this
.
newGraph
.
getModel
())
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"转码钱画布详情:"
,
encodedModel
);
console
.
log
(
"转码钱画布详情:"
,
encodedModel
);
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
data
.
append
(
"graphXml"
,
myXmlVal
);
data
.
append
(
"graphXml"
,
myXmlVal
);
data
.
append
(
"name"
,
name
);
data
.
append
(
"name"
,
name
);
...
@@ -533,7 +541,7 @@ export default {
...
@@ -533,7 +541,7 @@ export default {
this
.
createModel
=
testJson
;
this
.
createModel
=
testJson
;
console
.
log
(
"写死的数据库----"
,
this
.
createModel
);
console
.
log
(
"写死的数据库----"
,
this
.
createModel
);
this
.
$emit
(
"getSonValue"
,
this
.
createModel
.
name
);
//组件要传回父组件的值
this
.
$emit
(
"getSonValue"
,
this
.
createModel
.
name
);
//组件要传回父组件的值
return
//
return
// 写死测试-------
// 写死测试-------
getTransDatabase
(
data
).
then
((
res
)
=>
{
getTransDatabase
(
data
).
then
((
res
)
=>
{
...
@@ -738,6 +746,10 @@ export default {
...
@@ -738,6 +746,10 @@ export default {
if
(
this
.
noneRespository
==
1
){
if
(
this
.
noneRespository
==
1
){
console
.
log
(
this
.
newGraph
,
'最内层接收画布99999999999999'
)
console
.
log
(
this
.
newGraph
,
'最内层接收画布99999999999999'
)
var
root
=
this
.
newGraph
.
getDefaultParent
();
var
root
=
this
.
newGraph
.
getDefaultParent
();
const
codecx
=
new
mxCodec
();
const
encodedModel2
=
codecx
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
var
myXmlVal2
=
mxUtils
.
getPrettyXml
(
encodedModel2
);
//xml字符串
console
.
log
(
"=============myXmlVa
\
n"
,
myXmlVal2
)
var
databases
=
root
.
getAttribute
(
'databases'
);
var
databases
=
root
.
getAttribute
(
'databases'
);
console
.
log
(
databases
,
'55555555555555555559'
)
console
.
log
(
databases
,
'55555555555555555559'
)
var
jsonArray
=
JSON
.
parse
(
databases
);
var
jsonArray
=
JSON
.
parse
(
databases
);
...
@@ -769,7 +781,8 @@ export default {
...
@@ -769,7 +781,8 @@ export default {
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
console
.
log
(
"🚀 ~ file: main.vue ~ line 774 ~ check ~ myXmlVal"
,
myXmlVal
)
console
.
log
(
encodedModel
,
8888888888888
);
console
.
log
(
encodedModel
,
8888888888888
);
this
.
$emit
(
"getSonValue"
,
false
);
//组件要传回父组件的值,关闭弹窗
this
.
$emit
(
"getSonValue"
,
false
);
//组件要传回父组件的值,关闭弹窗
...
...
src/views/dialogs-components/global/trans-graph/main.vue
View file @
4cf30d89
...
@@ -19,7 +19,7 @@
...
@@ -19,7 +19,7 @@
</el-table>
</el-table>
</el-tab-pane>
</el-tab-pane>
<el-tab-pane
label=
"日志"
name=
"second"
>
<el-tab-pane
label=
"日志"
name=
"second"
:disabled=
"!finished"
>
<div
style=
"height:50vh;overflow-y:auto;"
>
{{mylog}}
</div>
<div
style=
"height:50vh;overflow-y:auto;"
>
{{mylog}}
</div>
</el-tab-pane>
</el-tab-pane>
...
@@ -55,6 +55,7 @@ export default ({
...
@@ -55,6 +55,7 @@ export default ({
name
:
"trans-graph"
,
name
:
"trans-graph"
,
data
(){
data
(){
return
{
return
{
finished
:
false
,
//只有执行成功才显示日志
executionId
:
null
,
//执行转换返回id
executionId
:
null
,
//执行转换返回id
mylog
:
''
,
//日志
mylog
:
''
,
//日志
field
:
false
,
//编辑弹窗
field
:
false
,
//编辑弹窗
...
@@ -85,15 +86,15 @@ export default ({
...
@@ -85,15 +86,15 @@ export default ({
stepName
:{},
stepName
:{},
activeName
:
'first'
,
activeName
:
'first'
,
engine
:[],
engine
:[],
tableData
:
[
//
tableData: [
{
//
{
filemask
:
""
,
//
filemask: "",
name
:
"王小虎"
,
//
name: "王小虎",
exclude_filemask
:
""
,
//
exclude_filemask: "",
file_required
:
"0"
,
//
file_required: "0",
include_subfolders
:
"1"
,
//
include_subfolders: "1",
},
//
},
],
//
],
// 表头数据
// 表头数据
...
@@ -217,7 +218,8 @@ export default ({
...
@@ -217,7 +218,8 @@ export default ({
console
.
log
(
'返回执行的数据===='
,
res
);
console
.
log
(
'返回执行的数据===='
,
res
);
// this.tableData=res;
// this.tableData=res;
this
.
stepMeasure
=
res
.
stepMeasure
this
.
stepMeasure
=
res
.
stepMeasure
this
.
mylog
=
res
.
log
this
.
mylog
=
res
.
log
;
this
.
finished
=
res
.
finished
;
//执行转换以后
let
tableKeyArr
=
[
"name"
,
"num"
,
"r"
,
"x"
,
"i"
,
"o"
,
"u"
,
"f"
,
"e"
,
"a"
,
"t"
,
"s"
,
"pio"
]
let
tableKeyArr
=
[
"name"
,
"num"
,
"r"
,
"x"
,
"i"
,
"o"
,
"u"
,
"f"
,
"e"
,
"a"
,
"t"
,
"s"
,
"pio"
]
...
...
src/views/output-dialog/delete.vue
View file @
4cf30d89
...
@@ -288,7 +288,9 @@ export default ({
...
@@ -288,7 +288,9 @@ export default ({
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"graphXml"
,
myXmlVal
);
...
...
src/views/output-dialog/insertOrUpdate.vue
View file @
4cf30d89
...
@@ -442,7 +442,8 @@ export default ({
...
@@ -442,7 +442,8 @@ export default ({
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"schema"
,
this
.
insertOrUpdateForm
.
schema
);
pamer
.
append
(
"schema"
,
this
.
insertOrUpdateForm
.
schema
);
...
@@ -467,7 +468,8 @@ export default ({
...
@@ -467,7 +468,8 @@ export default ({
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"before"
,
true
);
pamer
.
append
(
"before"
,
true
);
...
...
src/views/output-dialog/synchronize.vue
View file @
4cf30d89
...
@@ -532,7 +532,8 @@ export default ({
...
@@ -532,7 +532,8 @@ export default ({
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"schema"
,
this
.
synForm
.
schema
);
pamer
.
append
(
"schema"
,
this
.
synForm
.
schema
);
...
@@ -557,7 +558,8 @@ export default ({
...
@@ -557,7 +558,8 @@ export default ({
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"before"
,
true
);
pamer
.
append
(
"before"
,
true
);
...
...
src/views/output-dialog/table-out.vue
View file @
4cf30d89
...
@@ -327,10 +327,17 @@ export default ({
...
@@ -327,10 +327,17 @@ export default ({
},
},
methods
:{
methods
:{
clickFun
(
graph
){
clickFun
(
graph
){
console
.
log
(
graph
,
'双击获取值'
)
console
.
log
(
graph
,
1
)
this
.
newGraph
=
graph
this
.
newGraph
=
graph
// this.$refs.databaseChoose.clickFun(graph);
setTimeout
(()
=>
{
this
.
$refs
.
databaseChoose
.
clickFun
(
this
.
newGraph
);
this
.
$refs
.
databaseChoose
.
clickFun
(
graph
,
121331
);
},
500
);
let
codec
=
new
mxCodec
();
let
encodedModel
=
codec
.
encode
(
graph
.
getModel
());
let
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
console
.
log
(
'myXmlVal1'
,
myXmlVal
)
},
},
confirm
(){
confirm
(){
this
.
tableOutForm
.
label
=
this
.
doubleClickCell
.
title
;
this
.
tableOutForm
.
label
=
this
.
doubleClickCell
.
title
;
...
@@ -364,7 +371,8 @@ export default ({
...
@@ -364,7 +371,8 @@ export default ({
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
pamer
.
append
(
"databaseName"
,
this
.
tableOutForm
.
connection
);
pamer
.
append
(
"databaseName"
,
this
.
tableOutForm
.
connection
);
...
@@ -393,7 +401,8 @@ export default ({
...
@@ -393,7 +401,8 @@ export default ({
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"before"
,
true
);
pamer
.
append
(
"before"
,
true
);
...
...
src/views/output-dialog/text-file-output.vue
View file @
4cf30d89
...
@@ -391,6 +391,7 @@ import {
...
@@ -391,6 +391,7 @@ import {
export
default
({
export
default
({
data
(){
data
(){
return
{
return
{
newGraph
:{},
metaStoreList
:[],
//类型
metaStoreList
:[],
//类型
formatStoreList
:[],
//字段格式
formatStoreList
:[],
//字段格式
fieldsList2
:[],
fieldsList2
:[],
...
@@ -561,6 +562,12 @@ export default ({
...
@@ -561,6 +562,12 @@ export default ({
},
},
methods
:{
methods
:{
clickFun
(
graph
){
console
.
log
(
graph
,
'双击获取值'
)
this
.
newGraph
=
graph
// this.$refs.databaseChoose.clickFun(graph);
// this.$refs.databaseChoose.clickFun(this.newGraph);
},
handleClose
(){
handleClose
(){
this
.
$emit
(
"update:fileVisible"
,
false
);
this
.
$emit
(
"update:fileVisible"
,
false
);
},
},
...
@@ -673,7 +680,15 @@ export default ({
...
@@ -673,7 +680,15 @@ export default ({
console
.
log
(
'获取cell888888==='
,
this
.
doubleClickCell
);
console
.
log
(
'获取cell888888==='
,
this
.
doubleClickCell
);
let
pamer
=
new
FormData
();
// 创建form对象
let
pamer
=
new
FormData
();
// 创建form对象
pamer
.
append
(
"stepName"
,
encodeURIComponent
(
title
));
pamer
.
append
(
"stepName"
,
encodeURIComponent
(
title
));
pamer
.
append
(
"graphXml"
,
this
.
getXmlVal
);
// pamer.append("graphXml", this.getXmlVal);
// 画布xml转码
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"before"
,
true
);
pamer
.
append
(
"before"
,
true
);
pamer
.
append
(
"query"
,
''
);
pamer
.
append
(
"query"
,
''
);
inputOutputFields
(
pamer
).
then
(
res
=>
{
inputOutputFields
(
pamer
).
then
(
res
=>
{
...
...
src/views/output-dialog/update.vue
View file @
4cf30d89
...
@@ -426,7 +426,8 @@ export default ({
...
@@ -426,7 +426,8 @@ export default ({
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"schema"
,
this
.
updateForm
.
schema
);
pamer
.
append
(
"schema"
,
this
.
updateForm
.
schema
);
...
@@ -451,7 +452,9 @@ export default ({
...
@@ -451,7 +452,9 @@ export default ({
const
codec
=
new
mxCodec
();
const
codec
=
new
mxCodec
();
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
const
encodedModel
=
codec
.
encode
(
this
.
newGraph
.
getModel
());
//xml对象
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
console
.
log
(
"获取字段的画布详情:"
,
encodedModel
);
var
myXmlVal
=
mxUtils
.
getXml
(
encodedModel
);
//xml字符串
// var myXmlVal = mxUtils.getXml(encodedModel);//xml字符串
var
myXmlVal
=
mxUtils
.
getPrettyXml
(
encodedModel
);
//xml字符串
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"graphXml"
,
myXmlVal
);
pamer
.
append
(
"before"
,
true
);
pamer
.
append
(
"before"
,
true
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment