This commit is contained in:
kuaifan 2022-07-07 13:28:08 +08:00
parent 5651713032
commit f24a8230c1
25 changed files with 66 additions and 53 deletions

View File

@ -4,7 +4,7 @@
/**
* A helper file for Laravel, to provide autocomplete information to your IDE
* Generated for Laravel 8.83.2.
* Generated for Laravel 8.83.16.
*
* This file should not be included in your code, only analyzed by your IDE!
*
@ -8994,7 +8994,7 @@
/**
* Push a new job onto the queue.
*
* @param string $job
* @param string|object $job
* @param mixed $data
* @param string|null $queue
* @return mixed
@ -9023,7 +9023,7 @@
* Push a new job onto the queue after a delay.
*
* @param \DateTimeInterface|\DateInterval|int $delay
* @param string $job
* @param string|object $job
* @param mixed $data
* @param string|null $queue
* @return mixed
@ -9038,7 +9038,7 @@
* Push a new job onto the queue.
*
* @param string $queue
* @param string $job
* @param string|object $job
* @param mixed $data
* @return mixed
* @static
@ -9053,7 +9053,7 @@
*
* @param string $queue
* @param \DateTimeInterface|\DateInterval|int $delay
* @param string $job
* @param string|object $job
* @param mixed $data
* @return mixed
* @static
@ -11886,6 +11886,7 @@
* @method static \Illuminate\Routing\RouteRegistrar prefix(string $prefix)
* @method static \Illuminate\Routing\RouteRegistrar scopeBindings()
* @method static \Illuminate\Routing\RouteRegistrar where(array $where)
* @method static \Illuminate\Routing\RouteRegistrar withoutMiddleware(array|string $middleware)
* @see \Illuminate\Routing\Router
*/
class Route {
@ -16037,11 +16038,12 @@
* @param string $fileName
* @param string|null $writerType
* @param mixed $withHeadings
* @param array $responseHeaders
* @static
*/
public static function downloadExcel($fileName, $writerType = null, $withHeadings = false)
public static function downloadExcel($fileName, $writerType = null, $withHeadings = false, $responseHeaders = [])
{
return \Illuminate\Support\Collection::downloadExcel($fileName, $writerType, $withHeadings);
return \Illuminate\Support\Collection::downloadExcel($fileName, $writerType, $withHeadings, $responseHeaders);
}
/**
*

View File

@ -192,7 +192,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/todo 20. 获取会话待办
* @api {get} api/dialog/todo 05. 获取会话待办
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -218,7 +218,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/top 20. 会话置顶
* @api {get} api/dialog/top 06. 会话置顶
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -248,7 +248,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/open/user 05. 打开会话
* @api {get} api/dialog/open/user 07. 打开会话
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -279,7 +279,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/lists 06. 获取消息列表
* @api {get} api/dialog/msg/lists 08. 获取消息列表
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -344,7 +344,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/list 07. 获取消息列表(新)
* @api {get} api/dialog/msg/list 09. 获取消息列表(新)
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -475,7 +475,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/unread 08. 获取未读消息数量
* @api {get} api/dialog/msg/unread 10. 获取未读消息数量
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -508,7 +508,7 @@ class DialogController extends AbstractController
}
/**
* @api {post} api/dialog/msg/sendtext 09. 发送消息
* @api {post} api/dialog/msg/sendtext 11. 发送消息
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -588,7 +588,7 @@ class DialogController extends AbstractController
}
/**
* @api {post} api/dialog/msg/sendrecord 10. 发送语音
* @api {post} api/dialog/msg/sendrecord 12. 发送语音
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -635,7 +635,7 @@ class DialogController extends AbstractController
}
/**
* @api {post} api/dialog/msg/sendfile 11. 文件上传
* @api {post} api/dialog/msg/sendfile 13. 文件上传
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -719,7 +719,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/readlist 12. 获取消息阅读情况
* @api {get} api/dialog/msg/readlist 14. 获取消息阅读情况
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -748,7 +748,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/detail 13. 消息详情
* @api {get} api/dialog/msg/detail 15. 消息详情
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -796,7 +796,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/download 14. 文件下载
* @api {get} api/dialog/msg/download 16. 文件下载
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -836,7 +836,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/withdraw 15. 聊天消息撤回
* @api {get} api/dialog/msg/withdraw 17. 聊天消息撤回
*
* @apiDescription 消息撤回限制24小时内需要token身份
* @apiVersion 1.0.0
@ -862,7 +862,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/mark 16. 消息标记操作
* @api {get} api/dialog/msg/mark 18. 消息标记操作
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -914,7 +914,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/forward 17. 转发消息给
* @api {get} api/dialog/msg/forward 19. 转发消息给
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -949,7 +949,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/emoji 18. emoji回复
* @api {get} api/dialog/msg/emoji 20. emoji回复
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -985,7 +985,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/tag 19. 标注/取消标注
* @api {get} api/dialog/msg/tag 21. 标注/取消标注
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -1014,7 +1014,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/todo 19. 设待办/取消待办
* @api {get} api/dialog/msg/todo 22. 设待办/取消待办
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -1043,7 +1043,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/msg/done 19. 完成待办
* @api {get} api/dialog/msg/done 23. 完成待办
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -1090,7 +1090,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/group/add 21. 新增群组
* @api {get} api/dialog/group/add 24. 新增群组
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -1142,7 +1142,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/group/edit 22. 修改群组
* @api {get} api/dialog/group/edit 25. 修改群组
*
* @apiDescription 需要token身份
* @apiVersion 1.0.0
@ -1181,7 +1181,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/group/adduser 23. 添加群成员
* @api {get} api/dialog/group/adduser 26. 添加群成员
*
* @apiDescription 需要token身份
* - 有群主时:只有群主可以邀请
@ -1217,7 +1217,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/group/deluser 24. 移出(退出)群成员
* @api {get} api/dialog/group/deluser 27. 移出(退出)群成员
*
* @apiDescription 需要token身份
* - 只有群主、邀请人可以踢人
@ -1261,7 +1261,7 @@ class DialogController extends AbstractController
}
/**
* @api {get} api/dialog/group/disband 25. 解散群组
* @api {get} api/dialog/group/disband 28. 解散群组
*
* @apiDescription 需要token身份
* - 只有群主且是个人类型群可以解散

View File

@ -457,7 +457,7 @@ class WebSocketDialogMsg extends AbstractModel
$action = $data['msg']['action'] === 'remove' ? '取消标注' : '标注';
return "[{$action}] {$this->previewMsg(false, $data['msg']['data'])}";
case 'todo':
$action = $data['msg']['action'] === 'remove' ? '取消待办' : ($data['msg']['action'] === 'done' ? '完成' : '设待办');
$action = $data['msg']['action'] === 'remove' ? '取消待办' : ($data['msg']['action'] === 'done' ? '完成' : '设待办');
return "[{$action}] {$this->previewMsg(false, $data['msg']['data'])}";
case 'notice':
return $data['msg']['notice'];

View File

@ -10,6 +10,7 @@ namespace App\Models;
* @property int|null $msg_id 消息ID
* @property int|null $userid 接收会员ID
* @property string|null $done_at 完成时间
* @property-read array|mixed $msg_data
* @method static \Illuminate\Database\Eloquent\Builder|WebSocketDialogMsgTodo newModelQuery()
* @method static \Illuminate\Database\Eloquent\Builder|WebSocketDialogMsgTodo newQuery()
* @method static \Illuminate\Database\Eloquent\Builder|WebSocketDialogMsgTodo query()

View File

@ -18,6 +18,11 @@ class AddWebSocketDialogMsgsTodo extends Migration
$table->bigInteger('todo')->nullable()->default(0)->after('tag')->comment('设为待办会员ID');
}
});
Schema::table('web_socket_dialog_msg_reads', function (Blueprint $table) {
if (Schema::hasColumn('web_socket_dialog_msg_reads', 'userid')) {
$table->bigInteger('userid')->nullable()->default(0)->comment('接收会员ID')->change();
}
});
}
/**

View File

@ -17,7 +17,7 @@ class CreateWebSocketDialogMsgTodosTable extends Migration
$table->bigIncrements('id');
$table->bigInteger('dialog_id')->nullable()->default(0)->comment('对话ID');
$table->bigInteger('msg_id')->nullable()->default(0)->comment('消息ID');
$table->bigInteger('userid')->nullable()->default(0)->comment('发送会员ID');
$table->bigInteger('userid')->nullable()->default(0)->comment('接收会员ID');
$table->timestamp('done_at')->nullable()->comment('完成时间');
$table->index(['dialog_id', 'userid', 'done_at']);
});

View File

@ -1,6 +1,6 @@
{
"name": "DooTask",
"version": "0.18.71",
"version": "0.18.80",
"description": "DooTask is task management system.",
"scripts": {
"start": "./cmd dev",

2
public/css/app.css vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

2
public/js/app.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

2
public/js/build/70.js vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
21c14d0845b6384a
68ebf6188ccaa789

View File

@ -493,7 +493,7 @@
case 'tag':
return `[${$A.L(data.msg.action === 'remove' ? '取消标注' : '标注')}] ${$A.getMsgSimpleDesc(data.msg.data)}`
case 'todo':
return `[${$A.L(data.msg.action === 'remove' ? '取消待办' : (data.msg.action === 'done' ? '完成' : '设待办'))}] ${$A.getMsgSimpleDesc(data.msg.data)}`
return `[${$A.L(data.msg.action === 'remove' ? '取消待办' : (data.msg.action === 'done' ? '完成' : '设待办'))}] ${$A.getMsgSimpleDesc(data.msg.data)}`
case 'notice':
return data.msg.notice
default:

View File

@ -7,7 +7,7 @@
</div>
<div v-else-if="source.type === 'todo'" class="dialog-todo" @click="onViewTodo">
<div class="todo-user"><UserAvatar :userid="source.userid" :tooltipDisabled="source.userid == userId" :show-name="true" :show-icon="false"/></div>
{{$L(source.msg.action === 'remove' ? '取消待办' : (source.msg.action === 'done' ? '完成' : '设待办'))}}
{{$L(source.msg.action === 'remove' ? '取消待办' : (source.msg.action === 'done' ? '完成' : '设待办'))}}
"{{$A.getMsgSimpleDesc(source.msg.data)}}"
</div>
<div v-else-if="source.type === 'notice'" class="dialog-notice">

View File

@ -121,7 +121,7 @@
@on-progress="chatFile('progress', $event)"
@on-success="chatFile('success', $event)"
@on-error="chatFile('error', $event)"/>
<div v-if="todoList.length > 0" class="chat-todo">
<div v-if="todoShow" class="chat-todo">
<div class="todo-label">{{$L('待办')}}:</div>
<ul class="scrollbar-hidden">
<li v-for="item in todoList" @click.stop="onClickTodo(item, $event)">
@ -533,6 +533,10 @@ export default {
});
},
todoShow() {
return this.todoList.length > 0 && this.windowScrollY === 0 && this.replyId === 0
},
wrapperClass() {
if (['ready', 'ing'].includes(this.recordState)) {
return ['record-ready']
@ -1702,6 +1706,7 @@ export default {
}).then(({data, msg}) => {
resolve(msg)
this.tagOrTodoSuccess(data)
this.onActive()
}).catch(({msg}) => {
reject(msg);
}).finally(_ => {

@ -1 +1 @@
Subproject commit bf4fcff72b70d384992187d4492578daf9aac5ee
Subproject commit c6913ecc95df8d9754e10c1ff0e6fad557ee29d9