mirror of
https://github.com/kuaifan/dootask.git
synced 2026-03-17 19:23:26 +00:00
perf: 聊天设置待办时可快速选择
This commit is contained in:
parent
08a6be9499
commit
0c7adaf67a
@ -319,6 +319,16 @@
|
|||||||
<FormItem prop="type" :label="$L('当前会话')">
|
<FormItem prop="type" :label="$L('当前会话')">
|
||||||
<RadioGroup v-model="todoSettingData.type">
|
<RadioGroup v-model="todoSettingData.type">
|
||||||
<Radio label="all">{{$L('所有成员')}}</Radio>
|
<Radio label="all">{{$L('所有成员')}}</Radio>
|
||||||
|
<Radio v-if="todoSettingData.my_id" label="my">
|
||||||
|
<div style="display:inline-block">
|
||||||
|
<UserAvatar :userid="todoSettingData.my_id" :show-icon="false" :show-name="true"/>
|
||||||
|
</div>
|
||||||
|
</Radio>
|
||||||
|
<Radio v-if="todoSettingData.you_id" label="you">
|
||||||
|
<div style="display:inline-block">
|
||||||
|
<UserAvatar :userid="todoSettingData.you_id" :show-icon="false" :show-name="true"/>
|
||||||
|
</div>
|
||||||
|
</Radio>
|
||||||
<Radio label="user">{{$L('指定成员')}}</Radio>
|
<Radio label="user">{{$L('指定成员')}}</Radio>
|
||||||
</RadioGroup>
|
</RadioGroup>
|
||||||
</FormItem>
|
</FormItem>
|
||||||
@ -2177,12 +2187,19 @@ export default {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (type === 'submit') {
|
if (type === 'submit') {
|
||||||
if (this.todoSettingData.type === 'user' && $A.arrayLength(this.todoSettingData.userids) === 0) {
|
const todoData = $A.cloneJSON(this.todoSettingData)
|
||||||
|
if (todoData.type === 'my') {
|
||||||
|
todoData.type = 'user'
|
||||||
|
todoData.userids = [todoData.my_id]
|
||||||
|
} else if (todoData.type === 'you') {
|
||||||
|
todoData.type = 'user'
|
||||||
|
todoData.userids = [todoData.you_id]
|
||||||
|
} else if (todoData.type === 'user' && $A.arrayLength(todoData.userids) === 0) {
|
||||||
$A.messageWarning("选择指定成员");
|
$A.messageWarning("选择指定成员");
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.todoSettingLoad++
|
this.todoSettingLoad++
|
||||||
this.onTodoSubmit(this.todoSettingData).then(msg => {
|
this.onTodoSubmit(todoData).then(msg => {
|
||||||
$A.messageSuccess(msg)
|
$A.messageSuccess(msg)
|
||||||
this.todoSettingShow = false
|
this.todoSettingShow = false
|
||||||
}).catch($A.messageError).finally(_ => {
|
}).catch($A.messageError).finally(_ => {
|
||||||
@ -2193,6 +2210,8 @@ export default {
|
|||||||
type: 'all',
|
type: 'all',
|
||||||
userids: [],
|
userids: [],
|
||||||
msg_id: this.operateItem.id,
|
msg_id: this.operateItem.id,
|
||||||
|
my_id: this.userId,
|
||||||
|
you_id: this.dialogData.dialog_user?.userid,
|
||||||
}
|
}
|
||||||
if (this.operateItem.todo) {
|
if (this.operateItem.todo) {
|
||||||
$A.modalConfirm({
|
$A.modalConfirm({
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user