Skip to content

Commit

Permalink
Merge branch 'main' into feature_base_system_processConnection
Browse files Browse the repository at this point in the history
  • Loading branch information
anny1021 committed Jan 29, 2024
2 parents 4590059 + 9476fbc commit 498b7fa
Show file tree
Hide file tree
Showing 87 changed files with 31,297 additions and 3,320 deletions.
3 changes: 2 additions & 1 deletion packages/base/src/locale/en-US/dmsMenu.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,5 +52,6 @@ export default {
ruleManage: '规则管理',
system: '系统设置',
changeTheme: '模式切换'
}
},
copyRight: '© 2024 上海爱可生信息技术股份有限公司 版权所有'
};
3 changes: 2 additions & 1 deletion packages/base/src/locale/zh-CN/dmsMenu.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,5 +54,6 @@ export default {
ruleManage: '规则管理',
system: '系统设置',
changeTheme: '模式切换'
}
},
copyRight: '© 2024 上海爱可生信息技术股份有限公司 版权所有'
};
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,22 @@ import useDataExportDetailReduxManage from '../../../hooks/index.redux';
import { OverviewListAction, OverviewListColumn } from './column';
import { IGetDataExportTask } from '@actiontech/shared/lib/api/base/service/common';
import dms from '@actiontech/shared/lib/api/base/service/dms';
import { useCurrentProject } from '@actiontech/shared/lib/global';
import {
useCurrentProject,
useCurrentUser
} from '@actiontech/shared/lib/global';
import { useBoolean } from 'ahooks';
import { useMemo } from 'react';

