移除Host头验证中间件及相关逻辑,简化OAuth相关API的请求处理,优化代码结构和可读性。
This commit is contained in:
@@ -788,14 +788,13 @@ export default function DocumentsIndex() {
|
||||
try {
|
||||
setAttachmentUploading(true);
|
||||
|
||||
const jwtToken = (loaderData.frontendJWT as string | undefined) || (loaderData.userInfo?.frontend_jwt as unknown as string | undefined);
|
||||
const result = await appendContractAttachments(
|
||||
selectedDocumentId,
|
||||
attachmentFiles,
|
||||
attachmentMergeMode,
|
||||
true, // isReprocess
|
||||
attachmentRemark || undefined,
|
||||
jwtToken
|
||||
loaderData.frontendJWT as string | undefined
|
||||
);
|
||||
|
||||
if (result.error) {
|
||||
@@ -863,12 +862,11 @@ export default function DocumentsIndex() {
|
||||
try {
|
||||
setTemplateUploading(true);
|
||||
|
||||
const jwtToken = (loaderData.frontendJWT as string | undefined) || (loaderData.userInfo?.frontend_jwt as unknown as string | undefined);
|
||||
const result = await uploadContractTemplate(
|
||||
templateFile,
|
||||
selectedDocumentId,
|
||||
undefined, // comparisonId
|
||||
jwtToken
|
||||
loaderData.frontendJWT as string | undefined
|
||||
);
|
||||
|
||||
if (result.error) {
|
||||
|
||||
Reference in New Issue
Block a user