Commit d2b422ea authored by 樊国敬's avatar 樊国敬

o

parent 2ee438a7
......@@ -1019,6 +1019,7 @@ export default {
port: '端口',
userName: '用户名',
password: '密码',
description:'描述',
creationTime: '创建时间',
creatorUserId: '创建人',
lastModificationTime: '更新时间',
......
......@@ -30,6 +30,11 @@
<Input v-model="entity.password"></Input>
</FormItem>
</Col>
<Col :span="24">
<FormItem :label="l('description')" prop="description">
<Input v-model="entity.description"></Input>
</FormItem>
</Col>
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" :disabled="disabled">保存</Button>
......
......@@ -2,10 +2,13 @@
<div class="detail">
<Row>
<Filed :span="24" :name="l('hostName')">{{entity.hostName}}</Filed>
<Filed :span="24" :name="l('hostsq')">{{entity.hostName}}</Filed>
<Filed :span="24" :name="l('hostsq')">
<State code="datasource.type" :value="entity.databaseType"/>
</Filed>
<Filed :span="24" :name="l('port')">{{entity.port}}</Filed>
<Filed :span="24" :name="l('userName')">{{entity.userName}}</Filed>
<Filed :span="24" :name="l('password')">{{entity.password}}</Filed>
<Filed :span="24" :name="l('description')">{{entity.description}}</Filed>
</Row>
</div>
</template>
......@@ -15,7 +18,7 @@ export default {
name: 'Add',
data() {
return {
entity: {hostName:'', port: 0, userName: '', password: '' },
entity: {hostName:'', port: 0, userName: '', password: '' ,description:''},
rules: {
name: [{ required: true, message: '必填', trigger: 'blur' }],
code: [{ required: true, message: '必填', trigger: 'blur' }]
......
......@@ -10,7 +10,7 @@
</Col>
<Col :span="24">
<FormItem :label="l('hostsq')" prop="hostId">
<Input v-model="entity.hostId"></Input>
<Dictionary code="datasource.type" v-model="entity.databaseType" type="select"></Dictionary>
<!-- <Dictionary v-model="entity.hostId"></Dictionary> -->
</FormItem>
</Col>
......@@ -31,6 +31,11 @@
<!-- <Input v-model="entity.password"></Input> -->
<span>{{entity.password}}</span>
</FormItem>
<Col :span="24">
<FormItem :label="l('description')" prop="description">
<Input v-model="entity.description"></Input>
</FormItem>
</Col>
</Col>
</Row>
<FormItem>
......@@ -71,6 +76,9 @@ export default {
methods: {
load(v) {
Api.get({ id: v }).then(r => {
if(r.result.databaseType){
r.result.databaseType=parseInt(r.result.databaseType)
}
this.entity = r.result;
this.$emit("on-load");
});
......
......@@ -84,6 +84,7 @@ export default {
high: true
},
{ key: "password", title: this.l("password"), align: "left" },
{ key: "description", title: this.l("description"), align: "left" },
{
key: "creationTime",
title: this.l("creationTime"),
......
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