Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
WeiPanAPI
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Discuz
WeiPanAPI
Commits
8ac78970
Commit
8ac78970
authored
Mar 02, 2021
by
xiongyuwen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
no message
parent
43a57c84
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
7 deletions
+11
-7
WeiPanService.cs
src/Bailun.Discuz.Application/WeiPan/WeiPanService.cs
+11
-7
No files found.
src/Bailun.Discuz.Application/WeiPan/WeiPanService.cs
View file @
8ac78970
...
@@ -53,7 +53,7 @@ namespace Bailun.Discuz.Application.WeiPan
...
@@ -53,7 +53,7 @@ namespace Bailun.Discuz.Application.WeiPan
{
{
var
token
=
GetQYWeChatToken
(
userId
);
var
token
=
GetQYWeChatToken
(
userId
);
SpaceCreateRequest
resquest
=
new
SpaceCreateRequest
();
SpaceCreateRequest
resquest
=
new
SpaceCreateRequest
();
resquest
.
space_name
=
"
四千里
微盘"
;
resquest
.
space_name
=
"
4k
微盘"
;
resquest
.
userid
=
userId
;
resquest
.
userid
=
userId
;
var
apiUrl
=
$"https://qyapi.weixin.qq.com/cgi-bin/wedrive/space_create?access_token=
{
token
}
"
;
var
apiUrl
=
$"https://qyapi.weixin.qq.com/cgi-bin/wedrive/space_create?access_token=
{
token
}
"
;
var
apiOutput
=
HttpHelper
.
PostAsync
<
SpaceCreateRequest
,
SpaceCreateResponse
>(
apiUrl
,
resquest
);
var
apiOutput
=
HttpHelper
.
PostAsync
<
SpaceCreateRequest
,
SpaceCreateResponse
>(
apiUrl
,
resquest
);
...
@@ -72,7 +72,7 @@ namespace Bailun.Discuz.Application.WeiPan
...
@@ -72,7 +72,7 @@ namespace Bailun.Discuz.Application.WeiPan
CreateSpaceFileRequest
createSpaceFileRequest
=
new
CreateSpaceFileRequest
();
CreateSpaceFileRequest
createSpaceFileRequest
=
new
CreateSpaceFileRequest
();
var
weiPanSpaceId
=
GetWeiPanSpaceId
(
userId
);
var
weiPanSpaceId
=
GetWeiPanSpaceId
(
userId
);
createSpaceFileRequest
.
fatherid
=
weiPanSpaceId
;
createSpaceFileRequest
.
fatherid
=
weiPanSpaceId
;
createSpaceFileRequest
.
file_name
=
"
四千里
共享文件"
;
createSpaceFileRequest
.
file_name
=
"
4k
共享文件"
;
createSpaceFileRequest
.
file_type
=
1
;
createSpaceFileRequest
.
file_type
=
1
;
createSpaceFileRequest
.
userid
=
userId
;
createSpaceFileRequest
.
userid
=
userId
;
createSpaceFileRequest
.
spaceid
=
weiPanSpaceId
;
createSpaceFileRequest
.
spaceid
=
weiPanSpaceId
;
...
@@ -796,8 +796,11 @@ namespace Bailun.Discuz.Application.WeiPan
...
@@ -796,8 +796,11 @@ namespace Bailun.Discuz.Application.WeiPan
_weipanUserFilesRepository
.
Delete
(
u
.
Id
);
_weipanUserFilesRepository
.
Delete
(
u
.
Id
);
});
});
}
}
//await ProcessWeipanUserFilesByHr();
if
(
companyName
!=
"四千里数据科技有限公司"
)
{
await
ProcessWeipanUserFilesByHr
();
}
foreach
(
var
weiPanFile
in
weiPanFileList
)
foreach
(
var
weiPanFile
in
weiPanFileList
)
{
{
var
oldWeipanUserFiles
=
await
_weipanUserFilesRepository
.
Query
().
AsNoTracking
().
Where
(
u
=>
u
.
File_Id
==
weiPanFile
.
FileId
).
ToListAsync
();
var
oldWeipanUserFiles
=
await
_weipanUserFilesRepository
.
Query
().
AsNoTracking
().
Where
(
u
=>
u
.
File_Id
==
weiPanFile
.
FileId
).
ToListAsync
();
...
@@ -815,12 +818,13 @@ namespace Bailun.Discuz.Application.WeiPan
...
@@ -815,12 +818,13 @@ namespace Bailun.Discuz.Application.WeiPan
if
(
departmentItem
!=
null
||
selDepartments
[
0
]==
"公司制度及资讯"
)
if
(
departmentItem
!=
null
||
selDepartments
[
0
]==
"公司制度及资讯"
)
{
{
if
(
selDepartments
[
0
]
==
"公司制度及资讯"
)
var
isGetAll
=
false
;
if
(
selDepartments
[
0
]
==
"公司制度及资讯"
||
companyName
==
"四千里数据科技有限公司"
)
{
{
isGetAll
=
true
;
}
}
//根据部门获取对应得用户列表数据
//根据部门获取对应得用户列表数据
var
weChatUserList
=
GetWechatUserInfo
(
companyName
,
selDepartments
[
0
]
==
"公司制度及资讯"
?
1
:
departmentItem
.
id
).
ToList
();
var
weChatUserList
=
GetWechatUserInfo
(
companyName
,
isGetAll
==
true
?
1
:
departmentItem
.
id
).
ToList
();
if
(
weChatUserList
!=
null
)
if
(
weChatUserList
!=
null
)
{
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment