mirror of
https://github.com/kuaifan/dootask.git
synced 2026-02-02 10:59:42 +00:00
no message
This commit is contained in:
parent
dda603c7d8
commit
b64d4fd96f
@ -32,7 +32,7 @@
|
|||||||
"dayjs": "^1.11.13",
|
"dayjs": "^1.11.13",
|
||||||
"dexie": "^3.2.3",
|
"dexie": "^3.2.3",
|
||||||
"echarts": "^5.2.2",
|
"echarts": "^5.2.2",
|
||||||
"element-sea": "^2.15.10-7",
|
"element-sea": "^2.15.10-8",
|
||||||
"file-loader": "^6.2.0",
|
"file-loader": "^6.2.0",
|
||||||
"highlight.js": "^11.7.0",
|
"highlight.js": "^11.7.0",
|
||||||
"inquirer": "^8.2.0",
|
"inquirer": "^8.2.0",
|
||||||
|
|||||||
@ -10,17 +10,16 @@
|
|||||||
@visible-change="visibleChange">
|
@visible-change="visibleChange">
|
||||||
<div ref="icon" class="general-operation-icon"></div>
|
<div ref="icon" class="general-operation-icon"></div>
|
||||||
<EDropdownMenu ref="dropdownMenu" slot="dropdown" class="general-operation-more-dropdown menu-dropdown">
|
<EDropdownMenu ref="dropdownMenu" slot="dropdown" class="general-operation-more-dropdown menu-dropdown">
|
||||||
<li class="general-operation-more-warp" :class="[size]">
|
<li class="general-operation-more-warp" :class="size">
|
||||||
<ul :style="ulStyle">
|
<ul :style="ulStyle">
|
||||||
<EDropdownItem
|
<EDropdownItem
|
||||||
v-for="(item, key) in list"
|
v-for="(item, key) in list"
|
||||||
:key="key"
|
:key="key"
|
||||||
:class="item.className"
|
|
||||||
:command="item.value"
|
:command="item.value"
|
||||||
:divided="!!item.divided"
|
:divided="!!item.divided"
|
||||||
:disabled="(active === item.value && !activeClick) || !!item.disabled">
|
:disabled="(active === item.value && !activeClick) || !!item.disabled">
|
||||||
<div class="item-box">
|
<div class="item-box" :style="item.style" :class="item.className">
|
||||||
<div class="item">{{item.label}}</div>
|
<div class="item">{{language ? $L(item.label) : item.label}}</div>
|
||||||
<div v-if="tickShow" class="tick">
|
<div v-if="tickShow" class="tick">
|
||||||
<i v-if="active === item.value && !item.disabled" class="taskfont"></i>
|
<i v-if="active === item.value && !item.disabled" class="taskfont"></i>
|
||||||
</div>
|
</div>
|
||||||
@ -40,13 +39,14 @@ export default {
|
|||||||
visible: false,
|
visible: false,
|
||||||
|
|
||||||
list: [], // 数据列表: [{label: '', value: ''}]
|
list: [], // 数据列表: [{label: '', value: ''}]
|
||||||
active: '', // 当前选中的值
|
|
||||||
size: 'small', // 下拉框大小
|
size: 'small', // 下拉框大小
|
||||||
|
active: '', // 当前选中的值
|
||||||
activeClick: false, // 当前选中的值是否可以被点击
|
activeClick: false, // 当前选中的值是否可以被点击
|
||||||
onUpdate: null, // 选中后的回调函数
|
onUpdate: null, // 选中后的回调函数
|
||||||
scrollHide: true, // 滚动立即隐藏
|
scrollHide: true, // 滚动立即隐藏
|
||||||
tickShow: true, // 是否显示打勾
|
tickShow: true, // 是否显示打勾(默认为:true,如果 active === undefined 默认为:false)
|
||||||
maxHeight: 0, // 滚动区域最大高度
|
maxHeight: 0, // 滚动区域最大高度
|
||||||
|
language: true, // 是否国际化 item.label
|
||||||
|
|
||||||
element: null,
|
element: null,
|
||||||
target: null,
|
target: null,
|
||||||
@ -83,13 +83,14 @@ export default {
|
|||||||
height: `${eventRect.height}px`,
|
height: `${eventRect.height}px`,
|
||||||
}
|
}
|
||||||
this.list = data.list;
|
this.list = data.list;
|
||||||
this.active = data.active && this.list.find(item => item.value === data.active) ? data.active : '';
|
|
||||||
this.size = ['small', 'medium', 'large'].includes(data.size) ? data.size : 'small';
|
this.size = ['small', 'medium', 'large'].includes(data.size) ? data.size : 'small';
|
||||||
|
this.active = data.active && this.list.find(item => item.value === data.active) ? data.active : '';
|
||||||
this.activeClick = typeof data.activeClick === "boolean" ? data.activeClick : false;
|
this.activeClick = typeof data.activeClick === "boolean" ? data.activeClick : false;
|
||||||
this.onUpdate = typeof data.onUpdate === "function" ? data.onUpdate : null;
|
this.onUpdate = typeof data.onUpdate === "function" ? data.onUpdate : null;
|
||||||
this.scrollHide = typeof data.scrollHide === "boolean" ? data.scrollHide : true;
|
this.scrollHide = typeof data.scrollHide === "boolean" ? data.scrollHide : true;
|
||||||
this.tickShow = typeof data.tickShow === "boolean" ? data.tickShow : true;
|
this.tickShow = typeof data.tickShow === "boolean" ? data.tickShow : (typeof data.active !== "undefined");
|
||||||
this.maxHeight = typeof data.maxHeight === "number" ? data.maxHeight : 0;
|
this.maxHeight = typeof data.maxHeight === "number" ? data.maxHeight : 0;
|
||||||
|
this.language = typeof data.language === "boolean" ? data.language : true;
|
||||||
//
|
//
|
||||||
this.$refs.icon.focus();
|
this.$refs.icon.focus();
|
||||||
this.show();
|
this.show();
|
||||||
|
|||||||
@ -240,7 +240,7 @@ export default {
|
|||||||
}
|
}
|
||||||
])
|
])
|
||||||
}
|
}
|
||||||
this.$store.state.menuOperation = {
|
this.$store.commit('menu/operation', {
|
||||||
event,
|
event,
|
||||||
list,
|
list,
|
||||||
onUpdate: async (act) => {
|
onUpdate: async (act) => {
|
||||||
@ -259,7 +259,7 @@ export default {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
},
|
},
|
||||||
handleView(item) {
|
handleView(item) {
|
||||||
//查看
|
//查看
|
||||||
|
|||||||
@ -1572,22 +1572,23 @@ export default {
|
|||||||
if (type === 'transcription') {
|
if (type === 'transcription') {
|
||||||
// 语音转文字
|
// 语音转文字
|
||||||
list.unshift(...[
|
list.unshift(...[
|
||||||
{label: '选择识别语言', value: '', disabled: true},
|
{label: this.$L('选择识别语言'), value: '', disabled: true},
|
||||||
{label: '自动识别', value: '', divided: true},
|
{label: this.$L('自动识别'), value: '', divided: true},
|
||||||
])
|
])
|
||||||
active = this.cacheTranscriptionLanguage
|
active = this.cacheTranscriptionLanguage
|
||||||
} else {
|
} else {
|
||||||
// 翻译
|
// 翻译
|
||||||
list.unshift(...[
|
list.unshift(...[
|
||||||
{label: '选择翻译结果', value: '', disabled: true},
|
{label: this.$L('选择翻译结果'), value: '', disabled: true},
|
||||||
{label: '不翻译结果', value: '', divided: true},
|
{label: this.$L('不翻译结果'), value: '', divided: true},
|
||||||
])
|
])
|
||||||
active = this.recordConvertTranslate
|
active = this.recordConvertTranslate
|
||||||
}
|
}
|
||||||
this.$store.state.menuOperation = {
|
this.$store.commit('menu/operation', {
|
||||||
event,
|
event,
|
||||||
list,
|
list,
|
||||||
active,
|
active,
|
||||||
|
language: false,
|
||||||
onUpdate: async (language) => {
|
onUpdate: async (language) => {
|
||||||
if (type === 'transcription') {
|
if (type === 'transcription') {
|
||||||
await this.$store.dispatch('setTranscriptionLanguage', language)
|
await this.$store.dispatch('setTranscriptionLanguage', language)
|
||||||
@ -1596,7 +1597,7 @@ export default {
|
|||||||
}
|
}
|
||||||
this.convertRecord()
|
this.convertRecord()
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
convertSend(type) {
|
convertSend(type) {
|
||||||
|
|||||||
@ -1874,10 +1874,11 @@ export default {
|
|||||||
if (!active && item.config?.model) {
|
if (!active && item.config?.model) {
|
||||||
active = item.config.model
|
active = item.config.model
|
||||||
}
|
}
|
||||||
this.$store.state.menuOperation = {
|
this.$store.commit('menu/operation', {
|
||||||
event,
|
event,
|
||||||
list,
|
list,
|
||||||
active,
|
active,
|
||||||
|
language: false,
|
||||||
onUpdate: async model => {
|
onUpdate: async model => {
|
||||||
this.dialogAiModel = [
|
this.dialogAiModel = [
|
||||||
...this.dialogAiModel.filter(({dialog_id}) => dialog_id !== this.dialogId),
|
...this.dialogAiModel.filter(({dialog_id}) => dialog_id !== this.dialogId),
|
||||||
@ -1885,7 +1886,7 @@ export default {
|
|||||||
]
|
]
|
||||||
await $A.IDBSet('dialogAiModel', this.dialogAiModel)
|
await $A.IDBSet('dialogAiModel', this.dialogAiModel)
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
break;
|
break;
|
||||||
|
|
||||||
// 开启新会话
|
// 开启新会话
|
||||||
@ -3541,20 +3542,21 @@ export default {
|
|||||||
value: item
|
value: item
|
||||||
}))
|
}))
|
||||||
list.push(...[
|
list.push(...[
|
||||||
{label: '重新翻译', value: 'retranslation', divided: true},
|
{label: this.$L('重新翻译'), value: 'retranslation', divided: true},
|
||||||
{label: '隐藏翻译', value: 'hidden'},
|
{label: this.$L('隐藏翻译'), value: 'hidden'},
|
||||||
])
|
])
|
||||||
this.$store.state.menuOperation = {
|
this.$store.commit('menu/operation', {
|
||||||
event,
|
event,
|
||||||
list,
|
list,
|
||||||
active: this.cacheTranslationLanguage,
|
active: this.cacheTranslationLanguage,
|
||||||
|
language: false,
|
||||||
onUpdate: async (language) => {
|
onUpdate: async (language) => {
|
||||||
if (languageList[language]) {
|
if (languageList[language]) {
|
||||||
await this.$store.dispatch("setTranslationLanguage", language);
|
await this.$store.dispatch("setTranslationLanguage", language);
|
||||||
}
|
}
|
||||||
this.onTranslation(language);
|
this.onTranslation(language);
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
onCopy(data) {
|
onCopy(data) {
|
||||||
|
|||||||
@ -555,7 +555,7 @@ export default {
|
|||||||
{label: '任务人员', value: 2},
|
{label: '任务人员', value: 2},
|
||||||
{label: '指定成员', value: 3},
|
{label: '指定成员', value: 3},
|
||||||
];
|
];
|
||||||
this.$store.state.menuOperation = {
|
this.$store.commit('menu/operation', {
|
||||||
event,
|
event,
|
||||||
list,
|
list,
|
||||||
size: 'large',
|
size: 'large',
|
||||||
@ -563,7 +563,7 @@ export default {
|
|||||||
onUpdate: (value) => {
|
onUpdate: (value) => {
|
||||||
this.dropVisible(value)
|
this.dropVisible(value)
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
visibleUserSelectShowChange(isShow){
|
visibleUserSelectShowChange(isShow){
|
||||||
|
|||||||
@ -1917,7 +1917,7 @@ export default {
|
|||||||
{label: '任务人员', value: 2},
|
{label: '任务人员', value: 2},
|
||||||
{label: '指定成员', value: 3},
|
{label: '指定成员', value: 3},
|
||||||
];
|
];
|
||||||
this.$store.state.menuOperation = {
|
this.$store.commit('menu/operation', {
|
||||||
event,
|
event,
|
||||||
list,
|
list,
|
||||||
size: 'large',
|
size: 'large',
|
||||||
@ -1925,7 +1925,7 @@ export default {
|
|||||||
onUpdate: (value) => {
|
onUpdate: (value) => {
|
||||||
this.dropVisible(value)
|
this.dropVisible(value)
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
showAtDropdown(event){
|
showAtDropdown(event){
|
||||||
@ -1935,14 +1935,14 @@ export default {
|
|||||||
{label: '修改时间', value: 2},
|
{label: '修改时间', value: 2},
|
||||||
{label: '清除时间', value: 3},
|
{label: '清除时间', value: 3},
|
||||||
];
|
];
|
||||||
this.$store.state.menuOperation = {
|
this.$store.commit('menu/operation', {
|
||||||
event,
|
event,
|
||||||
list,
|
list,
|
||||||
size: 'large',
|
size: 'large',
|
||||||
onUpdate: (value) => {
|
onUpdate: (value) => {
|
||||||
this.dropDeadline(value)
|
this.dropDeadline(value)
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
visibleUserSelectShowChange(isShow){
|
visibleUserSelectShowChange(isShow){
|
||||||
@ -2033,16 +2033,16 @@ export default {
|
|||||||
const list = [
|
const list = [
|
||||||
{label: '查看附件', value: 1},
|
{label: '查看附件', value: 1},
|
||||||
{label: '下载附件', value: 2},
|
{label: '下载附件', value: 2},
|
||||||
{label: '删除附件', value: 3, className: 'task-calc-warn-text'},
|
{label: '删除附件', value: 3, style: {color:'#FF7070'}},
|
||||||
];
|
];
|
||||||
this.$store.state.menuOperation = {
|
this.$store.commit('menu/operation', {
|
||||||
event,
|
event,
|
||||||
list,
|
list,
|
||||||
size: 'large',
|
size: 'large',
|
||||||
onUpdate: (value) => {
|
onUpdate: (value) => {
|
||||||
this.dropFile(value)
|
this.dropFile(value)
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
dropFile(command) {
|
dropFile(command) {
|
||||||
@ -2113,16 +2113,17 @@ export default {
|
|||||||
if (this.msgTypes.length === 0) {
|
if (this.msgTypes.length === 0) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.$store.state.menuOperation = {
|
this.$store.commit('menu/operation', {
|
||||||
event,
|
event,
|
||||||
list: this.msgTypes,
|
list: this.msgTypes,
|
||||||
active: this.msgType,
|
active: this.msgType,
|
||||||
activeClick: true,
|
activeClick: true,
|
||||||
|
language: false,
|
||||||
onUpdate: (type) => {
|
onUpdate: (type) => {
|
||||||
this.navActive = 'dialog'
|
this.navActive = 'dialog'
|
||||||
this.$refs.dialog?.onMsgType(type)
|
this.$refs.dialog?.onMsgType(type)
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
autoScrollInto() {
|
autoScrollInto() {
|
||||||
|
|||||||
5
resources/assets/js/store/mutations.js
vendored
5
resources/assets/js/store/mutations.js
vendored
@ -293,4 +293,9 @@ export default {
|
|||||||
'longpress/clear': function(state) {
|
'longpress/clear': function(state) {
|
||||||
state.longpressData = {type: '', data: null, element: null}
|
state.longpressData = {type: '', data: null, element: null}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// 通用菜单
|
||||||
|
'menu/operation': function(state, data) {
|
||||||
|
state.menuOperation = data
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@ -947,10 +947,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.task-calc-warn-text {
|
|
||||||
color: $flow-status-start-color !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
body.window-portrait {
|
body.window-portrait {
|
||||||
.task-detail {
|
.task-detail {
|
||||||
.task-info {
|
.task-info {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user