fix: 初始化

This commit is contained in:
jiaojinfeng
2023-05-30 19:27:03 +08:00
commit 28db653900
4436 changed files with 500218 additions and 0 deletions

View File

@ -0,0 +1,36 @@
<template>
<div>
<cadPreview
:documentId="documentsId"
:accessToken="tokenTes"
:write="false"
v-if="tokenTes"
></cadPreview>
</div>
</template>
<script lang="ts">
import { defineComponent, ref } from 'vue';
import { getThirdToken } from '@/utils/commonMethonds';
import cadPreview from '@/views/components/cadPreview.vue';
export default defineComponent({
components: { cadPreview },
name: 'crownCAD',
setup() {
//TODO documentsId 目前需要通过项目去创建文档并生成对应的文档ID
// 或者通过调用新建文档接口
// 也可以直接通过调用 /thirdparty/inventory 进入项目,进行创建
const documentsId = ref('63dcce4e13f6f37d0f7c4ba4');
// accessToken 从 /thirdparty/token 接口返回值中取到
const tokenTes = ref();
getThirdToken().then((res: string) => {
tokenTes.value = res;
});
return {
tokenTes,
documentsId,
};
},
});
</script>
<style lang="less" scoped></style>