const OverviewList: React.FC = () => {
const { taskInfos, updateCurTaskID } = useDataExportDetailReduxManage();
const { taskInfos, updateCurTaskID, workflowInfo } =
useDataExportDetailReduxManage();
const { projectID } = useCurrentProject();
const { uid } = useCurrentUser();

const isCreateWorkflowUser = useMemo(() => {
return uid === workflowInfo?.create_user?.uid;
}, [uid, workflowInfo?.create_user?.uid]);

const [
downloadLoading,
Expand Down Expand Up @@ -36,7 +46,11 @@ const OverviewList: React.FC = () => {
dataSource={taskInfos ?? []}
pagination={false}
columns={OverviewListColumn()}
actions={OverviewListAction(downloadLoading, downloadAction)}
actions={
isCreateWorkflowUser
? OverviewListAction(downloadLoading, downloadAction)
: undefined
}
onRow={(record: IGetDataExportTask) => {
return {
onClick() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,23 +30,22 @@ const ExportDetailPageHeaderAction: React.FC = () => {
<ExportDetailPageHeaderExtraStyleWrapper>
{messageContentHolder}

<div hidden={closeWorkflowButtonMeta.hidden}>
<BasicButton
disabled={closeWorkflowButtonMeta.loading}
loading={closeWorkflowButtonMeta.loading}
danger
onClick={closeWorkflowButtonMeta.action}
>
{t('dmsDataExport.detail.action.close.text')}
</BasicButton>

<Divider
type="vertical"
className="export-detail-page-header-divider"
/>
</div>

<EmptyBox if={!projectArchive}>
<div hidden={closeWorkflowButtonMeta.hidden}>
<BasicButton
disabled={closeWorkflowButtonMeta.loading}
loading={closeWorkflowButtonMeta.loading}
danger
onClick={closeWorkflowButtonMeta.action}
>
{t('dmsDataExport.detail.action.close.text')}
</BasicButton>

<Divider
type="vertical"
className="export-detail-page-header-divider"
/>
</div>
<BasicButton
hidden={rejectWorkflowButtonMeta.hidden}
onClick={rejectWorkflowButtonMeta.action}
Expand Down
8 changes: 8 additions & 0 deletions packages/base/src/page/Nav/Copyright/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import { useTranslation } from 'react-i18next';

const CopyrightInformation: React.FC = () => {
const { t } = useTranslation();
return <div className="copyright-information">{t('dmsMenu.copyRight')}</div>;
};

export default CopyrightInformation;
11 changes: 10 additions & 1 deletion packages/base/src/page/Nav/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ import EESideMenu from './SideMenu';
import CESideMenu from './SideMenu/index.ce';
// #endif

// #if [demo || ce]
import CopyrightInformation from './Copyright';
// #endif

const Nav: React.FC<{ children?: ReactNode }> = (props) => {
return (
<LayoutStyleWrapper>
Expand All @@ -16,7 +20,12 @@ const Nav: React.FC<{ children?: ReactNode }> = (props) => {
<CESideMenu />
{/* #endif */}

<div className="dms-layout-content">{props.children}</div>
<div className="dms-layout-content">
{props.children}
{/* #if [demo || ce] */}
<CopyrightInformation />
{/* #endif */}
</div>
</LayoutStyleWrapper>
);
};
Expand Down
84 changes: 84 additions & 0 deletions packages/shared/lib/Icon/common.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1597,3 +1597,87 @@ export const IconPosition = () => {
</CommonIconStyleWrapper>
);
};

export const IconCheckout = () => {
return (
<CommonIconStyleWrapper role="img" className="custom-icon">
<svg
viewBox="0 0 1365 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
id="mx_n_1706169255985"
width="18"
height="18"
>
<path
d="M1173.504 192.170667l-10.410667-11.093334a123.562667 123.562667 0 0 0-40.277333-28.842666 117.248 117.248 0 0 0-135.338667 28.842666L576 619.008 377.685333 407.722667a123.562667 123.562667 0 0 0-40.277333-28.842667 117.248 117.248 0 0 0-135.168 28.842667l-11.093333 11.264a137.386667 137.386667 0 0 0-36.010667 93.354666c0 35.157333 12.970667 68.608 36.010667 93.525334L477.866667 912.042667l10.24 11.264a120.832 120.832 0 0 0 87.893333 38.4 120.832 120.832 0 0 0 87.722667-38.4l9.728-11.264 500.053333-532.821334a139.264 139.264 0 0 0 0-187.050666z"
fill="#0e932e"
></path>
</svg>
</CommonIconStyleWrapper>
);
};

export const IconBookMark = () => {
return (
<svg
width="160"
height="140"
viewBox="0 0 160 140"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<g opacity="0.06">
<path
d="M20 103.333V13.3333C20 2.28759 28.9543 -6.66675 40 -6.66675H133.333C137.015 -6.66675 140 -3.68195 140 -8.10623e-05V120C140 123.682 137.015 126.667 133.333 126.667H43.3333C30.4467 126.667 20 116.22 20 103.333ZM126.667 113.333V93.3333H43.3333C37.8105 93.3333 33.3333 97.8106 33.3333 103.333C33.3333 108.856 37.8105 113.333 43.3333 113.333H126.667ZM66.6667 6.66659H40C36.3181 6.66659 33.3333 9.65139 33.3333 13.3333V82.2453C36.3642 80.8053 39.7547 79.9999 43.3333 79.9999H126.667V6.66659H113.333V59.9999L90 46.6666L66.6667 59.9999V6.66659Z"
fill="url(#paint0_linear_2190_5858)"
/>
</g>
<defs>
<linearGradient
id="paint0_linear_2190_5858"
x1="80"
y1="-6.66675"
x2="80"
y2="126.667"
gradientUnits="userSpaceOnUse"
>
<stop stopColor="#169E75" stopOpacity="0.4" />
<stop offset="1" stopColor="#169E75" />
</linearGradient>
</defs>
</svg>
);
};

export const IconCustomService = () => {
return (
<svg
width="160"
height="140"
viewBox="0 0 160 140"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<g opacity="0.06">
<path
d="M140 33.3333C143.536 33.3333 146.927 34.7381 149.428 37.2386C151.928 39.7391 153.333 43.1304 153.333 46.6667V73.3333C153.333 76.8695 151.928 80.2609 149.428 82.7614C146.927 85.2619 143.536 86.6667 140 86.6667H132.92C131.295 99.5553 125.022 111.408 115.278 120C105.535 128.592 92.9906 133.333 79.9998 133.333V120C90.6085 120 100.783 115.786 108.284 108.284C115.786 100.783 120 90.6087 120 80V40C120 29.3913 115.786 19.2172 108.284 11.7157C100.783 4.21426 90.6085 -1.33514e-05 79.9998 -1.33514e-05C69.3912 -1.33514e-05 59.217 4.21426 51.7156 11.7157C44.2141 19.2172 39.9998 29.3913 39.9998 40V86.6667H19.9998C16.4636 86.6667 13.0722 85.2619 10.5717 82.7614C8.07126 80.2609 6.6665 76.8695 6.6665 73.3333V46.6667C6.6665 43.1304 8.07126 39.7391 10.5717 37.2386C13.0722 34.7381 16.4636 33.3333 19.9998 33.3333H27.0798C28.7067 20.446 34.9804 8.59514 44.7237 0.00449276C54.4669 -8.58615 67.0102 -13.3262 79.9998 -13.3262C92.9895 -13.3262 105.533 -8.58615 115.276 0.00449276C125.019 8.59514 131.293 20.446 132.92 33.3333H140ZM51.7332 85.2333L58.7998 73.9267C65.1537 77.9069 72.5023 80.0121 79.9998 80C87.4974 80.0121 94.846 77.9069 101.2 73.9267L108.266 85.2333C99.7949 90.541 89.9968 93.3487 79.9998 93.3333C70.0029 93.3487 60.2048 90.541 51.7332 85.2333Z"
fill="url(#paint0_linear_2190_5865)"
/>
</g>
<defs>
<linearGradient
id="paint0_linear_2190_5865"
x1="79.9998"
y1="-13.3262"
x2="79.9998"
y2="133.333"
gradientUnits="userSpaceOnUse"
>
<stop stopColor="#2E6BE6" stopOpacity="0.4" />
<stop offset="1" stopColor="#2E6BE6" />
</linearGradient>
</defs>
</svg>
);
};
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,7 @@ import { useTranslation } from 'react-i18next';
import { CEIndexStyleWrapper } from './style';
import Icon from '@ant-design/icons';
import BasicButton from '../BasicButton';
import {
IconBookMark,
IconCustomService
} from '../Icons/EnterpriseFeatureDisplay';
import { IconBookMark, IconCustomService } from '../../Icon/common';
import { DMS_DEFAULT_WEB_TITLE } from '../../data/common';
import EmptyBox from '../EmptyBox';
import VersionComparison from './components/VersionComparison';
Expand Down
Loading

0 comments on commit 498b7fa

Please sign in to comment.