|
|
|
|
@ -1,6 +1,6 @@
|
|
|
|
|
import React, { useEffect, useState, useRef } from 'react';
|
|
|
|
|
import styles from './style/index.module.less';
|
|
|
|
|
import { Button, Select, Space, Message, Modal, Input } from '@arco-design/web-react';
|
|
|
|
|
import { Button, Select, Space, Message, Modal, Input, Empty } from '@arco-design/web-react';
|
|
|
|
|
import { IconFullscreen, IconFullscreenExit } from '@arco-design/web-react/icon';
|
|
|
|
|
import { useSelector, useDispatch } from 'react-redux';
|
|
|
|
|
import { getMyComponentList } from '@/api/componentBase';
|
|
|
|
|
@ -149,7 +149,8 @@ const ComponentCoding = () => {
|
|
|
|
|
|
|
|
|
|
const uri = getCodeServerUri();
|
|
|
|
|
// 使用传入的localProjectPath或默认值
|
|
|
|
|
const path = componentCoding.localProjectPath || '/000000/admin_testcode1/master';
|
|
|
|
|
const path = componentCoding.localProjectPath;
|
|
|
|
|
if (!path) return;
|
|
|
|
|
setServerUrl(`${uri}?folder=${codeServerFolderPre}${path}`);
|
|
|
|
|
}, [componentCoding]);
|
|
|
|
|
|
|
|
|
|
@ -267,7 +268,18 @@ const ComponentCoding = () => {
|
|
|
|
|
)}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
{serverUrl ?
|
|
|
|
|
(
|
|
|
|
|
<iframe width="100%" height="100%" frameBorder={0} src={serverUrl} ref={iframeRef} />
|
|
|
|
|
)
|
|
|
|
|
:
|
|
|
|
|
(
|
|
|
|
|
<div className={styles['empty-container']}>
|
|
|
|
|
<Empty
|
|
|
|
|
description="暂无组件编码,请选择需要编码的组件"
|
|
|
|
|
></Empty>
|
|
|
|
|
</div>
|
|
|
|
|
)}
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|