|
|
@@ -178,6 +178,17 @@ public class FeiShuService {
|
|
|
String authUrl = buildAuthLink(companyId, companyUserId, courseId, videoId, shortLink);
|
|
|
docApiService.createTextLinkBlock(client, docId, authUrl);
|
|
|
docApiService.changeDocumentPermissions(client, docId);
|
|
|
+ if (StringUtils.isNotBlank(shortLink)){
|
|
|
+ FsCourseLink fsCourseLink = courseLinkMapper.selectFsCourseLinkByLink(shortLink);
|
|
|
+ //有视频短链+外部联系人id,需要缓存docId和account
|
|
|
+ if (fsCourseLink.getQwExternalId()!=null){
|
|
|
+ String docIdKey=FEISHU_DOC_ID + fsCourseLink.getQwExternalId()+ "_" + videoId;
|
|
|
+ log.error("公共账号池 外部联系人id不为空,缓存飞书docId,key:{}",docIdKey);
|
|
|
+ redisCache.setCacheObject(docIdKey, docId);
|
|
|
+ String accountKey = FEISHU_CLIENT+docId;
|
|
|
+ redisCache.setCacheObject(accountKey, account);
|
|
|
+ }
|
|
|
+ }
|
|
|
return "https://www.feishu.cn/docx/" + docId;
|
|
|
} catch (CustomException e) {
|
|
|
Integer code = e.getCode();
|