Skip to content

Commit

Permalink
Merge branch 'dev-4.2.3'
Browse files Browse the repository at this point in the history
  • Loading branch information
HSunboy committed Jan 11, 2024
2 parents de91dd9 + 49f0cd7 commit 136872f
Show file tree
Hide file tree
Showing 36 changed files with 113 additions and 435 deletions.
2 changes: 1 addition & 1 deletion src/component/WindowManager/factory.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ export default function withConfirmModal(WrappedComponent: any) {
<div
style={{
// 减去 topbar 和 tabbar 高度
height: 'calc(100vh - 28px)',
height: '100%',
background: 'var(--background-secondry-color)',
position: 'relative',
overflow: 'auto',
Expand Down
2 changes: 1 addition & 1 deletion src/component/WindowManager/index.less
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
.menuList {
:global {
.ant-dropdown-menu {
max-height: 100vh;
max-height: calc(100vh - 50px);
overflow-y: auto;

.ant-dropdown-menu-item {
Expand Down
9 changes: 5 additions & 4 deletions src/layout/SpaceContainer/Sider/MineItem/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ const MineItem: React.FC<IProps> = function ({
const [changePasswordLoading, setChangePasswordLoading] = useState(false);
const recordRef = useRef<RecordRef>();
const havePasswordLogin = !!settingStore.serverSystemInfo?.passwordLoginEnabled;
const hasUserInfo = !haveOCP() && !isClient();
const showUserInfo = !isClient();
const allowEditUser = !haveOCP() && showUserInfo;
const RoleNames = user?.roles?.length
? user?.roles
?.filter((item) => item.enabled)
Expand Down Expand Up @@ -101,7 +102,7 @@ const MineItem: React.FC<IProps> = function ({
}}
menu={
<Menu selectedKeys={null} key="user" className={!isClient() ? styles.userMenu : ''}>
{hasUserInfo && (
{showUserInfo && (
<>
<Menu.Item key={'username'}>
<Tooltip placement="right" title={userName}>
Expand All @@ -117,7 +118,7 @@ const MineItem: React.FC<IProps> = function ({
</>
)}

{hasUserInfo && havePasswordLogin ? (
{allowEditUser && havePasswordLogin ? (
<Menu.Item
onClick={() => {
setChangePasswordModalVisible(true);
Expand Down Expand Up @@ -171,7 +172,7 @@ const MineItem: React.FC<IProps> = function ({
)}

<Menu.Divider />
{hasUserInfo && (
{allowEditUser && (
<Menu.Item onClick={handleLogout} key={'exit'}>
{formatMessage({ id: 'odc.Sider.MineItem.Exit' }) /*退出*/}
</Menu.Item>
Expand Down
1 change: 1 addition & 0 deletions src/layout/SpaceContainer/Sider/index.less
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@

.collapsedBtn {
position: absolute;
z-index: 1;
top: 300px;
right: -6px;
display: flex;
Expand Down
12 changes: 12 additions & 0 deletions src/page/Workspace/Layout/index.less
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,17 @@
height: 100%;
background-color: var(--background-primary-color);
border-left: 1px solid var(--divider-color);
&>:global(.ant-tabs) {
height: 100%;
&>:global(.ant-tabs-content-holder) {
height: 100%;
&>:global(.ant-tabs-content){
height: 100%;
&>:global(.ant-tabs-tabpane) {
height: 100%;
}
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
position: relative;
margin-top: 16px;
padding-left: 16px;
// height: calc(100vh - 133px);
// overflow: auto;

:global {
label {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ import styles from './index.less';
import { getDataSourceModeConfigByConnectionMode } from '@/common/datasource';

interface IProps {
fixedFooter?: boolean;
dataTypes: IDataType[];
partitionType?: IPartitionType;
disableCheckMaxValue?: boolean;
Expand Down Expand Up @@ -259,7 +258,6 @@ class CreateTablePartitionRuleForm extends Component<
const {
columns,
disablePartition,
fixedFooter,
selectColumns,
addMode,
selectColumnName,
Expand All @@ -286,9 +284,6 @@ class CreateTablePartitionRuleForm extends Component<
ref={this.form}
requiredMark={false}
layout="vertical"
style={{
height: fixedFooter ? 'calc(100vh - 157px)' : 'initial',
}}
onValuesChange={(_, v) => {
this.handleSubmit();
}}
Expand All @@ -303,7 +298,6 @@ class CreateTablePartitionRuleForm extends Component<
>
<div
style={{
height: fixedFooter ? 'calc(100vh - 213px)' : 'initial',
overflow: 'auto',
marginBottom: '24px',
}}
Expand Down Expand Up @@ -356,28 +350,10 @@ class CreateTablePartitionRuleForm extends Component<
</Form.Item>
{this.renderPartitions()}
</div>
{fixedFooter ? (
<>
<div className={styles.footer}>{this.renderButtons()}</div>
</>
) : null}
</Form>
</>
);
}

private renderButtons() {
return (
<Button
size="small"
type="primary"
onClick={this.handleSubmit}
className={styles.submitButton}
>
{formatMessage({ id: 'app.button.ok' })}
</Button>
);
}
}

export default CreateTablePartitionRuleForm;
1 change: 1 addition & 0 deletions src/page/Workspace/components/CreateTable/index.less
Original file line number Diff line number Diff line change
Expand Up @@ -41,5 +41,6 @@
position: relative;
flex-grow: 1;
flex-shrink: 1;
overflow-y: auto;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ export default class CreateTableColumnForm extends Component<
<div
className={styles.container}
style={{
height: fixedFooter ? 'calc(100vh - 115px)' : 'initial',
height: fixedFooter ? 'calc(100% - 40px)' : 'initial',
border: hideBorder ? 'none' : '1px solid var(--odc-border-color)',
}}
>
Expand Down

This file was deleted.

26 changes: 0 additions & 26 deletions src/page/Workspace/components/CreateTableIndexForm/index.less

This file was deleted.

Loading

0 comments on commit 136872f

Please sign in to comment.