Compare commits
2 Commits
67320f897e
...
f60fdbafa0
Author | SHA1 | Date |
---|---|---|
yangws | f60fdbafa0 | |
yangws | 776be8eaac |
|
@ -94,13 +94,14 @@
|
|||
</div>
|
||||
</template>
|
||||
<template v-else>
|
||||
<div class="item-popover-item">
|
||||
<!-- 判断是不是自己创建的课件-->
|
||||
<div class="item-popover-item" v-if="userInfo.userId === Number(item.createUserId)">
|
||||
<el-button text @click="editTalk(item, index)">
|
||||
<i class="iconfont icon-bianji"></i>
|
||||
<span>重命名</span>
|
||||
</el-button>
|
||||
</div>
|
||||
<div class="item-popover-item">
|
||||
<div class="item-popover-item" v-if="userInfo.userId === Number(item.createUserId)">
|
||||
<el-button text @click="deleteTalk(item)">
|
||||
<i class="iconfont icon-shanchu"></i>
|
||||
<span>删除</span>
|
||||
|
@ -140,6 +141,7 @@ import { asyncLocalFile } from '@/utils/talkFile'
|
|||
import { toTimeText } from '@/utils/date'
|
||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
||||
import { deleteSmarttalk, updateSmarttalk, getPrepareById } from '@/api/file'
|
||||
import useUserStore from '@/store/modules/user'
|
||||
|
||||
const { ipcRenderer } = window.electron || {}
|
||||
export default {
|
||||
|
@ -162,11 +164,13 @@ export default {
|
|||
emits: { 'on-move': null, 'on-delete': null, 'on-set': null, 'on-delhomework': null },
|
||||
data() {
|
||||
return {
|
||||
listenList: []
|
||||
listenList: [],
|
||||
userInfo:{}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
editTalk(item) {
|
||||
console.log(item,this.userInfo,'this.userInfo')
|
||||
ElMessageBox.prompt('请输入新的名称', '重命名', {
|
||||
confirmButtonText: '确认',
|
||||
cancelButtonText: '取消',
|
||||
|
@ -253,6 +257,9 @@ export default {
|
|||
deleteHomework(item){
|
||||
this.$emit('on-delhomework', item)
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.userInfo = useUserStore().user
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
|
Loading…
Reference in New Issue