Commit fdbb4d82 authored by 华国豪's avatar 华国豪 🙄

粘贴

parent 5de2722d
...@@ -173,6 +173,7 @@ export default { ...@@ -173,6 +173,7 @@ export default {
that.usercardInfo.searchName = "" that.usercardInfo.searchName = ""
that.atInfo.atName = '' that.atInfo.atName = ''
} }
that.MsgBus.$emit("close-copy")
}); });
}, },
methods: { methods: {
......
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
</span> </span>
<div class="nick-name">添加</div> <div class="nick-name">添加</div>
</li> </li>
<li @click="addMembers('delete')"> <li @click="addMembers('delete')" v-if="membersInDisplay[0].account == ImAccount">
<span class="opera"> <span class="opera">
<i class="el-icon-minus"></i> <i class="el-icon-minus"></i>
</span> </span>
...@@ -241,7 +241,8 @@ export default { ...@@ -241,7 +241,8 @@ export default {
lstShowData:null, lstShowData:null,
showAt:false, showAt:false,
findTimer:null, findTimer:null,
requestCount:0 requestCount:0,
ImAccount: '',
}; };
}, },
updated() { updated() {
...@@ -272,6 +273,8 @@ export default { ...@@ -272,6 +273,8 @@ export default {
} }
}, },
mounted() { mounted() {
let user = this.$electron.remote.getGlobal("LOGINUSER");
this.ImAccount = this.user.ImAccount
//获取记录的操作区域高度 //获取记录的操作区域高度
if (localStorage.consoleh && localStorage.consoleh != "") { if (localStorage.consoleh && localStorage.consoleh != "") {
this.consoleinfo.currenth = parseInt(localStorage.consoleh); this.consoleinfo.currenth = parseInt(localStorage.consoleh);
......
...@@ -82,11 +82,14 @@ export default { ...@@ -82,11 +82,14 @@ export default {
} }
}, },
mounted() { mounted() {
let that = this;
this.MsgBus.$on("send-at-name", function(name) { this.MsgBus.$on("send-at-name", function(name) {
document.querySelector('#msgEditorBox').innerText = document.querySelector('#msgEditorBox').innerText + `@${name} ` document.querySelector('#msgEditorBox').innerText = document.querySelector('#msgEditorBox').innerText + `@${name} `
}) })
this.MsgBus.$on("close-copy", function() {
that.toolShow = false;
})
this.initClip(); this.initClip();
let that = this;
if(this.members && this.members.length>1){ if(this.members && this.members.length>1){
this.showMember=this.members.filter(x=>{ this.showMember=this.members.filter(x=>{
if(x.alias=='我'){ if(x.alias=='我'){
...@@ -205,8 +208,10 @@ export default { ...@@ -205,8 +208,10 @@ export default {
}, },
methods: { methods: {
toolPaste: function (e) { toolPaste: function (e) {
let clipboardData = 1 let clipboardData = 1;
console.log(e) document.getElementById('msgEditorBox').focus();
document.execCommand("paste");
this.toolShow = false;
}, },
copyBox: function (e) { copyBox: function (e) {
this.toolTop = e.offsetY this.toolTop = e.offsetY
......
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