Commit a5b6abd5 by Your Name

演示需要

parent 15bae5be
......@@ -10,8 +10,8 @@
# production
/build
/data-govern*
/data-govern*.zip
/data-govern-szse*
/data-govern-szse*.zip
# misc
.DS_Store
......
{
"name": "data-govern",
"name": "data-govern-szse",
"version": "0.1.0",
"lockfileVersion": 1,
"requires": true,
{
"name": "data-govern",
"name": "data-govern-szse",
"version": "0.1.0",
"private": true,
"dependencies": {
......@@ -79,5 +79,5 @@
"last 1 safari version"
]
},
"homepage": "http://myhost/data-govern"
"homepage": "http://myhost/data-govern-szse"
}
......@@ -188,7 +188,7 @@ export class App extends React.Component {
setGlobalState,
onGlobalStateChange
}}>
<Router basename={window.__POWERED_BY_QIANKUN__ ? '/data-govern' : '/'}>
<Router basename={window.__POWERED_BY_QIANKUN__ ? '/data-govern-szse' : '/'}>
<Switch>
<Route path={`${ContextPath}/login`} component={Signin} exact />
<Route path={`${ContextPath}/home`} component={Home} />
......@@ -229,7 +229,7 @@ export class App extends React.Component {
<Route path={'/center-home/data-model-action'} component={EditModel} exact />
<Route path={'/center-home/asset-detail'} component={AssetDetailPage} exact />
<Route path={'/center-home/model-review-detail'} component={ModelReviewDetail} />
<Route path={'/data-govern/model-compare-list'} component={ModelCompareList} />
<Route path={'/data-govern-szse/model-compare-list'} component={ModelCompareList} />
<Route path={'/data-model-product/physics-model'} component={Model} exact />
<Route path={'/data-model-product/physics-model-branch'} component={Model} exact />
......
......@@ -41,11 +41,11 @@ if (!window.__POWERED_BY_QIANKUN__) {
}
export async function bootstrap() {
console.log('[data-govern] react app bootstraped');
console.log('[data-govern-szse] react app bootstraped');
}
export async function mount(props) {
console.log('[data-govern] props from main framework', props);
console.log('[data-govern-szse] props from main framework', props);
storeTest(props);
render(props);
}
......@@ -56,6 +56,6 @@ export async function unmount(props) {
}
export async function update(props) {
console.log('[data-govern] props update from main framework', props);
console.log('[data-govern-szse] props update from main framework', props);
$hostParams.next(props?.data);
}
\ No newline at end of file
......@@ -16,7 +16,7 @@ export const isSzseEnv = true;
export const inputWidth = isSzseEnv?360:200;
export const ContextPath = '/data-govern';
export const ContextPath = '/data-govern-szse';
export const $hostParams = new Subject();
......@@ -569,13 +569,13 @@ export function openMetadataDetail(id) {
}
export function openModelDetail(id) {
window.open(`/data-govern/data-model-action?${Action}=detail&${ModelerId}=${id}`);
window.open(`/data-govern-szse/data-model-action?${Action}=detail&${ModelerId}=${id}`);
}
export function openNoticeDataModelById(id, versionId) {
window.open(`/data-govern/data-model-action?${Action}=detail&${ModelerId}=${id}&${NoticeModelerId}=${id}&${NoticeModelerLatestVersionId}=${versionId}`);
window.open(`/data-govern-szse/data-model-action?${Action}=detail&${ModelerId}=${id}&${NoticeModelerId}=${id}&${NoticeModelerLatestVersionId}=${versionId}`);
}
export function openNoticeDataModelByVersionId(id) {
window.open(`/data-govern/data-model-action?${Action}=detail&${ModelerId}=${id}&${NoticeModelerId}=${id}`);
window.open(`/data-govern-szse/data-model-action?${Action}=detail&${ModelerId}=${id}&${NoticeModelerId}=${id}`);
}
\ No newline at end of file
......@@ -534,7 +534,7 @@ const AssetAction = (props) => {
{
value => {
value?.onGlobalStateChange&&value?.onGlobalStateChange((state, prev) => {
if (state.message === 'data-govern-show-metadata-list-callback-message') {
if (state.message === 'data-govern-szse-show-metadata-list-callback-message') {
setMetadataId(state.data?.metadataId||'');
onMetadataChange && onMetadataChange(state.data?.metadataId||'');
......
......@@ -43,7 +43,7 @@ const ImportDirectory = (props) => {
}
const download = () => {
window.open("/data-govern/docs/AssetThemeModel.xlsx");
window.open("/data-govern-szse/docs/AssetThemeModel.xlsx");
}
const upload = async (ignoreRepeatPath = false) => {
......
......@@ -12,7 +12,7 @@ const ImportElement = (props) => {
const [ confirmLoading, setConfirmLoading ] = useState(false);
const downloadTemplate = () => {
window.open("/data-govern/docs/ElementModel.xlsx");
window.open("/data-govern-szse/docs/ElementModel.xlsx");
}
const uploadProps = {
......
......@@ -86,7 +86,7 @@ const FC = ({ value, onChange, readonly = true, terms = [] }) => {
>
<a onClick={() => {
app?.setGlobalState?.({
message: 'data-govern-show-metadata-message',
message: 'data-govern-szse-show-metadata-message',
data: item
})
}}
......
......@@ -1019,7 +1019,7 @@ const FC = (props) => {
if (refresh) {
setTimeout(() => {
window.open(`/data-govern/edit-assets?ids=${(selectedRows??[]).map(item => item.id).toString()}&elementIds=${(value??[]).toString()}&type=${AssetManageReference}`)
window.open(`/data-govern-szse/edit-assets?ids=${(selectedRows??[]).map(item => item.id).toString()}&elementIds=${(value??[]).toString()}&type=${AssetManageReference}`)
}, 300)
}
}}
......
......@@ -34,7 +34,7 @@ const FC = ({ value, onChange, readonly = true, terms = [] }) => {
>
<a onClick={() => {
app?.setGlobalState?.({
message: 'data-govern-show-metadata-message',
message: 'data-govern-szse-show-metadata-message',
data: decodeData[0]
})
}}
......@@ -48,7 +48,7 @@ const FC = ({ value, onChange, readonly = true, terms = [] }) => {
{
!readonly && <Button type='text' icon={<SettingFilled />} onClick={() => {
app?.setGlobalState?.({
message: 'data-govern-show-metadata-list-message',
message: 'data-govern-szse-show-metadata-list-message',
data: (IsArr(decodeData)&&decodeData.length>0) ? decodeData[0] : {}
})
}} />
......
......@@ -676,7 +676,7 @@ const FC = (props) => {
}
const onBatchAddToAssetClick = () => {
window.open(`/data-govern/edit-assets?ids=${(selectedRows??[]).map(item => item.id).toString()}&type=${ResourceManageReference}`)
window.open(`/data-govern-szse/edit-assets?ids=${(selectedRows??[]).map(item => item.id).toString()}&type=${ResourceManageReference}`)
}
const onDistributeTaskClick = () => {
......@@ -1537,7 +1537,7 @@ const FC = (props) => {
if (refresh) {
setTimeout(() => {
window.open(`/data-govern/edit-assets?ids=${(selectedRows??[]).map(item => item.id).toString()}&elementIds=${(value??[]).toString()}&type=${ResourceManageReference}`)
window.open(`/data-govern-szse/edit-assets?ids=${(selectedRows??[]).map(item => item.id).toString()}&elementIds=${(value??[]).toString()}&type=${ResourceManageReference}`)
}, 300)
}
}}
......
......@@ -390,7 +390,7 @@ const EditModel = (props) => {
}
const onCopy = () => {
window.open(`/data-govern/data-model-action?${Action}=add&${CatalogId}=${privilege?.catalogId??''}&${ModelerId}=${modelerId}`)
window.open(`/data-govern-szse/data-model-action?${Action}=add&${CatalogId}=${privilege?.catalogId??''}&${ModelerId}=${modelerId}`)
}
const onMetadataCompare = () => {
......
......@@ -123,7 +123,7 @@ const FC = (props) => {
relationModelerDatas?.length===0 ? '暂无信息' :
relationModelerDatas?.map((item, index) => (
<a className='mr-3' key={index} onClick={() => {
window.open(`/data-govern/data-model-action?${Action}=detail&${ModelerId}=${item.id}&${PermitCheckOut}=${item.permitCheckOut||false}&${Editable}=${item.editable||false}&${StateId}=${item.state?.id||''}&${ReadOnly}=false`);
window.open(`/data-govern-szse/data-model-action?${Action}=detail&${ModelerId}=${item.id}&${PermitCheckOut}=${item.permitCheckOut||false}&${Editable}=${item.editable||false}&${StateId}=${item.state?.id||''}&${ReadOnly}=false`);
}}>
{item.cnName}
</a>
......
......@@ -797,7 +797,7 @@ export const ImportActionTable = (props) => {
const onAddToStandardClick = (record) => {
app.setGlobalState?.({
message: 'data-govern-show-standard-create',
message: 'data-govern-szse-show-standard-create',
data: {
column: {...record, ...{ modelName: modelerData?.name, modelCnName: modelerData?.cnName }},
type: record?.isPossibleNewRecommendedDefinition?.type
......@@ -807,7 +807,7 @@ export const ImportActionTable = (props) => {
const onAddToWordClick = (record) => {
app.setGlobalState?.({
message: 'data-govern-show-standard-create',
message: 'data-govern-szse-show-standard-create',
data: {
column: record,
type: record?.isPossibleNewTerm?.type
......
......@@ -19,7 +19,7 @@ class ImportExcel extends React.Component {
}
downloadTemplate = () => {
window.open("/data-govern/docs/DataModel.xlsx");
window.open("/data-govern-szse/docs/DataModel.xlsx");
}
normFile = (e) => {
......
......@@ -659,9 +659,9 @@ const ModelTable = (props) => {
historyItem(currentItem);
} else if (key === 'copy') {
if (view !== 'branch') {
window.open(`/data-govern/data-model-action?${Action}=add&${CatalogId}=${(view==='dir')?(catalogId||''):''}&${ModelerId}=${currentItem.id}`);
window.open(`/data-govern-szse/data-model-action?${Action}=add&${CatalogId}=${(view==='dir')?(catalogId||''):''}&${ModelerId}=${currentItem.id}`);
} else {
window.open(`/data-govern/data-model-action?${Action}=add&${BranchId}=${catalogId??''}&${ModelerId}=${currentItem.id}`);
window.open(`/data-govern-szse/data-model-action?${Action}=add&${BranchId}=${catalogId??''}&${ModelerId}=${currentItem.id}`);
}
} else if (key === 'createTable') {
deployAction(currentItem);
......
......@@ -39,7 +39,7 @@ const VersionHistory = (props) => {
}
const onVersionItemClick = (version) => {
window.open(`/data-govern/data-model-action?${Action}=detail-version&${ModelerId}=${version.dataModelId||''}&${VersionId}=${version.id||''}`);
window.open(`/data-govern-szse/data-model-action?${Action}=detail-version&${ModelerId}=${version.dataModelId||''}&${VersionId}=${version.id||''}`);
}
return (
......
......@@ -27,9 +27,9 @@ const FC = (props) => {
callback: data => {
setWaiting(false)
if (type === 'notice') {
window.open(`/data-govern/data-model-action?${Action}=edit&${ModelerId}=${item?.id}&${ModelerMergeId}=${data?.id}&${ConflictItemId}=${item?.conflictItemId}`);
window.open(`/data-govern-szse/data-model-action?${Action}=edit&${ModelerId}=${item?.id}&${ModelerMergeId}=${data?.id}&${ConflictItemId}=${item?.conflictItemId}`);
} else {
window.open(`/data-govern/data-model-action?${Action}=edit&${ModelerId}=${item?.id}&${ModelerMergeId}=${data?.id}`);
window.open(`/data-govern-szse/data-model-action?${Action}=edit&${ModelerId}=${item?.id}&${ModelerMergeId}=${data?.id}`);
}
},
error: () => {
......
......@@ -328,7 +328,7 @@ const List = React.forwardRef(function ({ items }, ref) {
<Typography.Paragraph ellipsis={{
rows: 3,
}}><a onClick={() => {
window.open(`/data-govern/data-model-action?${Action}=detail&${ModelerId}=${record.id}&${PermitCheckOut}=${record.permitCheckOut||false}&${Editable}=${record.editable||false}&${StateId}=${record.state?.id||''}&${ReadOnly}=false`);
window.open(`/data-govern-szse/data-model-action?${Action}=detail&${ModelerId}=${record.id}&${PermitCheckOut}=${record.permitCheckOut||false}&${Editable}=${record.editable||false}&${StateId}=${record.state?.id||''}&${ReadOnly}=false`);
}}>{text}</a></Typography.Paragraph>
</Tooltip>
)
......
......@@ -378,7 +378,7 @@ class Model extends React.Component {
currentBranchId = catalogId
}
window.open(`/data-govern/data-model-action?${Action}=${importModalAction}&${CatalogId}=${currentCatalogId}&${ModelerId}=${modelerId}&${PermitCheckOut}=${record.permitCheckOut||false}&${Editable}=${record.editable||false}&${StateId}=${record.state?.id||''}&${ReadOnly}=${readOnly}&${BranchId}=${currentBranchId}`);
window.open(`/data-govern-szse/data-model-action?${Action}=${importModalAction}&${CatalogId}=${currentCatalogId}&${ModelerId}=${modelerId}&${PermitCheckOut}=${record.permitCheckOut||false}&${Editable}=${record.editable||false}&${StateId}=${record.state?.id||''}&${ReadOnly}=${readOnly}&${BranchId}=${currentBranchId}`);
});
}
......@@ -445,7 +445,7 @@ class Model extends React.Component {
onImportUnconditionBtnClick = () => {
const { catalogId, currentView } = this.state;
window.open(`/data-govern/data-model-action?${Action}=add&${CatalogId}=${(currentView==='dir')?(catalogId||''):''}`);
window.open(`/data-govern-szse/data-model-action?${Action}=add&${CatalogId}=${(currentView==='dir')?(catalogId||''):''}`);
}
onExportDDLBtnClick = () => {
......@@ -537,11 +537,11 @@ class Model extends React.Component {
if ((hints||[]).length > 0) {
setTimeout(() => {
window.open(`/data-govern/data-model-action?${Action}=add&${CatalogId}=${currentCatalogId}&${Hints}=${encodeURIComponent((hints||[]).join(','))}&${BranchId}=${branchId}`);
window.open(`/data-govern-szse/data-model-action?${Action}=add&${CatalogId}=${currentCatalogId}&${Hints}=${encodeURIComponent((hints||[]).join(','))}&${BranchId}=${branchId}`);
}, 1000);
} else {
setTimeout(() => {
window.open(`/data-govern/data-model-action?${Action}=add&${CatalogId}=${currentCatalogId}&${BranchId}=${branchId}`);
window.open(`/data-govern-szse/data-model-action?${Action}=add&${CatalogId}=${currentCatalogId}&${BranchId}=${branchId}`);
}, 1000);
}
}
......@@ -573,7 +573,7 @@ class Model extends React.Component {
}
wordData.content.slice(0, 5).forEach(data => {
window.open(`/data-govern/data-model-action?${Action}=add&${CatalogId}=${currentCatalogId}&${BranchId}=${branchId}&${ModelerData}=${encodeURIComponent(JSON.stringify(data))}`, '_blank');
window.open(`/data-govern-szse/data-model-action?${Action}=add&${CatalogId}=${currentCatalogId}&${BranchId}=${branchId}&${ModelerData}=${encodeURIComponent(JSON.stringify(data))}`, '_blank');
})
}, 2000);
......@@ -598,7 +598,7 @@ class Model extends React.Component {
branchId = catalogId
}
window.open(`/data-govern/data-model-action?${Action}=add&${CatalogId}=${currentCatalogId}&${BranchId}=${branchId}&${DDL}=${encodeURIComponent(ddl)}`, '_blank');
window.open(`/data-govern-szse/data-model-action?${Action}=add&${CatalogId}=${currentCatalogId}&${BranchId}=${branchId}&${DDL}=${encodeURIComponent(ddl)}`, '_blank');
}, 1000);
}
......@@ -753,7 +753,7 @@ class Model extends React.Component {
<Button
onClick={()=>{
value?.setGlobalState?.({
message: "data-govern-show-select-metadata",
message: "data-govern-szse-show-select-metadata",
data: {
// TODO
cb: async (val) => {
......
......@@ -158,11 +158,11 @@ const TemplateCURD = (props) => {
}
const editItem = (record) => {
window.open(`/data-govern/model-template-action?${Action}=edit&${TemplateId}=${record.id}`);
window.open(`/data-govern-szse/model-template-action?${Action}=edit&${TemplateId}=${record.id}`);
}
const detailItem = (record) => {
window.open(`/data-govern/model-template-action?${Action}=detail&${TemplateId}=${record.id}`);
window.open(`/data-govern-szse/model-template-action?${Action}=detail&${TemplateId}=${record.id}`);
}
const deleteItem = (record) => {
......@@ -187,7 +187,7 @@ const TemplateCURD = (props) => {
}
const onAddClick = () => {
window.open(`/data-govern/model-template-action?${Action}=add`);
window.open(`/data-govern-szse/model-template-action?${Action}=add`);
}
return (
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment