|
|
@@ -16,6 +16,7 @@ import FmXR from './gate.threejs.xr';
|
|
|
import { animateCamera } from '/@/utils/threejs/util';
|
|
|
import useEvent from '../../../../utils/threejs/useEvent';
|
|
|
import { useModelFileStore } from '/@/store/modules/modelFile';
|
|
|
+import { getDictItemsByCode } from '/@/utils/dict';
|
|
|
// import { useGlobSetting } from '/@/hooks/setting';
|
|
|
|
|
|
// 模型对象、 文字对象
|
|
|
@@ -868,7 +869,8 @@ export const mountedThree = () => {
|
|
|
model.setEnvMap('test1.hdr');
|
|
|
model.renderer.toneMappingExposure = 0.9;
|
|
|
model.camera.position.set(100, 0, 1000);
|
|
|
- const dictCodes = useModelFileStore().getModelFileDataByKey('gate');
|
|
|
+ const store = useModelFileStore();
|
|
|
+ const dictCodes = store.getModelFileDataByKey('gate').length ? store.getModelFileDataByKey('gate') : getDictItemsByCode('gateStyle');
|
|
|
if (dictCodes && dictCodes.length > 0) {
|
|
|
for (let i = 0; i < dictCodes.length; i++) {
|
|
|
const dict = dictCodes[i];
|