no message
This commit is contained in:
parent
e0e2318e2f
commit
921be40c64
@ -60,7 +60,7 @@
|
|||||||
<Loading v-if="loadIng > 0"/>
|
<Loading v-if="loadIng > 0"/>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<Button class="manage-box-new" type="primary" icon="md-add" @click="addShow=true">{{$L('新建项目')}}</Button>
|
<Button class="manage-box-new" type="primary" icon="md-add" @click="onAddShow">{{$L('新建项目')}}</Button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="manage-box-main">
|
<div class="manage-box-main">
|
||||||
@ -76,7 +76,7 @@
|
|||||||
:mask-closable="false">
|
:mask-closable="false">
|
||||||
<Form ref="addProject" :model="addData" :rules="addRule" label-width="auto" @submit.native.prevent>
|
<Form ref="addProject" :model="addData" :rules="addRule" label-width="auto" @submit.native.prevent>
|
||||||
<FormItem prop="name" :label="$L('项目名称')">
|
<FormItem prop="name" :label="$L('项目名称')">
|
||||||
<Input type="text" v-model="addData.name"></Input>
|
<Input ref="projectName" type="text" v-model="addData.name"></Input>
|
||||||
</FormItem>
|
</FormItem>
|
||||||
<FormItem prop="columns" :label="$L('项目模板')">
|
<FormItem prop="columns" :label="$L('项目模板')">
|
||||||
<Select v-model="addData.template" @on-change="(res) => {$set(addData, 'columns', columns[res].value)}" :placeholder="$L('请选择模板')">
|
<Select v-model="addData.template" @on-change="(res) => {$set(addData, 'columns', columns[res].value)}" :placeholder="$L('请选择模板')">
|
||||||
@ -280,6 +280,13 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
onAddShow() {
|
||||||
|
this.addShow = true;
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.projectName.focus();
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
onAddProject() {
|
onAddProject() {
|
||||||
this.$refs.addProject.validate((valid) => {
|
this.$refs.addProject.validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
|
@ -34,25 +34,24 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
mounted() {
|
|
||||||
this.getMsg();
|
|
||||||
},
|
|
||||||
|
|
||||||
computed: {
|
computed: {
|
||||||
...mapState(['projectDetail', 'projectChatShow']),
|
...mapState(['projectDetail', 'projectChatShow']),
|
||||||
},
|
},
|
||||||
|
|
||||||
watch: {
|
watch: {
|
||||||
projectDetail() {
|
'projectDetail.dialog_id' () {
|
||||||
this.getMsg()
|
this.getMsgList()
|
||||||
},
|
},
|
||||||
projectChatShow() {
|
projectChatShow: {
|
||||||
this.getMsg()
|
handler() {
|
||||||
|
this.getMsgList()
|
||||||
|
},
|
||||||
|
immediate: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
getMsg() {
|
getMsgList() {
|
||||||
if (this.projectChatShow && this.projectDetail.dialog_id) {
|
if (this.projectChatShow && this.projectDetail.dialog_id) {
|
||||||
this.$store.dispatch("getDialogMsgList", this.projectDetail.dialog_id);
|
this.$store.dispatch("getDialogMsgList", this.projectDetail.dialog_id);
|
||||||
}
|
}
|
||||||
|
@ -298,7 +298,7 @@
|
|||||||
:mask-closable="false">
|
:mask-closable="false">
|
||||||
<Form ref="addProject" :model="settingData" label-width="auto" @submit.native.prevent>
|
<Form ref="addProject" :model="settingData" label-width="auto" @submit.native.prevent>
|
||||||
<FormItem prop="name" :label="$L('项目名称')">
|
<FormItem prop="name" :label="$L('项目名称')">
|
||||||
<Input type="text" v-model="settingData.name" :maxlength="32" :placeholder="$L('必填')"></Input>
|
<Input ref="projectName" type="text" v-model="settingData.name" :maxlength="32" :placeholder="$L('必填')"></Input>
|
||||||
</FormItem>
|
</FormItem>
|
||||||
<FormItem prop="desc" :label="$L('项目介绍')">
|
<FormItem prop="desc" :label="$L('项目介绍')">
|
||||||
<Input type="textarea" :autosize="{ minRows: 3, maxRows: 5 }" v-model="settingData.desc" :maxlength="255" :placeholder="$L('选填')"></Input>
|
<Input type="textarea" :autosize="{ minRows: 3, maxRows: 5 }" v-model="settingData.desc" :maxlength="255" :placeholder="$L('选填')"></Input>
|
||||||
@ -973,6 +973,9 @@ export default {
|
|||||||
this.$set(this.settingData, 'name', this.projectDetail.name);
|
this.$set(this.settingData, 'name', this.projectDetail.name);
|
||||||
this.$set(this.settingData, 'desc', this.projectDetail.desc);
|
this.$set(this.settingData, 'desc', this.projectDetail.desc);
|
||||||
this.settingShow = true;
|
this.settingShow = true;
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.projectName.focus();
|
||||||
|
});
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case "user":
|
case "user":
|
||||||
|
Loading…
x
Reference in New Issue
Block a user