diff --git a/digiwf-apps/packages/components/digiwf-dms-input/package.json b/digiwf-apps/packages/components/digiwf-dms-input/package.json index fe730a1c63..27ee79b350 100644 --- a/digiwf-apps/packages/components/digiwf-dms-input/package.json +++ b/digiwf-apps/packages/components/digiwf-dms-input/package.json @@ -21,11 +21,11 @@ "files": [ "dist/*", "src/*", - "src/types/*" + "types/*" ], "publishConfig": { "access": "public" }, - "types": "src/types/index.ts", + "types": "types/index.d.ts", "gitHead": "47fcec12b321f6890de7729c98cd5f0ed7b1189d" } diff --git a/digiwf-apps/packages/components/digiwf-dms-input/src/apiClient/dmsApiCalls.ts b/digiwf-apps/packages/components/digiwf-dms-input/src/apiClient/dmsApiCalls.ts index 4e2fa01d2c..25414ab659 100644 --- a/digiwf-apps/packages/components/digiwf-dms-input/src/apiClient/dmsApiCalls.ts +++ b/digiwf-apps/packages/components/digiwf-dms-input/src/apiClient/dmsApiCalls.ts @@ -1,6 +1,6 @@ -import {Configuration, MetadataApiFactory, Metadata} from "@muenchen/digiwf-dms-api-internal"; +import {Configuration, Metadata, MetadataApiFactory} from "@muenchen/digiwf-dms-api-internal"; +import {Objectclass} from "@/middleware/dmsMiddleware"; import {AxiosResponse} from "axios"; -import {Objectclass} from "@/types"; /** * Calls readMetadata on dms api @@ -11,6 +11,6 @@ import {Objectclass} from "@/types"; export const getMetadataFromDmsservice = (ojectclass: Objectclass, coo: string, cfg: Configuration): Promise => { return MetadataApiFactory(cfg) .readMetadata(ojectclass,coo) - .then((response: AxiosResponse) => Promise.resolve(response.data)); + .then((response: AxiosResponse) => Promise.resolve(response.data)); } diff --git a/digiwf-apps/packages/components/digiwf-dms-input/src/components/DwfDmsInput.vue b/digiwf-apps/packages/components/digiwf-dms-input/src/components/DwfDmsInput.vue index 8770485450..3b1164fa01 100644 --- a/digiwf-apps/packages/components/digiwf-dms-input/src/components/DwfDmsInput.vue +++ b/digiwf-apps/packages/components/digiwf-dms-input/src/components/DwfDmsInput.vue @@ -77,8 +77,8 @@ import {defineComponent, inject, onMounted, ref} from "vue"; -import {getMetadata} from "@/middleware/dmsMiddleware"; -import {Metadata, Objectclass} from "@/types"; +import {getMetadata, Objectclass} from "@/middleware/dmsMiddleware"; +import {Metadata} from "@muenchen/digiwf-dms-api-internal"; interface DmsObject { readonly coo: string; diff --git a/digiwf-apps/packages/components/digiwf-dms-input/src/components/DwfObjectPreview.vue b/digiwf-apps/packages/components/digiwf-dms-input/src/components/DwfObjectPreview.vue index 9d241e88a9..3d2a168d0e 100644 --- a/digiwf-apps/packages/components/digiwf-dms-input/src/components/DwfObjectPreview.vue +++ b/digiwf-apps/packages/components/digiwf-dms-input/src/components/DwfObjectPreview.vue @@ -35,8 +35,6 @@ export default defineComponent({ props: ['coo','metadata','errormessage','readOnly'], emits: ['remove-object'], setup(props, {emit}) { - - console.log(props); const calculateIcon = (type: string) => { if (type === "PDF-Dokument") { return "mdi-file-pdf"; diff --git a/digiwf-apps/packages/components/digiwf-dms-input/src/middleware/dmsMiddleware.ts b/digiwf-apps/packages/components/digiwf-dms-input/src/middleware/dmsMiddleware.ts index ad6c9f0169..6e06979aa7 100644 --- a/digiwf-apps/packages/components/digiwf-dms-input/src/middleware/dmsMiddleware.ts +++ b/digiwf-apps/packages/components/digiwf-dms-input/src/middleware/dmsMiddleware.ts @@ -1,9 +1,16 @@ import { Configuration, FetchUtils, Metadata } from "@muenchen/digiwf-dms-api-internal"; -import {Objectclass} from "@/types"; import { getMetadataFromDmsservice } from "@/apiClient/dmsApiCalls"; +export enum Objectclass { + Sachakte ="Sachakte", + Vorgang = "Vorgang", + Eingang = "Eingang", + Ausgang = "Ausgang", + Intern = "Intern", + Schriftstueck = "Schriftstueck", +} export const getMetadata = async (ojectclass: Objectclass, coo: string, apiEndpoint: string): Promise => { const dmsAxiosConfig = axiosConfig(apiEndpoint); diff --git a/digiwf-apps/packages/components/digiwf-dms-input/src/types/index.ts b/digiwf-apps/packages/components/digiwf-dms-input/src/types/index.ts deleted file mode 100644 index 6b8eea4e16..0000000000 --- a/digiwf-apps/packages/components/digiwf-dms-input/src/types/index.ts +++ /dev/null @@ -1,21 +0,0 @@ -import Vue from "vue"; - -export class DwfDmsInput extends Vue { -} - -export interface Metadata { - name: string; - type: string | undefined; - url: string; -} - -export enum Objectclass { - Sachakte ="Sachakte", - Vorgang = "Vorgang", - Eingang = "Eingang", - Ausgang = "Ausgang", - Intern = "Intern", - Schriftstueck = "Schriftstueck", -} - - diff --git a/digiwf-apps/packages/components/digiwf-dms-input/types/index.d.ts b/digiwf-apps/packages/components/digiwf-dms-input/types/index.d.ts new file mode 100644 index 0000000000..57645cc34f --- /dev/null +++ b/digiwf-apps/packages/components/digiwf-dms-input/types/index.d.ts @@ -0,0 +1,4 @@ +import Vue from "vue"; + +export class DwfDmsInput extends Vue { +}