Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mes-ui
Project
Project
Details
Activity
Releases
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
周远喜
mes-ui
Commits
7a0eddb2
Commit
7a0eddb2
authored
Aug 17, 2020
by
kangzhenfei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
saas--数据管理
parent
94f6d8cc
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
28 additions
and
19 deletions
+28
-19
zh-CN.js
i18n/locale/zh-CN.js
+1
-0
add.vue
pages/system/datasource/add.vue
+21
-19
setdetail.vue
pages/system/tanant/setdetail.vue
+6
-0
No files found.
i18n/locale/zh-CN.js
View file @
7a0eddb2
...
...
@@ -966,6 +966,7 @@ export default {
databaseTypeName
:
"数据库类型"
,
databaseName
:
"数据库"
,
databaseType
:
"数据字典主键"
,
displayName
:
"用途"
,
port
:
"端口"
,
tenantId
:
0
,
},
...
...
pages/system/datasource/add.vue
View file @
7a0eddb2
...
...
@@ -3,23 +3,23 @@
<Row>
<Col
:span=
"24"
>
<FormItem
:label=
"l('hostName')"
prop=
"hostName"
>
<!-- @on-change="onchange_host" -->
<Select
v-model=
"entity.hostId"
>
<Option
v-for=
"(item,index) in hostlist"
:key=
"index"
:value=
"item.id"
>
{{
item
.
name
}}
</Option>
</Select>
<!-- @on-change="onchange_host" -->
<Select
@
on-change=
"onchange_host"
v-model=
"entity.hostId"
>
<Option
v-for=
"(item,index) in hostlist"
:key=
"index"
:value=
"item.id"
>
{{
item
.
name
}}
</Option>
</Select>
</FormItem>
</Col>
<Col
:span=
"24"
>
<FormItem
:label=
"l('hostsq')"
prop=
"hostId"
>
<!--
<Input
v-model=
"entity.hostId"
></Input>
-->
<Dictionary
code=
"datasource.type"
v-model=
"entity.id"
type=
"select"
></Dictionary>
<!--
<Input
v-model=
"entity.hostId"
></Input>
-->
<Dictionary
code=
"datasource.type"
v-model=
"entity.id"
type=
"select"
></Dictionary>
</FormItem>
</Col>
<!--
<Col
:span=
"24"
>
<FormItem
:label=
"l('port')"
prop=
"port"
>
<InputNumber
v-model=
"entity.port"
></InputNumber>
</FormItem>
</Col>
-->
</Col>
-->
<Col
:span=
"24"
>
<FormItem
:label=
"l('userName')"
prop=
"userName"
>
<Input
v-model=
"entity.userName"
></Input>
...
...
@@ -45,15 +45,14 @@ export default {
return
{
disabled
:
false
,
entity
:
{
id
:
null
,
id
:
null
},
rules
:
{
// hostName: [{ required: true, message: "必选", type:"number",trigger: "change" }],
// hostName: [{ required: true, message: '单位不能为空', trigger: 'change',type: 'number' }],
// hostId:[{ required: true, message: "必选", type: "number",trigger: "change" }],
},
hostlist
:
[],
hostlist
:
[]
};
},
props
:
{
...
...
@@ -61,17 +60,17 @@ export default {
},
mounted
()
{
Api
.
bindhostlist
()
.
then
(
(
r
)
=>
{
console
.
log
(
r
)
.
then
(
r
=>
{
console
.
log
(
r
)
;
if
(
r
.
success
)
{
this
.
hostlist
=
r
.
result
this
.
hostlist
=
r
.
result
;
}
else
{
}
// this.hostlist.map(u=>{u.id = u.id+''})
})
.
catch
(
(
err
)
=>
{
console
.
warn
(
err
)
})
.
catch
(
err
=>
{
console
.
warn
(
err
)
;
})
;
},
methods
:
{
handleSubmit
()
{
...
...
@@ -97,9 +96,12 @@ export default {
});
},
onchange_host
(
val
)
{
// console.log(val)
console
.
log
(
typeof
(
val
))
this
.
entity
.
id
=
val
console
.
log
(
val
);
this
.
hostlist
.
map
(
u
=>
{
if
(
u
.
id
==
val
){
this
.
entity
.
hostName
=
u
.
name
}
});
},
handleClose
()
{
this
.
$emit
(
"on-close"
);
...
...
pages/system/tanant/setdetail.vue
View file @
7a0eddb2
...
...
@@ -72,6 +72,12 @@ export default {
align
:
"center"
,
width
:
140
},
{
key
:
"displayName"
,
title
:
this
.
l
(
"displayName"
),
align
:
"center"
,
width
:
100
},
{
key
:
"databaseName"
,
title
:
this
.
l
(
"databaseName"
),
...
...
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