Przeglądaj źródła

fix importing types

Yuki Takei 1 rok temu
rodzic
commit
a877248af0

+ 4 - 2
apps/app/src/features/questionnaire/server/service/questionnaire.ts

@@ -3,6 +3,8 @@ import * as os from 'node:os';
 
 import type { IUserHasId } from '@growi/core';
 
+import { AttachmentMethodType } from '~/interfaces/attachment';
+import { GrowiDeploymentType, GrowiServiceType } from '~/interfaces/system';
 import type { ObjectIdLike } from '~/server/interfaces/mongoose-utils';
 // eslint-disable-next-line import/no-named-as-default
 import { Config } from '~/server/models/config';
@@ -11,7 +13,7 @@ import loggerFactory from '~/utils/logger';
 
 import type { IGrowiInfo } from '../../interfaces/growi-info';
 import {
-  GrowiWikiType, GrowiExternalAuthProviderType, GrowiServiceType, GrowiAttachmentType, GrowiDeploymentType,
+  GrowiWikiType, GrowiExternalAuthProviderType,
 } from '../../interfaces/growi-info';
 import { StatusType } from '../../interfaces/questionnaire-answer-status';
 import { type IUserInfo, UserType } from '../../interfaces/user-info';
@@ -64,7 +66,7 @@ class QuestionnaireService {
     const type = Object.values(GrowiServiceType).includes(typeStr) ? typeStr : null;
 
     const attachmentTypeStr = this.crowi.configManager.getConfig('crowi', 'app:fileUploadType');
-    const attachmentType = Object.values(GrowiAttachmentType).includes(attachmentTypeStr) ? attachmentTypeStr : null;
+    const attachmentType = Object.values(AttachmentMethodType).includes(attachmentTypeStr) ? attachmentTypeStr : null;
 
     const deploymentTypeStr = this.crowi.configManager.getConfig('crowi', 'app:deploymentType');
     const deploymentType = Object.values(GrowiDeploymentType).includes(deploymentTypeStr) ? deploymentTypeStr : null;

+ 1 - 1
apps/app/src/server/service/config-manager/legacy/config-loader.ts

@@ -1,7 +1,7 @@
 import { envUtils } from '@growi/core/dist/utils';
 import { parseISO } from 'date-fns/parseISO';
 
-import { GrowiServiceType } from '~/features/questionnaire/interfaces/growi-info';
+import { GrowiServiceType } from '~/interfaces/system';
 import loggerFactory from '~/utils/logger';
 
 import {