Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
datax-cloud
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
黄营
datax-cloud
Commits
15f0d08b
Commit
15f0d08b
authored
Jun 28, 2020
by
yuwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2.0.0项目初始化
parent
8da81b6a
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
75 additions
and
21 deletions
+75
-21
ApiMaskAdd.vue
datax-ui/src/views/market/apimask/ApiMaskAdd.vue
+3
-3
ApiMaskDetail.vue
datax-ui/src/views/market/apimask/ApiMaskDetail.vue
+10
-3
ApiMaskEdit.vue
datax-ui/src/views/market/apimask/ApiMaskEdit.vue
+16
-9
DataApiDetail.vue
datax-ui/src/views/market/dataapi/DataApiDetail.vue
+20
-0
DataApiEdit.vue
datax-ui/src/views/market/dataapi/DataApiEdit.vue
+26
-6
No files found.
datax-ui/src/views/market/apimask/ApiMaskAdd.vue
View file @
15f0d08b
...
@@ -220,9 +220,9 @@ export default {
...
@@ -220,9 +220,9 @@ export default {
})
})
},
},
apiSelectChanged
(
val
)
{
apiSelectChanged
(
val
)
{
this
.
resParamList
=
this
.
apiOptions
.
fi
lter
(
item
=>
item
.
id
===
val
).
map
(
function
(
item
)
{
this
.
resParamList
=
this
.
apiOptions
.
fi
nd
(
function
(
item
)
{
return
item
.
resParams
return
item
.
id
===
val
})
})
.
resParams
},
},
fieldRule
(
fieldName
)
{
fieldRule
(
fieldName
)
{
this
.
cipher
.
open
=
true
this
.
cipher
.
open
=
true
...
...
datax-ui/src/views/market/apimask/ApiMaskDetail.vue
View file @
15f0d08b
...
@@ -168,9 +168,16 @@ export default {
...
@@ -168,9 +168,16 @@ export default {
let
cipher
=
this
.
cipherTypeOptions
.
find
((
item
)
=>
{
let
cipher
=
this
.
cipherTypeOptions
.
find
((
item
)
=>
{
return
item
.
itemText
===
rule
.
cipherType
return
item
.
itemText
===
rule
.
cipherType
})
})
let
crypt
=
this
.
cryptTypeOptions
.
find
((
item
)
=>
{
let
crypt
=
{}
return
item
.
itemText
===
rule
.
cryptType
if
(
rule
.
cipherType
===
'1'
)
{
})
crypt
=
this
.
regexCryptoOptions
.
find
((
item
)
=>
{
return
item
.
itemText
===
rule
.
cryptType
})
}
else
if
(
rule
.
cipherType
===
'2'
)
{
crypt
=
this
.
algorithmCryptoOptions
.
find
((
item
)
=>
{
return
item
.
itemText
===
rule
.
cryptType
})
}
let
resParam
=
Object
.
assign
({},
this
.
resParamList
[
fieldParamIndex
],
{
cipherType
:
(
cipher
&&
cipher
.
itemValue
)
||
undefined
,
cryptType
:
(
crypt
&&
crypt
.
itemValue
)
||
undefined
})
let
resParam
=
Object
.
assign
({},
this
.
resParamList
[
fieldParamIndex
],
{
cipherType
:
(
cipher
&&
cipher
.
itemValue
)
||
undefined
,
cryptType
:
(
crypt
&&
crypt
.
itemValue
)
||
undefined
})
this
.
$set
(
this
.
resParamList
,
fieldParamIndex
,
resParam
)
this
.
$set
(
this
.
resParamList
,
fieldParamIndex
,
resParam
)
}
}
...
...
datax-ui/src/views/market/apimask/ApiMaskEdit.vue
View file @
15f0d08b
...
@@ -226,9 +226,9 @@ export default {
...
@@ -226,9 +226,9 @@ export default {
getApiMask
(
id
).
then
(
response
=>
{
getApiMask
(
id
).
then
(
response
=>
{
if
(
response
.
success
)
{
if
(
response
.
success
)
{
this
.
form
=
response
.
data
this
.
form
=
response
.
data
this
.
resParamList
=
this
.
apiOptions
.
fi
lter
(
item
=>
item
.
id
===
this
.
form
.
apiId
).
map
(
function
(
item
)
{
this
.
resParamList
=
this
.
apiOptions
.
fi
nd
(
function
(
item
)
{
return
item
.
resParams
return
item
.
id
===
this
.
form
.
apiId
})
})
.
resParams
this
.
form
.
rules
.
forEach
(
rule
=>
{
this
.
form
.
rules
.
forEach
(
rule
=>
{
let
fieldParamIndex
=
this
.
resParamList
.
findIndex
((
param
)
=>
{
let
fieldParamIndex
=
this
.
resParamList
.
findIndex
((
param
)
=>
{
return
param
.
fieldName
===
rule
.
fieldName
return
param
.
fieldName
===
rule
.
fieldName
...
@@ -237,9 +237,16 @@ export default {
...
@@ -237,9 +237,16 @@ export default {
let
cipher
=
this
.
cipherTypeOptions
.
find
((
item
)
=>
{
let
cipher
=
this
.
cipherTypeOptions
.
find
((
item
)
=>
{
return
item
.
itemText
===
rule
.
cipherType
return
item
.
itemText
===
rule
.
cipherType
})
})
let
crypt
=
this
.
cryptTypeOptions
.
find
((
item
)
=>
{
let
crypt
=
{}
return
item
.
itemText
===
rule
.
cryptType
if
(
rule
.
cipherType
===
'1'
)
{
})
crypt
=
this
.
regexCryptoOptions
.
find
((
item
)
=>
{
return
item
.
itemText
===
rule
.
cryptType
})
}
else
if
(
rule
.
cipherType
===
'2'
)
{
crypt
=
this
.
algorithmCryptoOptions
.
find
((
item
)
=>
{
return
item
.
itemText
===
rule
.
cryptType
})
}
let
resParam
=
Object
.
assign
({},
this
.
resParamList
[
fieldParamIndex
],
{
cipherType
:
(
cipher
&&
cipher
.
itemValue
)
||
undefined
,
cryptType
:
(
crypt
&&
crypt
.
itemValue
)
||
undefined
})
let
resParam
=
Object
.
assign
({},
this
.
resParamList
[
fieldParamIndex
],
{
cipherType
:
(
cipher
&&
cipher
.
itemValue
)
||
undefined
,
cryptType
:
(
crypt
&&
crypt
.
itemValue
)
||
undefined
})
this
.
$set
(
this
.
resParamList
,
fieldParamIndex
,
resParam
)
this
.
$set
(
this
.
resParamList
,
fieldParamIndex
,
resParam
)
}
}
...
@@ -248,9 +255,9 @@ export default {
...
@@ -248,9 +255,9 @@ export default {
})
})
},
},
apiSelectChanged
(
val
)
{
apiSelectChanged
(
val
)
{
this
.
resParamList
=
this
.
apiOptions
.
fi
lter
(
item
=>
item
.
id
===
val
).
map
(
function
(
item
)
{
this
.
resParamList
=
this
.
apiOptions
.
fi
nd
(
function
(
item
)
{
return
item
.
resParams
return
item
.
id
===
val
})
})
.
resParams
},
},
fieldRule
(
fieldName
)
{
fieldRule
(
fieldName
)
{
this
.
cipher
.
open
=
true
this
.
cipher
.
open
=
true
...
...
datax-ui/src/views/market/dataapi/DataApiDetail.vue
View file @
15f0d08b
...
@@ -436,6 +436,26 @@ export default {
...
@@ -436,6 +436,26 @@ export default {
})
})
}
}
})
})
this
.
form1
.
reqParams
.
forEach
(
param
=>
{
let
paramIndex
=
this
.
fieldParamList
.
findIndex
((
item
)
=>
{
return
item
.
colName
===
param
.
paramName
})
if
(
paramIndex
!==
-
1
)
{
let
reqParam
=
this
.
fieldParamList
[
paramIndex
]
reqParam
.
reqable
=
true
this
.
$set
(
this
.
fieldParamList
,
paramIndex
,
reqParam
)
}
})
this
.
form1
.
resParams
.
forEach
(
field
=>
{
let
fieldIndex
=
this
.
fieldParamList
.
findIndex
((
item
)
=>
{
return
item
.
colName
===
field
.
fieldName
})
if
(
fieldIndex
!==
-
1
)
{
let
resParam
=
this
.
fieldParamList
[
fieldIndex
]
resParam
.
resable
=
true
this
.
$set
(
this
.
fieldParamList
,
fieldIndex
,
resParam
)
}
})
}
}
if
(
this
.
form2
.
configType
===
'2'
)
{
if
(
this
.
form2
.
configType
===
'2'
)
{
this
.
$refs
.
sqleditor
.
editor
.
setValue
(
this
.
form2
.
sqlText
)
this
.
$refs
.
sqleditor
.
editor
.
setValue
(
this
.
form2
.
sqlText
)
...
...
datax-ui/src/views/market/dataapi/DataApiEdit.vue
View file @
15f0d08b
...
@@ -435,11 +435,11 @@ export default {
...
@@ -435,11 +435,11 @@ export default {
let
json
=
{}
let
json
=
{}
json
.
paramName
=
item
.
colName
json
.
paramName
=
item
.
colName
json
.
nullable
=
item
.
nullable
||
'0'
json
.
nullable
=
item
.
nullable
||
'0'
json
.
remark
=
item
.
remark
||
undefined
json
.
remark
=
item
.
colComment
||
undefined
json
.
paramType
=
item
.
paramType
||
undefined
json
.
paramType
=
undefined
json
.
whereType
=
item
.
whereType
||
undefined
json
.
whereType
=
undefined
json
.
exampleValue
=
item
.
exampleValue
||
undefined
json
.
exampleValue
=
undefined
json
.
defaultValue
=
item
.
d
efaultValue
||
undefined
json
.
defaultValue
=
item
.
d
ataDefault
||
undefined
return
json
return
json
})
})
this
.
form3
.
resParams
=
this
.
fieldParamList
.
filter
(
item
=>
item
.
resable
).
map
(
function
(
item
)
{
this
.
form3
.
resParams
=
this
.
fieldParamList
.
filter
(
item
=>
item
.
resable
).
map
(
function
(
item
)
{
...
@@ -447,7 +447,7 @@ export default {
...
@@ -447,7 +447,7 @@ export default {
json
.
fieldName
=
item
.
colName
json
.
fieldName
=
item
.
colName
json
.
remark
=
item
.
colComment
||
undefined
json
.
remark
=
item
.
colComment
||
undefined
json
.
dataType
=
item
.
dataType
||
undefined
json
.
dataType
=
item
.
dataType
||
undefined
json
.
exampleValue
=
item
.
exampleValue
||
undefined
json
.
exampleValue
=
undefined
return
json
return
json
})
})
}
}
...
@@ -546,6 +546,26 @@ export default {
...
@@ -546,6 +546,26 @@ export default {
this
.
fieldParamList
=
response
.
data
this
.
fieldParamList
=
response
.
data
}
}
})
})
this
.
form1
.
reqParams
.
forEach
(
param
=>
{
let
paramIndex
=
this
.
fieldParamList
.
findIndex
((
item
)
=>
{
return
item
.
colName
===
param
.
paramName
})
if
(
paramIndex
!==
-
1
)
{
let
reqParam
=
this
.
fieldParamList
[
paramIndex
]
reqParam
.
reqable
=
true
this
.
$set
(
this
.
fieldParamList
,
paramIndex
,
reqParam
)
}
})
this
.
form1
.
resParams
.
forEach
(
field
=>
{
let
fieldIndex
=
this
.
fieldParamList
.
findIndex
((
item
)
=>
{
return
item
.
colName
===
field
.
fieldName
})
if
(
fieldIndex
!==
-
1
)
{
let
resParam
=
this
.
fieldParamList
[
fieldIndex
]
resParam
.
resable
=
true
this
.
$set
(
this
.
fieldParamList
,
fieldIndex
,
resParam
)
}
})
}
}
})
})
}
}
...
...
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