feat(doclib): 文档库支持多选文档后批量设置分享。
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
dd4fdf1e6e
commit
0baa6880f7
3 files changed
+55
-20
No files matched your search
@@ -95,6 +95,12 @@ await context.route('**/api/**', async (route) => {
|
||||
return ok({ list, total: list.length })
|
||||
}
|
||||
if (path === '/web/doclib/users') return ok([{ id: 'other', name: '同事', deptName: '生产部' }])
|
||||
if (path === '/web/doclib/files/batch-shares' && req.method() === 'POST') {
|
||||
const body = req.postDataJSON()
|
||||
sharedUsers = body.userIds
|
||||
file.shares = sharedUsers.map((id) => ({ id, name: '同事', deptName: '生产部' }))
|
||||
return ok([file])
|
||||
}
|
||||
if (path.endsWith('/shares')) {
|
||||
sharedUsers = req.postDataJSON().userIds
|
||||
file.shares = sharedUsers.map((id) => ({ id, name: '同事', deptName: '生产部' }))
|
||||
|
||||
Reference in new issue
Block a user